Search...
Log inGet started
Airwallex logo
Home
Core API
Payments
Transactional FX
Payouts
Issuing
Back to home
OverviewHow Airwallex Payouts work
Payout network
Use cases
Batch transfers
Create a batch transfer
Batch transfer statuses
Retrieve batch transfersManage batch transfers
Test and go live
Older API versions

Create a batch transfer

Airwallex Batch Transfers allows you to create multiple payouts in bulk to streamline your transaction processing and reconciliation, and leverage different funding sources such as the Wallet or Linked Bank Account. Easily manage multiple payouts to recipients in various countries/regions and in various currencies to multiple beneficiaries for payroll runs and supplier payments. As a platform, you can bring your customers onto Airwallex and enhance your product offering by creating Batch Transfers on their behalf. Learn how to programmatically create batch transfers with our Batch Transfer API endpoints API in the following sections.

New feature: Airwallex supports batch transfers created via API to be routed through the transfer approval workflow set up on the Airwallex account. Learn more in Manage approvals for batch transfers.

Before you begin

  • Obtain your access token API by authenticating to Airwallex using your unique Client ID and API key. You will need the access token to make API calls.
  • Check out Payout Network for supported regions and currencies, and the country guides under it for more details on payment methods, delivery times, and other country specific details.
  • As a platform, you can call all Batch Transfers API endpoints on behalf of your connected accounts by specifying the connected account's open ID (in the format acct_xxxxxx) in the x-on-behalf-of header of your API request. To learn about how you can register as a platform and set up this solution, see Global Treasury and Global Finance.

Step 1: Create a batch transfer

Call Create a batch transfer API with the required funding source and batch information (name, remarks, request id, transfer date) to create a batch transfer. Please find below further considerations on some of the parameters:

  • funding_source: funding source details should only be provided in this object if the batch transfer is to be funded via direct debit from Linked Account. Do not specify any parameters for Wallet as the funding source.

    • id: Unique ID of your Linked Account as returned in Create a Linked Account API.
    • deposit_type: Should be either DIRECT_DEBIT or FASTER_DIRECT_DEBIT. Deposit type will default to DIRECT_DEBIT if not specified. See direct debit flight times to understand difference between the two deposit types.
  • transfer_date: current or future date (ISO 8601 format) for when the batch transfer should be processed if using Wallet as the funding source. If left blank, the transfer date will default to the earliest possible date. Please note that transfer_date cannot be specified when Linked Account is used as the funding source.

    Transfer items with the same source and payment currency can support transfer dates up to 120 days into the future; whereas transfer items with currency conversions can support transfer dates up to 2 days into the future (varies by currency pairs). Longer tenors up to 180 days (varies by currency pair) are possible with our FX forwards product for Australian or Hong Kong customers, but additional regulatory restrictions and application/review process may apply. Please confirm the acceptable value dates by currency pair with your Account Manager. Since all transfer items within a batch are scheduled to a single transfer date, you may get validation errors for transfer items due to invalid transfer dates.

    For batch transfers with approval flows, the transfer_date will be updated if it was approved after the original specified date; at which point the batch transfer status transitions to SCHEDULED and transfer_date is fixed.

In the response, you will see the batch transfer status is DRAFTING. Next, you can add transfer items (Step 3) to the batch you just created.

Example request

Shell

If you are registered as a platform account, you can call this endpoint on behalf of your connected accounts by specifying the open ID in the x-on-behalf-of header.

Example response

JSON

Step 2: Prepare required beneficiary information

Before adding transfer items to a batch, you will need to prepare the required beneficiary information, which can vary depending on the payout country/currency, payment method, local clearing system, beneficiary type.

Our dynamic schema API allows you to obtain precise field requirements specific to the intended payout scenario. Refer to the screenshot below on which fields you can specify to generate the schema.

dynamic schema bene

The dynamic schema comes in handy when you are checking for a handful of payout scenarios. To obtain our full schema for beneficiaries programmatically in a JSON payload, you can call Get the API schema API to retrieve the required fields and validation rules, and/or Get the form schema API to retrieve suggested specifications on the UI components to render the fields along with the corresponding validation rules. See Using API and form schemas to learn more.

Furthermore, beneficiary information can be saved beforehand and used directly when adding transfer items to a batch by specifying the beneficiary_id instead (see Step 3).

Step 3: Add items to a batch

After creating a batch transfer, you can call Add items to a batch API to add transfer items to a batch. You may add a maximum of 100 transfer items at a time, up to a maximum total of 1,000 transfer items per batch.

Each batch transfer item requires the same information required to create a payout. Please refer to Step 2 in Create a payout for further details. Note that you do not need to specify payment_date for each item as the transfer_date is set at the batch transfer level. If your funding source is a Linked Account, please make sure to specify the same source_currency for all items in the batch.

Example request

Shell

If you are registered as a platform account, you can call this endpoint on behalf of your connected accounts by specifying the open ID in the x-on-behalf-of header.

Total and valid item count

Within the response, there are two item counts to confirm the number of transfer items added to the batch:

  • Total_item_count: the total number of items in the batch.
  • Valid_item_count: the number of items that passed our validation schema in the batch.

If the two item counts equal each other, then all transfer items are valid and you can either get a quote for this batch (Step 4) or submit the batch (Step 7) directly.

If valid_item_count is less than total_item_count, you can still quote and submit valid items in the batch; alternatively, you can preview all items within the batch (Step 5) to identify the invalid items and delete items (Step 6) before submitting the batch (Step 7).

Step 4: Quote a batch transfer (optional)

After adding valid transfer items to the batch, you can call Quote a batch transfer API to get quotes to lock the conversion rates for valid items in the batch. Please note that this is not a required step.

  • If you have quoted before submitting the batch. You must always ensure to submit before the quotes expire; otherwise, you will receive a quote_expired error. In that case, you can call quote a batch transfer to obtain a new quote and submit the batch again;
  • If you have not quoted before submitting the batch, all transfer items will be quoted automatically upon submission and you can see the quote details in the response.

For batch transfers with approval flows, quotes will be updated if the batch transfer is approved after the quote expires; at which point the batch transfer status transitions to SCHEDULED, and quotes are fixed.

In the response, you will see a quote_summary with the following useful parameters:

  • expires_at: The expiration time of the quotes
  • quotes: Details of each quote based on currency pairs

Example request

Shell

If you are registered as a platform account, you can call this endpoint on behalf of your connected accounts by specifying the open ID in the x-on-behalf-of header.

Step 5: List all items within a batch (optional)

Call List all items within a batch API to preview all items added to the batch transfer. You can call this endpoint at any time, before or after submitting the batch. Please note that this is not a required step.

Example request

Shell

If you are registered as a platform account, you can call this endpoint on behalf of your connected accounts by specifying the open ID in the x-on-behalf-of header.

Details of each transfer item in the batch are returned in the response. Please find below further considerations on some parameters within the items array:

  • id: System generated ID for each item in the batch, which can be used to delete items (Step 6).
  • Errors: If the batch item status is VALIDATION_FAILED or BOOKING_FAILED. See Batch transfer item errors for detailed descriptions of each error code.
  • status: The status for each batch item, which can be one of VALIDATION_FAILED, VALIDATED, BOOKING, BOOKED, BOOKING_FAILED. See Batch transfer item statuses for detailed descriptions of each status.
  • transfer_draft: After obtaining a quote, you can preview the draft details of each transfer item before the batch transfer is BOOKED; after which this parameter is no longer available and you should call Get payment by ID API with transfer_id to retrieve transfer details.
  • transfer_id: System generated ID for each BOOKED item in the batch, which can be used to retrieve transfer details by calling Get payment by ID API.

Step 6: Delete items within a batch (optional)

Before submitting a batch transfer, i.e. the batch transfer status is DRAFTING, you can call Delete items within a batch API with item_ids to delete invalid or wrong items in the batch. Please note that this is not a required step.

Example request

Shell

If you are registered as a platform account, you can call this endpoint on behalf of your connected accounts by specifying the open ID in the x-on-behalf-of header.

Step 7: Submit a batch transfer

Once you have added valid items to the batch transfer, you can call Submit a batch transfer API to submit the batch.

  • If no approval is required, this batch will transition to SCHEDULED status and will be processed by Airwallex accordingly.
  • If approval is required, this batch will transition to IN_APPROVAL status.

In the response, you will see a funding object contains the following funding information:

  • deposit_type: If specified when creating the batch, the value can be DIRECT_DEBIT or FASTER_DIRECT_DEBIT.
  • failure_reason: If there is an error with the funding source, a failure reason will be returned. See Batch transfer direct debit deposit errors (async) for details.
  • funding_source_id: The unique ID of your Linked Account if funded by DIRECT_DEBIT or FASTER_DIRECT_DEBIT.
  • status: The funding status of this batch transfer. Please see details in Funding Statuses.

After submitting the batch transfer, please ensure sufficient balance is available in your Wallet or Linked Account to cover the batch transfer amount (including fees). Once the batch is successfully funded, the system will start to book single payouts, which can be retrieved by calling Get payment by ID API. See Payout statuses for further details of each payout item.

Example request

Shell

If you are registered as a platform account, you can call this endpoint on behalf of your connected accounts by specifying the open ID in the x-on-behalf-of header.

Fund deduction

Note: Applicable to batch transfers using Wallet as the funding source only.

Generally under the pre-funding workflow, funds will be immediately deducted from the Wallet when batch transfers are submitted (including future dated batch transfers). If a batch transfer was initially created and submitted for approval, funds will be deducted from the Wallet when the status of the batch transfer transitions to SCHEDULED. Please ensure that you have sufficient balance in your Wallet when creating batch transfers.

Alternatively under the post-funding workflow, certain customers without sufficient balance are permitted to create batch transfers in advance. Funds will be deducted from the Wallet on transfer date from 9am, on a first-in first-out basis based on the earliest transfer_date, and the earliest created_at time. Funding will be retried every 30 minutes if wallet balance is insufficient.

To learn more about fund deduction models, please see Funding and Settlement Models.

Batch transfer fee

The fee component of a batch transfer item (similar to a payout) is calculated by Airwallex and communicated back via fee_currency and fee_amount in the API response, while amount_payer_pays and amount_beneficiary_receives represent the actual amounts that you will pay and the recipient will receive respectively (with fees applied). If a batch transfer was initially created and submitted for approval, fee_amount, amount_payer_pays and amount_beneficiary_receives for each batch tiem are tentative based on the exchange rate at the time of creation until the batch transfer status changes to SCHEDULED, at which point the exchange rate is confirmed.

The batch transfer fee is set to be paid by the payer by default, while you can pass on the fees to the beneficiary instead by specifying BENEFICIARY for the fee_paid_by parameter in your request. See more details in required request information for a batch transfer item.

Errors

Airwallex uses conventional HTTP response codes API to indicate the success or failure of an API request.

A HTTP 400 status code indicates an error that has been triggered due to the information provided in the request. See Batch transfer error codes to learn about all possible errors associated with the HTTP 400 status when creating a batch transfer.

On this page