> ## Documentation Index
> Fetch the complete documentation index at: https://docs.datkey.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Authentication

> How to authenticate your requests to Datkey's API

You'll need to authenticate your requests to access all the endpoints in the Datkey API. In this guide, we'll look at how authentication works.

## API key

When requesting resources, you will need your workspace API key — you will find it in the [Dashboard](https://dashboard.datkey.dev). Here's how to add the key to the request header using cURL:

```bash theme={null}
curl https://api.datkey.dev/... \
  -H "X-api-key: datkey_xxx"
```

Always keep your workspace API key safe and reset it if you suspect it has been compromised.
