Tech Blog

New header in API response: X-Exl-Api-Remaining

Detailed information about API usage and daily threshold was made available in the dashboard and announced in a previous post.

However, in some cases a real-time feed can be useful, so we’ve added a new header which will be returned for each API request with the up-to-date number of remaining requests.
For example: X-Exl-Api-Remaining: 49999
The header’s value is the number of requests left until midnight according to the Institution’s Account Plan.

The numbers shown at the “Overview of API Usage” in the Reports page are updated less often than the number returned with the header, so the header should be considered¬†if you need exact number and the two sources do not match.

You can benefit from this header if for example you have 2 applications which are using APIs for different purposes in parallel. E.g. one is a weekly batch processing, and one handles online requests from a portal. In such a case, if the weekly batch has to process many records it might use up the account plan, and then the portal will stop functioning in the middle of the day. Using this header the batch job can pause when reaching a specific number of remaining requests, and continue the following day.

We hope that for those of you who make heavy use of the APIs will find this addition useful, as you continue to build new integrations with Ex Libris products.

Leave a Reply