BookOps-CAT / bookops-worldcat

BookOps WorldCat Metadata API wrapper
https://bookops-cat.github.io/bookops-worldcat/
MIT License
35 stars 7 forks source link

Reordered metadata methods #85

Closed charlottekostelic closed 7 months ago

charlottekostelic commented 7 months ago

Changed default status_forcelist in _session.py Added more tests to _session.py Changed method names and reordered MetadataSession

charlottekostelic commented 7 months ago

@klinga, I made all of the requested edits and went through the args for each endpoint to clarify which are required and which are optional. In most cases we only have default values for args that OCLC has provided a default value for. The only instances in which this is not the case is with preferredLanguage and inCatalogLanguage which have 'eng' as the default value.

There are some args which are technically optional but one of a few options must be included in a query (eg. summary_holdings_get must contain either oclcNumber, isbn, or issn). I added this and similar details to the doc strings to hopefully make it a bit clearer to users but if you have a suggestion about a better way to document this, let me know. The error messages from the API are mostly helpful but some of them are misleading and suggest using args that aren't actually available for a particular endpoint.