Idempotency

Transfer creation endpoints support idempotency. Include an Idempotency-Key header with a unique value on each logical operation:

$curl https://api.useroot.com/api/payouts \
> -H "x-api-key: test_your_key_here" \
> -H "Idempotency-Key: payout-attempt-2026-06-12-001" \
> -H "Content-Type: application/json" \
> -d '{
> "payee_id": "0862d70b-e74d-428e-99f5-11e942e23d90",
> "amount_in_minor_units": 100,
> "currency_code": "USD"
> }'

Behavior

  • The first request with a given key creates the resource.
  • Subsequent requests with the same key return the original result, even if the body differs.
  • Keys are looked up by header value only — not by request body comparison.

When to retry with the same key

  • Network timeouts or connection errors
  • 500 Internal Server Error or 503 Service Unavailable
  • Any ambiguous failure where you are unsure the request was processed

Response codes

CodeMeaning
201 CreatedNew resource created
200 OKExisting resource returned for this idempotency key
400 Bad RequestFix validation errors before retrying

Do not reuse idempotency keys across different logical operations.