{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/api-evangelist/folio/main/json-schema/folio-erm-resource-schema.json", "title": "ErmResource", "x-generated": "2026-10-09", "x-method": "derived", "x-generator": "derive-json-schema.py", "x-source": "openapi/folio-mod-agreements-openapi.yml#/components/schemas/ErmResource", "type": "object", "properties": { "id": { "type": "string", "format": "uuid" }, "class": { "type": "string", "enum": [ "org.olf.kb.TitleInstance", "org.olf.kb.PlatformTitleInstance", "org.olf.kb.PackageContentItem", "org.olf.kb.Pkg" ] }, "coverage": { "type": "array", "items": { "$ref": "#/$defs/CoverageStatement" } }, "customCoverage": { "type": "boolean" }, "dateCreated": { "type": "string", "format": "date-time" }, "lastUpdated": { "type": "string", "format": "date-time" }, "name": { "type": "string" }, "normalizedName": { "type": "string", "readOnly": true }, "description": { "type": "string" }, "publicationType": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] }, "suppressFromDiscovery": { "type": "boolean" }, "subType": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] }, "tags": { "type": "array", "items": { "$ref": "#/$defs/Tag" } }, "type": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] }, "alternateResourceNames": { "type": "array", "items": { "$ref": "#/$defs/AlternateResourceName" } }, "identifiers": { "type": "array", "items": { "$ref": "#/$defs/IdentifierOccurrence" } }, "_object": { "description": "The full, type-specific representation of this resource (fields vary depending on `class`)", "oneOf": [ { "$ref": "#/$defs/TitleInstance" }, { "$ref": "#/$defs/PlatformTitleInstance" }, { "$ref": "#/$defs/PackageContentItem" }, { "$ref": "#/$defs/Package" } ] } }, "$defs": { "AlternateResourceName": { "type": "object", "required": [ "id", "name" ], "properties": { "id": { "type": "string", "format": "uuid" }, "name": { "type": "string" } } }, "AvailabilityConstraint": { "type": "object", "required": [ "id", "body" ], "properties": { "id": { "type": "string", "format": "uuid" }, "body": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] } } }, "ContentType": { "type": "object", "required": [ "id", "contentType" ], "properties": { "id": { "type": "string", "format": "uuid" }, "contentType": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] } } }, "CoverageStatement": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid" }, "startDate": { "type": "string", "format": "date" }, "endDate": { "type": "string", "format": "date" }, "summary": { "type": "string" }, "startVolume": { "type": "string" }, "startIssue": { "type": "string" }, "endVolume": { "type": "string" }, "endIssue": { "type": "string" } } }, "Embargo": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid" }, "movingWallStart": { "$ref": "#/$defs/EmbargoStatement" }, "movingWallEnd": { "$ref": "#/$defs/EmbargoStatement" } } }, "EmbargoStatement": { "type": "object", "properties": { "unit": { "type": "string", "enum": [ "days", "months", "years" ] }, "length": { "type": "integer" } } }, "ErmResource": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid" }, "class": { "type": "string", "enum": [ "org.olf.kb.TitleInstance", "org.olf.kb.PlatformTitleInstance", "org.olf.kb.PackageContentItem", "org.olf.kb.Pkg" ] }, "coverage": { "type": "array", "items": { "$ref": "#/$defs/CoverageStatement" } }, "customCoverage": { "type": "boolean" }, "dateCreated": { "type": "string", "format": "date-time" }, "lastUpdated": { "type": "string", "format": "date-time" }, "name": { "type": "string" }, "normalizedName": { "type": "string", "readOnly": true }, "description": { "type": "string" }, "publicationType": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] }, "suppressFromDiscovery": { "type": "boolean" }, "subType": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] }, "tags": { "type": "array", "items": { "$ref": "#/$defs/Tag" } }, "type": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] }, "alternateResourceNames": { "type": "array", "items": { "$ref": "#/$defs/AlternateResourceName" } }, "identifiers": { "type": "array", "items": { "$ref": "#/$defs/IdentifierOccurrence" } }, "_object": { "description": "The full, type-specific representation of this resource (fields vary depending on `class`)", "oneOf": [ { "$ref": "#/$defs/TitleInstance" }, { "$ref": "#/$defs/PlatformTitleInstance" }, { "$ref": "#/$defs/PackageContentItem" }, { "$ref": "#/$defs/Package" } ] } } }, "Identifier": { "type": "object", "properties": { "ns": { "type": "object", "properties": { "value": { "type": "string" } } }, "value": { "type": "string" } } }, "IdentifierOccurrence": { "type": "object", "properties": { "title": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid" } } }, "identifier": { "$ref": "#/$defs/Identifier" }, "status": { "$ref": "#/$defs/Refdata" } } }, "Organisation": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid" }, "name": { "type": "string" }, "orgsUuid": { "type": "string", "format": "uuid" }, "orgsUuid_object": { "type": "object" } } }, "Package": { "type": "object", "required": [ "name", "source", "reference", "class" ], "allOf": [ { "$ref": "#/$defs/ErmResource" }, { "properties": { "class": { "enum": [ "org.olf.kb.Pkg" ] }, "source": { "type": "string" }, "sourceDataCreated": { "type": "string", "format": "date-time" }, "sourceDataUpdated": { "type": "string", "format": "date-time" }, "sourceTitleCount": { "type": "integer" }, "syncContentsFromSource": { "type": "boolean" }, "reference": { "type": "string" }, "nominalPlatform": { "$ref": "#/$defs/Platform" }, "vendor": { "$ref": "#/$defs/Organisation" }, "lifecycleStatus": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] }, "availabilityScope": { "oneOf": [ { "type": "string" }, { "$ref": "#/$defs/Refdata" } ] }, "packageDescriptionUrls": { "type": "array", "items": { "$ref": "#/$defs/PackageDescriptionUrl" } }, "contentTypes": { "type": "array", "items": { "$ref": "#/$defs/ContentType" } }, "availabilityConstraints": { "type": "array", "items": { "$ref": "#/$defs/AvailabilityConstraint" } }, "resourceCount": { "type": "integer" } } } ] }, "PackageContentItem": { "type": "object", "required": [ "class" ], "allOf": [ { "$ref": "#/$defs/ErmResource" }, { "properties": { "class": { "enum": [ "org.olf.kb.PackageContentItem" ] }, "accessStart": { "type": "string", "format": "date" }, "accessEnd": { "type": "string", "format": "date" }, "addedTimestamp": { "type": "integer" }, "depth": { "type": "string" }, "lastSeenTimestamp": { "type": "integer" }, "longName": { "type": "string" }, "note": { "type": "string" }, "removedTimestamp": { "type": "integer" }, "embargo": { "$ref": "#/$defs/Embargo" }, "pkg": { "$ref": "#/$defs/Package" }, "pti": { "$ref": "#/$defs/PlatformTitleInstance" } } } ] }, "PackageDescriptionUrl": { "type": "object", "required": [ "id" ], "properties": { "id": { "type": "string", "format": "uuid" }, "url": { "type": "string", "format": "uri" } } }, "Platform": { "type": "object", "required": [ "name" ], "properties": { "id": { "type": "string", "format": "uuid" }, "name": { "type": "string" }, "dateCreated": { "type": "string", "format": "date-time" }, "lastUpdated": { "type": "string", "format": "date-time" }, "locators": { "type": "array", "items": { "type": "object", "properties": { "domainName": { "type": "string" }, "id": { "type": "string", "format": "uuid" } } } } } }, "PlatformTitleInstance": { "type": "object", "required": [ "platform", "titleInstance", "class" ], "allOf": [ { "$ref": "#/$defs/ErmResource" }, { "properties": { "class": { "enum": [ "org.olf.kb.PlatformTitleInstance" ] }, "longName": { "type": "string" }, "platform": { "$ref": "#/$defs/Platform" }, "titleInstance": { "$ref": "#/$defs/TitleInstance" }, "url": { "type": "string", "format": "uri" } } } ] }, "Refdata": { "type": "object", "properties": { "id": { "type": "string" }, "label": { "type": "string" }, "value": { "type": "string" } } }, "Tag": { "type": "object", "properties": { "id": { "type": "integer" }, "normValue": { "type": "string" }, "value": { "type": "string" } } }, "TitleInstance": { "type": "object", "required": [ "name", "class" ], "allOf": [ { "$ref": "#/$defs/ErmResource" }, { "properties": { "class": { "enum": [ "org.olf.kb.TitleInstance" ] }, "dateMonographPublished": { "type": "string", "pattern": "^\\d{4}(-((0[0-9])|(1[0-2]))(-(([0-2][0-9])|3[0-1]))?)?\\$" }, "firstAuthor": { "type": "string" }, "firstEditor": { "type": "string" }, "identifiers": { "type": "array", "items": { "$ref": "#/$defs/IdentifierOccurrence" } }, "longName": { "type": "string", "readOnly": true }, "monographEdition": { "type": "string" }, "monographVolume": { "type": "string" }, "work": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid" } } }, "relatedTitles": { "type": "array", "readOnly": true, "items": { "$ref": "#/$defs/TitleInstanceRef" } } } } ] }, "TitleInstanceRef": { "description": "A lightweight representation of a title instance, used where a title references another title (e.g. `TitleInstance.relatedTitles`). Unlike the full `TitleInstance` representation, fields such as `class`, `dateCreated` and `coverage` are not populated on this partial view, and it does not nest further `relatedTitles`.", "allOf": [ { "$ref": "#/$defs/ErmResource" }, { "properties": { "dateMonographPublished": { "type": "string", "pattern": "^\\d{4}(-((0[0-9])|(1[0-2]))(-(([0-2][0-9])|3[0-1]))?)?\\$" }, "firstAuthor": { "type": "string" }, "firstEditor": { "type": "string" }, "longName": { "type": "string", "readOnly": true }, "monographEdition": { "type": "string" }, "monographVolume": { "type": "string" }, "work": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid" } } } } } ] } } }