Working with Query Quotas

Your AP Elections API key is assigned a quota (also referred to as throttle) setting for the number of API queries you can make per minute. Your API throttle value is indicated in your AP Elections API Welcome letter.

The recommended practices for working with API quotas are:

  • No need to synchronize your clock with the API. The minute time period covering each quota cycle does not begin at second one on a particular clock; instead, it begins when you make your first request (or first request following an idle period). Therefore, you do not need to synchronize your clock with the API.
  • Processing occasional '403: Per-minute quota exceeded' errors. Due to the timing differences between your client application sending a request and it being received and processed by the API, precise per-second quota management is not always practical from both the server and client perspective. Therefore, it is recommended that your client application gracefully handle occasional '403: Per-minute quota exceeded' errors by waiting 5-10 seconds and trying again.

 

  Note

 

Retrieving each individual report linked to the list of reports returned by the Election Reports method does not count against your quota limit.