Authentication
All requests to the Galen API are authenticated with an API key passed via HTTP header.
API key authentication
The Galen API uses API keys passed via the X-API-Key header. All requests except /health require a valid key.
Include the header in every request:
X-API-Key: gk_live_your_key_hereGetting your API key
- Sign up for a free account — no credit card required
- Open your Dashboard and click “Generate New Key”
- Keys use the
gk_live_prefix for easy identification - Copy your key immediately — it is only shown once
Important: Your API key is displayed only at creation time. If you lose it, revoke the old key and generate a new one from the Dashboard.
Code examples
Authenticate by passing your API key in the X-API-Key header:
import requests
API_KEY = "gk_live_your_key_here"
BASE = "https://research.usegalen.com/api/v1"
response = requests.get(
f"{BASE}/entities/EGFR",
headers={"X-API-Key": API_KEY}
)
print(response.json())Key management
Manage your API keys from the Dashboard.
- Rotate keys — generate a new key and revoke the old one with zero downtime
- Revoke compromised keys — takes effect immediately; all in-flight requests with the old key will fail
- Per-key usage tracking — each key tracks its own request count and rate limit usage
Rate limits by tier
Rate limits are enforced per API key. Exceeding the limit returns a 429 response with a Retry-After header.
| Tier | Per minute | Per hour | Per day |
|---|---|---|---|
| Explorer (Free) | 30 | 500 | 1,000 |
| Researcher ($49/mo) | 60 | 1,000 | 5,000 |
| Pro ($199/mo) | 300 | 10,000 | 50,000 |
| Enterprise (From $999/mo) | Custom | Custom | Unlimited |
See Pricing for a full comparison of tiers, endpoint access, and support levels.
Security best practices
- Never commit keys to version control — add
.envto your.gitignore - Use environment variables — load keys from
GALEN_API_KEYat runtime, not hardcoded strings - Rotate periodically — generate a fresh key every 90 days as a matter of hygiene
- Use the minimum tier needed — start with Explorer and upgrade only when your usage requires it