Request For Comments (RFCs)
  • Request for comments (RFC)
  • RFC 001: Matcher architecture
  • RFC 002: Archival Storage Service
  • RFC 003: Asset Access
  • RFC 004: METS Adapter
  • RFC 005: Reporting Pipeline
  • RFC 006: Reindexer architecture
  • RFC 007: Goobi Upload
  • RFC 008: API Filtering
  • RFC 009: AWS account setup
  • RFC 010: Data model
  • RFC 011: Network Architecture
  • RFC 012: API Architecture
  • RFC 013: Release & Deployment tracking
    • Deployment example
    • Version 1
  • RFC 014: Born digital workflow
  • RFC 015: How we work
    • Code Reviews
    • Shared Libraries
  • RFC 016: Holdings service
  • URL Design
  • Pipeline Tracing
  • Platform Reliability
    • CI/CD
    • Observability
    • Reliability
  • RFC 020: Locations and requesting
  • RFC 021: Data science in the pipeline
  • RFC 022: Logging
    • Logging example
  • RFC 023: Images endpoint
  • RFC 024: Library management
  • RFC 025: Tagging our Terraform resources
  • RFC 026: Relevance reporting service
  • RFC 026: Relation Embedder
  • RFC 027: Pipeline Intermediate Storage
  • RFC 029: Work state modelling
  • Pipeline merging
  • RFC 031: Relation Batcher
  • RFC 032: Calm deletion watcher
  • RFC 033: Api internal model versioning
  • RFC 034: Modelling Locations in the Catalogue API
  • RFC 035: Modelling MARC 856 "web linking entry"
  • RFC 036: Modelling holdings records
  • API faceting principles & expectations
  • Matcher versioning
  • Requesting API design
  • TEI Adapter
  • Tracking changes to the Miro data
  • How do we tell users how to find stuff?
  • Removing deleted records from (re)indexes
  • RFC 044: Tracking Patron Deletions
  • Work relationships in Sierra, part 2
    • Work relationships in Sierra
  • Born Digital in IIIF
  • Transitive hierarchies in Sierra
  • RFC 047: Changing the structure of the Catalogue API index
  • RFC 048: Concepts work plan
  • RFC 049: Changing how aggregations are retrieved by the Catalogue API
  • RFC 050: Design considerations for the concepts API
  • RFC 051: Ingesting Library of Congress concepts
  • RFC: 052: The Concepts Pipeline - phase one
  • RFC 053: Logging in Lambdas
  • RFC 054: Authoritative ids with multiple Canonical ids.
  • RFC 055: Genres as Concepts
  • RFC 055: Content API
    • Content API: articles endpoint
    • Content API: Events endpoint
    • Content API: exhibitions endpoint
    • The future of this endpoint
  • RFC 056: Prismic to Elasticsearch ETL pipeline
  • RFC 57: Relevance testing
    • Examples of rank CLI usage
  • RFC 059: Splitting the catalogue pipeline Terraform
  • RFC 060: Service health-check principles
  • RFC 060: Offsite requesting
    • Sierra locations in the Catalogue API
  • Content-api: next steps
Powered by GitBook
On this page
  • Access conditions
  • Determining access conditions
  • Requesting
  1. RFC 060: Offsite requesting

Sierra locations in the Catalogue API

PreviousRFC 060: Offsite requestingNextContent-api: next steps

Last updated 10 months ago

  1. locations which consist of a code and a name . There are a large number of possible values of these.

  2. Catalogue API items have locations which can be DigitalLocations or PhysicalLocations. This document is about physical locations.

  3. have locationTypes which have an id and a label. These can currently take the following values:

id
label

closed-stores

Closed stores

open-shelves

Open shelves

on-exhibition

On exhibition

on-order

On order

  1. We currently map Sierra item locations to the above locationTypes using the name only. We could also use the code, but we currently don't. is done by looking for case-insensitive substrings in the location names:

substring exists in name?
locationType ID

archives & mss well.coll

closed-stores

at digitisation

closed-stores

by appointment

closed-stores

closed stores

closed-stores

conservation

closed-stores

early printed books

closed-stores

iconographic collection

closed-stores

offsite

closed-stores

unrequestable

closed-stores

biographies

open-shelves

folios

open-shelves

history of medicine

open-shelves

journals

open-shelves

medical collection

open-shelves

medicine & society collection

open-shelves

open shelves

open-shelves

quick ref collection

open-shelves

quick ref. collection

open-shelves

rare materials room

open-shelves

student coll

open-shelves

exhibition

on-exhibition

Additionally:

    • We find all the distinct valid locationTypes of the other items

    • If there is only one, we use that for this location too. Otherwise, we assign no locationType.

Access conditions

Access methods can currently take the following values:

id
label

online-request

Online request

manual-request

Manual request

not-requestable

Not requestable

view-online

View online

open-shelves

Open shelves

Access statuses can take the following values:

id
Label

open

Open

open-with-advisory

Open with advisory

restricted

Restricted

by-appointment

By appointment

temporarily-unavailable

Temporarily unavailable

unavailable

Unavailable

closed

Closed

licensed-resources*

Licensed resources

permission-required

Permission required

Availability and Restrictions

Internally, access statuses also have derived boolean properties of isAvailable and hasRestrictions. Access conditions and locations inherit these properties transitively.

  • An access status is available if it is open, open-with-advisory, or is a licensed-resource that is not a related resource.

  • An access status has restrictions if it is open-with-advisory, restricted, by-appointment, closed or permission-required.

Externally, these properties have the following effects:

  1. Catalogue API works have availabilities, a list of any number (including none) of the following:

id
label

online

Online

closed-stores

Closed stores

open-shelves

Open shelves

  • A work has an online availability if any of its items have a DigitalLocation which is available

  • A work has an open-shelves availability if any of its items have a PhysicalLocation with an open-shelves location type

  1. Catalogue API digital location thumbnails are not populated if the location is restricted.

Determining access conditions

  • Hold count

  • Status code in fixed field 88

  • OPAC message code in fixed field 108

  • The result of the Sierra rules for requesting (see below)

  • The location type (see above)

  • The presence of a due date in fixed field 65

  • The notes, in any varfield with a field tag n

  • The reserves notes, in any varfield with a field tag r

Rules for requesting

Mapping Sierra data to access conditions

Note JP 19/01/2024: the rules are described here in the roughly same way that they are written in the code. My view is that the logic here has grown in a way which mixes wholly unrelated concerns and that it would be possible and desirable to rewrite this mapping in a way that would be easier to reason about. I think a "funneling" or flowchart-like approach to the mapping would be preferable to this very flat representation.

For closed-stores location types:

  • If they have no holds, an available status code, an online request OPAC message, and are determined as requestable by the rules for requesting: they are accessible by the method online-request with status open.

  • If they have no holds, an available status code, a restricted OPAC message, and are determined as requestable by the rules for requesting: they are accessible by the method online-request with status restricted.

  • If they have no holds, an available status code, a manual request OPAC message, and are determined as not requestable with a message corresponding to "needs manual request" by the rules for requesting: they are accessible by the method manual-request. Relevant notes are copied into the notes field.

  • If they have a closed status code, an unavailable OPAC message, and are determined as not requestable with a message corresponding to a closed item by the rules for requesting: they are not-requestable with status closed.

  • If they have no holds, a permission required status code, a by appointment OPAC message, and are determined as not requestable with a message corresponding to "no public message" by the rules for requesting: they are accessible by the method manual-request with status by-appointment.

  • If they have no holds, a permission required status code, a donor permission OPAC message, and are determined as not requestable by the rules for requesting: they are accessible by the method manual-request with status permission-required.

  • If they have 1 or more holds: they are not-requestable with status temporarily-unavailable.

  • If the rules for requesting determine them to be not requestable with a message corresponding to "in use by another reader": they are not-requestable with status temporarily-unavailable.

For open-shelves location types:

  • If they have no holds, an available status code, an open shelves OPAC message, no due date, and are determined as not requestable with a message corresponding to "on open shelves" by the rules for requesting: they are accessible by the method open-shelves.

  • If they are determined as not requestable with a message corresponding to "in use by another reader" by the rules for requesting: they are open-shelves with status temporarily-unavailable.

  • If they have a due date: they are open-shelves with status temporarily-unavailable.

on-exhibition location types with a non-empty reserve notes varfield are not-requestable with the note from the reserve notes.

Finally, for all locations not yet mapped:

  • If they are determined as not requestable with a message corresponding to "request top item" by the rules for requesting: they are not-requestable with a note from the message.

  • If they have no location type, a closed access status, an unavailable OPAC message, and are determined as not requestable with a message corresponding to a closed item by the rules for requesting: they are not-requestable with status closed.

  • If they have an unavailable status code, an unavailable OPAC message, and are determined as not requestable with a message corresponding to "item unavailable" or "at digitisation" by the rules for requesting: they are not-requestable with status temporarily-unavailable.

  • If they have a missing or withdrawn status code annd are determined as not requestable with a message corresponding to "item missing" or "item withdrawn" by the rules for requesting: they are not-requestable with status unavailable.

  • If any non-mapped item has a due date, it is not-requestable with status temporarily-unavailable.

  • Any remaining items are not-requestable.

Requesting

Note JP 19/01/2024: is it wise to duplicate a subset of the logic from the pipeline like this? Why are we representing rules for requesting results as Options?

An item is requestable via the items API if all of the below hold:

  • It is in the closed stores

  • It has an available status code

  • It has no current holds

  • It satisfies the rules for requesting

  • It has an OPAC message for online request or restricted access

Note JP 19/01/2024: Are all of these necessary? Why don't the rules for requesting cover the status code and OPAC message?

From the perspective of API consumers, this is equivalent to an item being requestable if it:

  • Has a location type of closed-stores

  • Has an online-request access method

  • Has an open, open-with-advisory, or restricted access status

Request dates

A list of valid pickup dates is created by the frontend webapp and presented to the user by using the venue opening times.

  1. We take the list of all days on which the library is open (starting the next open day if it's currently before 10am, or 2 working days later if it's after 10am) over the next 2 weeks.

  2. If there are any exceptional (ie non-routine working hours) closure dates during that period, we extend the list until until the total number of available days is equivalent to a normal 2 week period.

The data for opening times comes from Prismic.

Note JP 19/01/2024: the way this data is computed is very complex. I wonder if it could be simplified. It also feels like the responsibility to provide possible pickup dates should reside in the items API, although this would require it to talk to Prismic.

If the name is empty, or if it contains bound in above or contained in above, we look at the on the bib:

on-order items are created using order records and can be considered separate for the purposes of this document.

Locations in the catalogue API (described above) have consisting of a method and optionally a status, plus some optional free text terms and/or a note.

*the internal representation of licensed resources is further specified into "resources" and "related resources" as per , in order to implement availability.

A work has a closed-stores availability if any of its items have a PhysicalLocation with a closed-stores location type and none of the work's notes are a terms-of-use note that that the work is held at another institution. Note JP 18/01/24: this seems like a hack, should we address it?

Access methods are determined as a of the item in Sierra:

The "rules for requesting" live in Sierra, but are replicated in both the and the . They determine whether an item is requestable or not. If it is not requestable, the rules can provide a message.

Answering the question of "what makes a work requestable?" thankfully only requires knowledge of a subset of the above. This is represented by the in the items API.

The items API can receive a request with a pickupDate. This is not validated (other than for correctness) against any opening times etc. It is placed in the hold note with the "Requested for: yyyy-MM-dd".

Sierra items have
Catalogue API physical locations
This mapping
other items
slightly differently
accessConditions
MARC 856 ind 2
implies
function of the following properties
catalogue pipeline
items API
equivalent class
format