Crypto

get
Crypto Accounts

https://api.liquid.com/crypto_accounts
Get a list of crypto accounts.
Request
Response
Request
Response
200: OK
reserved_balance will not be 0.0 when you have live orders.
[
{
"id": 72294,
"currency": "BTC",
"balance": 0.0,
"reserved_balance": 0.0,
"pusher_channel": "user_35258_account_btc",
"lowest_offer_interest_rate": "0.00001",
"highest_offer_interest_rate": "0.00200",
"address": "19vvnmLKsqYbZDWugDGLNSKxd3oTmaKUpU",
"currency_symbol": "₿",
"minimum_withdraw": 0.02,
"currency_type": "crypto"
},
...
]

get
Crypto Withdrawals

https://api.liquid.com/crypto_withdrawal?currency={currency}
Get crypto withdrawal requests details.
Request
Response
Request
Query Parameters
address
optional
string
User's Liquid crypto address.
timestamp
optional
number
Only show withdrawal requests based on created_at at or after timestamp (timestamp in seconds).
state
optional
string
State of withdrawal request. pending, processing, processed, cancelled, reverted
currency
optional
string
Symbol of currency. eg. BTC
Response
200: OK
{
"models": [
{
"id": 1,
"address": "1BvBMSEYstWetqTFn5Au4m4GFg7xJaNVN2",
"amount": 1.5,
"state": "awaiting_confirmation",
"currency": "BTC",
"withdrawal_fee": 0,
"created_at": 1551264711,
"updated_at": 1551264711,
"payment_id": null
}
],
"current_page": 1,
"total_pages": 100000
}

get
Crypto Withdrawals Supported Network

https://api.liquid.com/crypto_withdrawals/crypto_networks?currency={{currency}}
Get crypto withdrawals supported networks.
Request
Response
Request
Path Parameters
currency
required
string
Example: /crypto_withdrawals/crypto_networks?currency=USDC
Response
200: OK
[
{
"network": "ERC20",
"currency": "USDC",
"chain_name": "Ethereum",
"root_currency": "ETH",
"depositable": true,
"withdrawable": true
},
{
"network": "Stellar",
"currency": "USDC",
"chain_name": "Stellar",
"root_currency": "XLM",
"depositable": true,
"withdrawable": true
}
]

post
Create a Crypto Withdrawal

https://api.liquid.com/crypto_withdrawals
Request
Response
Request
Body Parameters
network
required
string
Please refer to GET Crypto Withdarawals Supported Network. If the asset to be withdrawn supports only one network, this field is not required. Otherwise, network must be specified.
auth_code
optional
string
See explanation below.
currency
required
string
"crypto_withdrawals": {"currency": "BTC"}.
amount
required
string
"crypto_withdrawals": {"amount": "1.234"}
address
required
string
"crypto_withdrawals": {"address": "1BvBMSxxxx"}
payment_id
optional
string
For XRP only.
memo_type
optional
string
text, id, hash for XLM only.
memo_value
optional
string
For XLM only.
Response
200: OK
{
"id": 1353,
"address": "1BvBMSEYstWetqTFn5Au4m4GFg7xJaNVN2",
"amount": 1.0,
"state": "pending",
"currency": "BTC",
"withdrawal_fee": 0.0,
"created_at": 1568016450,
"updated_at": 1568016450,
"payment_id": null
}

NO-TOUCH MODE

Creating a crypto withdrawal requires user to interactively input 2FA code and confirm via email. This can be a problem if user is trying to build a fully automated system.

No-touch mode allows human interaction (auth token and email confirmation) to be omitted. No-touch mode can be enabled by adding at least one confirmed Whitelist IP.

Request Body
Request Body
// "auth_code" must be "000000" for NO-TOUCH MODE //
{
"auth_code": "000000",
"crypto_withdrawal":
{
"currency":"BTC",
"amount":"1",
"address":"1BvBMSEYstWetqTFn5Au4m4GFg7xJaNVN2",
"payment_id": null,
"memo_type": null,
"memo_value": null
}
}

put
Cancel a Crypto Withdrawal

https://api.liquid.com/crypto_withdrawal/{request_id}/cancel
Request
Response
Request
Path Parameters
request_id
required
string
Example crypto withdrawal request ID: 1351.
Response
200: OK
- state of this request has been cancelled.
{
"id": 1353,
"address": "1BvBMSEYstWetqTFn5Au4m4GFg7xJaNVN2",
"amount": 1.0,
"state": "cancelled",
"currency": "BTC",
"withdrawal_fee": 0.0,
"created_at": 1568016450,
"updated_at": 1568016450,
"payment_id": null
}