Skip to main content
This guide covers the full flow for sending crypto from a Yativo account to an external wallet: estimating gas fees, executing the transfer with an idempotency key, and tracking the transaction to completion.
Test this flow in the Sandbox at https://crypto-sandbox.yativo.com/api/v1/. Sandbox transactions are simulated — no real funds move.
1

Get a gas fee estimate

Before sending, retrieve the current gas fee estimate for the target chain. This lets you show users an accurate fee breakdown and choose a priority level.
Response:

Priority levels

2

Send funds with an idempotency key

Use POST /transactions/send-funds to initiate the transfer. Always include an Idempotency-Key header to safely retry without double-spending.
Response:

Idempotency keys

An idempotency key is a unique string you attach to a request. If the request fails or times out, you can safely retry with the same key — Yativo will return the original response instead of creating a duplicate transaction. If no key is supplied, no deduplication is applied.Best practices:
  • Derive the key from your internal record ID (e.g., payout_${payoutId})
  • Keys must be unique per operation — reusing a key for a different transfer will return the original transaction
  • Keys expire after 24 hours
3

Poll for transaction status

You can poll for the current transaction status using POST /transactions/get-transactions, filtering by transaction_id.
Response (completed):

Transaction statuses

4

Handle completion via webhook (recommended)

Rather than polling, register a webhook for transaction.{type}.completed and transaction.failed events to receive push notifications when transactions settle.
TypeScript (webhook handler)

Common Errors

Next Steps

  • See Webhook Integration for the full transaction.withdrawal.completed and transaction.failed event payloads.
  • Use Swap Tokens to exchange assets before sending.