HTTP Errors

Seatoutes' APIs follow the HTTP response status codes, which indicate whether a specific HTTP request has been successfully completed. Below a summary of the most common codes you'll find in our responses:

Code

Description

200

OK. Everything worked as expected.

400

Bad Request. The request was unacceptable, often due to missing a required parameter.

401

Unauthorized. No valid API key provided.

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. We recommend an exponential backoff of your requests.

500, 502, 503, 504

Server Errors. Something went wrong on Searoutes' end.

API Error Codes

In case of Bad Requests (400 status code) and Not Found (404 status code) responses, an error code is returned in the response to give more details. These error codes are listed below and can be used to map custom error messages.

Error code

Description / message

1000

Default error code when a ressource has not been found.

1010

Port with a given name has not been found.

1020

Route has not been found.

1031

Vessel with the given IMO has not been found.

1032

Vessel with the given name has not been found.

1040

Location has not been found.

1050

Airport has not been found.

1060

Area has not been found.

1071

Carrier with the given SCAC has not been found.

1072

Carrier with the given ID has not been found.

1080

Rail region has not been found - from/to should be in the same region.

1090

Road region has not been found - from/to should be in the same region.

1121

Service with the given name has not been found.

1122

Service with the given ID has not been found.

2000

Default error code when an illegal argument has been passed.

2001

Default error when a parameter is missing.

2002

Parameter name must be given to search for a service.

2003

Either parameter SCAC or name must be given to search for a carrier.

2010

Unknown container size.

2020

Coordinates or locode is required.

2030

CO2 values for rail for the combination of parameters cannot be calculated.

2040

CO2 values for road for the combination of parameters cannot be calculated.

2050

CO2 for carrier cannot be calculated.

2060

Could not find appropriate size of truck.

2070

Illegal list of sizes.

3000

Default error code when a parameter is not valid.

3010

'aircraftType' parameter is invalid.

3020

'weight' parameter is invalid.

3030

'loadCharacteristics' parameter is invalid.

3040

'size' parameter is invalid.

3050

'from' / 'to' is invalid.

3060

'aircraftIATA' parameter is invalid.

3070

'containerSize' parameter is invalid.

3080

'fuel' parameter is invalid.

3090

'carrierId' parameter is invalid.

3100

'fromIATA' /' toIATA' parameter is invalid.

3110

'fromLocode' / 'toLocode' parameter is invalid.

3120

'country' parameter is invalid.

3130

'postal' parameter is invalid.

3140

'vesselImo' parameter is invalid.

3150

'vesselName' parameter is invalid.

3160

Area name ('name' parameter) is invalid.

3170

'nameOrLocode' path variable is invalid.

3180

'nameOrLocodeOrIata' path variable is invalid.

3190

Coordinates have invalid format.

3200

'volume' parameter is invalid.

3210

From and/or to are in a blocked area.

3220

locationType is invalid.

3230

From and/or to are in a forbidden area (military base for example).

3240

Illegal hash format.

4001

Type is invalid.

5000

Default error code when a service is not available.

5010

The geocoding service is unavailable.

5020

The AIS service is unavailable.