Skip to content

Delivery revocations

A delivery revocation permanently fences one exact piece of delivery configuration that can no longer be trusted: a method revision, a rate callback revision, a callback signing key, or one geography version of a Location. Active quotes that used it are revoked at once, current selections that used it are released before payment, and no new quote or selection can use it.

Use one during an incident: a leaked signing key, a callback revision returning wrong rates, a method revision with an unsafe price, or a Location that can no longer ship. A revocation can't be edited, deleted, or undone.

Revoke or change the configuration#

A configuration change decides what new quotes offer. Quotes already issued stay active until they expire, so a buyer can still select an option priced from the old revision. A revocation also withdraws what Flint has already offered.

You need toUse
Change a price, zone, URL, or other setting from now onPATCH the method or rate callback, which publishes a new revision. See delivery configuration.
Stop offering a method or callbackDeactivate or archive it.
Rotate an HMAC secret on a scheduleRotate the secret.
Stop buyers from selecting or paying with prices already quoted from bad configurationCreate a delivery revocation, then publish a corrected revision.

Choose a target#

Name what to fence in target: a target_type and the IDs that type takes. Requests and responses include only the fields for that target type. Any other field in target is rejected.

  • delivery_method_revision fences one method revision. Send delivery_method_id and delivery_method_revision_id. Find the revision as the method's current_delivery_method_revision_id, or as delivery_method_revision_id on one of a quote's methods.
  • delivery_rate_callback_revision fences one rate callback revision. Send delivery_rate_callback_id and delivery_rate_callback_revision_id. The current revision is the callback's current_delivery_rate_callback_revision_id.
  • delivery_rate_callback_signing_key fences one HMAC signing key. Send delivery_rate_callback_id and delivery_rate_callback_signing_key_id: the delivery_rate_callback_signing_key_id from callback creation or rotate-secret, or an ID in the Flint-Signing-Key-Ids header of a callback request. The key must be that callback's current or previous HMAC key; older keys aren't available as targets.
  • location_geography fences one geography version of a Location. Send location_id and location_geography_version: the Location's geography_version.

The parent must belong to your merchant and the same environment as your request. A revision must belong to the parent you name, and a geography version must have been recorded by that Location. An unknown target returns 404 RESOURCE_NOT_FOUND without changing configuration, quotes, or selections.

Each revocation fences exactly one revision, key, or geography version. Revisions you publish afterward aren't affected, so publishing a corrected revision is how you resume offering the method or callback. A Location's next geography_version is likewise unfenced. Older revocations created with delivery_method or delivery_rate_callback targets read back as delivery_method_revision or delivery_rate_callback_revision, with both parent and revision IDs.

Revoke the current revision#

Read the method or callback, inspect its current revision, then send both IDs. For a method, use current_delivery_method_revision_id:

JSON
{
  "target": {
    "target_type": "delivery_method_revision",
    "delivery_method_id": "dmet_01K1P6G4M7H2N8Q9R3S5T6V7WX",
    "delivery_method_revision_id": "dmetr_01K1P6G4M7H2N8Q9R3S5T6V7WY"
  },
  "reason": "unsafe_configuration"
}

Flint fences that exact revision even if someone publishes a new revision before your request arrives. A callback works the same way with delivery_rate_callback_id and current_delivery_rate_callback_revision_id. Revocation requests and responses have no expected_version, and delivery_method and delivery_rate_callback aren't accepted target types.

Create a revocation#

Send POST /v1/delivery-revocations, or call deliveryRevocations.create in the SDK. The operation is createDeliveryRevocation, with request schema CreateDeliveryRevocationRequest.

Every revocation needs a reason. It doesn't change what the revocation does: Flint records it and copies it to each revoked quote as revocation_reason, so choose the one your incident records and filters need.

reasonUse it when
unsafe_configurationA revision prices, routes, or promises delivery wrongly.
location_unavailableA Location can no longer fulfill from the geography it had.
credential_compromiseA signing secret leaked or may have.
legal_requirementA legal or regulatory obligation stops you offering the option.
otherNone of the above fits. Explain in merchant_note.

merchant_note is optional, from 1 to 2,048 characters. Use it to record who authorized the revocation or the incident it belongs to. Send an Idempotency-Key so that a retry returns the original revocation. A target can be revoked only once, so a retry with a new key returns 409 ALREADY_EXISTS with the existing revocation in details[0].current_resource. This also applies when the original revocation used a legacy target type. A duplicate creates no revocation and sends no second event.

cURL
curl -X POST https://api.withflintpay.com/v1/delivery-revocations \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: incident-2026-10-28-rate-revision" \
  -d '{
    "target": {
      "target_type": "delivery_rate_callback_revision",
      "delivery_rate_callback_id": "dcb_01K1P6G4M7H2N8Q9R3S5T6V7WX",
      "delivery_rate_callback_revision_id": "dcbr_01K1P6G4M7H2N8Q9R3S5T6V7WY"
    },
    "reason": "unsafe_configuration",
    "merchant_note": "Rate service returned $0.00 for overnight shipping"
  }'
Response
{
  "data": {
    "delivery_revocation_id": "drev_01K1P6G4M7H2N8Q9R3S5T6V7WZ",
    "target": {
      "target_type": "delivery_rate_callback_revision",
      "delivery_rate_callback_id": "dcb_01K1P6G4M7H2N8Q9R3S5T6V7WX",
      "delivery_rate_callback_revision_id": "dcbr_01K1P6G4M7H2N8Q9R3S5T6V7WY"
    },
    "reason": "unsafe_configuration",
    "merchant_note": "Rate service returned $0.00 for overnight shipping",
    "estimated_impact": {
      "active_quote_count": 12,
      "current_selection_count": 3
    },
    "created_at": "2026-10-28T17:42:05Z"
  },
  "request_id": "req_01KWM6AASYFSEP53E9W34N8J33"
}

estimated_impact counts the active quotes and current selections that used the target when the revocation was created. Later reads return the same counts. Store delivery_revocation_id with your incident record.

What a revocation changes#

AffectedResult
Active quotes that used the targetstatus becomes revoked at once. delivery_revocation_id names the revocation, revocation_reason repeats its reason, and revoked_at records when. Selecting from one returns 409 DELIVERY_REQUOTE_REQUIRED with reason quote_revoked. See quote status.
Selections in selected status that used the targetReleased the next time they're read, so payment can't use them. Quote and select again.
Selections in locked_for_payment or committed statusUnchanged. Committed orders keep their delivery history for audit and fulfillment.
New quotesSucceed without options whose method revision or dependencies are fenced. The affected candidate has type: unavailable and unavailable_reason: dependency_revoked. Merchant callers receive a dependency_revoked diagnostic with recommended_action: review_configuration and the method and revision IDs. Other methods remain available; if all methods are fenced, the quote has no available options.
New selectionsCan't use the fenced revision, key, or geography version.
New references to an affected methodRefused with 409 ACTION_NOT_ALLOWED, reason dependency_revoked. This covers adding it to checkout.default_delivery_method_ids in settings, a checkout session's or payment link's delivery_method_ids, a subscription plan's or offer's subscription_delivery_method_ids, a subscription's delivery.delivery_method_id, and a migration's to_delivery_method_id. details[0].blocking_resources names the method and the method, rate callback, or Location that holds the revoked revision, key, or address.
Existing referencesKept. Defaults, payment links, plans, offers, and subscriptions that already list the method keep it, and its status doesn't change. Checkouts show it as unavailable until you publish a corrected revision.
Subscription renewals on an affected methodHeld with delivery_hold.reason method_unavailable and subscription.delivery_action_required, without charging. fixable_by is merchant when no other method is offered, otherwise it follows the buyer's can_update_delivery. Subscriptions don't pin a revision: each renewal quotes the method's current revision, so publishing a corrected revision clears the hold at the next check. See When a renewal can't ship.
Test deliveries and connection checks on a revoked callback revision or keyRefused with 409 ACTION_NOT_ALLOWED, reason dependency_revoked.
A revoked signing keyFlint stops signing callback requests with it at once. Revoking the previous key during a rotation ends the overlap. Revoking the current key stops requests to the endpoint until you rotate, which Flint allows even during an overlap. See Rotate or revoke the HMAC secret.

Requoting after a revocation succeeds. Offer the new quote's remaining options instead of retrying the revoked quote. If a revocation happens while Flint creates a quote, Flint removes affected options before storing the quote.

Open checkout sessions keep their pinned revisions. A fenced method stays unavailable in that session, even after you publish a corrected revision. Create a new session to pin the corrected method or callback revision, or a Location's new geography version. Rotating a callback signing secret allows the callback to sign with the replacement key.

Recover#

A revocation never changes a method's or callback's status, so the method keeps reading active. To use it again, fix what the revocation fenced:

  • A method revision. PATCH the method with a revision field, such as the corrected configuration, to publish a new revision. A PATCH of only metadata, external_reference_id, or status keeps the revoked revision.
  • A rate callback revision. PATCH the callback's configuration or signing_methods to publish a new revision, even with unchanged values. Every method that prices with it recovers. A PATCH of only name, external_reference_id, or status keeps the revoked revision.
  • A signing key. Rotate the secret.
  • A Location's geography. Change the Location's address, which records a new geography_version.

New quotes, new references, and subscription renewals then use the method again. Until then, offer another delivery method.

The delivery_revocation.created webhook fires once for each new revocation and carries the revocation as GET /v1/delivery-revocations/{delivery_revocation_id} returns it. When fencing the current method or callback revision advances that resource's version, Flint also sends delivery_method.updated or delivery_rate_callback.updated in the same transaction. From then on, the method or callback reads delivery_revocation_id naming the revocation, while its status stays unchanged. Publishing a new revision ends a fence on the old revision, and delivery_revocation_id reads null again; an older revocation that names the resource without a revision still applies to the new revision and stays named. Use these events to alert the people handling the incident and to refresh any delivery options your storefront has cached.

Review revocations#

GET /v1/delivery-revocations returns revocations newest first. Filter by target_type and reason, sending several values as a comma-separated list or a repeated parameter, and bound created_at with created_after (inclusive) and created_before (exclusive). This request lists the rate callback revocations from a credential incident in October:

cURL
curl -G https://api.withflintpay.com/v1/delivery-revocations \
  -H "Authorization: Bearer YOUR_API_KEY" \
  --data-urlencode "target_type=delivery_rate_callback_signing_key,delivery_rate_callback_revision" \
  --data-urlencode "reason=credential_compromise" \
  --data-urlencode "created_after=2026-10-01T00:00:00Z" \
  --data-urlencode "created_before=2026-11-01T00:00:00Z"
JSON
{
  "data": [
    {
      "delivery_revocation_id": "drev_01K1P6G4M7H2N8Q9R3S5T6V7X0",
      "target": {
        "target_type": "delivery_rate_callback_signing_key",
        "delivery_rate_callback_id": "dcb_01K1P6G4M7H2N8Q9R3S5T6V7WX",
        "delivery_rate_callback_signing_key_id": "cbkey_3f9a1c2b7d4e5f60a1b2c3d4"
      },
      "reason": "credential_compromise",
      "merchant_note": "Secret committed to a public repository",
      "estimated_impact": {
        "active_quote_count": 4,
        "current_selection_count": 1
      },
      "created_at": "2026-10-14T09:12:30Z"
    }
  ],
  "request_id": "req_01KWM6AASYFSEP53E9W34N8J33"
}

To see why a quote was revoked, read the revocation its delivery_revocation_id names.

Errors#

  • HTTP 400
    param names the field. details[0].code is REQUIRED for a missing reason or a target ID the target_type needs, including target.delivery_rate_callback_id for a signing-key target. It's NOT_ALLOWED for a field the selected target type doesn't take. It's UNKNOWN_FIELD for the removed top-level expected_version. It's INVALID_VALUE for an unknown target_type or reason, where message lists the accepted values, or for an ID with the wrong prefix.
  • HTTP 404
    The parent doesn't exist for your merchant and environment, the revision belongs to another parent, the key isn't the callback's current or previous HMAC key, or the Location never recorded that geography version. param names the failed field, such as target.delivery_method_id, target.delivery_rate_callback_revision_id, target.delivery_rate_callback_signing_key_id, or target.location_geography_version. Check the parent and child IDs and your credential's environment. Nothing is revoked or changed, and no event is sent.
  • HTTP 409
    Reason dependency_revoked comes from the writes that add a reference to a delivery method, not from creating a revocation: the method's current revision, the rate callback revision or signing key it prices with, or the address of a Location it uses is revoked. details[0].blocking_resources names the method and what holds the revoked part. Publish a new revision of that resource, rotate its signing secret, or use another delivery method. Test deliveries and connection checks on a revoked rate callback revision or key return the same reason.
  • HTTP 409
    The exact target is already revoked, including a target originally fenced with a legacy target type. details[0].current_resource contains the existing revocation. Use it for your incident record; the duplicate request changes nothing and sends no second event.
Delivery configurationMethods, rate callbacks, revisions, and versions.Live delivery rates with a callbackSigning keys, rotation, and revoking a leaked key.Delivery quotesQuote status, including revoked quotes.

The Delivery revocation object#

A permanent fence on an exact delivery method revision, rate callback revision, callback signing key, or Location geography version. Quotes that depend on it are revoked, and selections that depend on it stop being current.

Returned by GET /v1/delivery-revocations/{delivery_revocation_id} and carried by the endpoints below.

Attributes

created_atstringRequired

When Flint created this permanent fence, as an RFC 3339 timestamp in UTC.

delivery_revocation_idstringRequired

Unique ID of this permanent delivery revocation.

estimated_impactobjectRequired

Counts of active quotes and provisional selections that depended on the target when the fence was created. Later reads keep these recorded counts.

merchant_notestring

Optional incident context recorded when this revocation was created.

reasonenumRequired

Why the dependency was permanently fenced.

  • unsafe_configuration
  • location_unavailable
  • credential_compromise
  • legal_requirement
  • other
targetone ofRequired

The parent and exact revision, HMAC signing key, or recorded geography version permanently fenced by this revocation.

JSON
{
  "created_at": "2026-08-02T16:00:00Z",
  "delivery_revocation_id": "drev_01K1P6G4M7H2N8Q9R3S5T6V7WX",
  "estimated_impact": {
    "active_quote_count": 1,
    "current_selection_count": 1
  },
  "reason": "unsafe_configuration",
  "target": {
    "location_geography_version": 1,
    "location_id": "loc_01K1P6G4M7H2N8Q9R3S5T6V7WX",
    "target_type": "location_geography"
  }
}

List delivery revocations#

GET/v1/delivery-revocations

Requires scope commerce.delivery.read or commerce.delivery.write

Rate limit: read

Returns permanent delivery revocations, newest first by created_at and delivery_revocation_id. Default order: created_at descending, then delivery_revocation_id descending.

Query parameters

page_sizeinteger

Maximum number of results to return, from 1 to 100. Defaults to 20.

page_tokenstring

Opaque, signed next_page_token from the previous response, bound to the list and caller. Omit on the first request. You may change `page_size` between pages. Reuse it with the same endpoint, filters, sort, and request context. Do not parse or construct tokens. An altered, invalid, expired, or mismatched token returns a validation error.

target_typearray of enum

Filter by revocation target type. Values are trimmed and deduplicated in first-seen order; empty or unknown entries are rejected. Values within this filter are ORed; separate filters are ANDed.

  • location_geography
  • delivery_rate_callback_signing_key
  • delivery_rate_callback_revision
  • delivery_method_revision
reasonarray of enum

Filter by revocation reason. Values are trimmed and deduplicated in first-seen order; empty or unknown entries are rejected. Values within this filter are ORed; separate filters are ANDed.

  • unsafe_configuration
  • location_unavailable
  • credential_compromise
  • legal_requirement
  • other
created_afterstring

Inclusive lower bound on created_at.

created_beforestring

Exclusive upper bound on created_at.

Response · 200

Delivery revocation page.

dataarray of objectRequired

Resource, collection, or operation result returned by this request.

metaobject

Additional information about this response.

next_page_tokenstring

Opaque token to send as `page_token` to retrieve the next page. Omitted when there is no next page.

request_idstringRequired

Identifier of this API request, used to correlate logs and support requests.

curl https://api.withflintpay.com/v1/delivery-revocations \
  -H "Flint-Version: 2026-09-07" \
  -H "Authorization: Bearer YOUR_API_KEY"

Delivery revocation page.

JSON
{
  "data": [
    {
      "created_at": "2026-08-02T16:00:00Z",
      "delivery_revocation_id": "drev_01K1P6G4M7H2N8Q9R3S5T6V7WX",
      "estimated_impact": {
        "active_quote_count": 1,
        "current_selection_count": 1
      },
      "reason": "unsafe_configuration",
      "target": {
        "location_geography_version": 1,
        "location_id": "loc_01K1P6G4M7H2N8Q9R3S5T6V7WX",
        "target_type": "location_geography"
      }
    }
  ],
  "meta": {
    "api_version": "2026-09-07"
  },
  "next_page_token": "page_2",
  "request_id": "req_01KWM6AASYFSEP53E9W34N8J33"
}

Create delivery revocation#

POST/v1/delivery-revocationsIdempotent

Requires scope commerce.delivery.write

Rate limit: sensitive_write

Permanently fences one exact delivery method revision, rate callback revision, callback HMAC signing key, or recorded Location geography version. Name both the parent and the exact child. Unknown targets return RESOURCE_NOT_FOUND without effects; a duplicate returns ALREADY_EXISTS with the existing revocation. Issued quotes are revoked immediately. Provisional selections are released before they can be used again.

Request body

merchant_notestring

Optional incident context retained with this revocation.

reasonenumRequired

Why this dependency must no longer be used.

  • unsafe_configuration
  • location_unavailable
  • credential_compromise
  • legal_requirement
  • other
targetone ofRequired

The parent and exact child identity to fence. Each target_type accepts only its own IDs.

Response · 201

Created emergency revocation.

dataobjectRequired

Resource, collection, or operation result returned by this request.

metaobject

Additional information about this response.

request_idstringRequired

Identifier of this API request, used to correlate logs and support requests.

curl -X POST https://api.withflintpay.com/v1/delivery-revocations \
  -H "Flint-Version: 2026-09-07" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: a-unique-key" \
  -d '{
    "reason": "unsafe_configuration",
    "target": {
      "location_geography_version": 1,
      "location_id": "loc_01K1P6G4M7H2N8Q9R3S5T6V7WX",
      "target_type": "location_geography"
    }
  }'

Get delivery revocation#

GET/v1/delivery-revocations/{delivery_revocation_id}

Requires scope commerce.delivery.read or commerce.delivery.write

Rate limit: read

Returns one permanent delivery revocation and its estimated impact at creation time.

Path parameters

delivery_revocation_idstringRequired

Flint delivery revocation ID. Must be a valid ID with prefix drev_. Malformed IDs return 400 INVALID_REQUEST with detail INVALID_VALUE; well-formed IDs that do not exist return 404 RESOURCE_NOT_FOUND.

Response · 200

Delivery revocation.

Same response as Create delivery revocation.

curl https://api.withflintpay.com/v1/delivery-revocations/drev_01KEZF7C007Q141XJ28YAAC87B \
  -H "Flint-Version: 2026-09-07" \
  -H "Authorization: Bearer YOUR_API_KEY"

Delivery revocation.

JSON
{
  "data": {
    "created_at": "2026-08-02T16:00:00Z",
    "delivery_revocation_id": "drev_01K1P6G4M7H2N8Q9R3S5T6V7WX",
    "estimated_impact": {
      "active_quote_count": 1,
      "current_selection_count": 1
    },
    "reason": "unsafe_configuration",
    "target": {
      "location_geography_version": 1,
      "location_id": "loc_01K1P6G4M7H2N8Q9R3S5T6V7WX",
      "target_type": "location_geography"
    }
  },
  "meta": {
    "api_version": "2026-09-07"
  },
  "request_id": "req_01KWM6AASYFSEP53E9W34N8J33"
}

Was this helpful?