Errors
Nash uses HTTP response status codes to indicate the success or failure of your API requests. If your request fails, Nash returns an error using the appropriate status code.
In general, there are three status code ranges you can expect:
- 2xx success status codes confirm that your request worked as expected
- 4xx error status codes indicate an error because of the information provided (for example, a required parameter was missing)
- 5xx error status codes are rare and indicate an error with Nash’s end
Example of a failed request:
Please IncludeRequestID
in when communicating support@usenash.com so we can help you faster
Possible error codes
BAD_REQUEST
The request failed, often due to missing a required parameter or malformed input field Example:
Solution: include pickupAddress
field.
Another example:
Solution: refresh quotes and try again refresh-quotes
UNAUTHORIZED
Invalid or missing API key. Example:
FORBIDDEN
Provided API key does not have access to requested resource/action Example:
INVALID_ADDRESS
Provided address in either pickupsAddress
or dropoffAddress
is missing, invalid or couldn’t be parsed.
Example:
INVALID_PHONE_NUMBER
Provided phone-number in either pickupPhoneNumber
or dropoffPhoneNumber
is missing, invalid or couldn’t be parsed.
Provided phone-number are expected to be in E.164 format.
Example:
RESOURCE_ALREADY_EXISTS
provided externalIdentifier
has been already used for another job
Example:
MISSING_RESOURCE
job/task/options_group cannot be found Example:
INVALID_TIME_CONSTRAINT
Provided packagePickupStartTime
, packagePickupEndTime
, packageDropoffStartTime
, packageDropoffEndTime
are invalid (e.g. dropoff time window is before pickup time window)
Example:
DISALLOWED_OPERATION
An API operation was attempted but was disallowed, e.g., updating a job after completion.
AUTODISPATCH_FAILURE
Auto-dispatch failed due to no valid quotes.
INTERNAL_SERVER_ERROR
Something went wrong on Nash’s end. (These are rare.) Example:
List of possible HTTP response statuses
response_status | Description |
---|---|
200 OK | Everything worked as expected. |
400 BAD_REQUEST | The request was unacceptable, often due to missing a required parameter. See error.code for more details |
401 UNAUTHORIZED | Invalid or missing API key. |
403 FORBIDDEN | The API key doesn’t have permissions to perform the request. |
404 NOT_FOUND | The requested resource doesn’t exist. |
429 TOO_MANY_REQUESTS | Too many requests hit the API too quickly. |
500 INTERNAL_SERVER_ERROR | Something went wrong on Nash’s end. |