Submit Simulator Clearing
POST/api/simulator/clear
Test clearing a transaction on a simulated card network. A single clearing that references a prior authorization is the most common use case. The amount can be for the full or partial amount of the authorization.
Multiple Clearing
Multiple clearings can be submitted for a single authorization. Multiple
clearings has e-commerce use cases where clearing happens as items are
shipped. Clearing amounts are cumulative.
Use the clearingMode
field to simulate multiple clearings.
Clearing Mode:
Signals whether additional clearing messages are expected.
- final: No further clearing message is expected.
- multi-non-final: Additional clearing messages are expected.
- multi-final: This is the final of multiple clearing messages.
Request
- application/json
Body
required
- ClearWithAuthorization
- ClearWithoutAuthorization
oneOf
requestMsg returned by the Simulator Authorization endpoint
responseMsg returned by the Simulator Authorization endpoint
Possible values: [purchase
, refund
]
Transaction type.
Transaction amount as an integer in the smallest denomination of the currency.
Default value: USD
ISO 4217 currency code.
Possible values: Value must match regular expression ^[0-9]{16}$
Card number.
Possible values: Value must match regular expression ^[0-9]{6}$
Card expiry in YYYYMM format.
Possible values: Value must match regular expression ^[0-9]{3}$
Card CVV.
Possible values: [final
, multi-final
, multi-non-final
]
Possible values: [purchase
, refund
]
Transaction type.
Transaction amount as an integer in the smallest denomination of the currency.
Default value: USD
ISO 4217 currency code.
Possible values: Value must match regular expression ^[0-9]{16}$
Card number.
Possible values: Value must match regular expression ^[0-9]{6}$
Card expiry in YYYYMM format.
Possible values: Value must match regular expression ^[0-9]{3}$
Card CVV.
Possible values: [final
, multi-final
, multi-non-final
]
Responses
- 200
- 400
- 403
- application/json
- Schema
- Example (from schema)
Schema
XML formatted ISO 8583 message sent to the simulated card scheme
XML formatted ISO 8583 message returned from the simulated card scheme
ID of the transaction
{
"requestMsg": "string",
"responseMsg": "string",
"transactionId": 0
}
Request fields are invalid
- application/json
- Schema
- Example (from schema)
Schema
{
"statusCode": 400,
"statusName": "Bad Request",
"errorCode": "BAD_REQUEST",
"errors": [
"Expected string, received number"
]
}
No Authorization to access resource.
- application/json
- Schema
- Example (from schema)
Schema
{
"statusCode": 403,
"statusName": "Forbidden",
"errorCode": "FORBIDDEN",
"reason": "Unauthorized"
}