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

# Getting started

Connect your applications and AI tools to ControlBee

With the ControlBee API you connect ControlBee to other applications in your organisation or to AI tools. You can read and update actions, contexts, evidence, policies and processes.

This page explains what you need before your first request. The reference pages in the menu list every endpoint with its parameters and responses.

## OpenAPI specification

The complete API is described in an OpenAPI 3.1 specification. Use it to generate a client, import it into a tool such as Postman, or give it to an AI coding assistant:

<https://openapi.gitbook.com/o/RBrEn91LsNlSvnZAtIgE/spec/controlbee-api.json>

## Before you start

You need:

* access to ControlBee as a **company administrator**
* an **API token** (see below)
* the **address of your ControlBee environment**

### Base URL

Every organisation has its own ControlBee environment. The base URL is always:

```
https://<your-organisation>.controlbee.nl/api
```

Replace `<your-organisation>` with the name in the address you use to log in to ControlBee. For example, if you log in at `https://acme.controlbee.nl`, your policies are at `https://acme.controlbee.nl/api/policies`.

## Make your first request

{% stepper %}
{% step %}

### Create an API token

In ControlBee, go to **Profile > Company management > General and API** and create an API token. See [General and API](https://docs.controlbee.nl/en/profiel/bedrijfsbeheer/algemeen-en-api) in the user guide.

{% hint style="warning" %}
Treat the token like a password. Anyone with the token can access your organisation's data through the API. Delete a token in ControlBee as soon as you no longer need it.
{% endhint %}
{% endstep %}

{% step %}

### Send the token with every request

Add the token to the `Authorization` header:

```http
Authorization: Bearer <your-token>
```

{% endstep %}

{% step %}

### Retrieve your policies

```bash
curl https://<your-organisation>.controlbee.nl/api/policies \
  -H "Authorization: Bearer <your-token>" \
  -H "Accept: application/json"
```

The response contains your policies in a `data` array.
{% endstep %}
{% endstepper %}

## Good to know

### Pagination

Lists that can grow large, such as actions, are returned in pages. Use the `page` parameter to request the next page. The `meta` object in the response shows the current page, the last page and the total number of items.

```bash
curl "https://<your-organisation>.controlbee.nl/api/action-trackers?page=2" \
  -H "Authorization: Bearer <your-token>"
```

### Images in descriptions

Descriptions do not accept inline images (`data:` sources are removed). To add an image:

1. Upload the image with the `upload` endpoint of the item, for example `POST /api/processes/upload`.
2. Use the returned `url` as the `src` of the image in the description you send.

Accepted formats are JPEG, PNG, GIF, BMP and WebP, up to 4 MB.

### Importing process descriptions

An imported process description lands in a **draft**. The published version stays unchanged until someone publishes the draft in ControlBee. Send the description as HTML (default) or Markdown, and set the `X-Content-Format` header to `html` or `markdown`.

### Errors

| Code | Meaning                                                                                 |
| ---- | --------------------------------------------------------------------------------------- |
| 401  | The token is missing or invalid.                                                        |
| 403  | The token has no permission for this action.                                            |
| 404  | The item does not exist or is not available to your organisation.                       |
| 422  | The request did not pass validation. The `errors` object shows what is wrong per field. |
| 500  | Something went wrong on our side. Try again later or contact support.                   |

## Working with AI tools

Do you want to connect an AI assistant such as Claude to ControlBee? Use the ControlBee MCP server. You can request it free of charge at <support@controlbee.nl>.

## Missing a function?

Let us know through the feedback button in ControlBee which function your organisation needs, and we will get to work on it.


---

# 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.controlbee.nl/api/getting-started.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.
