Skip to content

Emulation

Emulation features are only available in Sandbox environment.

Bulb icon

Tip – You can also rely on webhooks

For operations that cannot be emulated in the Sandbox, webhook examples are provided.

Card Transactions

You can emulate CardTransactions using the following request.

Parameters

AttributeTypeDescription
publicToken stringThe public token of the Card to use for the Card Transaction.
transLink stringA unique reference used to associate the Card Transaction with a paymentId. Must be 100000000000000 or higher.
paymentStatusstringThe type of CardTransaction, which for simulation purposes can be A or S. See list of values.
datestringThe date of the CardTransaction, as seen in the authorizationIssuerTime attribute.
amountfloatThe amount of the CardTransaction, as seen it the paymentAmount and paymentLocalAmount attributes.
mccstringThe Merchant Category Code for this CardTransaction, allowing you to check your Card MCC restrictions.
merchantId stringThe Merchant's ID for this CardTransaction, allowing you to check your Card MID restrictions.
merchantName stringThe name of the merchant.
Bulb icon

Tip – You can emulate a complete flow

To emulate a complete flow, set a paymentStatus = A followed by a S while specifying the same transLink for both requests.

Learn more about the different transaction flows in the Transaction examples article.

Request

bash
curl -X POST {baseUrl}/simulation/cardtransactions \
	--header 'Authorization: Bearer {accessToken}' \
	--header 'Content-Type: application/json' \
	--data-raw '{payload}'

Here is a {payload} example:

json
{
	"publicToken": "103020378",
	"date": "2022-02-12 13:00:00",
	"amount": 15.90,
	"mcc": "8574",
	"merchantId": "3256",
	"merchantName": "Merchant Name",
	"paymentStatus": "A",
	"paymentCode": "100000000000004"
}

The request returns a 201 HTTP Status Code without any content and sends a cardtransaction.create webhook.

Note icon

Note – Disclaimers about this emulation

  • No impact on Wallet Balances: A balance.update webhook is sent, but values are set to 0.
  • No refunds and negative amount settlements support yet.