You’ll need to authenticate your requests to access some of the endpoints in the Unkey API. In this guide, we’ll look at how authentication works.

Bearer Token

When requesting resources, you will need your root key — you will find it in the Dashboard. Here’s how to add the root key to the request header using cURL:

curl https://api.unkey.dev/v1/... \
  -H "Authorization: Bearer unkey_xxx"

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