On-Demand Liquidity error codes

This document provides a list of error messages that On-Demand Liquidity returns if it encounters a problem.

Developers and architects may find this useful for designing integration logic. Administrators and other users may find this useful for troubleshooting.

On-Demand Liquidity returns errors to the RippleNet Payment Object (RPO) in the following format:

Copy
Copied!
{
  "status_code":400,
  "message":"Bad Request",
  "errors":	[
    {
      "code":1047,
      "odlCode":"ODL1047",
      "message":"The minimum order amount at the bitstamp exchange is 25 usd",
      "categories":["payment_validation"]
    }
  ]
}
Note:

You can locate errors passed by On-Demand Liquidity to the RippleNet Payment Object by searching for odlCode and categories. Do not rely on the error message content examples below for locating errors when coding exception management into your middleware. Error message content may change at any time without notice. Use the odlCode field to locate errors.

API usage errors

Errors from category api_usage mean that you sent a non-conforming request to the API.

odlCode Example message
ODL100 Invalid query param page value
ODL101 Invalid query param page_size value
ODL102 Invalid query param sort_field value
ODL103 Invalid query param sort_direction value
ODL104 The request object was missing the properties <properties>
ODL105 The filter must include state or state status, but includes neither.
ODL106 Request parameters are not valid: '<error_message>'

Missing payment errors

Errors from category missing_payment mean that the payment requested through the API cannot be found.

odlCode Example message
ODL400 The estimate with the identifier '<id>' could not be found.
ODL401 The payment with the identifier '<id>' could not be found.

Payment validation / 400 type errors

Errors from category payment_validation mean that there's a validation error of the estimate or submit request.

odlCode Example message
ODL1000 The <exchange> exchange is unknown by xRapid.
ODL1001 The currency pair <source_currency> <destination_currency> is not supported on the <exchange> exchange
ODL1002 The requested route (<route>) is not supported by xRapid
ODL1003 The request resulted in more than one route
ODL1004 Estimate with outbound transfer flag set to true must contain beneficiary info
ODL1005 You cannot submit an estimate request with a zero or negative amount.
ODL1006 Estimate request source amount exceeded maximum allowed: <amount> <currency>
ODL1007 You requested outbound status, but an outbound transfer was not configured
ODL1008 Estimate with outbound transfer flag set to false cannot contain beneficiary info
ODL1009 You cannot submit an estimate request with a non numerical source amount.
ODL1010 The address <digital_asset_address> for the digital currency <currency> is invalid. <reason_invalid>
ODL1017 Outbound information is required to make this payment.
ODL1018 Outbound outlet <outlet_id> is not supported at <exchange> exchange. Please recheck.
ODL1019 You must supply either a sourceamount or a destinationamount
ODL1020 Unable to parse JSON body
ODL1021 The <exchange> exchange does not support firm estimates
ODL1022 Estimate without outbound_instructions cannot contain submit with outbound instructions
ODL1023 Outlet id '<payment_outlet_id>' is different from '<estimate_outlet_id>' which is used for estimate
ODL1024 At a minimum either the source or destination exchange must be specified.
ODL1025 Invalid <code_name> code (<code_value>)
ODL1026 Invalid <code_name> code (<code_value>). The <sub_type> (<sub_value>) is invalid.
ODL1027 Field '<field>' is missing. Please refer API documentation
ODL1028 The instructions provided in the estimate request were insufficient to determine any executions instructions.
ODL1029 The estimate included inbound instructions, but the submit request did not
ODL1030 The estimate included inbound instructions with the input id <estimate_input_id>, but the submit request provided a different input id <submit_input_id>
ODL1031 The inbound instructions must contain the following three originator fields: <inbound_originator_fields>
ODL1032 Improperly formatted inbound instructions field <field_name> (<field_value>)
ODL1033 Inbound instructions unknown originator field
ODL1034 If the source exchange is specified, inbound instructions are not allowed.
ODL1035 If source currency and destination currency are present, intermediary is also required to be present.
ODL1036 The intermediary currency must always be a crypto currency.
ODL1037 xrpdeposit is the only supported inputid.
ODL1038 If the firm estimate_type is specified, a trade must also be specified.
ODL1039 The estimate service could not determine the desired route from the request.
ODL1040 The destination currency was specified, but not the destination exchange.
ODL1041 The processing flag <processing_flag> is invalid
ODL1042 Outbound outlet category on the <exchange> exchange could not be found for the outlet <outlet_id>
ODL1043 Outbound outlet '<outlet_id>' has following amount limits, minimum: <min_amount>, maximum: <max_amount>
ODL1044 Currency <currency> is not supported
ODL1045 The <currency> currency cannot be withdrawn from the <exchange> exchange
ODL1046 The minimum withdraw amount at the <exchange> exchange is <amount> <currency>
ODL1047 The minimum order amount at the <exchange> exchange is <amount> <currency>
ODL1048 The withdrawal of <currency> at the exchange <exchange> is missing <missing_items>
ODL1049 XRapid does not support withdrawal of non-digital currencies at the <exchange> exchange
ODL1050 The name of the destination exchange is required for crypto withdrawals, but it is not present.
ODL1051 The <exchange> exchange cannot support this payout. Amount out of range
ODL1052 The minimum order amount at the <exchange> exchange is <amount> <currency>. Your order of <source_amount> <source_currency> results in less than this amount.

Payment state errors

Errors from category payment_state mean that the payment doesn't allow the action you requested.

odlCode Example message
ODL2001 Failed payments in the SOURCE_EXCHANGE state may not be restarted.
ODL2002 Only payments that are failed may be restarted.
ODL2003 On restarting, the request may only contain the following fields: <fields>.
ODL2004 We could not determine the state status of the failed payment.
ODL2005 Failed payments in the SOURCE_EXCHANGE state may not be returned.
ODL2006 Only payments that are failed, done or held may be returned.
ODL2007 Failed payments in the OUTBOUND_TRANSFER state that are not held may not be returned.
ODL2008 We can not return the payment, as the intermediary deposit is missing.
ODL2009 The payment <paymentid> is not on hold and as such the finalize call does not apply. The current state status is <statestatus>.
ODL2010 The payment <paymentid> is not in the outbound transfer state and as such the finalize call does not apply. The current state is <state>.
ODL2012 Cannot request to hold the outbound transfer without it configured.
ODL2013 Completed payments that include an outbound transfer may not be returned.
ODL2014 For payment id: <payment_id> on <exchange> exchange we could not determine step to restart payment
ODL2015 The order <orderId> could not be canceled on the <exchange> exchange.
ODL2016 The outbound transfer results are not ready.

On-Demand Liquidity chaos code testing errors

Errors from category chaos mean that an exception was triggered by chaos flags.

Chaos codes are testing codes that can be sent through ODL when developing your implementation to determine how best to recover from a particular situation.

odlCode Example message
ODL3000 Chaos is not allowed in production
ODL3001 Chaos was applied with the <code> code.

On-Demand Liquidity account errors

Errors from category xrapid_account mean that there's an ODL account setup problem.

odlCode Example message
ODL4000 We could not find the <accountId> account
ODL4001 Please provide valid xRapid API authentication credentials
ODL4002 A valid access token is required for accessing the uri.

Exchange account setup credentials / authentication errors

Errors from category exchange_account_setup mean that there's an issue with the user's exchange account.

odlCode Example message
ODL5000 We could not find credentials for the <exchange> exchange, accountId=<accountId>
ODL5001 We found the credentials for the <exchange> exchange, but it is missing either the account, apiKey or the secret.
ODL5002 The signature for the <exchange> exchange could not be generated.
ODL5003 The credentials supplied were not accepted by the <exchange> exchange
ODL5004 We could not find a wallet for the currency (<currency>) at the exchange <exchange>
ODL5005 We could not find an address for the currency <currency> at the exchange <exchange>

Exchange insufficient funds errors

Errors from category insufficient_funds mean that the user's exchange account has insufficient funds.

odlCode Example message
ODL6000 The exchange has indicated that your balance is insufficient. We suspect that the exchange has not yet performed background processing and will we will retry until the balance is available.
ODL6001 User is sending <sender_amount>, but <exchange> exchange daily limit is <limit>, and daily amount remaining is: <amount>
ODL6002 Your available balance of <currency> at <exchange> is not sufficient to perform the estimate. Unfortunately, the payment can not proceed until the available balance at the source exchange is greater than or equal to the requested amount.

Exchange liquidity errors

Errors from category exchange_liquidity mean that there's insufficient liquidity at the exchange to fulfill a trade.

odlCode Example message
ODL7000 The exchange <exchange> contained insufficient liquidity to fill the order

Exchange connectivity errors

Errors from category exchange_connectivity mean that there's a network-related issue or issue related to the exchange connection.

odlCode Example message
ODL8000 Could not parse <uri> response
ODL8001 Retrieving the <currency_pair> orderbook on <exchange> failed with an unexpected exception
ODL8003 A <exptected_content_type> content-type was expected in the response from the <exchange> exchange, but a <returned_content_type> was returned.
ODL8004 The integration with the <exchange> exchange has issues. <http_status> status code received.
ODL8005 The <exchange> exchange service has issues. <http_status> status code received.
ODL8006 We are having issues network connectivity issues with the exchange.
ODL8007 Could not make socket connection to <exchange> exchange
ODL8008 Could not parse<exchange_name> <response_type> response
ODL8009 The delay processor for the <exchange> exchange encountered an exception
ODL8010 A call to the <exchange> exchange was unsuccessful because of an unknown upstream error.
ODL8011 Method timed-out.
ODL8012 Unable to fetch balances for the <exchange> exchange

Exchange throttling errors

Errors from category exchange_throttling mean that too many calls to the exchange were made or nonce errors.

odlCode Example message
ODL9000 A call to the <exchange> exchange was unsuccessful because of an invalid nonce.
ODL9001 Too high frequency of calls to the <exchange> exchange.

Exchange status errors

Errors from category exchange_status mean that the exchange is down.

odlCode Example message
ODL10000 We were unable to determine the status of the <exchange> exchange
ODL10001 The <exchange> exchange is currently unavailable. Please try later.
ODL10002 The <exchange> exchange is currently down for maintenance. Please try later.

Exchange integration / persistence Errors

Errors from category exchange_integration_persistence mean that there are integrity errors within Ripple's system.

odlCode Example message
ODL11000 We could not parse a date from <date>
ODL11001 An error was raised interpreting the error response from the <exchange> exchange
ODL11002 The request was for the <expected_gateway> exchange gateways but was delivered to the <actual_gateway> gateway
ODL11003 The order type <order_type> is not supported on the <exchange> exchange
ODL11004 The request to the exchange gateway was missing the <missing_field> field.
ODL11005 Limit orders require a price, but none was provided with the order.
ODL11006 The function <function> is not supported on the <exchange> exchange
ODL11007 Integrity error in the metadata for the <exchange> exchange. <reason>
ODL11008 Could not find <exchange> TradeOrder for client order id: <client_order_id>
ODL11009 The integration platform with the <exchange> exchange has issues. <issue> is not supported
ODL11010 The <exchange> exchange reported the status <status> on a funding, but the status is unknown
ODL11011 The <exchange> exchange reported the status <status> on an order, but the status is unknown
ODL11012 The persisted payment <id> could not be retrieved from the data store
ODL11013 The payment <id> does not contain <missing_item>
ODL11014 The payment <id> is in the <state> state and <state_status> status, but does contain <missing_item>
ODL11015 The payment <id> is in the <state> state and <state_status> status, and is not processable
ODL11016 An unknown error <error_message> was raised during the payment process for the payment <id>
ODL11017 Processing flags are present, but the registry is not
ODL11018 The persisted payment <id> could not be retrieved from the data store
ODL11019 Handle exchange step called with payment <id> in invalid state, <state>
ODL11020 The runtime mode <runtime_mode> is un-mappable
ODL11021 The metric <metric> was not found
ODL11022 Could not find transfer entity for transfers between <src_exchange> and <dst_exchange> for payment id: <payment_id>
ODL11023 Could not find transfer entity for transfers between <src_exchange> and <dst_exchange> for transfer id: <transfer_id>

Resource connectivity errors

Errors from category system_resources mean that there are errors related to the system or environment.

odlCode Example message
ODL12000 Please initialize the network client.
ODL12001 This message could not be sent over the transport: <msg>.
ODL12002 We did not receive a timely message from the service
ODL12003 We could not serialize the message.
ODL12004 We could not deserialize the message.
ODL12005 Unable to connect to database
ODL12006 Unable to connect to vault
ODL12007 Outbound outlet definition file for <exchange> is missing or not readable
ODL12008 Problem locking the key <lock_key>

Timeout exceptions

Errors from category payment_timeout mean that the payment execution has timed out.

odlCode Example message
ODL13000 The order at the source exchange <exchange> for the payment <id> has expired.
ODL13001 We were unable to complete the payment step <error_message> for payment <id> in time. The timeout period of <minutes> minutes has passed.
ODL13002 Estimate expiration: <expiration_date> has passed. Please request a new estimate.

Exchange-reported errors

Errors from category exchange_reported_errors mean that the exchange returned errors that are not explicit payment failure messages.

odlCode Example message
ODL14000 The <exchange> exchange did not return <element> on order submission.
ODL14001 A call to the <exchange> exchange was unsuccessful and returned the following error: <exchange_error>
ODL14002 The <exchange> exchange did not return withdrawal fees
ODL14003 The <exchange> exchange did not return fees for <ticker>
ODL14004 The order <orderId> could not be found at the <exchange> exchange
ODL14005 The withdrawal <withdrawal_id> could not be found at the <exchange> exchange
ODL14006 The withdrawal fees unavailable for <exchange> exchange
ODL14007 The transfer <transferId> could not be found at the <exchange> exchange
ODL14008 Fee could not be retrieved for currency <currency> on CoinsPro Exchange
ODL14009 The multi-step order (<orderId>) on the <exchange> exchange failed.
ODL14010 The <exchange> exchange responded with a <http_status> status code client error with the error messages: <error_messages>
ODL14011 The <exchange> exchange rejected the value (<code_value>) of the <code> field for the outletid `<outletid>in regionwith the validation message:<validation_message>`

Exchange payment failure exceptions

Errors from category exchange_reported_payment_failure mean that the exchange reported a trade or transfer failure.

odlCode Example message
ODL15000 A trade failed on the <exchange> exchange
ODL15001 <exchange_name> exchange outbound transfer failed for reason: <failure_reason>
ODL15002 Could not transfer <currency> to <to_exchange> from <from_exchange>
ODL15003 Trade Order for currency <currency> failed on CoinsPro exchange
ODL15004 Transfer from <to_exchange> to <from_exchange> failed.

Incentive errors

Errors from category incentive_errors mean that the error is related to the incentives program.

odlCode Example message
ODL16000 CurrencyLayer API threw an exception: <code> : <info>
ODL16002 Could not load this base pair from CurrencyLayer: base=<base> : counter=<counter>
ODL16003 Unable to generate spot rate: <message>
ODL16004 xRapid only currently supports FX rates with USD as the base: base=<base> : counter=<counter>
ODL16005 Invalid source/destination amounts provided: source=<source>, dest=<dest>
ODL16006 There was not enough pool balance to fulfill the estimate: account=<account>, exchange=<exchange>, incentive=<incentive>, currency=<currency>
ODL16007 This incentive type does not support negative values for payments: account=<account>, exchange=<exchange>, incentive=<incentive>, currency=<currency>
ODL16008 Couldn't load the details for this incentive type: incentive=<incentiveId>
ODL16009 Could not load the details for your incentive: account=<account>, exchange=<exchange>, incentive=<incentive>, currency=<currency>
ODL16010 This incentive mapping already exists, you need to deactivate the existing account_incentive before continuing: account=<account>, exchange=<exchange>, currency=<currency>, incentiveName=<incentiveName>, accountIncentiveId=<accountIncentiveId>
ODL16011 Could not find this account incentive: account=<account>, accountIncentiveId=<accountIncentiveId>
ODL16012 This update would result in a negative balance for this incentive: updateAmount=<updateAmount>, currentBalance=<currentBalance>
ODL16013 There was not enough incentive balance to cover the estimate or your account is not configured for a FIRM estimate at <exchange>