ndeipipayments APIv1 · 0.1.0-draftAPI reference

Object

The error object

Every error response has this shape. Branch on code, never on message.

Fields

codestringrequired

Stable machine-readable code. Clients must accept unknown codes. Defined in 1.0:

CodeStatusMeaning
invalid_request400Malformed JSON, unknown parameter or bad cursor
idempotency_key_missing400POST without Idempotency-Key
unauthorized401Missing, invalid or revoked key
key_environment_mismatch401Sandbox key on production or the reverse
forbidden403Key scope does not allow the action
sandbox_only403Sandbox endpoint called with a production key
user_not_approved403KYC or terms status is not approved
user_deactivated403User is deactivated
not_found404Object does not exist for this integrator
idempotency_key_reused409Same key, different body
idempotency_request_in_progress409Same key, original request still running
external_reference_exists409field is external_reference; existing_id names the user
wallet_exists409User already has a wallet in this asset
user_has_balance409Deactivation refused while a wallet holds funds
user_has_open_transfers409Deactivation refused while a transfer is open
transfer_not_cancelable409Transfer has posted or is final
payout_account_in_use409A pending off-ramp targets this account
invalid_state409Object is not in a state that allows the action
validation_failed422One or more fields invalid; see details
invalid_amount_precision422More decimal places than the asset allows
amount_below_minimum422Below the route minimum
amount_above_maximum422Above the route maximum
insufficient_funds422Available balance too low
amount_exceeds_cashable422Off-ramp above the purchased points still held; earned points cannot be cashed out
same_source_and_destination422Source and destination wallet are the same
asset_mismatch422Wallets hold different assets, and this is not a conversion
price_risk_not_acknowledged422NdeipiCoin wallet created without acknowledge_price_risk: true
quote_required422Conversion without a quote_id
quote_mismatch422Quote's assets, wallets or amount differ from the transfer
quote_expired422Quote's expires_at has passed; request a new one
quote_used409Quote already settled a conversion
insufficient_liquidity422Ndeipi's NdeipiCoin stock, or the treasury backing new points, is too low for this size; try a smaller amount later
unsupported_route422No route for this source and destination
limit_exceeded422Per-user or per-transfer limit; limit names it
sanctions_match422Payout beneficiary failed screening
rate_limited429Over the key's rate limit
provider_unavailable503Ramp provider down; request refused
internal_error500Unexpected server error
messagestringrequired

Human-readable. Never contains the API key or personal data.

fieldstring

JSON path of the offending request field, where there is one.

detailsarray of object

Per-field failures for validation_failed.

existing_idstring

For conflicts with an existing object, its ID.

limitobject

For limit_exceeded, the limit breached.

limit.namestring
limit.amountstring

Non-negative decimal string. Precision is limited per asset or currency (see Route).

limit.assetstring
limit.resets_attimestamp
request_idstringrequired
Example
{
  "code": "insufficient_funds",
  "message": "The source wallet's available balance is too low for this transfer.",
  "field": "amount",
  "request_id": "req_01JA8ZC4QK7N2Y5W3V0T9S8R6P"
}