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

# Authentication in the Hablla API

Hablla’s API uses authentication via Workspace Token, a recommended approach for integrations, automations, and bots.

### Authentication via Workspace Token (Recommended)

The **Workspace Token** is a token directly linked to a specific workspace. It is the most practical and robust form of authentication for integrations and automations.

**Main Advantages:**

* Allows access to most API routes.
* **Does not expire**.
* Can be safely used in automated environments.
* Offers traceability (actions are recorded in the history as performed via automation).

#### How to obtain it

You can obtain the *workspace token* by accessing <https://studio.hablla.com/> as an administrator. \
\
After logging in, go to the settings menu through the gear icon in the top-right corner. The token will be displayed within the company information.&#x20;

> **📌 Visual example:**

<figure><img src="https://1592162275-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrmxWrIrMauHcIrsuqfGq%2Fuploads%2FF60uLVTyqS5RjXkkUe13%2Fimage.png?alt=media&amp;token=47312083-51f0-40a7-9083-822846cef968" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
[*Only the user with the Administrator role has access to this information*](#user-content-fn-1)[^1][*. Important: always replace it with `token_here` when sharing public examples to avoid leaks.*](#user-content-fn-1)[^1]
{% endhint %}

#### Identifying the Workspace ID

The workspace ID (example: `64e683e59a0a699241b5222c`) is unique per customer. You can find it directly in the browser URL when accessing your environment in Hablla Studio:

`https://studio.hablla.com/workspaces/<WORKSPACE_ID>`

#### Request example

```http
curl "https://api.hablla.com/v2/workspaces/<WORKSPACE_ID>/persons?page=1&limit=50" \
  -H "authorization: <YOUR_TOKEN_HERE>" \
  -H "accept: application/json"
```

### Conclusion

| Token Type      | Ideal for                       | Traceable actions? | Expiration | Recommended? |
| --------------- | ------------------------------- | ------------------ | ---------- | ------------ |
| Workspace Token | Integrations, automations, bots | ✅ Yes (as a bot)   | ❌ No       | ✅ Yes        |

[^1]:


---

# 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.hablla.com/hablla-docs-en/api/authentication-in-the-hablla-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.
