Skip to content

Errors and Response Codes

Last Updated: March 2, 2022


Authentication

POST/authenticate

200 OK

Valid response

404 Bad Request

Problem: The JSON request is not valid.

Cause: This may be caused by a missing or invalid field.

Examples: In this example, the field "grant_type" was not included in the GetToken request.

{
   "message": "Bad Request: Input body does not match schema: 'grant_type' is a required property",
   "code": "invalid_input",
   "type": "invalid_request_error"
}

In this example, the "refresh token" value had brackets around it. This is not valid JSON formatting.

{
    "message": "Bad Request: Unable to Parse Request Body",
    "code": "unparsable_body",
    "type": "invalid_request_error"
}

401 Unauthorized

Problem: The username and password combination is unrecognized.

Cause: This may be caused by inputting the wrong username (email address) or password.

Example In this example, the user's password was incorrect.

{
    "message": "Unauthorized: username/password combination not recognized. If you need to reset your password use the following link: https://auth.ard.maxar.com/forgotPassword?client_id=74f469d1dh4f51hej7cceat5dk&response_type=token&scope=aws.cognito.signin.user.admin+email+openid&redirect_uri=https://ard.maxar.com/docs/getting-started/getting-started/",
    "code": "unrecognized_credentials",
    "type": "authentication_error"
}

500 Internal Server Error

The system encountered an error while processing the request.

Select Imagery

POST/select

200 OK

Valid response

400 Bad Request

Problem The JSON request is not valid.

Cause: This may be caused by missing or invalid parameters in the JSON request body.

Examples In this example, the request did not include an AOI in either the "intersects" or "bbox" field. An AOI is required for all "select" requests.

{
    "message": "Bad Request: Either 'intersects' or 'bbox' is required",
    "code": "invalid_parameters",
    "type": "invalid_request_error"
}

Note: Fields, operators, and values in the "query" section of a "select" request are not validated when the request is submitted. Invalid fields, operators, or values will not find a match. If your selection results are not as expected, check the documentation to make sure the names of your query fields are correct, and that you're using search operators and values that are supported.For example, if the range for a field is 1 - 100, and the value in the request is 110, no matches will be made for that field.

401 Unauthorized

Problem: the user is not authorized to make the request.

Cause: This may be caused by an invalid token, or the token may not be present. Make sure the token is stored in your environment or added to the request header. If the token is present, but cannot be authorized, try requesting a new token. Tokens expire every 12 hours, and need to be refreshed or re-issued.

Example:

{
    "message": "Unauthorized",
    "type": "authentication_error",
    "code": null
}

GET /select

200 OK

Valid response

400 Bad Request

Problem The select ID could not be found.

Cause: The select ID may not have been copied correctly from the "select" response, or it may have expired.

Example:

{
    "message": "Bad Request: A request with ID '579885123985551389' cannot be found.",
    "code": null,
    "type": "invalid_request_error"
}

401 Unauthorized

Clicking any file link from within the "select" response generates a "get" request for that file if you're using Postman. Running the GET request may result in a 401 unauthorized error.

To resolve this in Postman, select the "Authorization" link below the url request bar. Select the dropdown and choose "Bearer token." If your token is saved in your Postman environment, it will authorize the request.

Example:

{
    "message": "Unauthorized",
    "type": "authentication_error",
    "code": null
}

Ordering imagery

POST /order

200 OK

Valid response

400 Bad Request

Problem: The order request is not valid.

Cause: This is a result of missing required fields or invalid types for fields. It may also be due to an invalid S3 bucket name or no S3 bucket policy providing write access to Maxar.

Examples:

In this example, the select ID did not include any valid catalog IDs to order.

{
    "message": "Bad Request: select id: '5579890791008106533' has 0 results",
    "code": "invalid_parameters",
    "type": "invalid_request_error"
}

In this example, the S3 bucket "user-docs" does not exist.

{
    "message": "Bad Request: Failed to write to the 'user-docs' bucket.  Please check bucket permissions.",
    "code": "invalid_parameters",
    "type": "invalid_request_error"
}
In this example, no email address was supplied for the notifications field.

{
    "message": "Bad Request: {'type': 'email', address is not correctly formatted",
    "code": "invalid_parameters",
    "type": "invalid_request_error"
}

500 Internal Server Error

Problem: The order could not be processed.

Cause: The request may be valid, but something prevented the system from processing it.

GET /order

200 OK

Valid response

404 Not Found

Problem: The system cannot find the order ID requested.

Cause: The Order ID is invalid. It may have been copied or typed incorrectly.

Example:

{
    "message": "Not Found",
    "code": null,
    "type": "http_error"
}
Back to top