API introduction

Rate limits and key limits

On this page

Two kinds of limit protect your store: how many requests a key may send, and how many wrong keys one address may try.

Requests per minute#

Each key may send 120 requests a minute unless the admin sets another number for it. A Super Admin can set any number from 1 to 6000 when creating or editing the key.

  • Every answer to an authenticated request carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset (a Unix time).
  • Over the limit you get 429 with rate_limited and a Retry-After header in seconds. Wait that long, then retry.
  • Spread bulk work over time, and use limit=100 and updated_since instead of reading everything again.
  • The limit belongs to the key, not to each program: all the software that uses one key shares one count. Give a busy system its own key, with a higher limit if it needs one.

Wrong keys#

Wrong keys are counted for each internet address: after 10 invalid keys within 5 minutes that address gets 429 (too_many_failed_attempts) for a while, with a Retry-After header. A key that is only paused does not count.

Limits of a key#

LimitValue
Requests per minuteDefault 120, highest 6000.
Allowed internet addressesUp to 50 (IPv4, IPv6 or ranges). Empty means any address.
Expiry dateOptional. Not set means the key does not expire.
Idempotency answersKept 24 hours.
Request log in the adminEvery call is listed with its address, result and time. Old rows are removed after 30 days.

Scopes, pausing and revoking are described under Authentication.