API keys
If you are starting from zero tonight, follow Developer quickstart first and use this page as the deeper key-handling reference. Hilt API keys are for server-side merchant integrations and Hilt Pay API automation. They let a merchant’s own backend, bot, or automation call the public Hilt API directly from server-side code. If an AI agent or developer tool is doing the initial setup, use Agent setup first. Agent Bootstrap creates a sandbox setup intent and a temporary sandbox key before the owner approves live credentials.Create a key from the dashboard
The recommended path is:- sign in to the merchant dashboard
- open Advanced
- create a key in the key manager
- copy the raw key immediately
- store it in your secret manager
How to send the key
Send the key in the request header:What API keys should call
Use API keys for:- products
- hosted checkout helpers
- payment status
- Hilt Pay API apps, products, rail settings, payment sessions, entitlement checks, and webhooks
- memberships
- receipts
- support automation
Use API keys only on your backend
Do not:- embed a key in browser code
- ship it inside a mobile app
- expose it in a public checkout page
- hand it to third-party scripts
Recommended key lifecycle
| Step | Good practice |
|---|---|
| Create | Name the key for the system that will use it |
| Store | Put it in a secret manager immediately |
| Use | Restrict it to backend or bot-side code |
| Review | Check when it was last used and whether it is still needed |
| Revoke | Remove it when the integration is replaced or retired |
A production-friendly key setup
Most teams end up with at least two keys:- one key for the live backend or bot
- one key for support scripts or low-risk maintenance tasks
| Permission | Use |
|---|---|
access:read | Check entitlements and read Pay API rails |
access:write | Create Pay API apps, products, and payment sessions |
access:webhooks | Register webhook endpoints for Pay API flows |
- run simulated testing sessions safely
- separate pre-launch sandbox testing from live automation
- keep lower-risk integration work distinct from production traffic
Rotation playbook
When you need to rotate a key:- create the replacement key in the dashboard
- store it in your secret manager
- deploy the new value to the system that uses it
- make one read call such as
GET /v1/productsto confirm it works - revoke the old key
Naming pattern that works well
Good names tell the merchant what the key is for:Production Telegram botDiscord checkout integrationWarehouse fulfilment syncLaunch-week support script
First request examples
cURL
TypeScript
Python
A small server wrapper that scales well
If your backend will make more than a few Hilt calls, centralise the header handling instead of repeating it in every request.TypeScript
Python
Common mistakes
- creating one shared key for every integration
- leaving old keys active after the workflow has been replaced
- testing a backend flow with a dashboard cookie instead of a real key
- forgetting to store the raw key when it is first created
- hardcoding the key into the repo instead of reading it from environment or a secret manager
- giving an agent a broad live key before it has proven the setup in sandbox
Common questions
What permissions should a Hilt API key have?
Use the minimum permissions needed. Most server-side integrations needread; checkout creation or webhook subscription workflows may also need execute.

