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

# Authenticate with PIN API Keys and Agent Tokens

> How to authenticate to the Aria Compute PIN API using Bearer API keys or node-agent HMAC tokens, including bootstrap keys and public routes.

The PIN API uses a dual authentication model. Most endpoints require a user-created Bearer API key. Internal agent callback endpoints use a separate HMAC token scheme.

**Bearer API key** Pass your key in the `Authorization` header on every request:

```text theme={null}
Authorization: Bearer <your-api-key>
```

You can bootstrap the first key using the `ADMIN_API_KEY` environment variable on the PIN server, or create user-scoped keys via the `/v1/apikeys` endpoints. API keys are scoped to the user who created them.

**Public routes** The following routes do not require authentication:

* `GET /health`
* `GET /version`
* `POST /v1/auth/login`
* `POST /v1/auth/register`

**Node-agent HMAC token** Routes under `/v1/agent/*` use a node-agent HMAC token in a separate authentication scheme designed for internal agent callbacks. These tokens are not user-managed API keys.

**Example request**

```bash theme={null}
curl -H "Authorization: Bearer $ARIA_PIN_KEY" \
  http://localhost:8001/v1/auth/me
```

If the key is missing or invalid, PIN returns `401 Unauthorized` with an error envelope:

```json theme={null}
{
  "error": "unauthorized",
  "detail": "invalid or missing api key"
}
```


## Related topics

- [Authenticate with Aria Compute ROUTER](/api-reference/router/authentication.md)
- [Authenticate requests to the Aria Compute API](/authentication.md)
- [AGENT API Authentication: Bearer and ApiKey](/api-reference/agent/authentication.md)
- [POST /v1/auth/login: PIN User Login](/api-reference/pin/auth/login.md)
- [Aria Compute PIN API: Post-Training & Evaluation](/api-reference/pin/introduction.md)
