Skip to main content
Use validateOnly: true to validate a transfer without initiating or persisting it. This is useful for verifying that a target can receive funds before committing to execution.

When to use validation

Transfer validation is particularly useful when you need to:
  • Verify recipient addresses before performing foreign exchange (FX) conversions
  • Pre-validate email recipients to ensure users exist before showing transfer confirmation
  • Check onchain addresses are valid for the specified network before committing funds

How it works

When you set validateOnly: true:
  • The transfer is validated but not persisted
  • The transfer will not appear in list transfer responses
  • A 2xx response indicates valid transfer parameters
  • A 4xx response indicates validation failure with an errorType
validateOnly and execute are mutually exclusive. Setting both to true returns a 400 error.

Example request

{
  "source": {
    "accountId": "account_af2937b0-9846-4fe7-bfe9-ccc22d935114",
    "asset": "usd"
  },
  "target": {
    "email": "recipient@example.com",
    "asset": "usd"
  },
  "amount": "100.00",
  "asset": "usd",
  "validateOnly": true
}

Validation response

When validation succeeds, the response includes validated transfer details without persistence fields:
{
  "source": {
    "accountId": "account_af2937b0-9846-4fe7-bfe9-ccc22d935114",
    "asset": "usd"
  },
  "target": {
    "email": "recipient@example.com",
    "asset": "usd"
  },
  "sourceAmount": "100.00",
  "sourceAsset": "usd",
  "targetAmount": "100.00",
  "targetAsset": "usd"
}
When validateOnly is true, the response does not include transferId, status, createdAt, or updatedAt.

Validation errors

Error TypeDescription
invalid_requestThe request format is invalid or missing required fields, including invalid recipient addresses or unsupported networks
not_foundThe specified target user or account was not found
See Errors for the complete list of error types.

Sandbox testing

When testing email transfers in sandbox, only specific whitelisted emails will validate successfully. See Test data for transfers for valid test emails.