Create a buy order

Allows your customer to create a buy crypto order with Banxa. Upon success, the response will contain a checkout URL which will be unique for the order. The customer will be redirected to this URL to complete the checkout process, which will expire after 1 minute if a redirect does not occur.

Path Params
string
required

This is the partner code provided to you during onboarding. e.g. metamask.

Body Params
string

The payment method chosen by the user.

string
required

This is the crypto type the customer wants to buy.

string

This is the blockchain that is associated with the crypto token. If none is provided, then a default will be used.

string
required

This is the fiat type the customer wants to buy.

string
required

The amount of fiat the user wants to buy. Either fiatAmount OR cryptoAmount must be provided. If both are provided, then cryptoAmount will be used.

string
required

The amount of crypto the user wants to buy. Either fiatAmount OR cryptoAmount must be provided. If both are provided, then cryptoAmount will be used.

string
required

The user wallet address that Banxa will use to send the crypto.

string

Wallet tag or memo associated with the wallet address. This is required when the Customer's wallet address has a Memo or Tag such as BNB (Memo) and XRP (Tag).

string
required

The URL the user will be redirected to after the buy flow has been completed. If the case of an order failure or cancellation, then the returnUrl will be appended with the status e.g. /?status=failure, /?status=cancel

string

Your defined ID for associating an order with. e.g. you may use this to differentiate between channels such as Exchange, Wallet, Web, Mobile.

string

Free form string that you can use to send us any information that will be returned in the Get Orders endpoint

string
required

Unique customer reference provided by you. Used to check whether customer has completed KYC.

string

An order ID that you may define and will be returned to you in a Get Order call.

string

Allows you to configure the discount to your commission rate per order. This can be a promotion code such as XMAS or a way to differentiate between your customers.

string

The user's email address that can be used to pre-populate the Banxa form.

Headers
string
Defaults to application/json
string

This is the API Key that has been provided to you during onboarding.

Response

Language
LoadingLoading…
Response
Choose an example:
application/json