Rate Limiting With the Data API

To ensure quality of service, Learnosity rate limits the requests to the Data API per consumer key.

The rate limits use a window duration of 5 seconds. If a request will exceed the rate limit within any 5 second window, the Data API returns an HTTP 429 "Too many requests" response code.

The body of the HTTP 429 response has this structure:

{
   "meta": {
      "status": false,
      "code": 42000,
      "message": "Too many requests"
   }
}

 

If you receive a 429 response, allow the window duration of 5 seconds to elapse before retrying the request. Also be mindful of any concurrent processes using the same consumer key that might be competing for the request quota.

The following quotas reflect the maximum number of requests allowed to each endpoint within any 5 second window.

For brevity, the table only contains the top level endpoints. A '*' indicates the quota value is applied separately to each endpoint under the given path (except where a quota for a specific child path is provided).

Rate limiting is applied per individual endpoint, so requests to [GET] itembank/activities are not counted against the quota for [GET] itembank/items. Exceeding the limit for one endpoint does not affect requests sent to any other endpoint.

If these limits pose a concern for your implementation, please discuss your use case with the Learnosity support team.

[Action] Endpoint Requests / 5 second window
[GET] /itembank/* 1000
[GET] /itembank/conversion/* 50
[SET] /itembank/* 50
[UPDATE] /itembank/* 50
[GET] /jobs/* 1000
[SET] /jobs/* 50
[UPDATE] /jobs/* 50
[GET] /scoring 2000
[GET] /sessions/* 1000
[SET] /sessions 50
[UPDATE] /sessions/responses/scores 1000
[UPDATE] /sessions/item 1
[GET] /reports/* 1000
[SET] /reports/* 50
[SET] /consumers 50
Was this article helpful?

Did you arrive here by accident? If so, learn more about Learnosity.