> For the complete documentation index, see [llms.txt](https://docs.tonic.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.tonic.ai/fabricate/fabricate-api/using-the-fabricate-api.md).

# Using the Fabricate API

You can use the Fabricate API to manage databases and generate data. Except for generating data, most API calls are designed for rule-based databases.

The API is at <https://fabricate.tonic.ai/api/v1>. You make requests to the API endpoints within the API. Each request requires authentication with an API key.

A generated reference is available at <https://fabricate.tonic.ai/api>.

For examples of how to use the Fabricate API, go to the [fabricate-api-examples](https://github.com/mockaroo/fabricate-api-examples) repository on GitHub.

Fabricate also provides a Python library that you can use to make calls to the Fabricate API. The Python library is at <https://github.com/TonicAI/tonic-fabricate-python>.

There is also a client NPM package at <https://www.npmjs.com/package/@fabricate-tools/client>.

<table data-view="cards"><thead><tr><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>API authentication</strong><br><br>How to authenticate an API request.</td><td><a href="/fabricate/fabricate-api/using-the-fabricate-api/api-authentication.md">Authentication for the API</a></td></tr><tr><td><strong>Manage databases</strong><br><br>Retrieve database information. Create and update databases.</td><td><a href="/fabricate/fabricate-api/using-the-fabricate-api/managing-databases-from-the-api.md">Managing databases from the API</a></td></tr><tr><td><strong>Generate data</strong><br><br>Send and track generation requests. Load generated data into your database.</td><td><a href="/fabricate/fabricate-api/using-the-fabricate-api/api-generate-data.md">Generating data from the API</a></td></tr><tr><td><strong>Run a workflow</strong><br><br>Run a database workflow. Download resulting files.</td><td><a href="/fabricate/fabricate-api/using-the-fabricate-api/api-run-workflow.md">Running a database workflow</a></td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.tonic.ai/fabricate/fabricate-api/using-the-fabricate-api.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
