Cancel a conversion
Use this step-by-step guide to amend an existing unsettled conversion. Only conversion cancellations are currently supported using the Conversion amendments API.
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.
- Both pre-funding mode and post-funding mode are supported for conversion amendments. Contact your Airwallex Account Manager to change your funding mode. For more information on funding modes, see Funding and Settlement models.
- Follow the Create a conversion tutorial to create a future-dated conversion and save the
conversion_id
returned in the response.
Step 1: (Optional) Create an indicative amendment quote
Call Create an amendment quote API to retrieve an indicative financial adjustment resulting from the amendment.
Example request
Example response
Step 2: Create an amendment
Call Create an amendment API API to create a conversion amendment on a booked but unsettled conversion. Provide the conversion_id
and specify type
as CANCEL
to cancel the conversion.
The financial adjustment resulting from the amendment is returned in the charges
object. A charge type will either be a FEE
or CREDIT
. A FEE
will debit your account with any associated FX loss and a CREDIT
will credit your account with any associated FX Gain. See Conversion Amendments for more information on how this is calculated.
If the response returns any errors, see Error codes to learn about the troubleshooting steps.
Example request
Example response
Step 3: Retrieve an amendment
You can retrieve details of a specific conversion amendment anytime using Retrieve an amendment API. If you want to retrieve details of all conversion amendments associated with your account, see List all amendments API.
Example request
Example response