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

# Environments

How to authenticate environment credentials

Allows you to securely access the API using your `environmentUUID` and `envSecret` as your API keys. These credentials are required only for creatingSession endpoint (only if you are using a fingerprint alongside of it) and must be stored securely to maintain access.

<figure><img src="https://3113958468-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fp096M7kwcESLc9whXkjt%2Fuploads%2FuzpQhFJj0rOB6PayFQdd%2FEnvironments%20%20Flow%20(1).png?alt=media&amp;token=7e63935a-b95a-4945-a0bd-367ad485da79" alt=""><figcaption></figcaption></figure>

1. **Creating an environment from the api**

{% hint style="warning" %}
You must store `envSecret`, as it cannot be retrieved once lost.
{% endhint %}

{% content-ref url="/pages/ng14bdzqQo5JGHd8ImfG" %}
[Enviornments](/reference/api-reference/enviornments.md)
{% endcontent-ref %}

2. **Include environment credentials in the request headers**

To authenticate, you must include your `environmentUUID` and `envSecret` in the request headers.

<table><thead><tr><th>Header Key</th><th>Value</th></tr></thead><tbody><tr><td>X-Environment-Id</td><td><pre><code><strong>environmentUUID
</strong></code></pre></td></tr><tr><td>X-Environment-Secret</td><td><pre><code>envSecret
</code></pre></td></tr></tbody></table>
