Orders API Integration Guide
This guide is for partners building a white-label integration where your platform creates customer organisations, creates merchants, uploads complete order data through the Orders API, receives charge
Use this guide for COMPLETE Orders API integrations only. COMPLETE orders must use a CUSTOM_ORDERS integration. If you are enriching an existing Stripe, Adyen, Shopify, or other processor integration, use PARTIAL orders instead. See the Orders API reference.
Reference documentation
What you will build
Your integration should support this lifecycle:
Create one ChargebackStop organisation per customer.
Create one or more merchants inside that organisation.
Create a
CUSTOM_ORDERSintegration linked to the merchant or merchants.Upload
COMPLETEorders with card transaction identifiers that support chargeback alert matching.Create chargeback alert enrolments for Ethoca Alerts and/or Verifi RDR.
Receive
enrolment.created,enrolment.updated,alert.created, andalert.updatedwebhooks.Resolve actionable Ethoca alerts with
PATCH /v1/alerts/{alert_id}.Promote the same flow from a TEST partner account to a LIVE production partner account.
Environments and accounts
ChargebackStop uses the same API host for test and production:
The account mode controls whether records are TEST or LIVE.
Development
TEST partner account
Build API client, webhook receiver, order upload, and alert action workflows
Organisations created under a TEST partner become TEST organisations. Simulation endpoints work only with TEST organisations.
Production
LIVE partner account
Create real customer organisations, submit production orders, and receive real alerts
LIVE organisations cannot use simulation endpoints. Real enrolments must be approved/enabled before alerts arrive.
TEST IDs and LIVE IDs are separate. Do not carry org_, mrch_, int_, enrl_, ord_, or netalrt_ IDs from TEST into production. Store environment-specific mappings in your system.
Before you write code
Ask ChargebackStop for a TEST partner account. In that TEST account:
Open the partner dashboard.
Go to the partner settings or administrator group developer settings.
Create a TEST partner API key.
Add a TEST webhook endpoint for
enrolment.created,enrolment.updated,alert.created, andalert.updated.Reveal and store the webhook signing secret.
For local development, expose your webhook receiver through a temporary HTTPS URL, such as a tunnel, because webhook endpoint URLs must be HTTPS.
Authentication and access model
All API requests use a bearer token:
For partner-owned onboarding, create a partner-group API key in your partner dashboard. Admin partner-group keys can access all organisations under the partner account. Non-admin partner-group keys can access only organisations assigned to that group.
Use an admin partner-group key for automated customer onboarding because it can create organisations, merchants, and enrolments.
Required abilities for the full flow:
organisations:read,organisations:writemerchants:read,merchants:writeintegrations:read,integrations:writeorders:read,orders:write,orders:updateenrolments_v2:read,enrolments_v2:writealerts:read,alerts:writerulesets:read,rulesets:writeif you will create custom RDR resolution rulessimulations:alerts,simulations:enrollmentsfor TEST only
Use a non-admin partner-group key for steady-state operations against assigned organisations, such as uploading orders, reading alerts, and actioning alerts.
Restricted keys are useful once customer organisations and merchants already exist. They should not be used for fully automated onboarding unless your operating model deliberately separates setup from daily processing.
API keys are shown only once when created. Store them in your secrets manager immediately, never in source control, logs, or customer-visible configuration.
Data you should store
At minimum, store these mappings in your platform:
Customer account
organisation_id
Required for Orders, Alerts filters, Simulations, and Integrations.
Merchant/MID/CAID/provider account
merchant_id
Required for Integrations and Enrolments.
Orders feed connection
integration_id
Required for every COMPLETE order.
Alert provider enrolment
enrolment_id
Required for simulation, enrolment status tracking, and RDR ruleset assignment.
Order
order_id and reference_id
reference_id is your stable idempotency key for create. order_id is used for PATCH /v1/orders/{order_id}.
Alert
alert_id
Required for GET /v1/alerts/{alert_id} and PATCH /v1/alerts/{alert_id}.
Orders API requirements for alert matching
Send COMPLETE orders as soon as they are available, and backfill recent history before enabling real alert traffic. Agree the backfill window with ChargebackStop during onboarding.
Required order fields for COMPLETE mode:
type
Must be COMPLETE.
organisation_id
Customer organisation ID.
integration_id
CUSTOM_ORDERS integration ID.
reference_id
Stable unique order identifier from your system.
order_datetime
ISO 8601 order timestamp.
order_number
Customer-facing order number.
order_subtotal_amount_in_cents
Subtotal before tax.
order_currency
ISO 4217 currency code.
order_total_amount_in_cents
Total amount.
order_status
OPEN_PENDING, OPEN_PENDING_RETURN, CLOSED_COMPLETE, CLOSED_CANCELLED, or OTHER.
For alert matching, include at least one transaction per order.
Required transaction fields:
reference_id
Stable unique transaction identifier within the integration.
amount_in_cents
Transaction amount.
currency
ISO 4217 currency code.
payment_method_type
Usually CARD.
authorisation_status
Usually SETTLED for completed payments.
payment_method_reference_id
Your payment method or payment transaction reference.
authorised_at
ISO 8601 authorisation timestamp.
payment_method_card_brand
Required for card transactions, for example VISA or MASTERCARD.
payment_method_card_last_4
Required for card transactions.
Send as many matching identifiers as possible:
acquirer_reference_number
Send whenever available. This is the strongest matching identifier.
authorisation_code
Send whenever available, especially with card last 4.
payment_method_card_bin
Send whenever available, especially with card brand, last 4, amount, and currency.
Also send related refunds and disputes when you have them. These records help ChargebackStop identify invalid or already-refunded alerts.
Enrolment requirements
Create a separate enrolment for each chargeback alert product the customer will use. Save the returned enrolment_id; it is the identifier you will use for status tracking, TEST simulations, and RDR ruleset assignment.
Use type: ETHOCA_ALERT.
Required enrolment data:
merchant_ids
One or more merchant IDs from the same organisation.
ethoca_alert.descriptors
One or more billing descriptors.
ethoca_alert.descriptors[].descriptor
The descriptor text Ethoca should enrol.
ethoca_alert.descriptors[].match_type
STARTS_WITH or EXACT_MATCH.
Ethoca enrolment is descriptor based. Do not use ARN or BIN + CAID as the Ethoca enrolment identifier. ARN, authorisation code, BIN, last 4, amount, currency, and transaction dates belong on Orders API transaction records so alerts can be matched to uploaded orders.
Use type: VERIFI_RDR.
Required enrolment data:
merchant_ids
One or more merchant IDs from the same organisation.
verifi_rdr.bin and verifi_rdr.caid
Preferred for BIN + CAID enrolment. Some partners call this BIN + CID; the API field name is caid.
verifi_rdr.arns
Use this instead of BIN + CAID when the RDR enrolment is ARN based.
Provide either bin and caid together, or provide at least one ARN in arns.
By default, a Verifi RDR BIN + CAID enrolment is published without a custom ruleset. That means eligible RDR cases for that BIN + CAID follow the default RDR flow and are accepted/refunded at the network level. If the customer wants exceptions, create a platform-run resolution ruleset and attach it to the RDR enrolment_id before go-live.
Enrolments are created in PENDING. Treat the enrolment as live only after you receive enrolment.updated with status: "ENABLED" or a direct GET /v2/enrolments/{enrolment_id} returns ENABLED.
End-to-end TEST flow
Run this flow in a TEST partner account first.
Create a chargeback alert enrolment
Create one enrolment per product. The examples below use the same merchant, but production customers may need separate enrolments for different descriptors, BIN + CAID pairs, or ARN sets.
Ethoca enrolments use descriptors.
Example response:
Save the Ethoca enrolment_id.
Verifi RDR enrolments use either BIN + CAID or ARNs.
BIN + CAID example:
Example response:
ARN-based example:
Save the RDR enrolment_id. You will need it if the customer wants custom RDR decisioning through a ruleset.
RDR alerts resolve at the network level. By default, eligible RDR cases for an enrolled BIN + CAID are accepted/refunded. Configure an RDR ruleset before go-live only when the customer wants exceptions to that default flow.
Simulate an actionable chargeback alert
Use this to test alert webhooks and alert resolution. The simulator creates a test alert and triggers the same alert.created webhook flow as a non-simulated alert.
Example response:
The alert simulator validates alert API behavior, webhook delivery, and resolution flows. It does not perform Orders API transaction matching inline, so integration_id and integration_transaction_id can be null in simulator responses. For production matching readiness, also verify that real or ChargebackStop-coordinated matched test alerts include these fields when they match your uploaded orders.
Resolve the simulated alert
For a Custom Orders-only integration, ChargebackStop cannot refund through your processor. Your system should perform the refund, cancellation, or customer handling in your own platform first, then update the alert with the outcome.
If you refunded the customer:
If you want to accept/fight the dispute and did not refund:
Example response:
Webhook implementation
Create a partner webhook endpoint for:
enrolment.createdenrolment.updatedalert.createdalert.updated
Webhook endpoints must be HTTPS and should return a 2xx response within 20 seconds. Use the X-Idempotency-Key header and the event id to prevent duplicate processing. Retries use the same X-Idempotency-Key.
Webhook payloads put the domain object in data.object. For enrolment events, data.object matches the Enrolments API response shape and api_version is v2. For alert events, data.object matches the Alerts API response shape.
Verify signatures
To verify please refer to the Webhooks documentation.
Process enrolment webhooks
Use enrolment webhooks to manage whether a customer enrolment is live in your product.
Example enrolment.updated payload:
Recommended handling:
PENDING
Store the enrolment and show it as submitted, not live.
IN_PROGRESS
Show it as being configured by ChargebackStop or the alert provider.
ACTION_REQUIRED
Block go-live for that enrolment and show the customer-facing note to your operations team or customer success team.
ENABLED
Mark the enrolment live. Start expecting alerts for that product and identifier.
FAILED
Mark the enrolment failed and escalate with the note and enrolment ID.
CANCELLED, PAUSED, UNENROLLED
Mark the enrolment inactive. Stop treating the identifier as live for new alert traffic.
Webhook delivery can be retried and events may be processed out of order. Before showing an enrolment as live or blocked in a customer-facing workflow, fetch GET /v2/enrolments/{enrolment_id} and use that response as the current source of truth.
Process alert webhooks
Use this webhook processing pattern:
Verify
X-Signature.Store event
id,type,created_at,api_version, anddata.object.Deduplicate by event
id. You may also storeX-Idempotency-Keyfor delivery tracing.Return 2xx quickly.
Process the alert asynchronously.
Fetch the latest alert with
GET /v1/alerts/{alert_id}before taking irreversible action.
Example alert.created decision logic:
Alert resolution rules
Ethoca and Verifi RDR resolve differently.
Ethoca Alerts (ETHOCA_ALERT)
Alerts can arrive in ACTION_REQUIRED with action_required_deadline.
Decide quickly, perform any off-platform refund/cancellation first, then call PATCH /v1/alerts/{alert_id}.
Verifi RDR (VERIFI_RDR)
Alerts are resolved at the network level and arrive as RESOLVED or INVALID.
Configure RDR rules before go-live if needed. Do not expect an action-required workflow.
Ethoca alert resolution
For Custom Orders-only integrations, the usual manual actions are:
REFUND
You refunded the transaction in your own platform.
Alert is marked resolved with refunded outcome.
ACCEPT_DISPUTE
You did not refund and will accept or fight the dispute outside the alert workflow.
Alert is marked resolved with not-refunded outcome.
For Ethoca, refunding the customer in your own system is not enough. You must also action the alert through ChargebackStop before the deadline so the alert provider receives the outcome.
Use CANCEL and REFUND_AND_CANCEL only when your ChargebackStop setup has the processor/subscription context needed to support those actions, or when ChargebackStop confirms they fit your workflow.
Verifi RDR default decisioning
For Verifi RDR, the default path is intentionally simple:
Create a
VERIFI_RDRenrolment for the customer's BIN + CAID.Wait until the enrolment becomes
ENABLED.If no platform-run ruleset is attached to that RDR enrolment, eligible RDR cases for that BIN + CAID are accepted/refunded by default at the network level.
RDR alerts generally arrive in ChargebackStop after the network decision has already happened. They should be stored and reconciled, not routed into an ACTION_REQUIRED queue.
Customise Verifi RDR with a ruleset
Create a platform-run ruleset only when the customer wants exceptions to the default RDR refund flow. Attach the ruleset to the RDR enrolment_id.
RDR ruleset constraints:
Required API abilities
rulesets:read and rulesets:write.
Endpoint
POST /v1/rulesets/.
Enrolments
Use one or more VERIFI_RDR BIN + CAID enrolment IDs from the same organisation. Confirm with ChargebackStop before relying on custom rulesets for ARN-based RDR enrolments.
Ruleset count
Each enrolment can have one platform-run ruleset.
Outcomes for RDR
Use REFUND or ACCEPT_DISPUTE. REFUND_AND_CANCEL is published to Verifi as REFUND; handle cancellation in your own system. Do not use CANCEL for RDR decisioning.
Rule types
AMOUNT and DESCRIPTOR. Only one rule of each type is allowed per ruleset.
Amount currency
Must be USD.
Example: keep the default refund behavior for most RDR cases, but accept the dispute instead of refunding when the amount is greater than $100 or the descriptor starts with ACMEFIT HIGHVALUE.
Example response:
To update an existing ruleset:
Use
PATCH /v1/rulesets/{ruleset_id}forenrolment_ids,outcome, orjoin_operator.Use
PATCH /v1/rulesets/{ruleset_id}/rules/{rule_id}for rule criteria.Do not send
rulestoPATCH /v1/rulesets/{ruleset_id}; rule updates are handled by the nested rule endpoints.
Create and verify RDR rulesets before production go-live. Enrolment and ruleset changes are published to the RDR decisioning path asynchronously, so do not make last-minute rule changes during launch without coordinating with ChargebackStop.
Order update patterns
Create orders once with POST /v1/orders/. Use PATCH /v1/orders/{order_id} to add or update later lifecycle data such as refunds, disputes, delivery status, subscription status, or order communications.
Example refund update:
Do not generate a new reference_id when retrying the same order, transaction, refund, dispute, delivery, item, or subscription. Stable references let you reconcile duplicates and avoid creating conflicting records.
Error handling and retries
The Orders API uses partial success after schema validation. One valid order in a batch can be created even if another order in the same batch fails.
Handle these cases explicitly:
429 RATE_LIMITED
Retry with exponential backoff. Limits are 100 requests per minute per endpoint per organisation or partner group.
DUPLICATE_ORDER
Treat as a reconciliation case. Fetch the order with GET /v1/orders/?reference_id=<reference_id>.
INVALID_ORDER_TYPE
Ensure COMPLETE orders use a CUSTOM_ORDERS integration.
INVALID_INTEGRATION
Check integration_id, organisation access, and integration status.
MISSING_FIELD
Validate payloads before enqueueing. Required fields can depend on order mode and enabled product features.
422 schema validation
No orders were processed. Fix the top-level request shape or field types and retry.
5xx
Retry safely with the same reference_id values.
Sandbox acceptance checklist
Complete this checklist before asking ChargebackStop to move you to production.
Production launch checklist
When sandbox testing is complete, ChargebackStop will provision or enable your LIVE production partner account.
Create production credentials
In the LIVE partner account:
Create a new production partner API key.
Store it in your production secrets manager.
Register a production HTTPS webhook endpoint.
Select
enrolment.created,enrolment.updated,alert.created, andalert.updated.Reveal and store the webhook signing secret.
Do not reuse TEST API keys or TEST webhook secrets.
Submit production order history
Before alert traffic begins, backfill recent complete order history for each customer. Include transaction matching identifiers, refunds, and disputes wherever available.
Monitor:
Orders accepted vs failed
Duplicate references
Missing ARN/auth code/BIN coverage
Rate limiting
Payload validation errors
Create real chargeback alert enrolments
Create real Ethoca Alert and/or Verifi RDR enrolments using production descriptors, BIN/CAID, or ARNs.
For RDR, create any custom rulesets before go-live if the customer does not want the default accept/refund flow for every eligible BIN + CAID case.
Enrolments are created in PENDING. Treat an enrolment as live only after enrolment.updated or GET /v2/enrolments/{enrolment_id} returns status: "ENABLED".
Verify first production alerts
For the first real alerts:
Confirm your webhook receives the enrolment events and marks each live enrolment
ENABLED.Fetch the latest alert via
GET /v1/alerts/{alert_id}.Check whether
integration_idandintegration_transaction_idare present for matched alerts.Confirm your refund/accept-dispute workflow resolves Ethoca alerts before
action_required_deadline.Confirm
alert.updatedarrives after resolution.
Escalate unmatched alerts to ChargebackStop with the alert ID, order reference, transaction reference, ARN, auth code, card brand, BIN, last 4, amount, currency, and timestamps.
Operational recommendations
Send orders continuously, not only after an alert is received.
Keep webhook handlers fast. Verify, persist, enqueue, and return 2xx.
Use
enrolment.updatedandGET /v2/enrolments/{enrolment_id}to drive customer-facing enrolment status.Poll
GET /v1/alerts?status=ACTION_REQUIREDas a fallback if webhook delivery is interrupted.Alert your operations team well before
action_required_deadline.Treat
REFUNDas a declaration that your system has already refunded when using Custom Orders without a processor integration.Create RDR rulesets before go-live when the customer wants exceptions to the default RDR accept/refund behavior.
Keep TEST and LIVE credentials, webhook secrets, IDs, and queues separate.
Rotate API keys immediately after suspected exposure.
Last updated
Was this helpful?