API access
Every call to the Human Crash Baselines API needs an API key. This page explains how to get one and how to use it.
Request a key
API access is granted on request. Email humanbaselines@valgo.ai to request a key. A short note on your use case helps us provision the right access. You can also submit feedback or ask questions at the same address.
Use your key
Keys look like hbk_…. Pass yours to the client explicitly, or set the HUMANBASELINES_API_KEY environment variable and omit it:
from humanbaselines import HumanBaselines
hb = HumanBaselines(api_key="hbk_...")export HUMANBASELINES_API_KEY="hbk_..."hb = HumanBaselines() # key read from the environmentThe client sends it automatically as the X-API-Key header on every request. If no key is found, the constructor raises ValueError immediately; it never makes an unauthenticated request.
Keep keys out of source
Standard hygiene: We prefer the environment variable (or a secrets manager) over hard-coding the key. Don't commit keys to version control.
What the server enforces
| Situation | Response |
|---|---|
| Valid key | Request proceeds. |
| Missing or invalid key | 401 → AuthenticationError. |
| Server has no keys configured | 503 → ServiceUnavailableError (fails closed; never serves an open API). |
Keys are compared in constant time, so an invalid key reveals nothing about a valid one through timing.
Next steps
- Installation — install the client.
- Quickstart — your first request.