Guides

Error Codes

When Pay-i encounters an error, it will return a code and a message.

The code represents the type of error, and can be used in your service for control flow to retry and navigate around issues. A change to a code is considered a breaking change.

The message provides a human-readable, friendly string intended to assist with diagnosing issues. The message values will change over time as we improve our error reporting to make it easier to debug.

The below section is organized by groups of APIs. Each section describes the error codes and sample messages you may encounter when working with that group of APIs. Messages are subject to change at any time.

All APIs

CodeMessage
invalid_api_keyYour api key is invalid, missing, or expired.
unexpected_errorThe system has encountered an unexpected error
provider_errorThe downstream provider returned an error.
request_processing_errorAn error occurred while validating the request
header_is_missingRequired header '{header}' is missing from the request

All apis which accept tags as input

CodeMessage
invalid_tags{0} contains an invalid tag name '{1}'. Alphanumeric, underscore (_) and dash (-) only

All Proxy Routing APIs (excluding Direct Provider Call)

CodeMessage
invalid_provider_hostThe provided host URI '{0}' is invalid
invalid_provider_uriThe provided URI '{0}' is invalid
invalid_provider_ssl_certificateThe provided host URI '{0}' SSL certificate invalid

All Proxy Routing and Direct Provider Call APIs

CodeMessage
required_field_missingRequired request field '{0}' is missing
invalid_tags{0} contains an invalid tag name '{1}'. Alphanumeric, underscore (_) and dash (-) only
use_case_not_foundUse Case name '{0}' not found
use_case_instance_not_foundUse Case id '{0}' not found
invalid_user_idUser Id '{0}' is not valid
invalid_jsonBody JSON is invalid
category_not_foundCategory '{0}' not found
category_resource_not_foundCategory '{0}' and resource '{1}' not found

When providing a Limit ID to Proxy/Ingest APIs

CodeMessage
invalid_limit_idInvalid limit id '{0}'
invalid_limit_idsSome or all of passed limit-ids either do not exist or they are not related to the Application
limit_reachedInsufficient limit for the requested operation

All Direct Provider Call APIs (excluding Proxy Routing)

CodeMessage
invalid_ingest_event_timestampIngest event_timestamp {0} cannot be greater than 5 minutes into the future {1}
blocking_limit_not_allowedBlock limits cannot be used for ingest requests
category_resource_not_foundCategory '{0}' and resource '{1}' and event timestamp '{2}' not found

Limit APIs

CodeMessage
limit_not_foundLimit Id '{0}' not found
create_limit_validation_failedA error message for the specific validation that failed
update_limit_validation_failedA error message for the specific validation that failed
limit_name_already_existLimit name '{0}' already exists
invalid_max_limit_updateNew Limit max value cannot less than the current spent of '{0}'
invalid_max_limitMax limit must be greater than {limit}
duplicate_limit_idLimit ID '{limitId}' specified more than once

Use Case APIs

CodeMessage
use_case_not_foundUse Case name '{0}' not found
invalid_use_case_nameUse Case name '{0}' must be unique, contain only alphanumeric, '.', '-', and '_' characters, no spaces, with a max 64 characters
use_case_already_existsUse Casee name '{0}' already exists
invalid_use_case_descriptionUse Case description '{0}' must be supplied, max 256 characters
use_case_id_invalidUse Case id '{0}' is invalid
use_case_instance_not_foundUse Case id '{0}' not found
use_case_create_limit_failedCreating limit for Use Case '{0}' failed, {1}
use_case_id_requiredUse Case id is required if Use Case name is specified
application_no_use_casesApplication has not created any Use Cases
invalid_use_case_versionUse Case type version '{0}' must not be geater than the current version ('{1}')

Application APIs

CodeMessage
application_not_foundNo application found with Application Key '{applicationKey}'
application_userid_not_foundUserId '{userId}' not found
application_userid_already_usedUserId '{userId}' already used
application_request_properties_request_id_invalidApplication request id is invalid
application_request_result_request_id_not_foundApplication request id '{requestId}' not found
application_request_result_result_not_foundNo xproxy_result stored for application request id '{requestId}'

Categories and Resources APIs

CodeMessage
invalid_custom_categoryCustom categories must not be prefixed by 'system.'
invalid_custom_resourceInvalid custom resource value '{value}'
invalid_custom_resource_max_total_unitsmax_total_units must be > 0
invalid_custom_resource_total_unitsEither max_input_units or max_output_units must be > 0
invalid_custom_resource_pricesinput_price and output_price in '{value}' must be >= 0
category_resource_already_existsCategory '{category}' and resource '{resource}' at start_timestamp '{timestamp}' already exists