Order
You can create orders of one of the following types:
deposit
- depositdeposit_exchange
- deposit with exchangedeposit_exchange_withdraw
- deposit with exchange and withdrawalexchange
- exchangeexchange_withdraw
- exchange with withdrawalwithdraw
- withdrawal
The request to create an order differs depending on the order type. However, the created orders have the same set of fields.
Request
- Deposit
- Deposit with exchange
- Deposit with exchange and withdrawal
- Exchange
- Exchange with withdrawal
- Withdrawal
POST /v2/order/deposit HTTP/1.1
Content-Type: application/json
Accept: application/json; charset=utf-8
Api-key: {publicApiKey}
Signature: {signature}
{
"order_id": "merchant_unique_order_id",
"currency": "usdt",
"network": "trc20", // card, btc, erc20 ...
"amount": 10,
"callback_url": "", //optional
"description": "order for ...", //optional
"client_info": { //optional
"client_id": "id1234",
"client_ip": "127.0.0.1",
"client_email": "[email protected]"
}
}
Description of parameters in the request:
order_id
– Unique payment identifier in the merchant systemcurrency
– Order currencynetwork
– Deposit network, card for fiat currencies, blockchain name for cryptocurrenciesamount
– Deposit amountdescription
– Order description (optional)callback_url
– URL address for server-to-server message about order execution resultclient_info
– customer data in the merchant system: identifier, IP, email
POST /v2/order/deposit_exchange HTTP/1.1
Content-Type: application/json
Accept: application/json; charset=utf-8
Api-key: {publicApiKey}
Signature: {signature}
{
"order_id": "merchant_unique_order_id",
"currency_from": "usdt",
"network_from": "trc20",
"amount": 10,
"currency_to": "uah",
"callback_url": "", //optional
"description": "order for ...", //optional
"client_info": { //optional
"client_id": "id1234",
"client_ip": "127.0.0.1",
"client_email": "[email protected]"
}
}
Description of parameters in the request:
order_id
– Unique payment identifier in the merchant systemcurrency_from
– Deposit currencynetwork_from
– Deposit network, card for fiat currencies, blockchain name for cryptocurrenciesamount
– Deposit amountcurrency_to
– Currency into which the exchange takes placedescription
– Order description (optional)callback_url
– URL address for server-to-server message about order execution resultclient_info
– customer data in the merchant system: identifier, IP, email
POST /v2/order/deposit_exchange_withdraw HTTP/1.1
Content-Type: application/json
Accept: application/json; charset=utf-8
Api-key: {publicApiKey}
Signature: {signature}
{
"order_id": "merchant_unique_order_id",
"currency_from": "usdt",
"network_from": "trc20",
"amount": 29, | "amount_to": 0.0003,
"currency_to": "btc",
"network_to": "btc",
"wallet": "2N9MQVd2rQZF9TEE3SXHzjvBUNgFWr2qf6V",
"wallet_memo": "",
"wallet_details": {} | [] | null, //depends on network_to
"callback_url": "", //optional
"description": "order for ...", //optional
"client_info": { //optional
"client_id": "id1234",
"client_ip": "127.0.0.1",
"client_email": "[email protected]"
}
}
Description of parameters in the request:
order_id
– Unique payment identifier in the merchant systemcurrency_from
– Deposit currencynetwork_from
– Deposit network, card for fiat currencies, blockchain name for cryptocurrenciesamount
– Deposit amount.Instead of this amount, you can specify the amount to receive in the
amount_to
field so that the withdrawal will be exactly the specified amount. When you specify theamount_to
, the system calculates the required deposit amount, and further transactions are based on the actual deposit amount and the exchange rate at the time of exchange. In currency pairs where the exchange rate changes quickly, the actual withdrawal amount may differ from theamount_to
.currency_to
– Withdrawal currencynetwork_to
– Withdrawal network, card for fiat currencies, blockchain name for cryptocurrenciesdescription
– Order description (optional)wallet
– Wallet to which the withdrawal is made (card number or blockchain address)wallet_memo
– tag/memo of the address in the blockchain to which the payment is madewallet_details
– Parameter array (optional)wallet_details
is used for the following networksbank
– expected parameterbank_code
, for example:
{"bank_code": "123123"}
bank_ua
– withdrawal to IBAN of Ukrainian banks, the parametersrecipient_bank
,recipient_name
,taxpayer_number
are expected, for example:
{
"recipient_bank": "Super bank",
"recipient_name": "Name Surname",
"taxpayer_number": "1234567890"
}sepa
– withdrawal to IBAN of European banks, therecipient_email
,recipient_name
parameters are expected, for example:
{
"recipient_email": "[email protected]",
"recipient_name": "Name Surname"
}multiple_cards
– withdrawal to several cards, an array ofamount
andwallet
parameter pairs is expected, which determine what amount should be paid to which card, for example:
[{
"amount": 10,
"wallet": "4242424242424242"
},
{
"amount": 20,
"wallet": "4111111111111111"
}]callback_url
– URL address for server-to-server message about order execution resultclient_info
– customer data in the merchant system: identifier, IP, email
POST /v2/order/exchange HTTP/1.1
Content-Type: application/json
Accept: application/json; charset=utf-8
Api-key: {publicApiKey}
Signature: {signature}
{
"order_id": "merchant_unique_order_id",
"currency_from": "btc",
"currency_to": "usdt",
"amount": 0.001415,
"callback_url": "", //optional
"description": "order for ...", //optional
"client_info": { //optional
"client_id": "id1234",
"client_ip": "127.0.0.1",
"client_email": "[email protected]"
}
}
Description of parameters in the request:
order_id
– Unique payment identifier in the merchant systemcurrency_from
– Currency from which the exchange is madecurrency_to
– Currency into which the exchange takes placeamount
– Exchange amount in currencycurrency_from
description
– Order description (optional)callback_url
– URL address for server-to-server message about order execution resultclient_info
– customer data in the merchant system: identifier, IP, email
POST /v2/order/exchange_withdraw HTTP/1.1
Content-Type: application/json
Accept: application/json; charset=utf-8
Api-key: {publicApiKey}
Signature: {signature}
{
"order_id": "merchant_unique_order_id",
"currency_from": "uah",
"amount": 375.93, | "amount_to": 10,
"currency_to": "usdt",
"network_to": "trc20",
"delay_order_for_minutes": 5, //optional
"wallet": "Tvb4KtWABb9vyzMhiLm3cgFaE11MCZfvQu",
"wallet_memo": "",
"wallet_details": {} | [] | null, //depends on network_to
"callback_url": "", //optional
"description": "order for ...", //optional
"client_info": { //optional
"client_id": "id1234",
"client_ip": "127.0.0.1",
"client_email": "[email protected]"
}
}
Description of parameters in the request:
order_id
– Unique payment identifier in the merchant systemcurrency_from
– Currency from which the exchange is madeamount
– Exchange amount incurrency_from
.Instead of this amount, you can specify the amount to receive in the
amount_to
field so that the withdrawal will be exactly the specified amount. When you specify theamount_to
, the system calculates the required deposit amount, and further transactions are based on the actual deposit amount and the exchange rate at the time of exchange. In currency pairs where the exchange rate changes quickly, the actual withdrawal amount may differ from theamount_to
.currency_to
– Withdrawal currencynetwork_to
– Withdrawal network, card for fiat currencies, blockchain name for cryptocurrenciesdescription
– Order description (optional)wallet
– Wallet to which the withdrawal is made (card number or blockchain address)wallet_memo
– tag/memo of the address in the blockchain to which the payment is madewallet_details
– Parameter array (optional)wallet_details
is used for the following networksbank
– expected parameterbank_code
, for example:
{"bank_code": "123123"}
bank_ua
– withdrawal to IBAN of Ukrainian banks, the parametersrecipient_bank
,recipient_name
,taxpayer_number
are expected, for example:
{
"recipient_bank": "Super bank",
"recipient_name": "Name Surname",
"taxpayer_number": "1234567890"
}sepa
– withdrawal to IBAN of European banks, therecipient_email
,recipient_name
parameters are expected, for example:
{
"recipient_email": "[email protected]",
"recipient_name": "Name Surname"
}multiple_cards
– withdrawal to several cards, an array ofamount
andwallet
parameter pairs is expected, which determine what amount should be paid to which card, for example:
[{
"amount": 10,
"wallet": "4242424242424242"
},
{
"amount": 20,
"wallet": "4111111111111111"
}]callback_url
– URL address for server-to-server message about order execution resultclient_info
– customer data in the merchant system: identifier, IP, email
POST /v2/order/withdraw HTTP/1.1
Content-Type: application/json
Accept: application/json; charset=utf-8
Api-key: {publicApiKey}
Signature: {signature}
{
"order_id": "merchant_unique_order_id",
"currency": "btc",
"network": "btc",
"delay_order_for_minutes": 5, //optional
"wallet": "2N9MQVd2rQZF9TEE3SXHzjvBUNgFWr2qf6V",
"wallet_memo": "",
"wallet_details": {} | [] | null, //depends on network
"amount": 0.0025,
"callback_url": "", //optional
"description": "order for ...", //optional
"client_info": { //optional
"client_id": "id1234",
"client_ip": "127.0.0.1",
"client_email": "[email protected]"
}
}
Description of parameters in the request:
order_id
– Unique payment identifier in the merchant systemcurrency
– Order currencynetwork
– Withdrawal network, card for fiat currencies, blockchain name for cryptocurrenciesdelay_order_for_minutes
– Delay order execution for the specified number of minuteswallet
– Wallet to which the withdrawal is made (card number or blockchain address)wallet_memo
– tag/memo of the address in the blockchain to which the payment is madewallet_details
– Parameter array (optional)wallet_details
is used for the following networksbank
– expected parameterbank_code
, for example:
{"bank_code": "123123"}
bank_ua
– withdrawal to IBAN of Ukrainian banks, the parametersrecipient_bank
,recipient_name
,taxpayer_number
are expected, for example:
{
"recipient_bank": "Super bank",
"recipient_name": "Name Surname",
"taxpayer_number": "1234567890"
}sepa
– withdrawal to IBAN of European banks, therecipient_email
,recipient_name
parameters are expected, for example:
{
"recipient_email": "[email protected]",
"recipient_name": "Name Surname"
}multiple_cards
– withdrawal to several cards, an array ofamount
andwallet
parameter pairs is expected, which determine what amount should be paid to which card, for example:
[{
"amount": 10,
"wallet": "4242424242424242"
},
{
"amount": 20,
"wallet": "4111111111111111"
}]amount
– Withdrawal amountdescription
– Order description (optional)callback_url
– URL address for server-to-server message about order execution resultclient_info
– customer data in the merchant system: identifier, IP, email
Response
You should consider any non 200 or 400 HTTP status response as unexpected behavior.
For example, if you are getting 5xx http status during withdrawal create request, you should treat this withdrawal as possibly created.
You must check the status of this withdrawal by calling /v2/order/status
The success response object will contain a set of fields structured as follows:
- Deposit
- Deposit with exchange
- Deposit with exchange and withdrawal
- Exchange
- Exchange with withdrawal
- Withdrawal
HTTP/1.1 200 OK
Content-Type: application/json
{
/* The overall status of the request, not the order status */
"status": "success",
"data": {
"order_uuid": "99c7f491-62ea-47fa-89c8-6043720374bf",
"order_type": "deposit",
"user_order_id": "merchant_unique_order_id",
"description": null,
"expected_amount_from": "10",
"amount_from": null,
"currency_from": "usdt",
"network_from": "trc20",
"deposit_from_user": null | "fpid-e03682a76e65",
"wallet_from": null,
"wallet_memo_from": null,
"expected_amount_to": "9.9",
"amount_to": null,
"strict_withdrawal_amount": false,
"currency_to": "usdt",
"network_to": "trc20",
"withdraw_to_user": null,
"wallet_to": null,
"wallet_memo_to": null,
"wallet_to_details": null,
"wallet_to_transactions": [],
"amount_from_fee": "0.1",
"amount_to_fee": null,
"deposit_url": null,
"deposit_address": "TT8y4xoTZ9yUL7FTqnC5z1Gb9ZTCvQDhHz",
"deposit_memo": null,
"deposit_address_title": null,
"deposit_address_initial_order_uuid": null,
"blockchain_deposit_hash": null,
"blockchain_withdrawal_hash": null,
"exchange_rate_initial": null,
"exchange_rate_actual": null,
"client_info": {
"client_id": "id1234",
"client_ip": "127.0.0.1",
"client_email": "[email protected]"
},
/* Order status */
"status": "new",
"error_code": 0,
"error_message": "",
"created_at": "1970-01-01 14:48:53",
"updated_at": "1970-01-01 14:48:54",
"finalized_at": null,
"start_order_at": null,
"currency_from_precision": 2,
"currency_to_precision": 2
}
}
Description of parameters in the response:
order_uuid
– Order ID in the FlyPay systemorder_type
– Order typeuser_order_id
– Unique payment identifier in the merchant systemdescription
– Order descriptionexpected_amount_from
– Expected deposit amountamount_from
– Actual deposit amountcurrency_from
– Deposit currencynetwork_from
– Deposit networkdeposit_from_user
– User ID in the system FlyPay, if the replenishment is a result of a transfer, otherwise nullwallet_from
– Wallet from which the deposit was made (card number or blockchain address)wallet_memo_from
– tag/memo of the address in the blockchain from which the deposit was madeexpected_amount_to
– Expected amount credited to the merchant balanceamount_to
– Actual amount added to the merchant's balancestrict_withdrawal_amount
– Used for exchanges with withdrawalscurrency_to
– Currency of crediting to the merchant balancenetwork_to
– Payment networkwithdraw_to_user
– User ID in the system FlyPay, if the withdrawal is a result of a transfer, otherwise nullwallet_to
– nullwallet_memo_to
– nullwallet_to_details
– Can only be used in withdrawal orderswallet_to_transactions
– Can only be used in withdrawal ordersamount_from_fee
– Commission amountamount_to_fee
– nulldeposit_url
– The URL to which the client should be redirected to make a depositdeposit_address
– The address on the blockchain to which the deposit should be sentdeposit_memo
– tag/memo of the address in the blockchain to which the deposit should be sentdeposit_address_title
– The name of the deposit address, if it is a permanent deposit address, a name has been created for itdeposit_address_initial_order_uuid
– order_uuid of the first order in the system where this deposit address was used, if anyblockchain_deposit_hash
– Blockchain transaction hash for a completed cryptocurrency depositblockchain_withdrawal_hash
– nullexchange_rate_initial
– Expected exchange rate when creating an order (for orders with exchange)exchange_rate_actual
– Actual exchange rate (for orders with exchange)status
– Order status (new)error_code
– Error codeerror_message
– Error message textcreated_at
– Date and time of order creation in the format "Y-m-d H:i:s"updated_at
– Date and time of order update in the format "Y-m-d H:i:s"finalized_at
– Date and time of order finalization in the format "Y-m-d H:i:s"start_order_at
– Used only for withdrawals, order execution start date and time in the format "Y-m-d H:i:s" | nullcurrency_from_precision
– Deposit or exchange currency precision, number of decimal placescurrency_to_precision
– Withdrawal currency precision, number of decimal places
HTTP/1.1 200 OK
Content-Type: application/json
{
/* The overall status of the request, not the order status */
"status": "success",
"data": {
"order_uuid":"3e7d0f84-d655-4069-991c-ad4739874ca5",
"order_type":"deposit_exchange",
"user_order_id":"merchant_unique_order_id ",
"description": null,
"expected_amount_from":"10",
"amount_from":null,
"currency_from":"usdt",
"network_from":"trc20",
"deposit_from_user": null,
"wallet_from":null,
"wallet_memo_from":null,
"expected_amount_to":"370.06",
"amount_to":null,
"strict_withdrawal_amount": false,
"currency_to":"uah",
"network_to":null,
"withdraw_to_user": null,
"wallet_to":null,
"wallet_memo_to":null,
"wallet_to_details": null,
"wallet_to_transactions": [],
"amount_from_fee":"0",
"amount_to_fee":null,
"deposit_url":null,
"deposit_address":"TVb4KtWABb9vyzMhiLm3cgFaE11MCZfvQu",
"deposit_memo":null,
"blockchain_deposit_hash": null,
"blockchain_withdrawal_hash": null,
"exchange_rate_initial":"37.006",
"exchange_rate_actual":null,
/* Order status */
"status":"new",
"error_code":0,
"error_message":"",
"created_at":"1970-01-01 17:11:28",
"updated_at":"1970-01-01 17:11:29",
"finalized_at":null,
"start_order_at": null,
"currency_from_precision": 2,
"currency_to_precision": 2
}
}
Description of parameters in the response:
-
order_uuid
– Order ID in the FlyPay system -
order_type
– Order type -
user_order_id
– Unique payment identifier in the merchant system -
description
– Order description -
expected_amount_from
– Expected deposit amount -
amount_from
– Actual deposit amount -
currency_from
– Deposit currency -
network_from
– Deposit network -
deposit_from_user
– null -
wallet_from
– Wallet from which the deposit was made (card number or blockchain address) -
wallet_memo_from
– tag/memo of the address in the blockchain from which the deposit was made -
expected_amount_to
– Expected amount of the exchange result -
amount_to
– Actual amount of the exchange result -
strict_withdrawal_amount
– false -
currency_to
– The currency into which the exchange takes place -
network_to
– null -
withdraw_to_user
– null -
wallet_to
– null -
wallet_memo_to
– null -
wallet_to_details
– null -
wallet_to_transactions
– null -
amount_from_fee
– Commission amount in deposit currency -
amount_to_fee
– null -
deposit_url
– The URL to which the client should be redirected to make a deposit -
deposit_address
– The address on the blockchain to which the deposit should be sent -
deposit_memo
– tag/memo of the address in the blockchain to which the deposit should be sent -
deposit_address_title
– The name of the deposit address, if it is a permanent deposit address, a name has been created for it -
deposit_address_initial_order_uuid
– order_uuid of the first order in the system where this deposit address was used, if any -
blockchain_deposit_hash
– Blockchain transaction hash for a completed cryptocurrency deposit -
blockchain_withdrawal_hash
– null -
exchange_rate_initial
– Expected exchange rate when creating an order -
exchange_rate_actual
– Actual exchange rate -
status
– Order status (new) -
error_code
– Error code -
error_message
– Error message text -
created_at
– Date and time of order creation in the format "Y-m-d H:i:s" -
updated_at
– Date and time of order update in the format "Y-m-d H:i:s" -
finalized_at
– Date and time of order finalization in the format "Y-m-d H:i:s" -
start_order_at
– null -
currency_from_precision
– Deposit or exchange currency precision, number of decimal places -
currency_to_precision
– Withdrawal currency precision, number of decimal places
HTTP/1.1 200 OK
Content-Type: application/json
{
/* The overall status of the request, not the order status */
"status": "success",
"data": {
"order_uuid":"3e7d0f84-d655-4069-991c-ad4739874ca5",
"order_type":"deposit_exchange_withdraw",
"user_order_id":"merchant_unique_order_id",
"description": null,
"expected_amount_from":"29",
"amount_from":null,
"currency_from":"usdt",
"network_from":"trc20",
"deposit_from_user": null,
"wallet_from":null,
"wallet_memo_from":null,
"expected_amount_to":"0.00103988",
"amount_to":null,
"strict_withdrawal_amount": false | true,
"currency_to":"btc",
"network_to":"btc",
"withdraw_to_user": null,
"wallet_to":"2N9MQVd2rQZF9TEE3SXHzjvBUNgFWr2qf6V",
"wallet_memo_to":null,
"wallet_to_details": null | {},
"wallet_to_transactions": [],
"amount_from_fee":null,
"amount_to_fee":"0",
"deposit_url":null,
"deposit_address":"TVb4KtWABb9vyzMhiLm3cgFaE11MCZfvQu",
"deposit_memo":null,
"blockchain_deposit_hash": null,
"blockchain_withdrawal_hash": null,
"exchange_rate_initial":"0.000035858",
"exchange_rate_actual":null,
"client_info": {
"client_id": "id1234",
"client_ip": "127.0.0.1",
"client_email": "[email protected]"
},
/* Order status */
"status":"new",
"error_code":0,
"error_message":"",
"created_at":"1970-01-01 19:17:37",
"updated_at":"1970-01-01 19:17:38",
"finalized_at":null,
"start_order_at": null,
"currency_from_precision": 2,
"currency_to_precision": 8
}
}
Description of parameters in the response:
order_uuid
– Order ID in the FlyPay systemorder_type
– Order typeuser_order_id
– Unique payment identifier in the merchant systemdescription
– Order descriptionexpected_amount_from
– Expected deposit amountamount_from
– Actual deposit amountcurrency_from
– Deposit currencynetwork_from
– Deposit networkdeposit_from_user
– nullwallet_from
– Wallet from which the deposit was made (card number or blockchain address)wallet_memo_from
– tag/memo of the address in the blockchain from which the deposit was madeexpected_amount_to
– Expected amount to be credited to wallet (card or blockchain address)amount_to
– Actual amount credited to wallet (card or blockchain address)strict_withdrawal_amount
– true ifamount_to
was specified when creating the ordercurrency_to
– Withdrawal currencynetwork_to
– Withdrawal networkwithdraw_to_user
– nullwallet_to
– Wallet to which the payment is made (card number or blockchain address)wallet_memo_to
– tag/memo of the address in the blockchain to which the payment is madewallet_to_details
– Contains the payment details specified during the request in thewallet_details
parameterwallet_to_transactions
– Contains withdrawal data for multiple cards, otherwise nullamount_from_fee
– Commission amount in deposit currencyamount_to_fee
– Commission amount in the withdrawal currencydeposit_url
– The URL to which the client should be redirected to make a depositdeposit_address
– The address on the blockchain to which the deposit should be sentdeposit_memo
– tag/memo of the address in the blockchain to which the deposit should be sentdeposit_address_title
– The name of the deposit address, if it is a permanent deposit address, a name has been created for itdeposit_address_initial_order_uuid
– order_uuid of the first order in the system where this deposit address was used, if anyblockchain_deposit_hash
– Blockchain transaction hash for a completed cryptocurrency depositblockchain_withdrawal_hash
– Blockchain transaction hash for a completed cryptocurrency withdrawalexchange_rate_initial
– Expected exchange rate when creating an orderexchange_rate_actual
– Actual exchange ratestatus
– Order status (new)error_code
– Error codeerror_message
– Error message textcreated_at
– Date and time of order creation in the format "Y-m-d H:i:s"updated_at
– Date and time of order update in the format "Y-m-d H:i:s"finalized_at
– Date and time of order finalization in the format "Y-m-d H:i:s"start_order_at
– nullcurrency_from_precision
– Deposit or exchange currency precision, number of decimal placescurrency_to_precision
– Withdrawal currency precision, number of decimal places
HTTP/1.1 200 OK
Content-Type: application/json
{
/* The overall status of the request, not the order status */
"status": "success",
"data": {
"order_uuid":"eb7ac61f-18da-4983-a8a9-280c25f12ef4",
"order_type":"exchange",
"user_order_id":"merchant_unique_order_id",
"description": null,
"expected_amount_from":"0.001415",
"amount_from":null,
"currency_from":"btc",
"network_from":null,
"deposit_from_user": null,
"wallet_from":null,
"wallet_memo_from":null,
"expected_amount_to":"39.36",
"amount_to":null,
"strict_withdrawal_amount": false,
"currency_to":"usdt",
"network_to":null,
"withdraw_to_user": null,
"wallet_to":null,
"wallet_memo_to":null,
"wallet_to_details": null,
"wallet_to_transactions": [],
"amount_from_fee":null,
"amount_to_fee":null,
"deposit_url":null,
"deposit_address":null,
"deposit_memo":null,
"blockchain_deposit_hash": null,
"blockchain_withdrawal_hash": null,
"exchange_rate_initial":"27814.2473",
"exchange_rate_actual":null,
/* Order status */
"status":"processing",
"error_code":0,
"error_message":"",
"created_at":"1970-01-01 12:29:22",
"updated_at":"1970-01-01 12:29:22",
"finalized_at":null,
"start_order_at": null,
"currency_from_precision": 8,
"currency_to_precision": 2
}
}
Description of parameters in the response:
order_uuid
– Order ID in the FlyPay systemorder_type
– Order typeuser_order_id
– Unique payment identifier in the merchant systemdescription
– Order descriptionexpected_amount_from
– Expected exchange amountamount_from
– Actual exchange amountcurrency_from
– The currency from which the exchange takes placenetwork_from
– nulldeposit_from_user
– nullwallet_from
– nullwallet_memo_from
– nullexpected_amount_to
– Expected amount of the exchange resultamount_to
– Actual amount of the exchange resultstrict_withdrawal_amount
– falsecurrency_to
– The currency into which the exchange takes placenetwork_to
– nullwithdraw_to_user
– nullwallet_to
– nullwallet_memo_to
– nullwallet_to_details
– nullwallet_to_transactions
– nullamount_from_fee
– nullamount_to_fee
– nulldeposit_url
– nulldeposit_address
– nulldeposit_memo
– nulldeposit_address_title
– nulldeposit_address_initial_order_uuid
– nullblockchain_deposit_hash
– nullblockchain_withdrawal_hash
– nullexchange_rate_initial
– Expected exchange rate when creating an orderexchange_rate_actual
– Actual exchange ratestatus
– Order status (processing)error_code
– Error codeerror_message
– Error message textcreated_at
– Date and time of order creation in the format "Y-m-d H:i:s"updated_at
– Date and time of order update in the format "Y-m-d H:i:s"finalized_at
– Date and time of order finalization in the format "Y-m-d H:i:s"start_order_at
– nullcurrency_from_precision
– Deposit or exchange currency precision, number of decimal placescurrency_to_precision
– Withdrawal currency precision, number of decimal places
HTTP/1.1 200 OK
Content-Type: application/json
{
/* The overall status of the request, not the order status */
"status": "success",
"data": {
"order_uuid":"1ed5ee07-6ea1-4563-8679-b3f9d2272a8b",
"order_type":"exchange_withdraw",
"user_order_id":"merchant_unique_order_id",
"description": null,
"expected_amount_from":"413.54",
"amount_from":null,
"currency_from":"uah",
"network_from":null,
"deposit_from_user": null,
"wallet_from":null,
"wallet_memo_from":null,
"expected_amount_to":"10",
"amount_to":null,
"strict_withdrawal_amount": false | true,
"currency_to":"usdt",
"network_to":"trc20",
"withdraw_to_user": null,
"wallet_to":"Tvb4KtWABb9vyzMhiLm3cgFaE11MCZfvQu",
"wallet_memo_to":null,
"wallet_to_details": null | {},
"wallet_to_transactions": [],
"amount_from_fee":null,
"amount_to_fee":"1",
"deposit_url":null,
"deposit_address":null,
"deposit_memo":null,
"blockchain_deposit_hash": null,
"blockchain_withdrawal_hash": null,
"exchange_rate_initial":"0.0266",
"exchange_rate_actual":null,
/* Order status */
"status":"processing",
"error_code":0,
"error_message":"",
"created_at":"1970-01-01 17:16:12",
"updated_at":"1970-01-01 17:16:12",
"finalized_at":null,
"start_order_at": null,
"currency_from_precision": 2,
"currency_to_precision": 2
}
}
Description of parameters in the response:
order_uuid
– Order ID in the FlyPay systemorder_type
– Order typeuser_order_id
– Unique payment identifier in the merchant systemdescription
– Order descriptionexpected_amount_from
– Expected exchange amountamount_from
– Actual exchange amountcurrency_from
– The currency from which the exchange takes placenetwork_from
– nulldeposit_from_user
– nullwallet_from
– nullwallet_memo_from
– nullexpected_amount_to
– Expected amount to be credited to wallet (card or blockchain address)amount_to
– Actual amount credited to wallet (card or blockchain address)strict_withdrawal_amount
– true ifamount_to
was specified when creating the ordercurrency_to
– Withdrawal currencynetwork_to
– Withdrawal networkwithdraw_to_user
– nullwallet_to
– Wallet to which the payment is made (card number or blockchain address)wallet_memo_to
– tag/memo of the address in the blockchain to which the payment is madewallet_to_details
– Contains the payment details specified during the request in thewallet_details
parameterwallet_to_transactions
– Contains withdrawal data for multiple cards, otherwise nullamount_from_fee
– Commission amount in deposit currencyamount_to_fee
– Commission amount in the withdrawal currencydeposit_url
– nulldeposit_address
– nulldeposit_memo
– nulldeposit_address_title
– nulldeposit_address_initial_order_uuid
– nullblockchain_deposit_hash
– nullblockchain_withdrawal_hash
– Blockchain transaction hash for a completed cryptocurrency withdrawalexchange_rate_initial
– Expected exchange rate when creating an orderexchange_rate_actual
– Actual exchange ratestatus
– Order status (processing)error_code
– Error codeerror_message
– Error message textcreated_at
– Date and time of order creation in the format "Y-m-d H:i:s"updated_at
– Date and time of order update in the format "Y-m-d H:i:s"finalized_at
– Date and time of order finalization in the format "Y-m-d H:i:s"start_order_at
– Date and time of the start of the order execution in the format "Y-m-d H:i:s", if thedelay_order_for_minutes
parameter was specified when creating the order, otherwise nullcurrency_from_precision
– Deposit or exchange currency precision, number of decimal placescurrency_to_precision
– Withdrawal currency precision, number of decimal places
HTTP/1.1 200 OK
Content-Type: application/json
{
/* The overall status of the request, not the order status */
"status": "success",
"data": {
"order_uuid":"e7f9f137-395d-4ecc-8061-42e65b56f46b",
"order_type":"withdraw",
"user_order_id":"merchant_unique_order_id",
"description": null,
"expected_amount_from":"0.0047",
"amount_from":null,
"currency_from":"btc",
"network_from":"btc",
"deposit_from_user": null,
"wallet_from":null,
"wallet_memo_from":null,
"expected_amount_to":"0.0025",
"amount_to":null,
"strict_withdrawal_amount": false,
"currency_to":"btc",
"network_to":"btc",
"withdraw_to_user": null | "fpid-e03682a76e65",
"wallet_to":"2N9MQVd2rQZF9TEE3SXHzjvBUNgFWr2qf6V",
"wallet_memo_to":"",
"wallet_to_details": null | {},
"wallet_to_transactions": [],
"amount_from_fee":"0.0022",
"amount_to_fee":null,
"deposit_url":null,
"deposit_address":null,
"deposit_memo":null,
"blockchain_deposit_hash": null,
"blockchain_withdrawal_hash": null,
"exchange_rate_initial":null,
"exchange_rate_actual":null,
"client_info": {
"client_id": "id1234",
"client_ip": "127.0.0.1",
"client_email": "[email protected]"
},
/* Order status */
"status":"processing",
"error_code":0,
"error_message":"",
"created_at":"1970-01-01 12:32:47",
"updated_at":"1970-01-01 12:32:47",
"finalized_at":null,
"start_order_at": null,
"currency_from_precision": 8,
"currency_to_precision": 8
}
}
Description of parameters in the response:
order_uuid
– Order ID in the FlyPay systemorder_type
– Order typeuser_order_id
– Unique payment identifier in the merchant systemdescription
– Order descriptionexpected_amount_from
– Expected amount to be written off from the merchant's balanceamount_from
– Actual amount debited from the merchant's balancecurrency_from
– Withdrawal currencynetwork_from
– Withdrawal networkdeposit_from_user
– User ID in the system FlyPay, if the replenishment is a result of a transfer, otherwise nullwallet_from
– Wallet from which the deposit was made (card number or blockchain address)wallet_memo_from
– tag/memo of the address in the blockchain from which the deposit was madeexpected_amount_to
– Expected amount to be credited to wallet (card or blockchain address)amount_to
– Actual amount credited to wallet (card or blockchain address)strict_withdrawal_amount
– Used for exchanges with withdrawalscurrency_to
– Withdrawal currencynetwork_to
– Withdrawal networkwithdraw_to_user
– User ID in the system FlyPay, if the withdrawal is a result of a transfer, otherwise nullwallet_to
– Wallet to which the payment is made (card number or blockchain address)wallet_memo_to
– tag/memo of the address in the blockchain to which the payment is madewallet_to_details
– Contains the payment details specified during the request in thewallet_details
parameterwallet_to_transactions
– Contains withdrawal data for multiple cards, otherwise nullamount_from_fee
– Commission amountamount_to_fee
– nulldeposit_url
– nulldeposit_address
– nulldeposit_memo
– nulldeposit_address_title
– nulldeposit_address_initial_order_uuid
– nullblockchain_deposit_hash
– nullblockchain_withdrawal_hash
– Blockchain transaction hash for a completed cryptocurrency withdrawalexchange_rate_initial
– Expected exchange rate when creating an order (for orders with exchange)exchange_rate_actual
– Actual exchange rate (for orders with exchange)status
– Order status (processing)error_code
– Error codeerror_message
– Error message textcreated_at
– Date and time of order creation in the format "Y-m-d H:i:s"updated_at
– Date and time of order update in the format "Y-m-d H:i:s"finalized_at
– Date and time of order finalization in the format "Y-m-d H:i:s"start_order_at
– Date and time of the start of the order execution in the format "Y-m-d H:i:s", if thedelay_order_for_minutes
parameter was specified when creating the order, otherwise nullcurrency_from_precision
– Deposit or exchange currency precision, number of decimal placescurrency_to_precision
– Withdrawal currency precision, number of decimal places