Endpoints
Get a quote
Calculate the transfer amounts, fees, limits, and estimated delivery time before creating an order.
POST/cloak/v1/quote
Examples in
Body
| Field | Description | |
|---|---|---|
| amountstring | required | Raw base units. The pinned side, input under exact_in, delivery under exact_out. |
| sourceAssetIdstring | required | From GET /tokens. |
| destinationAssetIdstring | required | Equal to the source for a send. A different swappable asset makes it a private swap. |
| senderAddressstring | required | The wallet that will sign the deposit. |
| recipientAddressstring | required | An ordinary Solana address. Nothing to claim. |
| modestring | optional | exact_in (default) or exact_out. Cross-asset orders must use exact_in. |
| feeBpsinteger | optional | Your revenue share, in basis points. Capped per account. See Revenue share. |
| feeRecipientAddressstring | conditional | Required when feeBps > 0. Must be registered to your account. |
Request
Request
curl -sS -X POST "https://api.veilo.network/cloak/v1/quote" \
-H "Authorization: Bearer $VEILO_KEY" \
-H "Content-Type: application/json" \
-d '{
"amount": "10000000000",
"sourceAssetId": "veilo-usdc",
"destinationAssetId": "veilo-usdc",
"senderAddress": "SENDER_SOLANA_ADDRESS",
"recipientAddress": "RECIPIENT_SOLANA_ADDRESS",
"mode": "exact_out",
"feeBps": 50,
"feeRecipientAddress": "PARTNER_FEE_WALLET_ADDRESS"
}' Response
200 · application/json
{
"success": true,
"quote": {
"sourceAssetId": "veilo-usdc",
"destinationAssetId": "veilo-usdc",
"mode": "exact_out",
"amountIn": "10091009518", // sender is debited
"amountOut": "10000000000", // recipient receives 10,000 USDC
"fee": "91009518", // total = protocolFee + networkFee
"protocolFee": "90819085", // Veilo fee + your share
"networkFee": "190433", // on-chain cost, in the source token
"feeBreakdown": {
"veiloFee": "40364038",
"partnerFee": "50455047", // yours
"networkFee": "190433"
},
"duration": 300, // seconds until the recipient has funds
"min": "2000000",
"max": "200000000000",
"quoteId": "<quote-id>",
"issuedAt": "2026-08-26T11:22:27.000Z",
"expiresAt": "2026-08-26T11:52:27.000Z"
}
}Echo the whole quote object back
Send the complete quote object unchanged to POST /order. Cloak rejects modified terms with QUOTE_MISMATCH.
duration is the expected seconds until the recipient has funds, and min/max are the live bounds for this asset. Both are safe to show a user. See How fees are built for what the breakdown means.
