# Authentication

{% hint style="danger" %}
**Secure your secret key**

Do not commit your secret token to git, or use them in client-side code.
{% endhint %}

This **secret API key** grants unrestricted access to **Padiwise's** API and authorizes all API calls. If there's any suspicion of a security breach, the secret key can be reset directly from your **Padiwise** dashboard. To access **Padiwise** endpoints, you must first obtain an **access token** by sending a request to the login endpoint using the OAuth 2.0 protocol.

<figure><img src="/files/K92CsIVm6VoZ61XSqL8t" alt=""><figcaption></figcaption></figure>

The `Authorization` header should be formatted as:

```
--header 'Accept: application/json' \
--header 'Authorization: Bearer {{ access_token }}'
```


---

# 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://padiwise.gitbook.io/padiwise/getting-started/authentication.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.
