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

# Invalid query

> invalid_query: HTTP 422, not retryable.

| | |
| - | - |
| Code | `invalid_query` |
| HTTP status | `422` |
| Retryable | No |
| Python | `vaquill.UnprocessableEntityError` |
| TypeScript | `UnprocessableEntityError` |

## What it means

A Boolean query or a filter was refused before any charge.

## What to do

Read `detail` for the reason, such as a malformed expression.
See [Boolean Search](https://vaquill.ai/docs/api-guide/concepts/boolean-search.md#errors) for the grammar and its error messages.
Rejected requests are not charged.

## Example response

The `detail` text is illustrative and can differ by endpoint.
`retryAfterSeconds` appears only on a `429` or `503` that carries a `Retry-After` header.

```json theme={"theme":"github-light"}
{
  "type": "https://www.vaquill.ai/docs/errors/invalid_query",
  "title": "Invalid query",
  "status": 422,
  "detail": "Boolean query could not be parsed",
  "code": "invalid_query",
  "retryable": false,
  "requestId": "3f2b8c1e-5a7d-4e9b-9c34-0d6a1b2f7e58"
}
```

## In the SDKs

The Python SDK raises `UnprocessableEntityError` and the TypeScript SDK raises `UnprocessableEntityError`.
Both expose `code`, `retryable`, the request id and the retry hint.
See [Error codes](https://vaquill.ai/docs/errors/index.md) for the full table and attribute names.


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