Skip to main content

Overview

The Rampnow API returns standard HTTP status codes to indicate the success or failure of API requests. These codes are returned by the server and provide immediate feedback about your request.
HTTP status codes are different from application error codes. Status codes indicate the HTTP-level result, while error codes provide specific application-level details.

API Status Code Categories

2xx - Success

SuccessThe request was successful and the server returned the requested data.
{
  "code": 0,
  "data": { ... }
}
Resource CreatedThe request was successful and a new resource was created.
Success with No ContentThe request was successful but there is no content to return.

4xx - Client Errors

Invalid RequestThe request is malformed or contains invalid parameters. Check your request payload and parameters.Common causes:
  • Missing required fields
  • Invalid JSON format
  • Incorrect data types
Authentication FailedAuthentication credentials are missing or invalid.Common causes:
  • Missing X-RAMPNOW-API-KEY header
  • Invalid API key
  • Missing or incorrect signature
  • Expired timestamp
Access DeniedYou don’t have permission to access this resource.Common causes:
  • Insufficient account permissions
  • API key doesn’t have required scope
  • IP address not whitelisted
Resource Not FoundThe requested resource doesn’t exist.Common causes:
  • Incorrect endpoint URL
  • Invalid resource ID
  • Resource has been deleted
Validation ErrorThe request is well-formed but contains semantic errors.Common causes:
  • Business logic validation failed
  • Invalid currency pair
  • Amount outside allowed range
Rate Limit ExceededYou have exceeded the API rate limit.Solution: Wait before making additional requests. Check the Retry-After header for guidance.

5xx - Server Errors

Server ErrorAn unexpected error occurred on the server.Action: Retry the request. If the issue persists, contact support with your request details.
Bad GatewayThe server received an invalid response from an upstream server.Action: This is usually temporary. Retry the request after a short delay.
Service UnavailableThe service is temporarily unavailable, usually due to maintenance or overload.Action: Retry the request after some time. Check the Retry-After header if provided.
Gateway TimeoutThe server didn’t receive a timely response from an upstream server.Action: Retry the request. Consider reducing payload size if applicable.

Status Code Reference Table

Status CodeStatus TextCategoryDescription
200OKSuccessRequest successful
201CreatedSuccessResource created successfully
204No ContentSuccessSuccess with no response body
400Bad RequestClient ErrorInvalid request format or parameters
401UnauthorizedClient ErrorAuthentication required or failed
403ForbiddenClient ErrorAccess denied
404Not FoundClient ErrorResource not found
422Unprocessable EntityClient ErrorValidation error
429Too Many RequestsClient ErrorRate limit exceeded
500Internal Server ErrorServer ErrorUnexpected server error
502Bad GatewayServer ErrorInvalid upstream response
503Service UnavailableServer ErrorService temporarily unavailable
504Gateway TimeoutServer ErrorUpstream server timeout

API Error Code categories

The Rampnow API uses standardized error codes to indicate the success or failure of requests. All error responses include a numeric code to help you identify and handle specific error conditions.

Success Response

Success
number
Code: 0Request completed successfully.

Client Errors (100000-100019)

The requested resource could not be found. Verify the endpoint URL and resource ID.
Authentication credentials are missing or invalid. Check your API key and signature.
You don’t have permission to access this resource. Verify your account permissions.
One or more request parameters are invalid. Review the request payload and parameter requirements.
The request conflicts with the current state of the resource. Check for duplicate operations.
The request or resource has expired. Generate a new request with updated timestamp.
The request contains invalid data. Validate your input against the API specification.
Multi-factor authentication is required for this operation.
The request is malformed or contains errors. Review the request structure.
Your account or IP has been blocked. Contact support for assistance.
The resource or entity is blacklisted and cannot be processed.

Operational Errors (100020-100023)

Maximum retry attempts exceeded. Wait before retrying the operation.
The requested operation or feature is not supported.
Multi-factor authentication setup is required before proceeding.
The quote provided is invalid or has expired. Request a new quote.

Server Errors (100024-100032)

An internal server error occurred. Retry the request or contact support if the issue persists.
The request timed out. Retry with a shorter payload or check your connection.
Request payload exceeds the maximum allowed size. Reduce the payload size.
Rate limit exceeded. Wait before making additional requests.
Bad gateway error. The server received an invalid response from an upstream server.
Service is temporarily unavailable. Retry after some time.
Gateway timeout. The server did not receive a timely response from an upstream server.
HTTP method not allowed for this endpoint. Check the API documentation for allowed methods.
The request is well-formed but contains semantic errors. Validate your business logic.

System Errors (100003, 100006-100013)

An unknown error occurred. Contact support with your request details.
Database error occurred. Retry the request or contact support.
Error serializing or deserializing data. Check your request format.
Internal system error. Contact support if the issue persists.
HTTP communication error. Check your network connection and retry.
System setup or configuration error. Contact support.
Feature not yet implemented. Check the API documentation for available features.
External API error. A third-party service encountered an issue.
Operation timed out. Retry the request.

Quick Reference Table

CodeError NameCategoryDescription
0SuccessSuccessRequest completed successfully
100000NotFoundErrClientResource not found
100001NotAuthenticatedErrClientAuthentication failed
100002NotAuthorizedErrClientAuthorization failed
100003UnknownErrSystemUnknown error
100004InvalidArgsErrClientInvalid arguments
100005ConflictErrClientResource conflict
100006DbErrSystemDatabase error
100007MarshalErrSystemSerialization error
100008InternalErrSystemInternal error
100009HttpErrSystemHTTP error
100010SetupErrSystemSetup error
100011NotImplementedErrSystemNot implemented
100012ExtApiErrSystemExternal API error
100013TimeoutErrSystemTimeout error
100014ExpiredErrClientResource expired
100015InvalidErrClientInvalid data
100016MfaRequiredErrClientMFA required
100017RequestErrClientRequest error
100018BlockedErrClientAccount blocked
100019BlacklistedErrClientResource blacklisted
100020RetryExceededErrOperationalRetry limit exceeded
100021NotSupportedErrOperationalNot supported
100022MfaSetupRequiredErrOperationalMFA setup required
100023InvalidQuoteErrOperationalInvalid quote
100024ServerErrServerServer error
100025RequestTimeoutErrServerRequest timeout
100026PayloadSizeErrServerPayload too large
100027RateLimitErrServerRate limit exceeded
100028BadGatewayErrServerBad gateway
100029ServiceUnavailableErrServerService unavailable
100030GatewayTimeoutErrServerGateway timeout
100031InvalidMethodErrServerInvalid HTTP method
100032UnprocessableEntityErrServerUnprocessable entity
Always implement proper error handling in your application. Log error codes and messages for debugging purposes.