Inventory Storage Instance Batch Sync Unsafe API (v3.0)

http://localhost

Table of contents

Inventory Storage Instance Batch Sync Unsafe API

Batch API for synchronously uploading instances into the inventory with optimistic locking disabled

Instances Batch Upload Sync API With Optimistic Locking Disabled

POST /instance-storage/batch/synchronous-unsafe

Create or update a collection of instances in a single synchronous request; if any instance fails the complete batch will be rejected (all or nothing). Environment variable DB_ALLOW_SUPPRESS_OPTIMISTIC_LOCKING is required, see https://github.com/folio-org/raml-module-builder#environment-variables for details. The _version property is ignored, optimistic locking is disabled - this is known to lead to data loss in some cases, don't use in production, you have been warned!

POST /instance-storage/batch/synchronous-unsafe
Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "A collection of instance records",
  "type": "object",
  "properties": {
    "instances": {
      "description": "List of instance records",
      "id": "instances",
      "type": "array",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "An instance record",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique ID of the instance record; a UUID",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
          },
          "_version": {
            "type": "integer",
            "description": "Record version for optimistic locking"
          },
          "hrid": {
            "type": "string",
            "description": "The human readable ID, also called eye readable ID. A system-assigned sequential ID which maps to the Instance ID"
          },
          "matchKey": {
            "type": "string",
            "description": "A unique instance identifier matching a client-side bibliographic record identification scheme, in particular for a scenario where multiple separate catalogs with no shared record identifiers contribute to the same Instance in Inventory. A match key is typically generated from select, normalized pieces of metadata in bibliographic records"
          },
          "source": {
            "type": "string",
            "description": "The metadata source and its format of the underlying record to the instance record. (e.g. FOLIO if it's a record created in Inventory; MARC if it's a MARC record created in MARCcat or EPKB if it's a record coming from eHoldings; CONSORTIUM-MARC or CONSORTIUM-FOLIO for sharing Instances)."
          },
          "title": {
            "type": "string",
            "description": "The primary title (or label) associated with the resource"
          },
          "indexTitle": {
            "type": "string",
            "description": "Title normalized for browsing and searching; based on the title with articles removed"
          },
          "alternativeTitles": {
            "type": "array",
            "description": "List of alternative titles for the resource (e.g. original language version title of a movie)",
            "items": {
              "type": "object",
              "properties": {
                "alternativeTitleTypeId": {
                  "type": "string",
                  "description": "UUID for an alternative title qualifier",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "alternativeTitle": {
                  "type": "string",
                  "description": "An alternative title for the resource"
                },
                "authorityId": {
                  "type": "string",
                  "description": "UUID of authority record that controls an alternative title",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                }
              }
            },
            "uniqueItems": true
          },
          "editions": {
            "type": "array",
            "description": "The edition statement, imprint and other publication source information",
            "items": {
              "type": "string"
            },
            "uniqueItems": true
          },
          "series": {
            "type": "array",
            "description": "List of series titles associated with the resource (e.g. Harry Potter)",
            "items": {
              "type": "object",
              "properties": {
                "value": {
                  "type": "string",
                  "description": "Series title value"
                },
                "authorityId": {
                  "type": "string",
                  "description": "UUID of authority record that controls an series title",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                }
              },
              "additionalProperties": false,
              "required": [
                "value"
              ]
            },
            "uniqueItems": true
          },
          "identifiers": {
            "type": "array",
            "description": "An extensible set of name-value pairs of identifiers associated with the resource",
            "minItems": 0,
            "items": {
              "type": "object",
              "properties": {
                "value": {
                  "type": "string",
                  "description": "Resource identifier value"
                },
                "identifierTypeId": {
                  "type": "string",
                  "description": "UUID of resource identifier type (e.g. ISBN, ISSN, LCCN, CODEN, Locally defined identifiers)",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "identifierTypeObject": {
                  "type": "object",
                  "description": "Information about identifier type, looked up from identifierTypeId",
                  "readonly": true,
                  "folio:isVirtual": true,
                  "folio:linkBase": "identifier-types",
                  "folio:linkFromField": "identifierTypeId",
                  "folio:linkToField": "id",
                  "folio:includedElement": "identifierTypes.0",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "properties": {
                    "id": {
                      "type": "string",
                      "description": "unique ID of the ILL policy; UUID"
                    },
                    "name": {
                      "type": "string",
                      "description": "name of the policy"
                    },
                    "source": {
                      "type": "string",
                      "description": "label indicating where the ILL policy entry originates from, i.e. 'folio' or 'local'"
                    },
                    "metadata": {
                      "type": "object",
                      "readonly": true,
                      "$schema": "http://json-schema.org/draft-04/schema#",
                      "id": "metadata.schema",
                      "title": "Metadata Schema",
                      "description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
                      "properties": {
                        "createdDate": {
                          "description": "Date and time when the record was created",
                          "type": "string",
                          "format": "date-time"
                        },
                        "createdByUserId": {
                          "description": "ID of the user who created the record (when available)",
                          "type": "string",
                          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                        },
                        "createdByUsername": {
                          "description": "Username of the user who created the record (when available)",
                          "type": "string"
                        },
                        "updatedDate": {
                          "description": "Date and time when the record was last updated",
                          "type": "string",
                          "format": "date-time"
                        },
                        "updatedByUserId": {
                          "description": "ID of the user who last updated the record (when available)",
                          "type": "string",
                          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                        },
                        "updatedByUsername": {
                          "description": "Username of the user who last updated the record (when available)",
                          "type": "string"
                        }
                      },
                      "additionalProperties": false,
                      "required": [
                        "createdDate"
                      ]
                    }
                  },
                  "additionalProperties": false,
                  "required": [
                    "name",
                    "source"
                  ]
                }
              },
              "additionalProperties": false,
              "required": [
                "value",
                "identifierTypeId"
              ]
            }
          },
          "contributors": {
            "type": "array",
            "description": "List of contributors",
            "minItems": 0,
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string",
                  "description": "Personal name, corporate name, meeting name"
                },
                "contributorTypeId": {
                  "type": "string",
                  "description": "UUID for the contributor type term defined in controlled vocabulary",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "contributorTypeText": {
                  "type": "string",
                  "description": "Free text element for adding contributor type terms other that defined by the MARC code list for relators"
                },
                "contributorNameTypeId": {
                  "type": "string",
                  "description": "UUID of contributor name type term defined by the MARC code list for relators",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "authorityId": {
                  "type": "string",
                  "description": "UUID of authority record that controls the contributor",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "contributorNameType": {
                  "type": "object",
                  "description": "Dereferenced contributor-name type",
                  "javaType": "org.folio.rest.jaxrs.model.contributorNameTypeVirtual",
                  "readonly": true,
                  "folio:isVirtual": true,
                  "folio:linkBase": "contributor-name-types",
                  "folio:linkFromField": "contributorNameTypeId",
                  "folio:linkToField": "id",
                  "folio:includedElement": "contributorNameTypes.0",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "description": "label for the type of contributor name",
                      "type": "string"
                    },
                    "ordering": {
                      "description": "used for ordering of contributor name types in displays, i.e. in select lists",
                      "type": "string"
                    },
                    "source": {
                      "type": "string",
                      "description": "origin of the contributor name type record, e.g. 'local', 'consortium' etc."
                    },
                    "metadata": {
                      "type": "object",
                      "readonly": true,
                      "$schema": "http://json-schema.org/draft-04/schema#",
                      "id": "metadata.schema",
                      "title": "Metadata Schema",
                      "description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
                      "properties": {
                        "createdDate": {
                          "description": "Date and time when the record was created",
                          "type": "string",
                          "format": "date-time"
                        },
                        "createdByUserId": {
                          "description": "ID of the user who created the record (when available)",
                          "type": "string",
                          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                        },
                        "createdByUsername": {
                          "description": "Username of the user who created the record (when available)",
                          "type": "string"
                        },
                        "updatedDate": {
                          "description": "Date and time when the record was last updated",
                          "type": "string",
                          "format": "date-time"
                        },
                        "updatedByUserId": {
                          "description": "ID of the user who last updated the record (when available)",
                          "type": "string",
                          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                        },
                        "updatedByUsername": {
                          "description": "Username of the user who last updated the record (when available)",
                          "type": "string"
                        }
                      },
                      "additionalProperties": false,
                      "required": [
                        "createdDate"
                      ]
                    }
                  },
                  "required": [
                    "name"
                  ]
                },
                "primary": {
                  "type": "boolean",
                  "description": "Whether this is the primary contributor"
                }
              },
              "additionalProperties": false,
              "required": [
                "name",
                "contributorNameTypeId"
              ]
            }
          },
          "subjects": {
            "type": "array",
            "description": "List of subject headings",
            "items": {
              "type": "object",
              "properties": {
                "value": {
                  "type": "string",
                  "description": "Subject heading value"
                },
                "authorityId": {
                  "type": "string",
                  "description": "UUID of authority record that controls a subject heading",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "sourceId": {
                  "type": "string",
                  "description": "UUID of subject source",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "typeId": {
                  "type": "string",
                  "description": "UUID of subject type",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                }
              },
              "additionalProperties": false,
              "required": [
                "value"
              ]
            },
            "uniqueItems": true
          },
          "classifications": {
            "type": "array",
            "description": "List of classifications",
            "minItems": 0,
            "items": {
              "type": "object",
              "properties": {
                "classificationNumber": {
                  "type": "string",
                  "description": "Classification (e.g. classification scheme, classification schedule)"
                },
                "classificationTypeId": {
                  "type": "string",
                  "description": "UUID of classification schema (e.g. LC, Canadian Classification, NLM, National Agricultural Library, UDC, and Dewey)",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "classificationType": {
                  "type": "object",
                  "description": "Dereferenced classification schema",
                  "javaType": "org.folio.rest.jaxrs.model.classificationTypeVirtual",
                  "readonly": true,
                  "folio:isVirtual": true,
                  "folio:linkBase": "classification-types",
                  "folio:linkFromField": "classificationTypeId",
                  "folio:linkToField": "id",
                  "folio:includedElement": "classificationTypes.0",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "description": "label for the classification type",
                      "type": "string"
                    },
                    "source": {
                      "type": "string",
                      "description": "label indicating where the classification type entry originates from, i.e. 'folio' or 'local'"
                    },
                    "metadata": {
                      "type": "object",
                      "readonly": true,
                      "$schema": "http://json-schema.org/draft-04/schema#",
                      "id": "metadata.schema",
                      "title": "Metadata Schema",
                      "description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
                      "properties": {
                        "createdDate": {
                          "description": "Date and time when the record was created",
                          "type": "string",
                          "format": "date-time"
                        },
                        "createdByUserId": {
                          "description": "ID of the user who created the record (when available)",
                          "type": "string",
                          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                        },
                        "createdByUsername": {
                          "description": "Username of the user who created the record (when available)",
                          "type": "string"
                        },
                        "updatedDate": {
                          "description": "Date and time when the record was last updated",
                          "type": "string",
                          "format": "date-time"
                        },
                        "updatedByUserId": {
                          "description": "ID of the user who last updated the record (when available)",
                          "type": "string",
                          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                        },
                        "updatedByUsername": {
                          "description": "Username of the user who last updated the record (when available)",
                          "type": "string"
                        }
                      },
                      "additionalProperties": false,
                      "required": [
                        "createdDate"
                      ]
                    }
                  },
                  "required": [
                    "name"
                  ]
                }
              },
              "additionalProperties": false,
              "required": [
                "classificationNumber",
                "classificationTypeId"
              ]
            }
          },
          "publication": {
            "type": "array",
            "description": "List of publication items",
            "items": {
              "type": "object",
              "properties": {
                "publisher": {
                  "type": "string",
                  "description": "Name of publisher, distributor, etc."
                },
                "place": {
                  "type": "string",
                  "description": "Place of publication, distribution, etc."
                },
                "dateOfPublication": {
                  "type": "string",
                  "description": "Date (year YYYY) of publication, distribution, etc."
                },
                "role": {
                  "type": "string",
                  "description": "The role of the publisher, distributor, etc."
                }
              }
            }
          },
          "publicationFrequency": {
            "type": "array",
            "description": "List of intervals at which a serial appears (e.g. daily, weekly, monthly, quarterly, etc.)",
            "items": {
              "type": "string"
            },
            "uniqueItems": true
          },
          "publicationRange": {
            "type": "array",
            "description": "The range of sequential designation/chronology of publication, or date range",
            "items": {
              "type": "string"
            },
            "uniqueItems": true
          },
          "electronicAccess": {
            "type": "array",
            "description": "List of electronic access items",
            "items": {
              "type": "object",
              "properties": {
                "uri": {
                  "type": "string",
                  "description": "uniform resource identifier (URI) is a string of characters designed for unambiguous identification of resources"
                },
                "linkText": {
                  "type": "string",
                  "description": "The value of the MARC tag field 856 2nd indicator, where the values are: no information provided, resource, version of resource, related resource, no display constant generated"
                },
                "materialsSpecification": {
                  "type": "string",
                  "description": "Materials specified is used to specify to what portion or aspect of the resource the electronic location and access information applies (e.g. a portion or subset of the item is electronic, or a related electronic resource is being linked to the record)"
                },
                "publicNote": {
                  "type": "string",
                  "description": "URL public note to be displayed in the discovery"
                },
                "relationshipId": {
                  "type": "string",
                  "description": "UUID for the type of relationship between the electronic resource at the location identified and the item described in the record as a whole",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                }
              },
              "additionalProperties": false,
              "required": [
                "uri"
              ]
            }
          },
          "dates": {
            "type": "object",
            "description": "Instance Dates",
            "properties": {
              "dateTypeId": {
                "type": "string",
                "description": "Date type ID",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
              },
              "date1": {
                "type": "string",
                "description": "Date 1",
                "maxLength": 4
              },
              "date2": {
                "type": "string",
                "description": "Date 2",
                "maxLength": 4
              }
            },
            "additionalProperties": false
          },
          "instanceTypeId": {
            "type": "string",
            "description": "UUID of the unique term for the resource type whether it's from the RDA content term list of locally defined",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
          },
          "instanceFormatIds": {
            "type": "array",
            "description": "UUIDs for the unique terms for the format whether it's from the RDA carrier term list of locally defined",
            "items": {
              "type": "string",
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "A universally unique identifier (UUID), this is a 128-bit number used to identify a record and is shown in hex with dashes, for example 6312d172-f0cf-40f6-b27d-9fa8feaf332f; the UUID version must be from 1-5; see https://dev.folio.org/guides/uuids/",
              "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
            }
          },
          "instanceFormats": {
            "type": "array",
            "description": "List of dereferenced instance formats",
            "items": {
              "type": "object",
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "The format of an Instance",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "description": "label for the Instance format",
                  "type": "string"
                },
                "code": {
                  "description": "distinct code for the Instance format",
                  "type": "string"
                },
                "source": {
                  "description": "origin of the Instance format record",
                  "type": "string"
                },
                "metadata": {
                  "type": "object",
                  "readonly": true,
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "id": "metadata.schema",
                  "title": "Metadata Schema",
                  "description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
                  "properties": {
                    "createdDate": {
                      "description": "Date and time when the record was created",
                      "type": "string",
                      "format": "date-time"
                    },
                    "createdByUserId": {
                      "description": "ID of the user who created the record (when available)",
                      "type": "string",
                      "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                    },
                    "createdByUsername": {
                      "description": "Username of the user who created the record (when available)",
                      "type": "string"
                    },
                    "updatedDate": {
                      "description": "Date and time when the record was last updated",
                      "type": "string",
                      "format": "date-time"
                    },
                    "updatedByUserId": {
                      "description": "ID of the user who last updated the record (when available)",
                      "type": "string",
                      "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                    },
                    "updatedByUsername": {
                      "description": "Username of the user who last updated the record (when available)",
                      "type": "string"
                    }
                  },
                  "additionalProperties": false,
                  "required": [
                    "createdDate"
                  ]
                }
              },
              "required": [
                "name",
                "code",
                "source"
              ]
            },
            "readonly": true,
            "folio:isVirtual": true,
            "folio:linkBase": "instance-formats",
            "folio:linkFromField": "instanceFormatIds",
            "folio:linkToField": "id",
            "folio:includedElement": "instanceFormats"
          },
          "physicalDescriptions": {
            "type": "array",
            "description": "Physical description of the described resource, including its extent, dimensions, and such other physical details as a description of any accompanying materials and unit type and size",
            "items": {
              "type": "string"
            }
          },
          "languages": {
            "type": "array",
            "description": "The set of languages used by the resource",
            "minItems": 0,
            "items": {
              "type": "string"
            }
          },
          "notes": {
            "type": "array",
            "description": "Bibliographic notes (e.g. general notes, specialized notes)",
            "items": {
              "type": "object",
              "javaType": "org.folio.rest.jaxrs.model.InstanceNote",
              "additionalProperties": false,
              "properties": {
                "instanceNoteTypeId": {
                  "description": "ID of the type of note",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "type": "string",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "note": {
                  "type": "string",
                  "description": "Text content of the note"
                },
                "staffOnly": {
                  "type": "boolean",
                  "description": "If true, determines that the note should not be visible for others than staff",
                  "default": false
                }
              }
            }
          },
          "administrativeNotes": {
            "type": "array",
            "description": "Administrative notes",
            "minItems": 0,
            "items": {
              "type": "string"
            }
          },
          "modeOfIssuanceId": {
            "type": "string",
            "description": "UUID of the RDA mode of issuance, a categorization reflecting whether a resource is issued in one or more parts, the way it is updated, and whether its termination is predetermined or not (e.g. monograph,  sequential monograph, serial; integrating Resource, other)",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
          },
          "catalogedDate": {
            "type": "string",
            "description": "Date or timestamp on an instance for when is was considered cataloged"
          },
          "previouslyHeld": {
            "type": "boolean",
            "description": "Records the fact that the resource was previously held by the library for things like Hathi access, etc.",
            "default": false
          },
          "staffSuppress": {
            "type": "boolean",
            "description": "Records the fact that the record should not be displayed for others than catalogers"
          },
          "discoverySuppress": {
            "type": "boolean",
            "description": "Records the fact that the record should not be displayed in a discovery system",
            "default": false
          },
          "deleted": {
            "type": "boolean",
            "description": "Indicates whether the record was marked for deletion",
            "default": false
          },
          "statisticalCodeIds": {
            "type": "array",
            "description": "List of statistical code IDs",
            "items": {
              "type": "string"
            },
            "uniqueItems": true
          },
          "sourceRecordFormat": {
            "type": "string",
            "description": "Format of the instance source record, if a source record exists (e.g. FOLIO if it's a record created in Inventory,  MARC if it's a MARC record created in MARCcat or EPKB if it's a record coming from eHoldings)",
            "enum": [
              "MARC-JSON"
            ],
            "readonly": true
          },
          "statusId": {
            "type": "string",
            "description": "UUID for the Instance status term (e.g. cataloged, uncatalogued, batch loaded, temporary, other, not yet assigned)",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
          },
          "statusUpdatedDate": {
            "type": "string",
            "description": "Date [or timestamp] for when the instance status was updated"
          },
          "tags": {
            "description": "arbitrary tags associated with this instance",
            "id": "tags",
            "type": "object",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "title": "tags",
            "properties": {
              "tagList": {
                "description": "List of tags",
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "additionalProperties": false
          },
          "metadata": {
            "type": "object",
            "readonly": true,
            "$schema": "http://json-schema.org/draft-04/schema#",
            "id": "metadata.schema",
            "title": "Metadata Schema",
            "description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
            "properties": {
              "createdDate": {
                "description": "Date and time when the record was created",
                "type": "string",
                "format": "date-time"
              },
              "createdByUserId": {
                "description": "ID of the user who created the record (when available)",
                "type": "string",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
              },
              "createdByUsername": {
                "description": "Username of the user who created the record (when available)",
                "type": "string"
              },
              "updatedDate": {
                "description": "Date and time when the record was last updated",
                "type": "string",
                "format": "date-time"
              },
              "updatedByUserId": {
                "description": "ID of the user who last updated the record (when available)",
                "type": "string",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
              },
              "updatedByUsername": {
                "description": "Username of the user who last updated the record (when available)",
                "type": "string"
              }
            },
            "additionalProperties": false,
            "required": [
              "createdDate"
            ]
          },
          "holdingsRecords2": {
            "type": "array",
            "description": "List of holdings records",
            "items": {
              "type": "object",
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "A holdings record",
              "javaType": "org.folio.rest.jaxrs.model.HoldingsRecord",
              "additionalProperties": false,
              "properties": {
                "id": {
                  "type": "string",
                  "description": "the unique ID of the holdings record; UUID",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "_version": {
                  "type": "integer",
                  "description": "Record version for optimistic locking"
                },
                "sourceId": {
                  "description": "(A reference to) the source of a holdings record",
                  "type": "string",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "hrid": {
                  "type": "string",
                  "description": "the human readable ID, also called eye readable ID. A system-assigned sequential ID which maps to the Instance ID"
                },
                "holdingsTypeId": {
                  "type": "string",
                  "description": "unique ID for the type of this holdings record, a UUID",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "formerIds": {
                  "type": "array",
                  "description": "Previous ID(s) assigned to the holdings record",
                  "items": {
                    "type": "string"
                  },
                  "uniqueItems": true
                },
                "instanceId": {
                  "description": "Inventory instances identifier",
                  "type": "string",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "permanentLocationId": {
                  "type": "string",
                  "description": "The permanent shelving location in which an item resides.",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "temporaryLocationId": {
                  "type": "string",
                  "description": "Temporary location is the temporary location, shelving location, or holding which is a physical place where items are stored, or an Online location.",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "effectiveLocationId": {
                  "type": "string",
                  "description": "Effective location is calculated by the system based on the values in the permanent and temporary locationId fields.",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "electronicAccess": {
                  "description": "List of electronic access items",
                  "type": "array",
                  "items": {
                    "type": "object",
                    "$schema": "http://json-schema.org/draft-04/schema#",
                    "description": "Electronic access item",
                    "javaType": "org.folio.rest.jaxrs.model.ElectronicAccessItem",
                    "additionalProperties": false,
                    "properties": {
                      "uri": {
                        "type": "string",
                        "description": "uniform resource identifier (URI) is a string of characters designed for unambiguous identification of resources"
                      },
                      "linkText": {
                        "type": "string",
                        "description": "the value of the MARC tag field 856 2nd indicator, where the values are: no information provided, resource, version of resource, related resource, no display constant generated"
                      },
                      "materialsSpecification": {
                        "type": "string",
                        "description": "materials specified is used to specify to what portion or aspect of the resource the electronic location and access information applies (e.g. a portion or subset of the item is electronic, or a related electronic resource is being linked to the record)"
                      },
                      "publicNote": {
                        "type": "string",
                        "description": "URL public note to be displayed in the discovery"
                      },
                      "relationshipId": {
                        "type": "string",
                        "description": "relationship between the electronic resource at the location identified and the item described in the record as a whole"
                      }
                    },
                    "required": [
                      "uri"
                    ]
                  }
                },
                "callNumberTypeId": {
                  "type": "string",
                  "description": "unique ID for the type of call number on a holdings record, a UUID",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "callNumberPrefix": {
                  "type": "string",
                  "description": "Prefix of the call number on the holding level."
                },
                "callNumber": {
                  "type": "string",
                  "description": "Call Number is an identifier assigned to an item, usually printed on a label attached to the item."
                },
                "callNumberSuffix": {
                  "type": "string",
                  "description": "Suffix of the call number on the holding level."
                },
                "shelvingTitle": {
                  "type": "string",
                  "description": "Indicates the shelving form of title."
                },
                "acquisitionFormat": {
                  "type": "string",
                  "description": "Format of holdings record acquisition"
                },
                "acquisitionMethod": {
                  "type": "string",
                  "description": "Method of holdings record acquisition"
                },
                "receiptStatus": {
                  "type": "string",
                  "description": "Receipt status (e.g. pending, awaiting receipt, partially received, fully received, receipt not required, and cancelled)"
                },
                "administrativeNotes": {
                  "type": "array",
                  "description": "Administrative notes",
                  "minItems": 0,
                  "items": {
                    "type": "string"
                  }
                },
                "notes": {
                  "type": "array",
                  "description": "Notes about action, copy, binding etc.",
                  "items": {
                    "type": "object",
                    "$schema": "http://json-schema.org/draft-04/schema#",
                    "description": "A holdings record note",
                    "javaType": "org.folio.rest.jaxrs.model.HoldingsNote",
                    "additionalProperties": false,
                    "properties": {
                      "holdingsNoteTypeId": {
                        "type": "string",
                        "description": "ID of the type of note",
                        "$schema": "http://json-schema.org/draft-04/schema#",
                        "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                      },
                      "note": {
                        "type": "string",
                        "description": "Text content of the note"
                      },
                      "staffOnly": {
                        "type": "boolean",
                        "description": "If true, determines that the note should not be visible for others than staff",
                        "default": false
                      }
                    }
                  }
                },
                "illPolicyId": {
                  "type": "string",
                  "description": "unique ID for an ILL policy, a UUID",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                },
                "retentionPolicy": {
                  "type": "string",
                  "description": "Records information regarding how long we have agreed to keep something."
                },
                "digitizationPolicy": {
                  "description": "Records information regarding digitization aspects.",
                  "type": "string"
                },
                "holdingsStatements": {
                  "description": "Holdings record statements",
                  "type": "array",
                  "items": {
                    "type": "object",
                    "$schema": "http://json-schema.org/draft-04/schema#",
                    "description": "Holdings record statement",
                    "javaType": "org.folio.rest.jaxrs.model.HoldingsStatement",
                    "additionalProperties": false,
                    "properties": {
                      "statement": {
                        "type": "string",
                        "description": "Specifies the exact content to which the library has access, typically for continuing publications."
                      },
                      "note": {
                        "type": "string",
                        "description": "Note attached to a holdings statement"
                      },
                      "staffNote": {
                        "type": "string",
                        "description": "Private note attached to a holdings statement"
                      }
                    }
                  }
                },
                "holdingsStatementsForIndexes": {
                  "description": "Holdings record indexes statements",
                  "type": "array",
                  "items": {
                    "type": "object",
                    "$schema": "http://json-schema.org/draft-04/schema#",
                    "description": "Holdings record statement",
                    "javaType": "org.folio.rest.jaxrs.model.HoldingsStatement",
                    "additionalProperties": false,
                    "properties": {
                      "statement": {
                        "type": "string",
                        "description": "Specifies the exact content to which the library has access, typically for continuing publications."
                      },
                      "note": {
                        "type": "string",
                        "description": "Note attached to a holdings statement"
                      },
                      "staffNote": {
                        "type": "string",
                        "description": "Private note attached to a holdings statement"
                      }
                    }
                  }
                },
                "holdingsStatementsForSupplements": {
                  "description": "Holdings record supplements statements",
                  "type": "array",
                  "items": {
                    "type": "object",
                    "$schema": "http://json-schema.org/draft-04/schema#",
                    "description": "Holdings record statement",
                    "javaType": "org.folio.rest.jaxrs.model.HoldingsStatement",
                    "additionalProperties": false,
                    "properties": {
                      "statement": {
                        "type": "string",
                        "description": "Specifies the exact content to which the library has access, typically for continuing publications."
                      },
                      "note": {
                        "type": "string",
                        "description": "Note attached to a holdings statement"
                      },
                      "staffNote": {
                        "type": "string",
                        "description": "Private note attached to a holdings statement"
                      }
                    }
                  }
                },
                "copyNumber": {
                  "type": "string",
                  "description": "Item/Piece ID (usually barcode) for systems that do not use item records. Ability to designate the copy number if institution chooses to use copy numbers."
                },
                "numberOfItems": {
                  "type": "string",
                  "description": "Text (Number)"
                },
                "receivingHistory": {
                  "description": "Receiving history of holdings record",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "javaType": "org.folio.rest.jaxrs.model.HoldingsReceivingHistory",
                  "additionalProperties": false,
                  "type": "object",
                  "properties": {
                    "displayType": {
                      "type": "string",
                      "description": "Display hint. 1: Display fields separately. 2: Display fields concatenated"
                    },
                    "entries": {
                      "type": "array",
                      "description": "Entries of receiving history",
                      "items": {
                        "$schema": "http://json-schema.org/draft-04/schema#",
                        "description": "Receiving history entry of holdings record",
                        "javaType": "org.folio.rest.jaxrs.model.HoldingsReceivingHistoryEntry",
                        "additionalProperties": false,
                        "type": "object",
                        "properties": {
                          "publicDisplay": {
                            "type": "boolean",
                            "description": "Defines if the receivingHistory should be visible to the public."
                          },
                          "enumeration": {
                            "type": "string",
                            "description": "This is the volume/issue number (e.g. v.71:no.6-2)"
                          },
                          "chronology": {
                            "type": "string",
                            "description": "Repeated element from Receiving history - Enumeration AND Receiving history - Chronology"
                          }
                        }
                      }
                    }
                  }
                },
                "discoverySuppress": {
                  "type": "boolean",
                  "description": "records the fact that the record should not be displayed in a discovery system"
                },
                "statisticalCodeIds": {
                  "type": "array",
                  "description": "List of statistical code IDs",
                  "items": {
                    "type": "string",
                    "$schema": "http://json-schema.org/draft-04/schema#",
                    "description": "A universally unique identifier (UUID), this is a 128-bit number used to identify a record and is shown in hex with dashes, for example 6312d172-f0cf-40f6-b27d-9fa8feaf332f; the UUID version must be from 1-5; see https://dev.folio.org/guides/uuids/",
                    "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
                  },
                  "uniqueItems": true
                },
                "tags": {
                  "description": "arbitrary tags associated with this holding",
                  "id": "tags",
                  "type": "object",
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "title": "tags",
                  "properties": {
                    "tagList": {
                      "description": "List of tags",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  },
                  "additionalProperties": false
                },
                "metadata": {
                  "type": "object",
                  "readonly": true,
                  "$schema": "http://json-schema.org/draft-04/schema#",
                  "id": "metadata.schema",
                  "title": "Metadata Schema",
                  "description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
                  "properties": {
                    "createdDate": {
                      "description": "Date and time when the record was created",
                      "type": "string",
                      "format": "date-time"
                    },
                    "createdByUserId": {
                      "description": "ID of the user who created the record (when available)",
                      "type": "string",
                      "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                    },
                    "createdByUsername": {
                      "description": "Username of the user who created the record (when available)",
                      "type": "string"
                    },
                    "updatedDate": {
                      "description": "Date and time when the record was last updated",
                      "type": "string",
                      "format": "date-time"
                    },
                    "updatedByUserId": {
                      "description": "ID of the user who last updated the record (when available)",
                      "type": "string",
                      "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
                    },
                    "updatedByUsername": {
                      "description": "Username of the user who last updated the record (when available)",
                      "type": "string"
                    }
                  },
                  "additionalProperties": false,
                  "required": [
                    "createdDate"
                  ]
                }
              },
              "required": [
                "sourceId",
                "instanceId",
                "permanentLocationId"
              ]
            },
            "readonly": true,
            "folio:isVirtual": true,
            "folio:linkBase": "holdings-storage/holdings",
            "folio:linkFromField": "id",
            "folio:linkToField": "instanceId",
            "folio:includedElement": "holdingsRecords"
          },
          "natureOfContentTermIds": {
            "type": "array",
            "description": "Array of UUID for the Instance nature of content (e.g. bibliography, biography, exhibition catalogue, festschrift, newspaper, proceedings, research report, thesis or website)",
            "uniqueItems": true,
            "items": {
              "type": "string",
              "description": "Single UUID for the Instance nature of content",
              "$schema": "http://json-schema.org/draft-04/schema#",
              "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
            }
          }
        },
        "additionalProperties": false,
        "required": [
          "source",
          "title",
          "instanceTypeId"
        ]
      }
    }
  },
  "additionalProperties": false,
  "required": [
    "instances"
  ]
}

Example:

{
  "instances": [
    {
      "id": "601a8dc4-dee7-48eb-b03f-d02fdf0debd0",
      "title": "ADVANCING LIBRARY EDUCATION: TECHNOLOGICAL INNOVATION AND INSTRUCTIONAL DESIGN",
      "source": "Local: MARC",
      "contributors": [
        {
          "name": "Sigal, Ari",
          "contributorNameTypeId": "2b94c631-fca9-4892-a730-03ee529ffe2a",
          "primary": true
        }
      ],
      "identifiers": [
        {
          "identifierTypeId": "2e48e713-17f3-4c13-a9f8-23845bb210af",
          "value": "9781466636897"
        },
        {
          "identifierTypeId": "6051f95c-028e-4c6a-8a9e-ee689dd51453",
          "value": "1"
        }
      ],
      "instanceTypeId": "2b94c631-fca9-4892-a730-03ee529ffe2c",
      "tags" : {
        "tagList" : [
          "important"
        ]
      }
    },
    {
      "id": "f31a36de-fcf8-44f9-87ef-a55d06ad21ae",
      "title": "ADVANCING RESEARCH METHODS WITH NEW TECHNOLOGIES.",
      "source": "Local: MARC",
      "contributors": [
        {
          "name": "Sappleton, Natalie",
          "contributorNameTypeId": "2b94c631-fca9-4892-a730-03ee529ffe2a",
          "primary": true
        }
      ],
      "identifiers": [
        {
          "identifierTypeId": "2e48e713-17f3-4c13-a9f8-23845bb210af",
          "value": "9781466639195"
        },
        {
          "identifierTypeId": "6051f95c-028e-4c6a-8a9e-ee689dd51453",
          "value": "2"
        }
      ],
      "instanceTypeId": "2b94c631-fca9-4892-a730-03ee529ffe2c"
    }
  ]
}

Response 201

All instances have been successfully created or updated

Response 413

Payload too large or not allowed by DB_ALLOW_SUPPRESS_OPTIMISTIC_LOCKING environment variable

Body

Media type: text/plain

Type: any

Example:

Payload Too Large

Response 422

Unprocessable Entity

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "id": "errors.schema",
  "description": "A set of errors",
  "type": "object",
  "properties": {
    "errors": {
      "description": "List of errors",
      "id": "errors",
      "type": "array",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "id": "error.schema",
        "description": "An error",
        "properties": {
          "message": {
            "type": "string",
            "description": "Error message text"
          },
          "type": {
            "type": "string",
            "description": "Error message type"
          },
          "code": {
            "type": "string",
            "description": "Error message code"
          },
          "parameters": {
            "description": "Error message parameters",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "id": "parameters.schema",
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string"
                },
                "value": {
                  "type": "string"
                }
              }
            }
          }
        },
        "required": [
          "message"
        ]
      }
    },
    "total_records": {
      "description": "Total number of errors",
      "type": "integer"
    }
  }
}

Response 500

Internal server error

Body

Media type: text/plain

Type: any

Example:

Internal server error