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

# API Error Handling

> Quick guide to handling Shovels API errors. For complete details, see the API Introduction documentation.

**For comprehensive error handling documentation, see the [API Introduction - Error Handling](https://docs.shovels.ai/docs/shovels-api-introduction.md#error-handling) section.** This article covers the most common scenarios.

## Most Common Issue: 422 Errors

A 422 error typically means you're missing a required parameter—usually a `geo_id`. **Solution:** Resolve your address first using the Address Search endpoint, then use the returned geo\_id in your permit query.

See [422 error explained](https://docs.shovels.ai/docs/knowledge-base/api/errors/422-error.md) for details.

## Empty Results vs Errors

An empty `items` array with a 200 response is **not an error**—it means your query was valid but no matching data exists.

```json theme={"theme":{"light":"css-variables","dark":"css-variables"}}
{
  "items": [],
  "size": 10,
  "next_cursor": null,
  "total_count": { "value": 0, "relation": "eq" }
}
```

## Quick Reference

| Code | Meaning | Action |
| - | - | - |
| 200 | Success (may be empty) | Check `items` array |
| 400 | Bad request | Review request format |
| 401 | Unauthorized | Check API key |
| 422 | Missing/invalid parameter | [See 422 guide](https://docs.shovels.ai/docs/knowledge-base/api/errors/422-error.md) |
| 500 | Server error | Contact [support@shovels.ai](mailto:support@shovels.ai) |

## Full Documentation

For complete error handling details, response code explanations, and troubleshooting tips, see:

* [API Introduction - Error Handling](https://docs.shovels.ai/docs/shovels-api-introduction.md#error-handling)
* [API Introduction - Troubleshooting](https://docs.shovels.ai/docs/shovels-api-introduction.md#troubleshooting)

## Related Articles

* [422 error explained](https://docs.shovels.ai/docs/knowledge-base/api/errors/422-error.md)
* [Resolving addresses](https://docs.shovels.ai/docs/knowledge-base/api/address-resolution/resolving-addresses.md)


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