Skip to main content
POST
Find-or-create customer + post transaction in one call

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Idempotency-Key
string

Replay-safe request key. Repeated requests with the same value within 24h return the original response unchanged.

Maximum string length: 255

Body

application/json
identifier
object
required

Customer identifier block. At least ONE field must be present. Resolution order is fixed: card_serial → external_ref → email → phone. First match wins.

transaction
object
required
card_id
string

Optional. Defaults to the org's single ACTIVE card. If multiple ACTIVE cards exist, this is required (else 400 ambiguous_default_card).

create_customer_if_missing
boolean
default:true
customer_fields
object

Fields used when create_customer_if_missing is true and no existing customer matches the identifier.

Response

Existing transaction returned (external_transaction_id dedup hit).

customer
object
enrollment
object
transaction
object
wallet_passes
object | null
customer_created
boolean
enrollment_created
boolean
idempotent_replay
boolean

Set to true when the response is a replay of an existing transaction (external_transaction_id dedup hit). Absent on fresh creates.