---
title: Authentication Guide | Libraxis API
url: https://api.libraxis.com/auth.md
---

# Authentication — `api.libraxis.com`

## 1. Public Endpoints (No Authentication Required)

The following routes work without an API key:
- `GET https://api.libraxis.com/health` — public liveness probe (`{"ok": true}`)
- `GET https://api.libraxis.com/v1/audio/health` and `GET https://api.libraxis.com/v1/audio/ready` — speech liveness probes
- Documentation & discovery: `/`, `/api-reference`, `/docs`, `/llms.txt`, `/llms-full.txt`, `/auth.md`, `/openapi.json`, `/openapi.yaml`, `/about`, `/contact`, `/privacy`, `/robots.txt`, `/sitemap.xml`, `/access`

## 2. Obtaining an API Key (Reviewed Private Beta)

1. Email `contact@libraxis.ai` with your clinic or engineering team, role, and target workflow.
2. Once approved, Libraxis issues a signed registration token.
3. Exchange the token at `https://api.libraxis.com/access` (browser UI or `POST https://api.libraxis.com/access` with `Authorization: Bearer <registration_token>` and JSON `{"email": "you@clinic.example", "ttl_hours": 72, "scopes": ["default"]}`).
4. Store the returned API key immediately — keys are shown once.

## 3. Sending Credentials on `/v1/*` Requests

Pass your API key using either standard header:

```bash
# Option A: OpenAI / Bearer convention
curl -sS https://api.libraxis.com/v1/models \
  -H "Authorization: Bearer $LIBRAXIS_API_KEY"

# Option B: API key header
curl -sS https://api.libraxis.com/v1/models \
  -H "X-API-Key: $LIBRAXIS_API_KEY"
```

## 4. Verifying Your Key & Handling Auth Errors

- Valid key on `GET /v1/models` returns `HTTP 200` with the active model catalog.
- Missing or invalid key returns `HTTP 401` with JSON:
  ```json
  {"error": {"type": "authentication_error", "code": "authentication_error", "message": "Invalid API key", "param": null}}
  ```
- Rate-limited requests return `HTTP 429` with `Retry-After` and IETF `RateLimit-*` headers.
