foliolib.folio.api.oaiPmh.OaiPmh

class foliolib.folio.api.oaiPmh.OaiPmh(tenant: str, okapi: Optional[foliolib.okapi.okapiClient.OkapiClient] = None)

Bases: foliolib.folio.FolioApi

OAI-PMH Business Logic API

The Open Archives Initiative Protocol for Metadata Harvesting (OAI-PMH) provides

an application-independent interoperability framework based on metadata harvesting. This module supports the OAI-PMH as a means of exposing FOLIO metadata.

Parameters
  • tenant (str) – Tenant id

  • okapi (OkapiClient, optional) – Instance of OkapiClient. Defaults to None.

Methods

get_records(**kwargs)

GET /oai/records

get_records(**kwargs)

GET /oai/records

Parameters

**kwargs (properties) – Keyword Arguments

Keyword Arguments
  • verb (str) – verb that specifies oai-pmh request type

  • identifier (str) – parameter that is used for GetRecord and ListMetadataFormats requests

  • resumptionToken (str) – flow control token returned by a ListIdentifiers request that issued an incomplete list

  • from (str) –

    UTC datetime value, which specifies a lower bound for datestamp-based selective harvesting

    Example

    • 2018-10-15 15:16:17+00:00

  • until (str) –

    UTC datetime value, which specifies a upper bound for datestamp-based selective harvesting

    Example

    • 2018-10-22 23:22:21+00:00

  • set (str) – setSpec value, which specifies set criteria for selective harvesting

  • metadataPrefix (str) – metadata prefix of the format that should be included in the metadata part of the returned record

Raises
  • OkapiRequestError – Bad Request

  • OkapiRequestNotFound – Not Found

  • OkapiRequestUnprocessableEntity – Unprocessable Entity

  • OkapiFatalError – Server Error

  • OkapiFatalError – Server Error