# Authentication

## Authencate your app in Twake

**All your connections** should respect the Basic access authentication protocol, which must be used via HTTPS, except in development mode. In order to make an API call with this method, you must add an HTTP header:

```
Authorization: Basic base64(public_id:private_api_key)
```

**You must concatenate** your [public\_id and private\_api\_key](/developers-api/get-started.md#identity-and-api-settings) , **then convert** the whole **to base64**. Your HTTP header will therefore look like:

```
# For the keys 'public_id' and 'private_key'
Authorization: Basic cHVibGljX2lkOnByaXZhdGVfYXBpX2tleQ==
```

## Authencate your app in a company

**All your requests should have at least a "group\_id" key with the company id you**


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.twake.app/developers-api/api-reference/auth.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
