Keep both on the server, in your host’s environment variables or a secrets manager. Never put them in code that runs in a browser.
API keys
An API key lets your app start runs, emit events, register workflows, and save steps, all in one project. A project can have up to 10 API keys, so each app or each server can have its own.Create a key
Go to API keys and create one. A key takes:- A name, up to 256 characters, that says where it’s used, like
production servers. - A project. Its endpoint must be set first, since a key is what lets your app start runs.
- Allowed IPs, if you want: up to 20 addresses or ranges, like
203.0.113.7or203.0.113.0/24, in IPv4 or IPv6. Requests from any other address are turned down withipNotAllowed. Leave it empty to accept requests from anywhere. - An expiry date, if you want. After that date, the key is turned down with
apiKeyInvalid.
Change or revoke a key
Edit a key to change its name, its allowed IPs, or its expiry date. The change applies to the next request. Delete a key to revoke it. Requests using it are turned down at once withapiKeyInvalid, so put the new key in place first.
Replace a key without downtime
- Create a new key in the same project.
- Set it as
NELKAP_API_KEYin your app, and deploy. - Once every instance of your app runs with the new key, delete the old one.
The project secret
Every project has one secret. Nelkap sends it in theAuthorization header of each call to your endpoint, and handle compares it with NELKAP_SECRET. A call without the right secret gets a 401, and no workflow runs.
You can reveal the secret from your project at any time.
Rotate the secret
Rotate the secret if it leaked. The old one stops working at once, and your endpoint turns every call away until it has the new one:- Rotate the secret from your project, and copy the new one.
- Set it as
NELKAP_SECRETin your app, and deploy right away.
deliveryFailed: replay it once the new secret is live.
Who can do what
See Members and roles.