Response Code
A standard HTTP response code will be returned for each request. Many responses contain content, especially error codes.
| Response Code | Description |
|---|---|
| 200 | The request completed successfully. |
| 204 | The server has completed the request successfully but is not returning content in the body. This is primarily used for storing data points as it is not necessary to return data to caller. |
| 301 | This may be used in the event that an API call has migrated or should be forwarded to another server. |
| Response Code | Description |
|---|---|
| 400 | Information provided by the API user, via a query string or content data, was in error or missing. This will usually include information in the error body about what parameter caused the issue. Correct the data and try again. |
| 404 | The requested endpoint or file was not found. This is usually related to the static file endpoint. |
| 405 | The requested verb or method was not allowed. Please see the documentation for the endpoint you are attempting to access. |
| 406 | The request could not generate a response in the format specified. For example, if you ask for a PNG file of the logs endpoint, you will get a 406 response since log entries cannot be converted to a PNG image (easily). |
| 408 | The request has timed out. This may be due to a timeout fetching data from the underlying storage system or other issues. |
| 413 | The results returned from a query may be too large for the server's buffers to handle. This can happen if you request a lot of raw data from OpenTSDB. In such cases break your query up into smaller queries and run each individually. |
| 500 | An internal error occurred within OpenTSDB. Make sure all of the systems OpenTSDB depends on are accessible and check the bug list for issues. |
| 501 | The requested feature has not been implemented yet. This may appear with formatters or when calling methods that depend on plugins |
| 503 | A temporary overload has occurred. Check with other users/applications that are interacting with OpenTSDB and determine if you need to reduce requests or scale your system. |
| Attribute | Type | Mandatory | Description | Example Value |
|---|---|---|---|---|
| code | Integer | Yes | HTTP response code | 400 |
| message | String | Yes | Brief description about an error | Missing required parameter |
| details | String | No | Details about an error | Missing value: type |
The HTTP status code and response content are returned for all error responses.
Example:
{
"error": {
"code": 400,
"message": "Missing parameter <code>type</code>"
}
} Last Article: Managing the Data Lifecycle
Next Article: Use Restrictions
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.