Skip to main content
POST
/
deposit
Create deposit
curl --request POST \
  --url https://api.leokit.dev/deposit \
  --header 'Api-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "quote_id": "019b4c96-e47b-7000-afd4-17252097b092",
  "protocol": "thorchain"
}
'
{
  "type": "EVM",
  "protocol": "mayachain",
  "quote_id": "019b4c96-e47b-7000-afd4-17252097b092",
  "details": {
    "from_asset": "ETH.ETH",
    "to_asset": "BTC.BTC",
    "from_address": "0xacd9a974065de9c7a19873f95af7595e1d632167",
    "to_address": "bc1q2hk2q3zy7pdh0tp4awzn4k5lyetedaue5zt88r",
    "amount": "1",
    "network": "ETH",
    "decimals": 18
  },
  "unsigned_transactions": [
    {
      "to": "0xe3985e6b61b814f7cdb188766562ba71b446b46d",
      "from": "0xacd9a974065de9c7a19873f95af7595e1d632167",
      "data": "0x44bc937b...",
      "value": "1000000000000000000",
      "gasLimit": 180000,
      "type": 2,
      "maxFeePerGas": "1580264892",
      "maxPriorityFeePerGas": "1500000000",
      "chainId": 1,
      "nonce": 245
    }
  ]
}

Documentation Index

Fetch the complete documentation index at: https://docs.leokit.dev/llms.txt

Use this file to discover all available pages before exploring further.

QR Code Enrichment

When using Chainflip or NEAR as the selected protocol, the deposit response is automatically enriched with:
FieldTypeDescription
deposit_addressstringThe generated deposit address (Chainflip channel or NEAR)
payment_uristringChain-specific payment URI (BIP-21, EIP-681, Solana Pay, etc.)
qr_urlstringCDN URL of a QR code PNG encoding the payment_uri
These fields allow users to complete swaps by scanning a QR code from any wallet app, without needing to manually copy the deposit address.
These fields are only present for chainflip and near protocols. Other protocols (thorchain, mayachain, relay, etc.) return only unsigned_transactions.

Payment URI Standards

The payment_uri follows the wallet standard for the source chain:
Source ChainStandardExample
BTC, LTC, DOGE, DASHBIP-21bitcoin:bc1q...?amount=0.5
ETH, ARB, BASE (native)EIP-681ethereum:0x...@1?value=500000000000000000
ETH, ARB, BASE (ERC20)EIP-681ethereum:0xTOKEN@1/transfer?address=0x...&uint256=
SOL (native)Solana Paysolana:So1...?amount=2
ZEC (transparent / shielded)ZIP-321zcash:t1...?amount=0.5 / zcash:zs1...?amount=0.5
OtherFallbackPlain deposit address

Chainflip Boost

For Chainflip swaps, you can opt into the Boost Pool to get faster confirmation in exchange for a tip.
FieldTypeRequiredDescription
boost_feenumberNoMaximum boost fee (basis points). Common values: 5, 10, 30. 0 (default) = no boost
When boost_fee > 0, the deposit response includes a boost-channel ID. The user’s deposit is fronted by liquidity providers as soon as it’s seen in the mempool, instead of waiting for full chain confirmation.
{
  "quote_id": "01953c9a-...",
  "selected_protocol": "chainflip",
  "boost_fee": 10
}
Refer to the Chainflip Boost Pools documentation for the latest tier structure and capacity. The boost_fee parameter is silently ignored for non-Chainflip protocols.

Authorizations

Api-Key
string
header
required

Demo API-Key (Sandbox): 7037d2b3-9c76-4f62-b730-c544f7570fa4

Body

application/json

Request body for /deposit.

quote_id
string<uuid>
default:019b4c96-e47b-7000-afd4-17252097b092
required

Quote identifier returned from /quote.

Example:

"019b4c96-e47b-7000-afd4-17252097b092"

protocol
string
default:thorchain
required

Protocol to use for deposit generation.

Example:

"thorchain"

Response

Deposit created. For Chainflip and NEAR protocols, the response includes deposit_address, payment_uri, and qr_url.

Deposit generation response containing unsigned transactions to sign per network type.

type
enum<string>
required

Network family used for signing/broadcasting.

Available options:
EVM,
COSMOS,
UTXO
protocol
string
required

Protocol selected for execution (e.g., mayachain).

quote_id
string<uuid>
required

Quote identifier used to generate this deposit.

details
object
required

Normalized deposit context used to construct unsigned transactions.

unsigned_transactions
object[]
required

Prepared raw transaction(s) you must sign and broadcast. The item shape depends on type.

Prepared EVM transaction object to sign and broadcast.

deposit_address
string | null

Generated deposit address. Only present for Chainflip and NEAR protocols.

payment_uri
string | null

Chain-specific payment URI (BIP-21, EIP-681, or Solana Pay). Only present for Chainflip and NEAR protocols.

qr_url
string | null

CDN URL of a QR code PNG encoding the payment_uri. Only present for Chainflip and NEAR protocols.