The returned data.table
contains fields for various pieces of
metadata returned by the API request. These fields include the
ISBN/ISSN/OCLC number used, title of work, author, total number of
holdings, total number of electronic holdings, call number type,
call number recommendation (by most popular), number of holdings
using that call number, the HTTP status code, and the Classify
API response code.
For each ISBN/ISSN/OCLC number used, two rows will be returned; one for
the DDC and one for the LCC. Common information (work metadata)
will the the same in both rows. If one of the call numbers is missing,
the recommendation and holdings fields will be NA.
The API can be persnickety, and there are many things that can go
wrong. For example, the API can respond with multiple works for a
single standard number (ISBN 9780900565748, for example). If this happens,
no attempt is made to follow one of the results, and the returned
data.table
will return no useful information.
If the http_status_code
is 200 and the classify_response_code
is 0, you've received good results.If the classify_response_code
is
4, the standard number may have returned multiple works.
The http_status_code
should never not be 200.
If something went wrong (for example, the status/response codes are not
200 and 0, respectively), you may want to re-run the function call with
print.api.responses
set to TRUE
. This will print the
HTTP status code and the raw XML text response from the API.
As with all API access functions in this package, it's up to the
user to limit their API usage so as to not get blocked. These
functions are deliberately not vectorized for this reason; they
only accept one standard number at a time.
Final note: all of these API functions seem to work better with
OCLC numbers than any other standard number. If multiple standard
numbers are available, using the OCLC number is always preferred.