Ready to Learn?Ex Libris products all provide open APIs

Tech Blog

 

Using Alma APIs for displaying overdue laptops

Duncan Wilson on January 9th, 2018

Our library loans laptops with an item policy of 24 hours. We wanted to display laptops borrowed from the previous day, in order to show those that could go overdue.
 
We use the Bibs API to retrieve data on laptops that were overdue based on the due date and time, then we present this information in a webpage.
 
There is a caveat to using this in being aware of the number of API calls the application makes as each laptop has a unique bibliographic record and so to get information on each one then an individual API call is made. Our library has over 300 laptops and so using the application regularly could result in the API limit being exceeded. As a consequence the live version of the application is for internal use only restricted to the host institution.
 
In order to speed up the application the laptop records are in groups of 60 records and a front facing webpage (see HTML page sample here) contains 6 AJAX functions which call 6 separate scripts (see example of one of these here) that make the API calls. Therefore these can run in parallel and present the data to the webpage so that the GET requests aren't iterating through in a long list slowing down how quickly the data can be presented but can still be presented on the same page.