Airwallex logo
Airwallex logoAirwallex logo

Issuing

Copy for LLMView as Markdown

You can simulate transactions on cards issued by Airwallex and KYC processes of cardholders. Find out more about generating card issuing transactions and cardholder status .

Endpoints
POST /api/v1/simulation/issuing/create
POST /api/v1/simulation/issuing/{transaction_id}/capture
POST /api/v1/simulation/issuing/refund
POST /api/v1/simulation/issuing/{transaction_id}/reverse
POST /api/v1/simulation/issuing/cardholders/{id}/pass_review
POST /api/v1/simulation/issuing/threeds/notify

Create a transaction for the provided card

POST /api/v1/simulation/issuing/create

Creates a transaction for the card_id (or card_number) provided, but does not capture the transaction. This is only available in the sandbox environment.

Request body
transaction_amountrequirednumber

Transaction amount

transaction_currencyrequiredstring

Currency of the transaction. Can only be one of USD, AUD, GBP, EUR, CAD, JPY, HKD, CNY, SGD, NZD, CHF

auth_codestring

Authorization code

card_idstring

Unique Identifier for card. Leave this blank if using card_number. If both card_number and card_id are provided, card_number will be used

card_numberstring

Card Number

merchant_category_codestring

Merchant category code

merchant_infostring

Merchant description

single_phaseboolean

Set this to true to combine a single transaction that both authorizes and clears the transaction request. Defaults to false if not set.

transaction_failure_reasonstring

Set this field to simulate a failed transaction with the specific failure reason. Can be one of: PIN_INVALID, CVV_INVALID, PIN_RETRIES_EXCEEDED, CARDHOLDER_VERIFICATION_FAILED, INVALID_EXPIRY_DATE, TRANSACTION_BLOCKED

transaction_idstring

Transaction id. Optional field used to associate the new authorization request with a previous transaction.

Response body - 201 Created
auth_codestring

Authorization Code

billing_amountnumber

Billing amount

billing_currencystring

Billing Currency

card_idstring

Unique Identifier for card

card_nicknamestring

The nickname of the card used

client_datastring

Client data stored against the card record

failure_reasonstring

Reason for transaction failure, only applicable if status is FAILED - one of ACCOUNT_INVALID, CARD_INVALID, INSUFFICIENT_FUNDS, LIMIT_EXCEEDED, MERCHANT_CATEGORY_NOT_ALLOWED, CURRENCY_NOT_ALLOWED, NOT_SUPPORTED, INTERNAL_ERROR

ACCOUNT_INVALID, CARDHOLDER_VERIFICATION_FAILED, CARD_INVALID, CURRENCY_NOT_ALLOWED, CVV_INVALID, INSUFFICIENT_FUNDS, INTERNAL_ERROR, INVALID_EXPIRY_DATE, LIMIT_EXCEEDED, MERCHANT_CATEGORY_NOT_ALLOWED, NOT_SUPPORTED, PIN_INVALID, PIN_RETRIES_EXCEEDED, REMOTE_AUTH_DECLINED, TRANSACTION_BLOCKED

masked_card_numberstring

Masked card number

merchantobject

Merchant of the card transaction

merchant.category_codestring

Merchant category code

merchant.citystring

Merchant city

merchant.countrystring

Merchant country

merchant.namestring

Merchant Name

network_transaction_idstring

The transaction unique identifier from VISA network

posted_datestring

Date transaction posted

retrieval_refstring

Transaction retrieval reference number. Data element 37 of an financial transaction message (https://en.wikipedia.org/wiki/ISO_8583)

statusstring

Transaction Status - one of APPROVED, PENDING, FAILED

transaction_amountnumber

Transaction amount

transaction_currencystring

Transaction currency

transaction_datestring

Transaction date

transaction_idstring

An unique id for this authorization, a uuid

transaction_typestring

Transaction type - one of AUTHORIZATION, CLEARING, REFUND, REVERSAL, ORIGINAL_CREDIT

Errors
Error statusDescription
400

invalid_argument

401

credentials_invalid

500

service_unavailable

POST /api/v1/simulation/issuing/create
$curl --request POST \
> --url 'https://api-demo.airwallex.com/api/v1/simulation/issuing/create' \
> --header 'Authorization: Bearer {{ACCESS_TOKEN}}' \
> --header 'Content-Type: application/json' \
> --data '{
> "auth_code": "123312",
> "card_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2",
> "card_number": "4242424242424242",
> "merchant_category_code": "0742",
> "merchant_info": "Example",
> "single_phase": true,
> "transaction_amount": 100,
> "transaction_currency": "AUD",
> "transaction_failure_reason": "CVV_INVALID",
> "transaction_id": "d8af1614-a6a1-4d45-aae7-6858fc6d9ede"
>}'
Response (201 Created)
1{
2 "auth_code": "000001",
3 "billing_amount": 100,
4 "billing_currency": "USD",
5 "card_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2",
6 "card_nickname": "<string>",
7 "client_data": "Some client data",
8 "failure_reason": "INSUFFICIENT_FUNDS",
9 "masked_card_number": "************4242",
10 "merchant": {
11 "category_code": "4829",
12 "city": "Melbourne",
13 "country": "Australia",
14 "name": "Merchant A"
15 },
16 "network_transaction_id": "3951729271768745",
17 "posted_date": "2018-03-22T16:08:02+00:00",
18 "retrieval_ref": "909916088001",
19 "status": "APPROVED",
20 "transaction_amount": 100,
21 "transaction_currency": "USD",
22 "transaction_date": "2018-03-21T16:08:02+00:00",
23 "transaction_id": "6c2dc266-09ad-4235-b61a-767c7cd6d6ea",
24 "transaction_type": "REFUND"
25}
Was this section helpful?

Capture the transaction with the provided id

POST /api/v1/simulation/issuing/{transaction_id}/capture

Capture a transaction that is currently in the 'PENDING' state. This is only available in the sandbox environment.

Parameters
transaction_idrequiredstring

Unique identifier of the transaction to capture.

Request body
merchant_infostring

Merchant description

transaction_amountnumber

Amount to capture. Providing an amount smaller than the full authorised amount will result in a partial capture of the indicated amount only. When not present, the full authorised amount will be captured.

Response body - 200 OK
auth_codestring

Authorization Code

billing_amountnumber

Billing amount

billing_currencystring

Billing Currency

card_idstring

Unique Identifier for card

card_nicknamestring

The nickname of the card used

client_datastring

Client data stored against the card record

failure_reasonstring

Reason for transaction failure, only applicable if status is FAILED - one of ACCOUNT_INVALID, CARD_INVALID, INSUFFICIENT_FUNDS, LIMIT_EXCEEDED, MERCHANT_CATEGORY_NOT_ALLOWED, CURRENCY_NOT_ALLOWED, NOT_SUPPORTED, INTERNAL_ERROR

ACCOUNT_INVALID, CARDHOLDER_VERIFICATION_FAILED, CARD_INVALID, CURRENCY_NOT_ALLOWED, CVV_INVALID, INSUFFICIENT_FUNDS, INTERNAL_ERROR, INVALID_EXPIRY_DATE, LIMIT_EXCEEDED, MERCHANT_CATEGORY_NOT_ALLOWED, NOT_SUPPORTED, PIN_INVALID, PIN_RETRIES_EXCEEDED, REMOTE_AUTH_DECLINED, TRANSACTION_BLOCKED

masked_card_numberstring

Masked card number

merchantobject

Merchant of the card transaction

merchant.category_codestring

Merchant category code

merchant.citystring

Merchant city

merchant.countrystring

Merchant country

merchant.namestring

Merchant Name

network_transaction_idstring

The transaction unique identifier from VISA network

posted_datestring

Date transaction posted

retrieval_refstring

Transaction retrieval reference number. Data element 37 of an financial transaction message (https://en.wikipedia.org/wiki/ISO_8583)

statusstring

Transaction Status - one of APPROVED, PENDING, FAILED

transaction_amountnumber

Transaction amount

transaction_currencystring

Transaction currency

transaction_datestring

Transaction date

transaction_idstring

An unique id for this authorization, a uuid

transaction_typestring

Transaction type - one of AUTHORIZATION, CLEARING, REFUND, REVERSAL, ORIGINAL_CREDIT

Errors
Error statusDescription
400

invalid_argument

401

credentials_invalid

500

service_unavailable

POST /api/v1/simulation/issuing/{transaction_id}/capture
$curl --request POST \
> --url 'https://api-demo.airwallex.com/api/v1/simulation/issuing/transaction_id/capture' \
> --header 'Authorization: Bearer {{ACCESS_TOKEN}}' \
> --header 'Content-Type: application/json' \
> --data '{
> "merchant_info": "Example",
> "transaction_amount": 100
>}'
Response (200 OK)
1{
2 "auth_code": "000001",
3 "billing_amount": 100,
4 "billing_currency": "USD",
5 "card_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2",
6 "card_nickname": "<string>",
7 "client_data": "Some client data",
8 "failure_reason": "INSUFFICIENT_FUNDS",
9 "masked_card_number": "************4242",
10 "merchant": {
11 "category_code": "4829",
12 "city": "Melbourne",
13 "country": "Australia",
14 "name": "Merchant A"
15 },
16 "network_transaction_id": "3951729271768745",
17 "posted_date": "2018-03-22T16:08:02+00:00",
18 "retrieval_ref": "909916088001",
19 "status": "APPROVED",
20 "transaction_amount": 100,
21 "transaction_currency": "USD",
22 "transaction_date": "2018-03-21T16:08:02+00:00",
23 "transaction_id": "6c2dc266-09ad-4235-b61a-767c7cd6d6ea",
24 "transaction_type": "REFUND"
25}
Was this section helpful?

Refund a transaction for the provided card

POST /api/v1/simulation/issuing/refund

Refunds a transaction. This is only available in the sandbox environment.

Request body
transaction_amountrequirednumber

Transaction amount

transaction_currencyrequiredstring

Currency of the transaction. Can only be one of USD, AUD, GBP, EUR, CAD, JPY, HKD, CNY, SGD, NZD, CHF

card_idstring

Unique Identifier for card. Leave this blank if using card_number. If both card_number and card_id are provided, card_number will be used

card_numberstring

Card Number

merchant_category_codestring

Merchant category code

merchant_infostring

Merchant description

transaction_idstring

Transaction id. Optional field used to associate the new authorization request with a previous transaction.

Response body - 200 OK
auth_codestring

Authorization Code

billing_amountnumber

Billing amount

billing_currencystring

Billing Currency

card_idstring

Unique Identifier for card

card_nicknamestring

The nickname of the card used

client_datastring

Client data stored against the card record

failure_reasonstring

Reason for transaction failure, only applicable if status is FAILED - one of ACCOUNT_INVALID, CARD_INVALID, INSUFFICIENT_FUNDS, LIMIT_EXCEEDED, MERCHANT_CATEGORY_NOT_ALLOWED, CURRENCY_NOT_ALLOWED, NOT_SUPPORTED, INTERNAL_ERROR

ACCOUNT_INVALID, CARDHOLDER_VERIFICATION_FAILED, CARD_INVALID, CURRENCY_NOT_ALLOWED, CVV_INVALID, INSUFFICIENT_FUNDS, INTERNAL_ERROR, INVALID_EXPIRY_DATE, LIMIT_EXCEEDED, MERCHANT_CATEGORY_NOT_ALLOWED, NOT_SUPPORTED, PIN_INVALID, PIN_RETRIES_EXCEEDED, REMOTE_AUTH_DECLINED, TRANSACTION_BLOCKED

masked_card_numberstring

Masked card number

merchantobject

Merchant of the card transaction

merchant.category_codestring

Merchant category code

merchant.citystring

Merchant city

merchant.countrystring

Merchant country

merchant.namestring

Merchant Name

network_transaction_idstring

The transaction unique identifier from VISA network

posted_datestring

Date transaction posted

retrieval_refstring

Transaction retrieval reference number. Data element 37 of an financial transaction message (https://en.wikipedia.org/wiki/ISO_8583)

statusstring

Transaction Status - one of APPROVED, PENDING, FAILED

transaction_amountnumber

Transaction amount

transaction_currencystring

Transaction currency

transaction_datestring

Transaction date

transaction_idstring

An unique id for this authorization, a uuid

transaction_typestring

Transaction type - one of AUTHORIZATION, CLEARING, REFUND, REVERSAL, ORIGINAL_CREDIT

Errors
Error statusDescription
400

invalid_argument

401

credentials_invalid

500

service_unavailable

POST /api/v1/simulation/issuing/refund
$curl --request POST \
> --url 'https://api-demo.airwallex.com/api/v1/simulation/issuing/refund' \
> --header 'Authorization: Bearer {{ACCESS_TOKEN}}' \
> --header 'Content-Type: application/json' \
> --data '{
> "card_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2",
> "card_number": "4242424242424242",
> "merchant_category_code": "0742",
> "merchant_info": "Example",
> "transaction_amount": 100,
> "transaction_currency": "AUD",
> "transaction_id": "d8af1614-a6a1-4d45-aae7-6858fc6d9ede"
>}'
Response (200 OK)
1{
2 "auth_code": "000001",
3 "billing_amount": 100,
4 "billing_currency": "USD",
5 "card_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2",
6 "card_nickname": "<string>",
7 "client_data": "Some client data",
8 "failure_reason": "INSUFFICIENT_FUNDS",
9 "masked_card_number": "************4242",
10 "merchant": {
11 "category_code": "4829",
12 "city": "Melbourne",
13 "country": "Australia",
14 "name": "Merchant A"
15 },
16 "network_transaction_id": "3951729271768745",
17 "posted_date": "2018-03-22T16:08:02+00:00",
18 "retrieval_ref": "909916088001",
19 "status": "APPROVED",
20 "transaction_amount": 100,
21 "transaction_currency": "USD",
22 "transaction_date": "2018-03-21T16:08:02+00:00",
23 "transaction_id": "6c2dc266-09ad-4235-b61a-767c7cd6d6ea",
24 "transaction_type": "REFUND"
25}
Was this section helpful?

Reverse the transaction with the provided id

POST /api/v1/simulation/issuing/{transaction_id}/reverse

Reverse a transaction that is currently in the 'PENDING' state. This is only available in the sandbox environment.

Parameters
transaction_idrequiredstring

Unique identifier of the transaction to reverse.

Request body
transaction_amountnumber

Amount to reverse. Providing an amount smaller than the full authorised amount will result in a partial reversal of the indicated amount only. When not present, the full authorised amount will be reversed.

Response body - 200 OK
auth_codestring

Authorization Code

billing_amountnumber

Billing amount

billing_currencystring

Billing Currency

card_idstring

Unique Identifier for card

card_nicknamestring

The nickname of the card used

client_datastring

Client data stored against the card record

failure_reasonstring

Reason for transaction failure, only applicable if status is FAILED - one of ACCOUNT_INVALID, CARD_INVALID, INSUFFICIENT_FUNDS, LIMIT_EXCEEDED, MERCHANT_CATEGORY_NOT_ALLOWED, CURRENCY_NOT_ALLOWED, NOT_SUPPORTED, INTERNAL_ERROR

ACCOUNT_INVALID, CARDHOLDER_VERIFICATION_FAILED, CARD_INVALID, CURRENCY_NOT_ALLOWED, CVV_INVALID, INSUFFICIENT_FUNDS, INTERNAL_ERROR, INVALID_EXPIRY_DATE, LIMIT_EXCEEDED, MERCHANT_CATEGORY_NOT_ALLOWED, NOT_SUPPORTED, PIN_INVALID, PIN_RETRIES_EXCEEDED, REMOTE_AUTH_DECLINED, TRANSACTION_BLOCKED

masked_card_numberstring

Masked card number

merchantobject

Merchant of the card transaction

merchant.category_codestring

Merchant category code

merchant.citystring

Merchant city

merchant.countrystring

Merchant country

merchant.namestring

Merchant Name

network_transaction_idstring

The transaction unique identifier from VISA network

posted_datestring

Date transaction posted

retrieval_refstring

Transaction retrieval reference number. Data element 37 of an financial transaction message (https://en.wikipedia.org/wiki/ISO_8583)

statusstring

Transaction Status - one of APPROVED, PENDING, FAILED

transaction_amountnumber

Transaction amount

transaction_currencystring

Transaction currency

transaction_datestring

Transaction date

transaction_idstring

An unique id for this authorization, a uuid

transaction_typestring

Transaction type - one of AUTHORIZATION, CLEARING, REFUND, REVERSAL, ORIGINAL_CREDIT

Errors
Error statusDescription
400

invalid_argument

401

credentials_invalid

500

service_unavailable

POST /api/v1/simulation/issuing/{transaction_id}/reverse
$curl --request POST \
> --url 'https://api-demo.airwallex.com/api/v1/simulation/issuing/transaction_id/reverse' \
> --header 'Authorization: Bearer {{ACCESS_TOKEN}}' \
> --header 'Content-Type: application/json' \
> --data '{
> "transaction_amount": 100
>}'
Response (200 OK)
1{
2 "auth_code": "000001",
3 "billing_amount": 100,
4 "billing_currency": "USD",
5 "card_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2",
6 "card_nickname": "<string>",
7 "client_data": "Some client data",
8 "failure_reason": "INSUFFICIENT_FUNDS",
9 "masked_card_number": "************4242",
10 "merchant": {
11 "category_code": "4829",
12 "city": "Melbourne",
13 "country": "Australia",
14 "name": "Merchant A"
15 },
16 "network_transaction_id": "3951729271768745",
17 "posted_date": "2018-03-22T16:08:02+00:00",
18 "retrieval_ref": "909916088001",
19 "status": "APPROVED",
20 "transaction_amount": 100,
21 "transaction_currency": "USD",
22 "transaction_date": "2018-03-21T16:08:02+00:00",
23 "transaction_id": "6c2dc266-09ad-4235-b61a-767c7cd6d6ea",
24 "transaction_type": "REFUND"
25}
Was this section helpful?

Pass review stage of a cardholder

POST /api/v1/simulation/issuing/cardholders/{id}/pass_review

Use this endpoint to bypass the RFI process. Learn about the cardholder status and Handle Cardholder Request for Information (RFI) . This is only available in the sandbox environment.

Parameters
idrequiredstring

Unique identifier of the cardholder

Response body - 200 OK

OK

Errors
Error statusDescription
400

not_found

401

credentials_invalid

500

service_unavailable

POST /api/v1/simulation/issuing/cardholders/{id}/pass_review
$curl --request POST \
> --url 'https://api-demo.airwallex.com/api/v1/simulation/issuing/cardholders/issuing_id/pass_review' \
> --header 'Authorization: Bearer {{ACCESS_TOKEN}}' \
> --header 'Content-Type: application/json'
Was this section helpful?

Send Threeds notification for the provided card

POST /api/v1/simulation/issuing/threeds/notify

Use this endpoint to send a threeds delegation mode notification for the provided card. Please note that this account must enable threeds delegation mode in notification configuration. This is only available in sandbox environment.

Request body
card_numberrequiredstring

Card Number

merchant_infoobject

Merchant Description

merchant_info.acquirer_idstring

Acquirer unique identifier

merchant_info.merchant_category_codestring

Merchant Category Code

merchant_info.merchant_country_codestring

Merchant Country Code

merchant_info.merchant_idstring

Merchant unique identifier

merchant_info.merchant_namestring

Merchant Name

merchant_info.merchant_urlstring

Merchant URL

Response body - 200 OK
statusstring

Notification Status

Errors
Error statusDescription
400

configuration_error or card_not_found

401

credentials_invalid

500

internal_error

POST /api/v1/simulation/issuing/threeds/notify
$curl --request POST \
> --url 'https://api-demo.airwallex.com/api/v1/simulation/issuing/threeds/notify' \
> --header 'Authorization: Bearer {{ACCESS_TOKEN}}' \
> --header 'Content-Type: application/json' \
> --data '{
> "card_number": "4012000300000088",
> "merchant_info": {
> "acquirer_id": "459535",
> "merchant_category_code": "1200",
> "merchant_country_code": "US",
> "merchant_id": "641025a8-5845-477e-b9da-06dcd28d0d28",
> "merchant_name": "happyPay",
> "merchant_url": "http://www.happypay.com/"
> }
>}'
Response (200 OK)
1{
2 "status": "SUCCESS"
3}
Was this section helpful?