# Error codes

Ordnance Survey uses standard HTTP response codes to provide key information on the outcome of API requests. These codes serve as a straightforward means of communication, indicating the success or failure of each API request between your application and our APIs.

When a request is successful, you'll encounter codes within the `2xx` range. If the information in the request is incorrect (for example, missing query parameters), you'll receive codes within the `4xx` range, and `5xx` codes indicate an error with the OS APIs.

The following table details the HTTP response codes and their meaning within the context of OS APIs:

<table data-full-width="false"><thead><tr><th width="95">Code</th><th width="184">Official description</th><th>Explanation in context of the API</th></tr></thead><tbody><tr><td><code>200</code></td><td>OK</td><td>Request has been successful.</td></tr><tr><td><code>304</code></td><td>Not Modified</td><td>In response to a conditional <code>GET</code> request this response indicates that the underlying data has not changed since the previous request, and cached results may be re-used.</td></tr><tr><td><code>400</code></td><td>Bad request</td><td>For example, missing query parameter or malformed syntax.</td></tr><tr><td><code>401</code></td><td>Unauthorized</td><td>The client has not provided authentication or has provided incorrect authentication.</td></tr><tr><td><code>403</code></td><td>Forbidden</td><td>The client has authenticated its access but does not have sufficient rights to complete the request.</td></tr><tr><td><code>404</code></td><td>Not found</td><td>The server has not found anything matching the Request-URI.</td></tr><tr><td><code>405</code></td><td>Method not allowed</td><td>The request used an unsupported HTTP method, for example, <code>DELETE</code> or <code>PUT</code>.</td></tr><tr><td><code>429</code></td><td>Too many requests</td><td>The number of requests per minute (rate-limit) has been exceeded.</td></tr><tr><td><code>500</code></td><td>Internal server error</td><td>A generic internal server error occurred.</td></tr><tr><td><code>503</code></td><td>Service unavailable</td><td>A temporary outage due to overloading or maintenance.</td></tr></tbody></table>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.os.uk/os-apis/core-concepts/error-codes.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
