Airwallex logo

Reserves

Copy for LLMView as Markdown
POST /api/v1/reserves/createCreate a Reserve
POST /api/v1/reserves/unreserveCreate an Unreserve

Create a Reserve

POST /api/v1/reserves/create

Reserve balance. Deduct from Available balance and increase Reserve balance.

Request body
account_idrequiredstring

Airwallex account unique identifier.

amountrequirednumber

Amount of the reserve in currency, representing how much to reserve.

currencyrequiredstring

Currency (3-letter ISO-4217 code).

request_idrequiredstring

Unique request identifier. 1-50 characters long.

Response body - 201 Created
account_idstring

Airwallex account unique identifier specified in the request.

amountnumber

Amount of the reserve in currency specified in the request.

created_atstring

The time this reserve was created.

currencystring

Currency (3-letter ISO-4217 code) specified in the request.

request_idstring

Unique request identifier specified in the request.

reserve_idstring

Unique identifier for the reserve.

Errors
Error statusDescription
400

Possible errors: field_required, invalid_argument

401

Possible errors: credentials_invalid, credentials_expired

429

Too many requests

500

Service unavailable

POST /api/v1/reserves/create
$curl --request POST \
> --url 'https://api.sandbox.airwallex.com/api/v1/reserves/create' \
> --header 'Authorization: Bearer {{ACCESS_TOKEN}}' \
> --header 'Content-Type: application/json' \
> --data '{
> "account_id": "1936398",
> "amount": 10000,
> "currency": "AUD",
> "request_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2"
>}'
Response (201 Created)
1{
2 "account_id": "1936398",
3 "amount": 10000,
4 "created_at": "2018-03-22T16:08:02+1100",
5 "currency": "AUD",
6 "request_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2",
7 "reserve_id": "d9af1614-a6a1-4d45-aae7-6858fc6d9ede"
8}
Was this section helpful?

Create an Unreserve

POST /api/v1/reserves/unreserve

Unreserve balance. Deduct from Reserve balance and increase Available balance.

Request body
account_idrequiredstring

Airwallex account unique identifier.

amountrequirednumber

Amount of the unreserve in currency, representing how much to unreserve.

currencyrequiredstring

Currency (3-letter ISO-4217 code).

request_idrequiredstring

Unique request identifier. 1-50 characters long.

Response body - 201 Created
account_idstring

Airwallex account unique identifier specified in the request.

amountnumber

Amount of the unreserve in currency specified in the request.

created_atstring

The time this unreserve was created.

currencystring

Currency (3-letter ISO-4217 code) specified in the request.

request_idstring

Unique request identifier specified in the request.

unreserve_idstring

Unique identifier for the unreserve.

Errors
Error statusDescription
400

Possible errors: field_required, invalid_argument

401

Possible errors: credentials_invalid, credentials_expired

429

Too many requests

500

Service unavailable

POST /api/v1/reserves/unreserve
$curl --request POST \
> --url 'https://api.sandbox.airwallex.com/api/v1/reserves/unreserve' \
> --header 'Authorization: Bearer {{ACCESS_TOKEN}}' \
> --header 'Content-Type: application/json' \
> --data '{
> "account_id": "1936398",
> "amount": 10000,
> "currency": "AUD",
> "request_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2"
>}'
Response (201 Created)
1{
2 "account_id": "1936398",
3 "amount": 10000,
4 "created_at": "2018-03-22T16:08:02+1100",
5 "currency": "AUD",
6 "request_id": "7f687fe6-dcf4-4462-92fa-80335301d9d2",
7 "unreserve_id": "d9af1614-a6a1-4d45-aae7-6858fc6d9ede"
8}
Was this section helpful?