# API reference overview > The Flax programmatic REST API — base URL, authentication, content types, versioning, and the machine-readable OpenAPI spec. *[View this page in the Flax docs](https://flax-analytics.com/docs/api-reference/overview)* The Flax REST API lets you run queries and manage sheets, charts, dashboards, and schedules programmatically. It is the same surface the MCP server is built on. For the machine-readable contract, see the [OpenAPI spec](/docs/openapi.yaml). ## Base URL All endpoints live under `/api` on your Flax host: ``` https://flax-analytics.com/api ``` ## Authentication Every request authenticates with a **service-account API token** (`flax_pat_...`) sent as a Bearer token. See [Authentication](/docs/developers/authentication) to create one. ```bash curl https://flax-analytics.com/api/charts \ -H "Authorization: Bearer flax_pat_..." ``` A token carries a `read` or `write` scope, and every request is additionally constrained by the service account's team memberships and row-level security. The API grants no privilege the account does not already have. ## Requests and responses - Request and response bodies are JSON (`Content-Type: application/json`). - Timestamps are ISO-8601 UTC. - Errors use a consistent envelope — see [Errors & limits](/docs/api-reference/errors-and-limits). ## Versioning The API is versioned by the OpenAPI document's `info.version`. Backward-incompatible changes ship under a new major version; additive changes (new endpoints, new optional fields) do not. ## Resource groups | Group | Reference | |-------|-----------| | Run and inspect queries | [Queries](/docs/api-reference/queries) | | Spreadsheet workbooks | [Sheets](/docs/api-reference/sheets) | | Saved visualizations | [Charts](/docs/api-reference/charts) | | Dashboards & layout | [Dashboards](/docs/api-reference/dashboards) | | Warehouse connections | [Connections](/docs/api-reference/connections) | | Semantic projects & models | [Models](/docs/api-reference/models) | | Scheduled deliveries | [Schedules](/docs/api-reference/schedules) | | Automations | [Actions](/docs/api-reference/actions) | | Members, service accounts, embed tokens | [Orgs & admin](/docs/api-reference/orgs-and-admin) |