API keys
API keys are workspace-scoped credentials for the public /v1 API. They are managed from the
dashboard under Settings → API keys. There is one key system across the platform — the same
key works for payments and verification; there are no per-product keys.
Create a key
Section titled “Create a key”- Open Settings → API keys in the dashboard.
- Choose Create key.
- Give it a name you will recognise in an incident —
Production server,Staging worker, or the name of the service that holds it. - Choose an environment:
live(default) ortest. - Select scopes. Leaving the selection empty grants all four scopes.
The response is the only time the full key is available:
nvs_live_sk_1a2b3c4d5e6f_9f8e7d6c5b4a39281706f5e4d3c2b1a09f8e7d6c5b4a39281706f5e4d3c2b1a0Copy it into your secret manager immediately. Nuansis stores sha256(secret) and the non-secret
prefix; it cannot re-display or recover the secret. If it is lost, revoke the key and mint a new one.
What the dashboard shows
Section titled “What the dashboard shows”The key list never includes the secret. Each row contains:
| Field | Meaning |
|---|---|
id |
Numeric key id, used for revocation |
name |
Label you gave the key |
prefix |
The 12-character non-secret prefix, for identifying a key in logs |
environment |
live or test |
scopes |
Granted scopes |
active |
false once revoked |
last_used_at |
Last authenticated request, updated at most once per minute |
revoked_at |
When the key was revoked, or null |
created_at |
Creation timestamp |
Revoke a key
Section titled “Revoke a key”Use the revoke action next to the key in Settings → API keys. Revocation takes effect
immediately: the authentication query excludes revoked rows, so the next request with that key
returns 401 unauthorized / invalid_api_key.
Revocation is permanent. To restore access, create a new key.
Rotate without downtime
Section titled “Rotate without downtime”- Create a second key with the same scopes and environment.
- Add it to your deployment’s secret store and roll it out.
- Watch
last_used_aton the old key until it stops moving. - Revoke the old key.
Because rate limits are tracked per key id, the new key starts with a fresh budget during the overlap — useful when rotating a busy integration.
Under the hood
Section titled “Under the hood”The dashboard calls three JWT-authenticated endpoints. They are documented here for completeness;
they are not part of the API-key surface and cannot be called with a nvs_… key.
| Method | Path | Purpose |
|---|---|---|
GET |
/api-keys |
List keys for the workspace |
POST |
/api-keys |
Mint a key — returns the plaintext key once |
DELETE |
/api-keys/:id |
Revoke a key |
POST /api-keys accepts:
{ "name": "Production server", "scopes": ["collections:write", "payouts:write", "read"], "environment": "live"}All three fields are optional. Omitting scopes (or sending an empty array) grants every scope;
omitting environment mints a live key.
Handling keys safely
Section titled “Handling keys safely”- Keep keys server-side. Never ship one in a browser bundle, mobile binary, or public repository.
- Use a separate key per service and per environment so a leak has a small blast radius.
- Prefer the narrowest scope set that works. A read-only reporting job should hold only
read. - Log the
prefix, never the full key. The prefix is designed to be safe to display. - Subscribe to webhooks rather than polling, and keep key usage to what you need.