API keys, scopes and rate limits
How keys become access tokens, what a key can reach on each store, how IP lists work, and how many requests a key can send.
Last updated 2026-11-30
A key decides who is calling and what they may touch. This article covers how a key turns into a token, what a key can reach, how to lock it to your addresses, and how fast it can call.
Keys and tokens
The API uses two credentials:
| API key | Access token | |
|---|---|---|
| Looks like | hlak_ followed by random characters |
A JWT (three dot-separated parts) |
| Lasts | Until it expires or is revoked | One hour |
| Used for | POST /v1/auth/token only |
Every other call |
You keep the key and exchange it for a token when you need one. Every other request carries the token.
Exchanging a key for a token
Send the key as a bearer credential, with no body:
POST /v1/auth/token
Authorization: Bearer hlak_...
The answer is the standard OAuth 2.0 client-credentials shape, so most HTTP client libraries can store and refresh it for you:
{ "access_token": "eyJ...", "token_type": "Bearer", "expires_in": 3600 }
Then call everything else with Authorization: Bearer <access_token>.
Treat the token as opaque. Don't parse it or check its timestamps yourself. Its issued-at time is set a minute in the past, which some JWT libraries reject when they verify locally. The API checks it for you.
Refreshing
A token lasts one hour (expires_in is 3600 seconds). Reuse it for the whole hour, then
exchange the key again:
- Exchange again a minute or so before
expires_inruns out. - If a call comes back with the gateway's 401,
{"message":"Unauthorized"}, exchange once and retry the call once. If that fails too, stop and look at the error.
Each key has an exchange allowance of 10 that refills at 10 a minute, so a key can exchange
about 20 times in its first minute and 10 a minute after that. A healthy client needs one
exchange an hour, so this only stops a client stuck in a loop. Over it, the answer is 429
api_key_exchange_rate_limited with Retry-After.
Creating and managing keys
Keys live on the My API Keys tab in Settings. For each key you choose:
- A name and an optional description. Names are unique among your active keys.
- The stores it can reach, and which areas it can read or write. The key editor applies the same permissions to every store the key reaches; for different access on different stores, create a key per store.
- When it expires: after 30 days, 180 days or 1 year (the default). The expiry is set when the key is created and can't be changed. When a key runs out, create a new one.
The key is shown once. HippoLink keeps only a fingerprint of it, so a lost key can't be recovered: revoke it and create a new one. You can hold up to 25 active keys, and each key can reach up to 50 stores.
You can rename a key and change its stores, its access and its IP list at any time. Revoking a key, or narrowing its access, takes effect on the next request, including for tokens already issued from it. A revoked key stays in your list, marked with who revoked it: you, or HippoLink support (for example, after a key was found exposed). A store owner can also remove a key's access to their store without touching its other stores.
Who can use the API on a store
A store owner can always use the API on their own store. A manager or an employee needs the
store owner to turn on the API access switch for them on Settings > Team. Until then,
their keys get 403 api_access_not_enabled on that store.
A key never does more than the person holding it. Your role on the store and the store's permission settings still apply to every call, so an employee's key reaches what that employee can reach in the web app, and no more. If you are removed from a store, or your role changes, your keys follow on the very next request.
Restricting a key to your addresses
Limit each key to the IP addresses your software runs from, so a key that leaks can't be used anywhere else. Set the list in the key's settings on My API Keys. A key with no list works from any address.
The list holds up to 50 entries. Each one can be:
- One address:
203.0.113.7or2001:db8::1. - A range in CIDR notation:
203.0.113.0/24or2001:db8:1234::/48. - An IPv4 address with trailing wildcards:
203.0.113.*,10.20.*.*or10.*.*.*, the same as/24,/16and/8. A wildcard in the middle, such as10.*.1.5, isn't accepted, and neither is a bare*. To allow every address, leave the list empty.
HippoLink stores each entry as a range and shows it back that way, so 203.0.113.* reads
203.0.113.0/24 and 203.0.113.7 reads 203.0.113.7/32. An entry already inside another one
is dropped. An IPv4 address written in IPv6 form (::ffff:203.0.113.7) counts as the IPv4
address.
The list is checked on every token exchange and every call, so a change applies to tokens
already issued. A call from another address is refused with 403 api_key_ip_not_allowed, and
params.source_ip is the address it came from. If that address is yours, add it to the list.
A refused exchange doesn't spend the key's exchange allowance.
Stores that require a list
A store owner can require every key that reaches their store to have an IP list. A key with no
list is then refused on that store only, with 403 api_key_ip_restriction_required and
params.store_uuid naming the store. The key keeps working on your other stores, and the token
exchange still succeeds. While a key has no list, you can't give it access to such a store, or
clear its list while it has access to one.
Scopes: what a key can reach
A key holds one grant per store. Each grant gives the key read or write in each of a set of
areas. write includes read, with the exceptions below. The key editor shows each area by
the name in the second column.
| Area | In the key editor | What it covers |
|---|---|---|
inventory |
Inventory | Stock and its history, cost batches, store items, tags, labels, exports, marketplace listing drift and sync rejections, pull alerts |
locations |
Locations | Bins and other locations, what is in them, box rebuilds, bulk moves and their pull sheets |
orders |
Orders | Orders, fulfillment runs and pick lists, shipping rates, labels and scan forms, shipping rules, envelope labels, TCGplayer Direct and CardTrader Zero, TCGplayer message counts |
buylist |
Buylist | Buylist rules and settings, offers and their lines, pickup locations, the buylist storefront |
repricing |
Repricing | Repricing rules, previews, run history, schedules and price explanations |
integrations |
Integrations | Marketplace and shipping-provider connection status, sync and job history, and starting resyncs, pushes and imports |
kiosk |
Kiosk | The kiosk storefront config, publishing, bundles, email templates and the stale-order and auto-cancel settings. Kiosk orders are under orders |
reports |
Reports | Sales, trades, profit, margin, fees, refunds, returns and the other store reports. Read-only |
audit |
Audit log | The store's audit log. Read-only |
store_settings |
Store settings | Store details, currency rates, referral, status and import and export job history. Read-only |
price_lists |
Price lists | The store's buylist and retail price lists. Read-only |
shipping_purchases |
Buy postage | Buying shipping labels and voiding them. Write-only |
refunds |
Refunds | Refunds, marketplace reports and Snapcaster change requests. Write-only |
buylist_payouts |
Pay sellers (buylist) | Accepting, proposing and confirming changes to, completing, reconciling and pushing buylist offers. Write-only |
staff |
Team | Staff and pending invitations. Not served yet |
billing |
Billing | Daily costs and billing periods. Not served yet |
On a read-only area, write grants nothing extra, because changes stay in the web app. The
three write-only areas spend or return the store's money, so read on them grants nothing.
Each operation's required scope, written as area:access, is in the
endpoint reference.
A call into an area production doesn't serve answers a gateway 404. A grant on such an area does nothing until it is served.
The money areas
shipping_purchases, refunds and buylist_payouts sit apart from orders and buylist on
purpose:
orders:writecan't buy a label or issue a refund without the matching grant, andshipping_purchases:writecan't read an order withoutorders:read.buylist:writeedits offers but can't accept, propose or confirm changes to, complete, reconcile or push one, andbuylist_payouts:writecan't list offers withoutbuylist:read.- Pushing an offer, or completing a walk-in, adds the bought cards to inventory as part of the
purchase, so
buylist_payouts:writechanges stock withoutinventory:write. - On Mana Pool, Snapcaster, eBay, CardTrader and CardNexus, cancelling an order refunds the
buyer. Cancelling one of those orders with
updateOrderorbulkUpdateOrderStatusneedsrefunds:writeas well asorders:write, and a bulk request with one such order is refused whole.cancelOrderItemsneedsrefunds:writeonly on a Snapcaster order. Cancels on Square or TCGplayer need onlyorders:write.
Keep these three areas off any key that doesn't need them.
Endpoints that belong to no store
Your profile (GET /v1/users/me), your store list (GET /v1/stores) and the rule-language
tools for checking repricing and buylist rules belong to no store. They need only a key that
can reach at least one store where you still have API access. Through a key, both lists show
only the stores that key can use, and GET /v1/users/me shows no pending invitations.
Price list sharing
The price_lists area holds two read-only lists, the buylist and the retail list, covered in
Large lists, syncing and background jobs. Both need the store to be on the Pro plan or higher.
Each store a key can read price lists on carries its own sharing options, set by whoever holds the key in the key editor:
- The buylist, on or off.
- The retail list, on or off. With it on, the base price is always included, and you pick any of the marketplaces the store has a working connection to, whether to include quantities, and the last price update.
Anything not picked is left out of the response entirely: no field, no entry, not null. A
marketplace the store connects later is never added on its own. Asking for a list that isn't
shared, or for a marketplace= source that wasn't picked (BASE included), answers 403
api_key_price_list_not_shared with params.source naming it. The options for one store never
apply to another.
Rate limits
Each key has its own request budget, shared by every token minted from it and every endpoint. One key emptying its budget doesn't slow your other keys.
The budget is a bucket of 25 tokens that refills at 5 tokens a second, shown on the key's page as "5 requests/s, bursts of 25". You can send 25 calls at once, then about 5 a second. HippoLink support can set a different limit for a key, and the headers always show the limit of the key that made the call.
Most calls cost 1 token. Heavier ones (reports, exports, label and PDF generation, previews)
cost 5 or 10, and the endpoint reference gives
each operation's cost. A call refused for what the key may do on the store, such as a 403
api_key_scope_insufficient, api_key_store_denied or api_access_not_enabled, still costs
its tokens, so a script looping on a permission error runs out like any other. A call refused
because the key itself can't be used (a 401, or 403 api_key_ip_not_allowed) costs nothing.
| Header | Meaning |
|---|---|
X-RateLimit-Limit |
The size of the key's bucket (25 by default) |
X-RateLimit-Remaining |
Tokens left after this call |
X-RateLimit-Reset |
Whole seconds until the bucket is full again |
Over the limit, the answer is 429 api_rate_limited with a Retry-After header in seconds.
Wait that long, then try again.
The API gateway also has its own coarse throttle. When it trips, the answer is 429
{"message":"Too Many Requests"} with no Retry-After and no rate-limit headers. Back off for
a second or two, doubling the wait on each repeat.
The token exchange has its own allowance and doesn't use the request budget.
Every answer from HippoLink is gzip-compressed when the request sends Accept-Encoding: gzip,
except bodies under 4 KB, bodies that wouldn't get smaller, file downloads and answers to
HEAD. The gateway's own {"message": ...} answers are never compressed. Most HTTP clients send the header and
decompress for you.