Authentication
NeuralSnap uses API keys for authentication. Every request must include a valid key in the Authorization header as a Bearer token.
Getting Your API Key
Open API Keys settings
Click Settings in the sidebar, then select the API Keys tab.
Generate a new key
Click Generate New Key. Give it a descriptive name (e.g. "Production" or "Dev Testing") so you can identify it later.
Copy your key
Your key will be displayed once. Copy it immediately and store it securely — you won't be able to see it again.
Header Format
Include your API key in the Authorization header with every request:
Authorization: Bearer ns_live_abc123def456...
curl https://neuralsnap.ai/api/v1/snapshots \-H "Authorization: Bearer ns_live_abc123def456"
Never expose keys client-side
Rate Limit Headers
Every API response includes headers to help you track your rate limit usage:
| Property | Type | Description |
|---|---|---|
X-RateLimit-Limit | number | Maximum number of requests allowed per hour for your plan. |
X-RateLimit-Remaining | number | Number of requests remaining in the current window. |
X-RateLimit-Reset | timestamp | Unix timestamp (seconds) when the rate limit window resets. |
HTTP/1.1 200 OKX-RateLimit-Limit: 1000X-RateLimit-Remaining: 847X-RateLimit-Reset: 1706140800
Error Responses
401 Unauthorized
Returned when the API key is missing, malformed, or revoked.
{"error": "Invalid API key. Check your Authorization header.","code": "AUTH_INVALID_KEY"}
429 Rate Limited
Returned when you exceed the request limit for your plan. Back off and retry after the reset window.
{"error": "Rate limit exceeded. Try again in 342 seconds.","code": "RATE_LIMIT_EXCEEDED"}
Handling rate limits
X-RateLimit-Remaining header proactively to avoid hitting the limit, and queue requests when remaining is low.