foliolib.folio.api.kbEbscoJava.Titles

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

Bases: foliolib.folio.FolioApi

Parameters
  • tenant (str) – Tenant id

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

Methods

get_title(titleId, **kwargs)

Get the title by its unique identifier.

get_titles(**kwargs)

Get a set of titles matching the given search criteria.

modify_title(titleId, title)

Update Custom Title.

set_title(title)

Create a new Custom Title.

get_title(titleId: str, **kwargs)

Get the title by its unique identifier.

GET /eholdings/titles/{titleId}

Parameters
  • titleId (str) –

  • **kwargs (properties) – Keyword Arguments

Keyword Arguments

include (str) –

Include related resource objects, each representing a partnering of this title with a package. Any bogus value, like include=deciduousTrees, will be silently ignored.

Example

  • resources

Returns

See Schema below

Return type

dict

Raises

OkapiRequestNotFound – Not Found

Schema

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Title",
  "type": "object",
  "properties": {
    "id": {
      "description": "UUID of this title",
      "$ref": "../../common/schemas/uuid.json"
    },
    "expectedReceiptDate": {
      "description": "Vendor agreed date prior to the Receipt Due date item is expected to be received by",
      "type": "string",
      "format": "date-time"
    },
    "title": {
      "description": "The title name",
      "type": "string"
    },
    "poLineId": {
      "description": "UUID of the purchase order line this Title is associated with",
      "$ref": "../../common/schemas/uuid.json"
    },
    "instanceId": {
      "description": "UUID of the instance associated with this Title",
      "$ref": "../../common/schemas/uuid.json"
    },
    "productIds": {
      "description": "List of product identifiers",
      "id": "productIds",
      "type": "array",
      "items": {
        "$ref": "product_identifier.json"
      }
    },
    "contributors": {
      "description": "List of contributors to the material",
      "id": "contributors",
      "type": "array",
      "items": {
        "type": "object",
        "$ref": "contributor.json"
      }
    },
    "publisher": {
      "description": "Publisher of the material",
      "type": "string"
    },
    "edition": {
      "description": "Edition of the material",
      "type": "string"
    },
    "packageName": {
      "description": "The name of the package",
      "type": "string"
    },
    "poLineNumber": {
      "description": "The number of the POL identified by poLineId",
      "type": "string",
      "pattern": "^[a-zA-Z0-9]{1,16}-[0-9]{1,3}$"
    },
    "publishedDate": {
      "description": "Year of the material's publication",
      "type": "string"
    },
    "receivingNote": {
      "description": "Receiving note of the POL identified by poLineId",
      "type": "string"
    },
    "subscriptionFrom": {
      "description": "The start date of the subscription",
      "type": "string",
      "format": "date-time"
    },
    "subscriptionTo": {
      "description": "The end date of the subscription",
      "type": "string",
      "format": "date-time"
    },
    "subscriptionInterval": {
      "description": "The subscription interval in days",
      "type": "integer"
    },
    "isAcknowledged": {
      "description": "Flag for acknowledge receiving note",
      "type": "boolean",
      "default": false
    },
    "metadata": {
      "type": "object",
      "$ref": "../../../raml-util/schemas/metadata.schema",
      "readonly": true
    }
  },
  "additionalProperties": false,
  "required": [
    "title",
    "poLineId"
  ]
}
get_titles(**kwargs)

Get a set of titles matching the given search criteria.

GET /eholdings/titles

Parameters

**kwargs (properties) – Keyword Arguments

Keyword Arguments
  • filter[tags] (list) – Filter to narrow down results based on assigned tags. Contains list of required tags.

  • filter[access-type] (list) – Filter to narrow down results based on assigned access type.

  • filter[selected] (str) –

    Filter to narrow down results based on selection status. Defaults to all. Possible values are all, true, false, ebsco.

    Example

    • ebsco

  • filter[type] (str) – Filter to narrow down results based on content type. Possible values are all, audiobook, book, bookseries, database, journal, newsletter, newspaper, proceedings, report, streamingaudio, streamingvideo,thesisdissertation, website, unspecified.

  • filter[name] (str) –

    String to search title name to get a collection of titles

    Example

    • War and Peace

  • filter[isxn] (str) –

    String to search ISSN and ISBN to get a collection of titles

    Example

    • 1050-3331

  • filter[subject] (str) –

    String to search subjects to get a collection of titles

    Example

    • history

  • filter[publisher] (str) –

    String to search publishers to get a collection of titles

    Example

    • academic

  • filter[packageIds] (list) – Search by package ids.

  • include (str) –

    Include related resource objects, each representing a partnering of this title with a package. Any bogus value, like include=deciduousTrees, will be silently ignored.

    Example

    • resources

  • sort (str) – (default=relevance) Option by which results are sorted. Possible values are name, relevance.

  • page (int) –

    (default=1) Page number

    Example

    • 1

  • count (int) –

    (default=<<defaultCountValue>>) Page size

    Example

    • 100

Returns

See Schema below

Return type

dict

Schema

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Collection of titles",
  "type": "object",
  "properties": {
    "titles": {
      "description": "Collection of titles",
      "type": "array",
      "id": "titles",
      "items": {
        "$ref": "title.json"
      }
    },
    "totalRecords": {
      "description": "The number of objects contained in this collection",
      "type": "integer"
    }
  },
  "additionalProperties": false,
  "required": [
    "titles",
    "totalRecords"
  ]
}
modify_title(titleId: str, title: dict)

Update Custom Title.

PUT /eholdings/titles/{titleId}

Parameters
  • titleId (str) –

  • title (dict) – See Schema below

Returns

See Schema below

Return type

dict

Raises

OkapiRequestUnprocessableEntity – Unprocessable Entity

Schema

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Title",
  "type": "object",
  "properties": {
    "id": {
      "description": "UUID of this title",
      "$ref": "../../common/schemas/uuid.json"
    },
    "expectedReceiptDate": {
      "description": "Vendor agreed date prior to the Receipt Due date item is expected to be received by",
      "type": "string",
      "format": "date-time"
    },
    "title": {
      "description": "The title name",
      "type": "string"
    },
    "poLineId": {
      "description": "UUID of the purchase order line this Title is associated with",
      "$ref": "../../common/schemas/uuid.json"
    },
    "instanceId": {
      "description": "UUID of the instance associated with this Title",
      "$ref": "../../common/schemas/uuid.json"
    },
    "productIds": {
      "description": "List of product identifiers",
      "id": "productIds",
      "type": "array",
      "items": {
        "$ref": "product_identifier.json"
      }
    },
    "contributors": {
      "description": "List of contributors to the material",
      "id": "contributors",
      "type": "array",
      "items": {
        "type": "object",
        "$ref": "contributor.json"
      }
    },
    "publisher": {
      "description": "Publisher of the material",
      "type": "string"
    },
    "edition": {
      "description": "Edition of the material",
      "type": "string"
    },
    "packageName": {
      "description": "The name of the package",
      "type": "string"
    },
    "poLineNumber": {
      "description": "The number of the POL identified by poLineId",
      "type": "string",
      "pattern": "^[a-zA-Z0-9]{1,16}-[0-9]{1,3}$"
    },
    "publishedDate": {
      "description": "Year of the material's publication",
      "type": "string"
    },
    "receivingNote": {
      "description": "Receiving note of the POL identified by poLineId",
      "type": "string"
    },
    "subscriptionFrom": {
      "description": "The start date of the subscription",
      "type": "string",
      "format": "date-time"
    },
    "subscriptionTo": {
      "description": "The end date of the subscription",
      "type": "string",
      "format": "date-time"
    },
    "subscriptionInterval": {
      "description": "The subscription interval in days",
      "type": "integer"
    },
    "isAcknowledged": {
      "description": "Flag for acknowledge receiving note",
      "type": "boolean",
      "default": false
    },
    "metadata": {
      "type": "object",
      "$ref": "../../../raml-util/schemas/metadata.schema",
      "readonly": true
    }
  },
  "additionalProperties": false,
  "required": [
    "title",
    "poLineId"
  ]
}
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "title": "Title object schema",
  "description": "Title object schema",
  "javaType": "org.folio.rest.jaxrs.model.Title",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "data": {
      "type": "object",
      "description": "The Data Schema",
      "properties": {
        "id": {
          "type": "string",
          "description": "The Id Schema",
          "example": "100130"
        },
        "type": {
          "type": "string",
          "description": "Title Type",
          "example": "titles"
        },
        "attributes": {
          "type": "object",
          "description": "The Attributes Schema",
          "$ref": "titleData.json"
        },
        "relationships": {
          "type": "object",
          "description": "Displays title relationships",
          "$ref": "../relationships.json"
        }
      }
    },
    "included": {
      "type": "array",
      "description": "List of resources for a given title",
      "items": {
        "type": "object",
        "$ref": "../resources/resourceCollectionItem.json"
      }
    },
    "jsonapi": {
      "type": "object",
      "description": "version of json api",
      "$ref": "../jsonapi.json"
    }
  },
  "required": [
    "data"
  ]
}
set_title(title: dict)

Create a new Custom Title.

POST /eholdings/titles

Parameters

title (dict) – See Schema below

Returns

See Schema below

Return type

dict

Raises
  • OkapiRequestError – Bad Request

  • OkapiRequestUnprocessableEntity – Unprocessable Entity

Schema

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Title",
  "type": "object",
  "properties": {
    "id": {
      "description": "UUID of this title",
      "$ref": "../../common/schemas/uuid.json"
    },
    "expectedReceiptDate": {
      "description": "Vendor agreed date prior to the Receipt Due date item is expected to be received by",
      "type": "string",
      "format": "date-time"
    },
    "title": {
      "description": "The title name",
      "type": "string"
    },
    "poLineId": {
      "description": "UUID of the purchase order line this Title is associated with",
      "$ref": "../../common/schemas/uuid.json"
    },
    "instanceId": {
      "description": "UUID of the instance associated with this Title",
      "$ref": "../../common/schemas/uuid.json"
    },
    "productIds": {
      "description": "List of product identifiers",
      "id": "productIds",
      "type": "array",
      "items": {
        "$ref": "product_identifier.json"
      }
    },
    "contributors": {
      "description": "List of contributors to the material",
      "id": "contributors",
      "type": "array",
      "items": {
        "type": "object",
        "$ref": "contributor.json"
      }
    },
    "publisher": {
      "description": "Publisher of the material",
      "type": "string"
    },
    "edition": {
      "description": "Edition of the material",
      "type": "string"
    },
    "packageName": {
      "description": "The name of the package",
      "type": "string"
    },
    "poLineNumber": {
      "description": "The number of the POL identified by poLineId",
      "type": "string",
      "pattern": "^[a-zA-Z0-9]{1,16}-[0-9]{1,3}$"
    },
    "publishedDate": {
      "description": "Year of the material's publication",
      "type": "string"
    },
    "receivingNote": {
      "description": "Receiving note of the POL identified by poLineId",
      "type": "string"
    },
    "subscriptionFrom": {
      "description": "The start date of the subscription",
      "type": "string",
      "format": "date-time"
    },
    "subscriptionTo": {
      "description": "The end date of the subscription",
      "type": "string",
      "format": "date-time"
    },
    "subscriptionInterval": {
      "description": "The subscription interval in days",
      "type": "integer"
    },
    "isAcknowledged": {
      "description": "Flag for acknowledge receiving note",
      "type": "boolean",
      "default": false
    },
    "metadata": {
      "type": "object",
      "$ref": "../../../raml-util/schemas/metadata.schema",
      "readonly": true
    }
  },
  "additionalProperties": false,
  "required": [
    "title",
    "poLineId"
  ]
}
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "title": "Title object schema",
  "description": "Title object schema",
  "javaType": "org.folio.rest.jaxrs.model.Title",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "data": {
      "type": "object",
      "description": "The Data Schema",
      "properties": {
        "id": {
          "type": "string",
          "description": "The Id Schema",
          "example": "100130"
        },
        "type": {
          "type": "string",
          "description": "Title Type",
          "example": "titles"
        },
        "attributes": {
          "type": "object",
          "description": "The Attributes Schema",
          "$ref": "titleData.json"
        },
        "relationships": {
          "type": "object",
          "description": "Displays title relationships",
          "$ref": "../relationships.json"
        }
      }
    },
    "included": {
      "type": "array",
      "description": "List of resources for a given title",
      "items": {
        "type": "object",
        "$ref": "../resources/resourceCollectionItem.json"
      }
    },
    "jsonapi": {
      "type": "object",
      "description": "version of json api",
      "$ref": "../jsonapi.json"
    }
  },
  "required": [
    "data"
  ]
}