# ODN API API

> ODN API API on Apizie: 9 endpoints (Find all available data for some entities, Get constraint permutations for entities, Create a map, Get values for variables, …) returned as clean JSON through one API key. 9 endpoints are live now. Call it over REST at https://zieapi.vercel.app/v1/open-data:opendatanetwork/{endpoint} or from Claude, ChatGPT and Cursor through the Apizie MCP server. Free plan: 1,000 requests a month.

- Project key: `open-data:opendatanetwork`
- Category: Open Data
- Status: live
- Source: https://opendatanetwork.com
- Page: https://zieapi.vercel.app/api/open-data/opendatanetwork
- OpenAPI: https://zieapi.vercel.app/api/open-data/opendatanetwork/openapi.json

The Socrata OpenDataNetwork (ODN) REST API exposes public data, often continuosly updated and enhanced, from many thousands of public government and non profit agencies. Much of this data originating from independent…

## Endpoints

### Find all available data for some entities
`GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/find-all-available-data-for-some-entities`

| Parameter | Type | Required | Description |
|---|---|---|---|
| entity_id | string | yes | Comma separated list of entity IDs. |
| app_token | string | no | The [Socrata App Token](https://dev.socrata.com/docs/app-tokens.html) to be used with your request. The `app_token` parameter is required… |
| X-App-Token | string | no | e.g. cQovpGcdUT1CSzgYk0KPYdAI0 |

### Get constraint permutations for entities
`GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/get-constraint-permutations-for-entities`

| Parameter | Type | Required | Description |
|---|---|---|---|
| variable | string | yes | Full ID of the variable to retrieve. |
| entity_id | string | yes | Comma separated list of entity IDs. |
| constraint | string | yes | Constraint to use. |
| app_token | string | no | The [Socrata App Token](https://dev.socrata.com/docs/app-tokens.html) to be used with your request. The `app_token` parameter is required… |
| X-App-Token | string | no | e.g. cQovpGcdUT1CSzgYk0KPYdAI0 |

### Create a map
`GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/create-a-map`

| Parameter | Type | Required | Description |
|---|---|---|---|
| variable | string | yes | A single variable ID. |
| entity_id | string | yes | A comma separated list of entity IDs. Entities must have the same type and represent geographical regions. |
| constraint | string | no | Values must be specified for each constraint in the dataset. For example, to generate map data for `demographics.population.count`, you… |
| app_token | string | no | The [Socrata App Token](https://dev.socrata.com/docs/app-tokens.html) to be used with your request. The `app_token` parameter is required… |
| X-App-Token | string | no | e.g. cQovpGcdUT1CSzgYk0KPYdAI0 |

### Get values for variables
`GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/get-values-for-variables`

| Parameter | Type | Required | Description |
|---|---|---|---|
| variable | string | yes | Comma separated list of variable IDs. Defaults to retrieving all variables. It is also possible to pass in a topic such as `demographics`,… |
| entity_id | string | no | Comma separated list of entity IDs. Defaults to retrieving all entities. Note that since there is currently no results pagination,… |
| forecast | number | no | Number of steps to forecast. Must be an integer between 0 and 20. Forecasts are produced using linear extrapolation on the data. They are… |
| describe | boolean | no | Whether or not to produce a description of the data. Set to `true` to produce a description. Descriptions are not available if no entities… |
| format | string | no | If format is set to `google`, the data frame will be formatted as a [Google Visualizations data… |
| app_token | string | no | The [Socrata App Token](https://dev.socrata.com/docs/app-tokens.html) to be used with your request. The `app_token` parameter is required… |
| X-App-Token | string | no | e.g. cQovpGcdUT1CSzgYk0KPYdAI0 |

### Get Entities
`GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/get-entities`

| Parameter | Type | Required | Description |
|---|---|---|---|
| entity_id | string | no | ID of the entity. |
| entity_name | string | no | Name of the entity. |
| entity_type | string | no | Type of the entity. |
| app_token | string | no | The [Socrata App Token](https://dev.socrata.com/docs/app-tokens.html) to be used with your request. The `app_token` parameter is required… |
| X-App-Token | string | no | e.g. cQovpGcdUT1CSzgYk0KPYdAI0 |

### Find the relatives of an entity
`GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/find-the-relatives-of-an-entity`

| Parameter | Type | Required | Description |
|---|---|---|---|
| relation | string | yes | The type of relation to find. |
| entity_id | string | yes | ID of the target entity. |
| variable_id | string | no | If this parameter is included, only entities with data for the given variable will be returned. Note that this may cause the number of… |
| limit | number | no | Maximum number of entities in each group. Must be an integer from 1 to 1000. |
| app_token | string | no | The [Socrata App Token](https://dev.socrata.com/docs/app-tokens.html) to be used with your request. The `app_token` parameter is required… |
| X-App-Token | string | no | e.g. cQovpGcdUT1CSzgYk0KPYdAI0 |

### Get datasets
`GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/get-datasets`

| Parameter | Type | Required | Description |
|---|---|---|---|
| entity_id | string | no | Entities to use in formulating the query. |
| dataset_id | string | no | If included, the search terms of the dataset will be used in the query. |
| limit | number | no | Maximum number of results to return. Must be an integer from 0 to 50000. |
| offset | number | no | Number of results to skip. Used for pagination. |
| app_token | string | no | The [Socrata App Token](https://dev.socrata.com/docs/app-tokens.html) to be used with your request. The `app_token` parameter is required… |
| X-App-Token | string | no | e.g. cQovpGcdUT1CSzgYk0KPYdAI0 |

### Get questions
`GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/get-questions`

| Parameter | Type | Required | Description |
|---|---|---|---|
| query | string | yes | String to search against. |
| limit | number | no | Maximum number of results to return. Must be an integer from 0 to 50000. |
| offset | number | no | Number of results to skip. Used for pagination. |
| app_token | string | no | The [Socrata App Token](https://dev.socrata.com/docs/app-tokens.html) to be used with your request. The `app_token` parameter is required… |
| X-App-Token | string | no | e.g. cQovpGcdUT1CSzgYk0KPYdAI0 |

### Get suggestions
`GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/get-suggestions`

| Parameter | Type | Required | Description |
|---|---|---|---|
| type | string | yes | Type of the object to find. |
| query | string | yes | Query to match. |
| limit | number | no | Maximum number of results to return. Must be an integer from 0 to 100. |
| variable_id | string | no | This parameter is only available when suggesting entities with `type=entity`. If it is provided, suggestions will be filtered to include… |
| app_token | string | no | The [Socrata App Token](https://dev.socrata.com/docs/app-tokens.html) to be used with your request. The `app_token` parameter is required… |
| X-App-Token | string | no | e.g. cQovpGcdUT1CSzgYk0KPYdAI0 |

## Example
```
curl "https://zieapi.vercel.app/v1/open-data:opendatanetwork/find-all-available-data-for-some-entities" \
  -H "x-api-key: $APIZIE_KEY"
```

## FAQ

### How do I call the ODN API API?
Create a free Apizie key, then send GET https://zieapi.vercel.app/v1/open-data:opendatanetwork/find-all-available-data-for-some-entities with the header x-api-key. Every endpoint returns { project, data, timestamp }.

### Is the ODN API API free on Apizie?
Yes. The Free plan includes 1,000 requests a month at 100 requests a minute, no credit card.

### Can AI agents use the ODN API API?
Yes. Add the Apizie MCP server (https://zieapi.vercel.app/mcp) to Claude, ChatGPT, Cursor or VS Code, then ask in plain language. The agent calls run_scraper with project key open-data:opendatanetwork.

### What is the status of the ODN API API?
Live: works with just an Apizie key
