> ## Documentation Index
> Fetch the complete documentation index at: https://docs.flystack.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Status Code

> The following list of HTTP codes are returned by FlyStack.

The following list of HTTP status codes is returned by FlyStack. Each status code indicates the outcome of an API call and suggests a potential resolution for errors.

| Status Code | Is Billed? | Explanation | Resolution |
| - | - | - | - |
| 200 and 201 | Yes | **Successful API Call** | No action required. |
| 400 | No | **Bad Request / Inactive API Key** | Verify your parameters and their types. Ensure your API key is active and not expired. Check the detailed error message in the response body for more information. |
| 401 | No | **Expired API Key** | Expired API key. Please update your API key or generate a new one. |
| 402 | No | **Payment Required / You Have Open Invoices** | Settle any outstanding invoices to continue using the API. |
| 403 | No | **Forbidden / Account Deactivated** | Verify your permissions. Contact us if you believe this is a mistake. |
| 404 | No | **Not Found / URL Not Found** | Ensure the endpoint URL is correct. Also returned by Flight Lookup when no flight matches. |
| 405 | No | **Method Not Allowed** | Use `GET`. |
| 429 | No | **Rate Limit or Quota Exceeded** | Consider upgrading your current plan or get in touch with our sales team. |
| 500 | No | **Unexpected Error** | Retry the action and check the detailed error message in the response body for more insights. For `TIMEOUT`, narrow the request with filters. |

### Error format

Every error has the same JSON body, with a stable `code` to branch on and a human-readable `message`:

```json theme={null}
{
  "error": {
    "code": "VALIDATION_ERROR",
    "message": "delay: Input should be greater than 30"
  }
}
```

| Code | Status | Meaning |
| - | - | - |
| `VALIDATION_ERROR` | 400 | A parameter is missing, unknown, invalid or given twice (the message names it). |
| `INACTIVE_KEY` | 400 | The API key is inactive. |
| `UNAUTHORIZED` | 401 | The `x-api-key` header is missing or the key is unknown. |
| `EXPIRED_KEY` | 401 | The API key has expired. |
| `PAYMENT_REQUIRED` | 402 | The account has open invoices. |
| `FORBIDDEN` | 403 | The account is deactivated. |
| `NOT_FOUND` | 404 | Unknown endpoint, or no flight matching a lookup. |
| `METHOD_NOT_ALLOWED` | 405 | The HTTP method is not supported by this endpoint. |
| `QUOTA_EXCEEDED` | 429 | The monthly request quota of your plan is used up. |
| `TIMEOUT` | 500 | The request took too long (15 seconds). |
| `INTERNAL_ERROR` | 500 | A technical error on our side. |

### Additional Notes

* **400 Bad Request**: This status indicates that the server cannot process the request due to a client error (e.g., malformed request syntax or invalid parameters).
* **401 Unauthorized**: Typically returned when an invalid API key is used. Make sure your API key is active and not expired.
* **402 Payment Required**: Occurs if there are outstanding invoices. Settle any open invoices to continue using the API.
* **403 Forbidden**: Indicates that the user does not have permission to access the requested resource.
* **405 Method Not Allowed**: The endpoint exists but not for this HTTP method.
* **429 Too Many Requests**: The client has sent too many requests in a given amount of time (rate limiting), or the monthly quota of the plan is used up (`QUOTA_EXCEEDED`).
* **500 Internal Server Error**: This is a generic error message for unexpected server issues. Check logs for more detailed information.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.