https://github.com/folio-org/mod-kb-ebsco-java
Implements the eholdings interface using EBSCO KB as backend.
Create a relation between an existing custom package and an existing custom/managed title.
POST /eholdings/resources
Example:
application/vnd.api+json
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource POST Request Schema",
"description": "Resource Post Request Schema using JSON API",
"javaType": "org.folio.rest.jaxrs.model.ResourcePostRequest",
"type": "object",
"additionalProperties": false,
"properties": {
"data": {
"description": "Data object of resource post request",
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Post Data Schema",
"javaType": "org.folio.rest.jaxrs.model.ResourcePostData",
"additionalProperties": false,
"properties": {
"type": {
"description": "Data type",
"type": "string",
"enum": [
"resources"
],
"example": "resources"
},
"attributes": {
"description": "Data type attributes",
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Post Data attributes schema",
"javaType": "org.folio.rest.jaxrs.model.ResourcePostDataAttributes",
"additionalProperties": false,
"properties": {
"packageId": {
"type": "string",
"description": "Id of the custom package",
"example": "123355-2845510"
},
"titleId": {
"type": "string",
"description": "Id of the managed/custom title",
"example": "17059786"
},
"url": {
"type": "string",
"description": "Custom URL",
"example": "https://hello.io"
}
},
"required": [
"packageId",
"titleId"
]
}
},
"required": [
"type",
"attributes"
]
}
},
"required": [
"data"
]
}
Example:
{
"data": {
"type": "resources",
"attributes": {
"packageId": "123355-2845510",
"titleId": "17059786",
"url": "https://hello.io"
}
}
}
OK
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource object schema",
"description": "Resource object schema",
"javaType": "org.folio.rest.jaxrs.model.Resource",
"type": "object",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "The Data Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource object schema for a collection",
"javaType": "org.folio.rest.jaxrs.model.ResourceCollectionItem",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"description": "Unique identifier of resource - combination of providerId-packageId-titleId",
"example": "583-4345-760027"
},
"type": {
"type": "string",
"description": "Type of resource",
"enum": [
"resources"
],
"example": "resources"
},
"attributes": {
"type": "object",
"description": "Resource object data attributes",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Object Data Attributes Schema",
"javaType": "org.folio.rest.jaxrs.model.ResourceDataAttributes",
"additionalProperties": false,
"properties": {
"alternateTitles": {
"type": "array",
"description": "List of alternate titles",
"items": {
"type": "object",
"description": "Alternate Title Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Alternate Title Schema",
"javaType": "org.folio.rest.jaxrs.model.AlternateTitle",
"additionalProperties": false,
"properties": {
"alternateTitle": {
"type": "string",
"description": "alternate title name",
"example": "Boston Coll Law Rev"
},
"titleType": {
"type": "string",
"description": "alternate title type",
"example": "Abbreviated"
}
}
}
},
"description": {
"type": "string",
"description": "Description of Resource. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "Online Reference"
},
"edition": {
"type": "string",
"description": "Edition. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE."
},
"isPeerReviewed": {
"type": "boolean",
"description": "Defines if peer is reviewed. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": false
},
"isTitleCustom": {
"type": "boolean",
"readonly": true,
"description": "Defines if title is custom",
"example": false
},
"publisherName": {
"type": "string",
"description": "Publisher. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "Indiana University-Purdue Fort Wayne"
},
"titleId": {
"type": "integer",
"readonly": true,
"description": "Title Id",
"example": 2985519
},
"contributors": {
"type": "array",
"description": "List of contributors. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"items": {
"type": "object",
"description": "The Contributors Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Contributor object schema",
"javaType": "org.folio.rest.jaxrs.model.Contributors",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "Type of contributor. Valid values are Author, Illustrator, and Editor.",
"example": "Author"
},
"contributor": {
"type": "string",
"description": "Contributor Name",
"example": "Havard, Margaret"
}
}
}
},
"identifiers": {
"type": "array",
"description": "List of identifiers. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"items": {
"type": "object",
"description": "The Identifiers Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Identifier object schema",
"javaType": "org.folio.rest.jaxrs.model.Identifier",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"description": "Identifier Value",
"example": "100130"
},
"subtype": {
"type": "string",
"description": "Subtype for the identifier. Valid values are Print, Online.",
"enum": [
"Print",
"Online"
],
"example": "Print"
},
"type": {
"type": "string",
"description": "Type of identifier. Valid values are ISSN, ISBN.",
"enum": [
"ISSN",
"ISBN"
],
"example": "ISSN"
}
}
}
},
"name": {
"type": "string",
"description": "Resource name. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "American Journal of Undergraduate Research"
},
"publicationType": {
"type": "string",
"description": "Publication type. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Publication Type schema",
"javaType": "org.folio.rest.jaxrs.model.PublicationType",
"additionalProperties": false,
"enum": [
"All",
"Audiobook",
"Audio book",
"Book",
"Book Series",
"Database",
"Journal",
"Newsletter",
"Newspaper",
"Proceedings",
"Report",
"Streaming Audio",
"Streaming Video",
"Thesis & Dissertation",
"Thesis/Dissertation",
"Website",
"Web site",
"Unspecified"
],
"example": "Journal"
},
"subjects": {
"type": "array",
"readonly": true,
"description": "List of subjects for a given resource",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Subject object schema",
"description": "Subject object schema",
"javaType": "org.folio.rest.jaxrs.model.TitleSubject",
"additionalProperties": false,
"properties": {
"subject": {
"type": "string",
"description": "Subject subtype",
"example": "Social Services"
},
"type": {
"type": "string",
"description": "Subject type",
"example": "TLI"
}
}
}
},
"coverageStatement": {
"type": "string",
"description": "Coverage statement. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": "Only 2000s issues available."
},
"customEmbargoPeriod": {
"type": "object",
"description": "Custom Embargo Period information. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Embargo Period Schema",
"javaType": "org.folio.rest.jaxrs.model.EmbargoPeriod",
"additionalProperties": false,
"properties": {
"embargoUnit": {
"type": "string",
"description": "The unit of time to use for the embargo. Possible values are 'Days', 'Weeks', 'Months', 'Years'",
"enum": [
"Days",
"Weeks",
"Months",
"Years"
],
"example": "Days"
},
"embargoValue": {
"type": "integer",
"description": "The embargo value (number of embargoUnits). A Null value means there is no embargo.",
"example": 7
}
}
},
"isPackageCustom": {
"type": "boolean",
"readonly": true,
"description": "Defines if package is custom",
"example": false
},
"isSelected": {
"type": "boolean",
"description": "Defines if this item is selected. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": false
},
"titleHasSelectedResources": {
"type": "boolean",
"description": "Indicates if the title that contains this resource has selected resources",
"example": true
},
"isTokenNeeded": {
"type": "boolean",
"readonly": true,
"description": "Defines if token is needed",
"example": false
},
"locationId": {
"type": "integer",
"readonly": true,
"description": "Unique location id",
"example": 9091063
},
"managedEmbargoPeriod": {
"type": "object",
"readonly": true,
"description": "Managed Embargo Period information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Embargo Period Schema",
"javaType": "org.folio.rest.jaxrs.model.EmbargoPeriod",
"additionalProperties": false,
"properties": {
"embargoUnit": {
"type": "string",
"description": "The unit of time to use for the embargo. Possible values are 'Days', 'Weeks', 'Months', 'Years'",
"enum": [
"Days",
"Weeks",
"Months",
"Years"
],
"example": "Days"
},
"embargoValue": {
"type": "integer",
"description": "The embargo value (number of embargoUnits). A Null value means there is no embargo.",
"example": 7
}
}
},
"packageId": {
"type": "string",
"readonly": true,
"description": "Unique package id",
"example": "19-2333046"
},
"packageName": {
"type": "string",
"readonly": true,
"description": "Package name",
"example": "Applied Science & Technology Source Ultimate"
},
"url": {
"type": "string",
"description": "URL. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "http://search.ebscohost.com/direct.asp?db=aps&jid=BDGR&scope=site"
},
"providerId": {
"type": "integer",
"readonly": true,
"description": "Provider Id",
"example": 19
},
"providerName": {
"type": "string",
"readonly": true,
"description": "Provider name",
"example": "EBSCO"
},
"visibilityData": {
"type": "object",
"description": "Visibility data. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Visibility Data Schema",
"javaType": "org.folio.rest.jaxrs.model.VisibilityData",
"additionalProperties": false,
"properties": {
"isHidden": {
"type": "boolean",
"description": "Whether resource is hidden or not",
"example": false
},
"reason": {
"type": "string",
"description": "Reason why resource is hidden",
"example": "Set by System"
}
}
},
"managedCoverages": {
"type": "array",
"readonly": true,
"description": "List of Managed Coverages information",
"items": {
"type": "object",
"description": "Managed Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
},
"customCoverages": {
"type": "array",
"description": "List of Custom Coverages information. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"items": {
"type": "object",
"description": "Custom Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
},
"proxy": {
"type": "object",
"description": "Proxy. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Proxy Url Schema",
"javaType": "org.folio.rest.jaxrs.model.ProxyUrl",
"additionalProperties": false,
"extends": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Proxy Schema",
"description": "Proxy Schema",
"javaType": "org.folio.rest.jaxrs.model.Proxy",
"type": "object",
"additionalProperties": true,
"properties": {
"id": {
"type": "string",
"description": "Proxy Id",
"example": "EZProxy"
},
"inherited": {
"type": "boolean",
"description": "Whether this proxy is inherited",
"example": true
}
}
},
"properties": {
"proxiedUrl": {
"type": "string",
"description": "Proxied Url",
"example": "https://example.com"
}
}
},
"tags": {
"type": "object",
"description": "Resource tags",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "tags.schema",
"title": "tags",
"properties": {
"tagList": {
"description": "List of tags",
"type": "array",
"items": {
"type": "string"
}
}
},
"additionalProperties": false
},
"userDefinedField1": {
"type": "string",
"description": "User defined field 1",
"maxLength": 100
},
"userDefinedField2": {
"type": "string",
"description": "User defined field 2",
"maxLength": 100
},
"userDefinedField3": {
"type": "string",
"description": "User defined field 3",
"maxLength": 100
},
"userDefinedField4": {
"type": "string",
"description": "User defined field 4",
"maxLength": 100
},
"userDefinedField5": {
"type": "string",
"description": "User defined field 5",
"maxLength": 100
}
}
},
"relationships": {
"type": "object",
"description": "Displays if any relationship is included",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.ResourceRelationships",
"additionalProperties": false,
"properties": {
"provider": {
"type": "object",
"description": "Relationship of provider for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"title": {
"type": "object",
"description": "Relationship of title for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"package": {
"type": "object",
"description": "Relationship of package for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"accessType": {
"type": "object",
"description": "Relationship of access type for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"resources": {
"type": "object",
"description": "Resources relationship",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of whether an object is related to this resource",
"javaType": "org.folio.rest.jaxrs.model.MetaIncluded",
"additionalProperties": false,
"properties": {
"meta": {
"type": "object",
"description": "Metadata of whether an object is related to this resource",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
}
}
},
"included": {
"type": "array",
"description": "List of included objects",
"items": {
"type": "object",
"javaType": "java.lang.Object"
}
}
}
},
"included": {
"type": "array",
"description": "List of included items",
"items": {
"type": "object",
"javaType": "java.lang.Object"
}
},
"jsonapi": {
"type": "object",
"description": "version of json api",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
},
"required": [
"data",
"jsonapi"
]
}
Example:
{
"data": {
"id": "123355-2845510-17059786",
"type": "resources",
"attributes": {
"description": null,
"edition": null,
"isPeerReviewed": false,
"isTitleCustom": true,
"publisherName": null,
"titleId": 17059786,
"contributors": [],
"identifiers": [
{
"id": "978-1-4488-6317-4",
"type": "ISBN",
"subtype": "Print"
},
{
"id": "978-1-4488-6522-2",
"type": "ISBN",
"subtype": "Online"
}
],
"name": "SD custom title",
"publicationType": "Book",
"subjects": [],
"coverageStatement": null,
"customEmbargoPeriod": {
"embargoUnit": null,
"embargoValue": 0
},
"isPackageCustom": true,
"isSelected": true,
"isTokenNeeded": false,
"locationId": 0,
"managedEmbargoPeriod": {
"embargoUnit": null,
"embargoValue": 0
},
"packageId": "123355-2845510",
"packageName": "Testing2",
"url": null,
"providerId": 123355,
"providerName": "API DEV CORPORATE CUSTOMER",
"visibilityData": {
"isHidden": false,
"reason": ""
},
"managedCoverages": [],
"customCoverages": [],
"proxy": {
"id": "<n>",
"inherited": true
}
},
"relationships": {
"provider": {
"meta": {
"included": false
}
},
"title": {
"meta": {
"included": false
}
},
"package": {
"meta": {
"included": false
}
}
}
},
"jsonapi": {
"version": "1.0"
}
}
Bad Request
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [
{
"title": "Package and provider id are required"
}
],
"jsonapi": {
"version": "1.0"
}
}
Not Found
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [
{
"title": "Title not found"
}
],
"jsonapi": {
"version": "1.0"
}
}
Unprocessable Entity
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [{
"title": "Invalid PackageId",
"detail": "Packageid Cannot associate Title with a managed Package",
"source": {}
}],
"jsonapi": {
"version": "1.0"
}
}
Retrieve a specific resource given resourceId. Note that a resource is a managed/custom title associated with a managed/custom package. resourceId is providerId-packageId-titleId
GET /eholdings/resources/{resourceId}
Identifier of the resource formed from Provider Id, Package Id, Title Id (see example)
Example:
22-1887786-1440285
Include provider, package or title in response Possible values are
Example:
provider
OK
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource object schema",
"description": "Resource object schema",
"javaType": "org.folio.rest.jaxrs.model.Resource",
"type": "object",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "The Data Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource object schema for a collection",
"javaType": "org.folio.rest.jaxrs.model.ResourceCollectionItem",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"description": "Unique identifier of resource - combination of providerId-packageId-titleId",
"example": "583-4345-760027"
},
"type": {
"type": "string",
"description": "Type of resource",
"enum": [
"resources"
],
"example": "resources"
},
"attributes": {
"type": "object",
"description": "Resource object data attributes",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Object Data Attributes Schema",
"javaType": "org.folio.rest.jaxrs.model.ResourceDataAttributes",
"additionalProperties": false,
"properties": {
"alternateTitles": {
"type": "array",
"description": "List of alternate titles",
"items": {
"type": "object",
"description": "Alternate Title Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Alternate Title Schema",
"javaType": "org.folio.rest.jaxrs.model.AlternateTitle",
"additionalProperties": false,
"properties": {
"alternateTitle": {
"type": "string",
"description": "alternate title name",
"example": "Boston Coll Law Rev"
},
"titleType": {
"type": "string",
"description": "alternate title type",
"example": "Abbreviated"
}
}
}
},
"description": {
"type": "string",
"description": "Description of Resource. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "Online Reference"
},
"edition": {
"type": "string",
"description": "Edition. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE."
},
"isPeerReviewed": {
"type": "boolean",
"description": "Defines if peer is reviewed. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": false
},
"isTitleCustom": {
"type": "boolean",
"readonly": true,
"description": "Defines if title is custom",
"example": false
},
"publisherName": {
"type": "string",
"description": "Publisher. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "Indiana University-Purdue Fort Wayne"
},
"titleId": {
"type": "integer",
"readonly": true,
"description": "Title Id",
"example": 2985519
},
"contributors": {
"type": "array",
"description": "List of contributors. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"items": {
"type": "object",
"description": "The Contributors Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Contributor object schema",
"javaType": "org.folio.rest.jaxrs.model.Contributors",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "Type of contributor. Valid values are Author, Illustrator, and Editor.",
"example": "Author"
},
"contributor": {
"type": "string",
"description": "Contributor Name",
"example": "Havard, Margaret"
}
}
}
},
"identifiers": {
"type": "array",
"description": "List of identifiers. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"items": {
"type": "object",
"description": "The Identifiers Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Identifier object schema",
"javaType": "org.folio.rest.jaxrs.model.Identifier",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"description": "Identifier Value",
"example": "100130"
},
"subtype": {
"type": "string",
"description": "Subtype for the identifier. Valid values are Print, Online.",
"enum": [
"Print",
"Online"
],
"example": "Print"
},
"type": {
"type": "string",
"description": "Type of identifier. Valid values are ISSN, ISBN.",
"enum": [
"ISSN",
"ISBN"
],
"example": "ISSN"
}
}
}
},
"name": {
"type": "string",
"description": "Resource name. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "American Journal of Undergraduate Research"
},
"publicationType": {
"type": "string",
"description": "Publication type. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Publication Type schema",
"javaType": "org.folio.rest.jaxrs.model.PublicationType",
"additionalProperties": false,
"enum": [
"All",
"Audiobook",
"Audio book",
"Book",
"Book Series",
"Database",
"Journal",
"Newsletter",
"Newspaper",
"Proceedings",
"Report",
"Streaming Audio",
"Streaming Video",
"Thesis & Dissertation",
"Thesis/Dissertation",
"Website",
"Web site",
"Unspecified"
],
"example": "Journal"
},
"subjects": {
"type": "array",
"readonly": true,
"description": "List of subjects for a given resource",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Subject object schema",
"description": "Subject object schema",
"javaType": "org.folio.rest.jaxrs.model.TitleSubject",
"additionalProperties": false,
"properties": {
"subject": {
"type": "string",
"description": "Subject subtype",
"example": "Social Services"
},
"type": {
"type": "string",
"description": "Subject type",
"example": "TLI"
}
}
}
},
"coverageStatement": {
"type": "string",
"description": "Coverage statement. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": "Only 2000s issues available."
},
"customEmbargoPeriod": {
"type": "object",
"description": "Custom Embargo Period information. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Embargo Period Schema",
"javaType": "org.folio.rest.jaxrs.model.EmbargoPeriod",
"additionalProperties": false,
"properties": {
"embargoUnit": {
"type": "string",
"description": "The unit of time to use for the embargo. Possible values are 'Days', 'Weeks', 'Months', 'Years'",
"enum": [
"Days",
"Weeks",
"Months",
"Years"
],
"example": "Days"
},
"embargoValue": {
"type": "integer",
"description": "The embargo value (number of embargoUnits). A Null value means there is no embargo.",
"example": 7
}
}
},
"isPackageCustom": {
"type": "boolean",
"readonly": true,
"description": "Defines if package is custom",
"example": false
},
"isSelected": {
"type": "boolean",
"description": "Defines if this item is selected. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": false
},
"titleHasSelectedResources": {
"type": "boolean",
"description": "Indicates if the title that contains this resource has selected resources",
"example": true
},
"isTokenNeeded": {
"type": "boolean",
"readonly": true,
"description": "Defines if token is needed",
"example": false
},
"locationId": {
"type": "integer",
"readonly": true,
"description": "Unique location id",
"example": 9091063
},
"managedEmbargoPeriod": {
"type": "object",
"readonly": true,
"description": "Managed Embargo Period information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Embargo Period Schema",
"javaType": "org.folio.rest.jaxrs.model.EmbargoPeriod",
"additionalProperties": false,
"properties": {
"embargoUnit": {
"type": "string",
"description": "The unit of time to use for the embargo. Possible values are 'Days', 'Weeks', 'Months', 'Years'",
"enum": [
"Days",
"Weeks",
"Months",
"Years"
],
"example": "Days"
},
"embargoValue": {
"type": "integer",
"description": "The embargo value (number of embargoUnits). A Null value means there is no embargo.",
"example": 7
}
}
},
"packageId": {
"type": "string",
"readonly": true,
"description": "Unique package id",
"example": "19-2333046"
},
"packageName": {
"type": "string",
"readonly": true,
"description": "Package name",
"example": "Applied Science & Technology Source Ultimate"
},
"url": {
"type": "string",
"description": "URL. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "http://search.ebscohost.com/direct.asp?db=aps&jid=BDGR&scope=site"
},
"providerId": {
"type": "integer",
"readonly": true,
"description": "Provider Id",
"example": 19
},
"providerName": {
"type": "string",
"readonly": true,
"description": "Provider name",
"example": "EBSCO"
},
"visibilityData": {
"type": "object",
"description": "Visibility data. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Visibility Data Schema",
"javaType": "org.folio.rest.jaxrs.model.VisibilityData",
"additionalProperties": false,
"properties": {
"isHidden": {
"type": "boolean",
"description": "Whether resource is hidden or not",
"example": false
},
"reason": {
"type": "string",
"description": "Reason why resource is hidden",
"example": "Set by System"
}
}
},
"managedCoverages": {
"type": "array",
"readonly": true,
"description": "List of Managed Coverages information",
"items": {
"type": "object",
"description": "Managed Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
},
"customCoverages": {
"type": "array",
"description": "List of Custom Coverages information. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"items": {
"type": "object",
"description": "Custom Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
},
"proxy": {
"type": "object",
"description": "Proxy. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Proxy Url Schema",
"javaType": "org.folio.rest.jaxrs.model.ProxyUrl",
"additionalProperties": false,
"extends": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Proxy Schema",
"description": "Proxy Schema",
"javaType": "org.folio.rest.jaxrs.model.Proxy",
"type": "object",
"additionalProperties": true,
"properties": {
"id": {
"type": "string",
"description": "Proxy Id",
"example": "EZProxy"
},
"inherited": {
"type": "boolean",
"description": "Whether this proxy is inherited",
"example": true
}
}
},
"properties": {
"proxiedUrl": {
"type": "string",
"description": "Proxied Url",
"example": "https://example.com"
}
}
},
"tags": {
"type": "object",
"description": "Resource tags",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "tags.schema",
"title": "tags",
"properties": {
"tagList": {
"description": "List of tags",
"type": "array",
"items": {
"type": "string"
}
}
},
"additionalProperties": false
},
"userDefinedField1": {
"type": "string",
"description": "User defined field 1",
"maxLength": 100
},
"userDefinedField2": {
"type": "string",
"description": "User defined field 2",
"maxLength": 100
},
"userDefinedField3": {
"type": "string",
"description": "User defined field 3",
"maxLength": 100
},
"userDefinedField4": {
"type": "string",
"description": "User defined field 4",
"maxLength": 100
},
"userDefinedField5": {
"type": "string",
"description": "User defined field 5",
"maxLength": 100
}
}
},
"relationships": {
"type": "object",
"description": "Displays if any relationship is included",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.ResourceRelationships",
"additionalProperties": false,
"properties": {
"provider": {
"type": "object",
"description": "Relationship of provider for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"title": {
"type": "object",
"description": "Relationship of title for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"package": {
"type": "object",
"description": "Relationship of package for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"accessType": {
"type": "object",
"description": "Relationship of access type for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"resources": {
"type": "object",
"description": "Resources relationship",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of whether an object is related to this resource",
"javaType": "org.folio.rest.jaxrs.model.MetaIncluded",
"additionalProperties": false,
"properties": {
"meta": {
"type": "object",
"description": "Metadata of whether an object is related to this resource",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
}
}
},
"included": {
"type": "array",
"description": "List of included objects",
"items": {
"type": "object",
"javaType": "java.lang.Object"
}
}
}
},
"included": {
"type": "array",
"description": "List of included items",
"items": {
"type": "object",
"javaType": "java.lang.Object"
}
},
"jsonapi": {
"type": "object",
"description": "version of json api",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
},
"required": [
"data",
"jsonapi"
]
}
Example:
{
"data": {
"id": "22-1887786-1440285",
"type": "resources",
"attributes": {
"description": null,
"edition": null,
"isPeerReviewed": false,
"isTitleCustom": false,
"publisherName": "Elsevier",
"titleId": 1440285,
"contributors": [
{
"type": "Author",
"contributor": "Havard, Margaret"
},
{
"type": "Author",
"contributor": "Tiziani, Adriana."
}
],
"identifiers": [
{
"id": "1440285",
"type": "BHM",
"subtype": "Empty"
},
{
"id": "475765",
"type": "EPBookID",
"subtype": "Empty"
},
{
"id": "978-0-7295-3913-5",
"type": "ISBN",
"subtype": "Print"
},
{
"id": "978-0-7295-7913-1",
"type": "ISBN",
"subtype": "Online"
}
],
"name": "Havard's Nursing Guide to Drugs (Nursing Guide to Drugs)",
"publicationType": "Book",
"subjects": [
{
"type": "BISAC",
"subject": "MEDICAL / Nursing / Pharmacology"
}
],
"coverageStatement": "Only 2000s issues available.",
"customEmbargoPeriod": {
"embargoUnit": "Days",
"embargoValue": 7
},
"isPackageCustom": false,
"isSelected": true,
"isTokenNeeded": true,
"locationId": 17545807,
"managedEmbargoPeriod": {
"embargoUnit": null,
"embargoValue": 0
},
"packageId": "22-1887786",
"packageName": "ProQuest Ebook Central",
"url": "https://ebookcentral.proquest.com/lib/[[SiteID]]/detail.action?docID=1722033",
"providerId": 22,
"providerName": "Proquest Info & Learning Co",
"visibilityData": {
"isHidden": true,
"reason": ""
},
"managedCoverages": [
{
"beginCoverage": "2010-01-01",
"endCoverage": "2010-12-31"
}
],
"customCoverages": [
{
"beginCoverage": "2003-01-01",
"endCoverage": "2004-01-01"
}
],
"proxy": {
"id": "EZProxy",
"inherited": false
}
},
"relationships": {
"provider": {
"data": {
"type": "providers",
"id": "22"
}
},
"title": {
"meta": {
"included": false
}
},
"package": {
"meta": {
"included": false
}
}
}
},
"included": [
{
"id": "22",
"type": "providers",
"attributes": {
"name": "Proquest Info & Learning Co",
"packagesTotal": 840,
"packagesSelected": 30,
"providerToken": null,
"supportsCustomPackages": false,
"proxy": {
"id": "EZProxy",
"inherited": true
}
},
"relationships": {
"packages": {
"meta": {
"included": false
}
}
}
},
{
"id": "1440285",
"type": "titles",
"attributes": {
"name": "Havard's Nursing Guide to Drugs (Nursing Guide to Drugs)",
"publisherName": "Elsevier",
"isTitleCustom": false,
"subjects": [
{
"type": "BISAC",
"subject": "MEDICAL / Nursing / Pharmacology"
}
],
"identifiers": [
{
"id": "978-0-7295-3913-5",
"type": "ISBN",
"subtype": "Print"
},
{
"id": "978-0-7295-7913-1",
"type": "ISBN",
"subtype": "Online"
}
],
"publicationType": "Book",
"edition": null,
"description": null,
"isPeerReviewed": false,
"contributors": [
{
"type": "author",
"contributor": "Havard, Margaret"
},
{
"type": "author",
"contributor": "Tiziani, Adriana."
}
]
},
"relationships": {
"resources": {
"meta": {
"included": false
}
}
}
},
{
"id": "22-1887786",
"type": "packages",
"attributes": {
"contentType": "E-Book",
"customCoverage": {
"beginCoverage": "",
"endCoverage": ""
},
"isCustom": false,
"isSelected": true,
"name": "ProQuest Ebook Central",
"packageId": 1887786,
"packageType": "Variable",
"providerId": 22,
"providerName": "Proquest Info & Learning Co",
"selectedCount": 1305491,
"titleCount": 1305491,
"visibilityData": {
"isHidden": false,
"reason": ""
},
"allowKbToAddTitles": true,
"packageToken": {
"factName": "[[SiteID]]",
"helpText": "The ID may contain a combination of alphanumeric characters, varying in length.",
"value": null,
"prompt": "/lib/ "
},
"proxy": {
"id": "EZProxy",
"inherited": true
}
},
"relationships": {
"resources": {
"meta": {
"included": false
}
},
"provider": {
"meta": {
"included": false
}
}
}
}
],
"jsonapi": {
"version": "1.0"
}
}
Bad Request
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [
{
"title": "Invalid package_id",
"detail": "Package can't be blank",
"source": {}
},
{
"title": "Invalid package_id",
"detail": "Package :Invalid package id",
"source": {}
},
{
"title": "Invalid title_id",
"detail": "Title can't be blank",
"source": {}
},
{
"title": "Invalid title_id",
"detail": "Title :Invalid title id",
"source": {}
}
],
"jsonapi": {
"version": "1.0"
}
}
Not Found
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [{
"title": "Title not found"
}],
"jsonapi": {
"version": "1.0"
}
}
Update a managed or custom resource using resourceId Note that resourceId is providerId-packageId-titleId
PUT /eholdings/resources/{resourceId}
Identifier of the resource formed from Provider Id, Package Id, Title Id (see example)
Example:
22-1887786-1440285
Example:
application/vnd.api+json
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource PUT Request Schema",
"description": "Resource Put Request Schema using JSON API",
"javaType": "org.folio.rest.jaxrs.model.ResourcePutRequest",
"type": "object",
"additionalProperties": false,
"properties": {
"data": {
"description": "Data object of resource put request",
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Put Data Schema",
"javaType": "org.folio.rest.jaxrs.model.ResourcePutData",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"readonly": true,
"description": "Unique resource id",
"example": "123356-3157038-394579"
},
"type": {
"description": "Data type",
"type": "string",
"enum": [
"resources"
],
"example": "resources"
},
"attributes": {
"description": "Data type attributes",
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Put Data Attributes Schema",
"javaType": "org.folio.rest.jaxrs.model.ResourcePutDataAttributes",
"additionalProperties": true,
"properties": {
"isTitleCustom": {
"type": "boolean",
"readonly": true,
"description": "Defines if title is custom",
"example": false
},
"titleId": {
"type": "integer",
"readonly": true,
"description": "Title Id",
"example": 2985519
},
"coverageStatement": {
"type": "string",
"description": "Coverage statement. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": "Only 2000s issues available."
},
"customEmbargoPeriod": {
"type": "object",
"description": "Custom Embargo Period information. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Embargo Period Schema",
"javaType": "org.folio.rest.jaxrs.model.EmbargoPeriod",
"additionalProperties": false,
"properties": {
"embargoUnit": {
"type": "string",
"description": "The unit of time to use for the embargo. Possible values are 'Days', 'Weeks', 'Months', 'Years'",
"enum": [
"Days",
"Weeks",
"Months",
"Years"
],
"example": "Days"
},
"embargoValue": {
"type": "integer",
"description": "The embargo value (number of embargoUnits). A Null value means there is no embargo.",
"example": 7
}
}
},
"isPackageCustom": {
"type": "boolean",
"readonly": true,
"description": "Defines if package is custom",
"example": false
},
"isSelected": {
"type": "boolean",
"description": "Defines if this item is selected. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": false
},
"isTokenNeeded": {
"type": "boolean",
"readonly": true,
"description": "Defines if token is needed",
"example": false
},
"locationId": {
"type": "integer",
"readonly": true,
"description": "Unique location id",
"example": 9091063
},
"managedEmbargoPeriod": {
"type": "object",
"readonly": true,
"description": "Managed Embargo Period information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Embargo Period Schema",
"javaType": "org.folio.rest.jaxrs.model.EmbargoPeriod",
"additionalProperties": false,
"properties": {
"embargoUnit": {
"type": "string",
"description": "The unit of time to use for the embargo. Possible values are 'Days', 'Weeks', 'Months', 'Years'",
"enum": [
"Days",
"Weeks",
"Months",
"Years"
],
"example": "Days"
},
"embargoValue": {
"type": "integer",
"description": "The embargo value (number of embargoUnits). A Null value means there is no embargo.",
"example": 7
}
}
},
"packageId": {
"type": "string",
"readonly": true,
"description": "Unique package id",
"example": "19-2333046"
},
"packageName": {
"type": "string",
"readonly": true,
"description": "Package name",
"example": "Applied Science & Technology Source Ultimate"
},
"url": {
"type": "string",
"description": "URL. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "http://search.ebscohost.com/direct.asp?db=aps&jid=BDGR&scope=site"
},
"providerId": {
"type": "integer",
"readonly": true,
"description": "Provider Id",
"example": 19
},
"providerName": {
"type": "string",
"readonly": true,
"description": "Provider name",
"example": "EBSCO"
},
"visibilityData": {
"type": "object",
"description": "Visibility data. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Visibility Data Schema",
"javaType": "org.folio.rest.jaxrs.model.VisibilityData",
"additionalProperties": false,
"properties": {
"isHidden": {
"type": "boolean",
"description": "Whether resource is hidden or not",
"example": false
},
"reason": {
"type": "string",
"description": "Reason why resource is hidden",
"example": "Set by System"
}
}
},
"managedCoverages": {
"type": "array",
"readonly": true,
"description": "List of Managed Coverages information",
"items": {
"type": "object",
"description": "Managed Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
},
"accessTypeId": {
"type": "string",
"description": "Access type id",
"example": "f973c3b6-85fc-4d35-bda8-f31b568957bf",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"customCoverages": {
"type": "array",
"description": "List of Custom Coverages information. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"items": {
"type": "object",
"description": "Custom Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
},
"userDefinedField1": {
"type": "string",
"description": "User defined field 1"
},
"userDefinedField2": {
"type": "string",
"description": "User defined field 2"
},
"userDefinedField3": {
"type": "string",
"description": "User defined field 3"
},
"userDefinedField4": {
"type": "string",
"description": "User defined field 4"
},
"userDefinedField5": {
"type": "string",
"description": "User defined field 5"
},
"proxy": {
"type": "object",
"description": "Proxy. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Proxy Schema",
"javaType": "org.folio.rest.jaxrs.model.Proxy",
"additionalProperties": true,
"properties": {
"id": {
"type": "string",
"description": "Proxy Id",
"example": "EZProxy"
},
"inherited": {
"type": "boolean",
"description": "Whether this proxy is inherited",
"example": true
}
}
}
},
"required": [
"isSelected"
]
}
},
"required": [
"type",
"attributes"
]
}
},
"required": [
"data"
]
}
Example:
{
"data": {
"type": "resources",
"attributes": {
"name": "Updated Custom Title Name",
"isPeerReviewed": true,
"publicationType": "Newspaper",
"publisherName": "Updated Publisher",
"edition": "5",
"description": "Updated Description",
"url": "https://hello.io",
"contributors": [
{
"type":"Author",
"contributor":"smith, john"
},
{
"type":"Illustrator",
"contributor":"smith, ralph"
}
],
"identifiers": [
{
"id":"11-2222-3333",
"type":"ISSN",
"subtype":"Online"
}
],
"isSelected": true,
"visibilityData": {
"isHidden" : false
},
"customEmbargoPeriod": {
"embargoUnit" : "Months",
"embargoValue" : 5
},
"customCoverages" : [
{
"beginCoverage" : "2001-01-01",
"endCoverage" : "2004-02-01"
}
],
"coverageStatement": "Updated Coverage Statement",
"proxy" : {
"id" : "<n>"
}
}
}
}
OK
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource object schema",
"description": "Resource object schema",
"javaType": "org.folio.rest.jaxrs.model.Resource",
"type": "object",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "The Data Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource object schema for a collection",
"javaType": "org.folio.rest.jaxrs.model.ResourceCollectionItem",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"description": "Unique identifier of resource - combination of providerId-packageId-titleId",
"example": "583-4345-760027"
},
"type": {
"type": "string",
"description": "Type of resource",
"enum": [
"resources"
],
"example": "resources"
},
"attributes": {
"type": "object",
"description": "Resource object data attributes",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Object Data Attributes Schema",
"javaType": "org.folio.rest.jaxrs.model.ResourceDataAttributes",
"additionalProperties": false,
"properties": {
"alternateTitles": {
"type": "array",
"description": "List of alternate titles",
"items": {
"type": "object",
"description": "Alternate Title Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Alternate Title Schema",
"javaType": "org.folio.rest.jaxrs.model.AlternateTitle",
"additionalProperties": false,
"properties": {
"alternateTitle": {
"type": "string",
"description": "alternate title name",
"example": "Boston Coll Law Rev"
},
"titleType": {
"type": "string",
"description": "alternate title type",
"example": "Abbreviated"
}
}
}
},
"description": {
"type": "string",
"description": "Description of Resource. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "Online Reference"
},
"edition": {
"type": "string",
"description": "Edition. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE."
},
"isPeerReviewed": {
"type": "boolean",
"description": "Defines if peer is reviewed. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": false
},
"isTitleCustom": {
"type": "boolean",
"readonly": true,
"description": "Defines if title is custom",
"example": false
},
"publisherName": {
"type": "string",
"description": "Publisher. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "Indiana University-Purdue Fort Wayne"
},
"titleId": {
"type": "integer",
"readonly": true,
"description": "Title Id",
"example": 2985519
},
"contributors": {
"type": "array",
"description": "List of contributors. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"items": {
"type": "object",
"description": "The Contributors Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Contributor object schema",
"javaType": "org.folio.rest.jaxrs.model.Contributors",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "Type of contributor. Valid values are Author, Illustrator, and Editor.",
"example": "Author"
},
"contributor": {
"type": "string",
"description": "Contributor Name",
"example": "Havard, Margaret"
}
}
}
},
"identifiers": {
"type": "array",
"description": "List of identifiers. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"items": {
"type": "object",
"description": "The Identifiers Schema",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Identifier object schema",
"javaType": "org.folio.rest.jaxrs.model.Identifier",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"description": "Identifier Value",
"example": "100130"
},
"subtype": {
"type": "string",
"description": "Subtype for the identifier. Valid values are Print, Online.",
"enum": [
"Print",
"Online"
],
"example": "Print"
},
"type": {
"type": "string",
"description": "Type of identifier. Valid values are ISSN, ISBN.",
"enum": [
"ISSN",
"ISBN"
],
"example": "ISSN"
}
}
}
},
"name": {
"type": "string",
"description": "Resource name. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "American Journal of Undergraduate Research"
},
"publicationType": {
"type": "string",
"description": "Publication type. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Publication Type schema",
"javaType": "org.folio.rest.jaxrs.model.PublicationType",
"additionalProperties": false,
"enum": [
"All",
"Audiobook",
"Audio book",
"Book",
"Book Series",
"Database",
"Journal",
"Newsletter",
"Newspaper",
"Proceedings",
"Report",
"Streaming Audio",
"Streaming Video",
"Thesis & Dissertation",
"Thesis/Dissertation",
"Website",
"Web site",
"Unspecified"
],
"example": "Journal"
},
"subjects": {
"type": "array",
"readonly": true,
"description": "List of subjects for a given resource",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Subject object schema",
"description": "Subject object schema",
"javaType": "org.folio.rest.jaxrs.model.TitleSubject",
"additionalProperties": false,
"properties": {
"subject": {
"type": "string",
"description": "Subject subtype",
"example": "Social Services"
},
"type": {
"type": "string",
"description": "Subject type",
"example": "TLI"
}
}
}
},
"coverageStatement": {
"type": "string",
"description": "Coverage statement. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": "Only 2000s issues available."
},
"customEmbargoPeriod": {
"type": "object",
"description": "Custom Embargo Period information. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Embargo Period Schema",
"javaType": "org.folio.rest.jaxrs.model.EmbargoPeriod",
"additionalProperties": false,
"properties": {
"embargoUnit": {
"type": "string",
"description": "The unit of time to use for the embargo. Possible values are 'Days', 'Weeks', 'Months', 'Years'",
"enum": [
"Days",
"Weeks",
"Months",
"Years"
],
"example": "Days"
},
"embargoValue": {
"type": "integer",
"description": "The embargo value (number of embargoUnits). A Null value means there is no embargo.",
"example": 7
}
}
},
"isPackageCustom": {
"type": "boolean",
"readonly": true,
"description": "Defines if package is custom",
"example": false
},
"isSelected": {
"type": "boolean",
"description": "Defines if this item is selected. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": false
},
"titleHasSelectedResources": {
"type": "boolean",
"description": "Indicates if the title that contains this resource has selected resources",
"example": true
},
"isTokenNeeded": {
"type": "boolean",
"readonly": true,
"description": "Defines if token is needed",
"example": false
},
"locationId": {
"type": "integer",
"readonly": true,
"description": "Unique location id",
"example": 9091063
},
"managedEmbargoPeriod": {
"type": "object",
"readonly": true,
"description": "Managed Embargo Period information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Embargo Period Schema",
"javaType": "org.folio.rest.jaxrs.model.EmbargoPeriod",
"additionalProperties": false,
"properties": {
"embargoUnit": {
"type": "string",
"description": "The unit of time to use for the embargo. Possible values are 'Days', 'Weeks', 'Months', 'Years'",
"enum": [
"Days",
"Weeks",
"Months",
"Years"
],
"example": "Days"
},
"embargoValue": {
"type": "integer",
"description": "The embargo value (number of embargoUnits). A Null value means there is no embargo.",
"example": 7
}
}
},
"packageId": {
"type": "string",
"readonly": true,
"description": "Unique package id",
"example": "19-2333046"
},
"packageName": {
"type": "string",
"readonly": true,
"description": "Package name",
"example": "Applied Science & Technology Source Ultimate"
},
"url": {
"type": "string",
"description": "URL. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "http://search.ebscohost.com/direct.asp?db=aps&jid=BDGR&scope=site"
},
"providerId": {
"type": "integer",
"readonly": true,
"description": "Provider Id",
"example": 19
},
"providerName": {
"type": "string",
"readonly": true,
"description": "Provider name",
"example": "EBSCO"
},
"visibilityData": {
"type": "object",
"description": "Visibility data. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Visibility Data Schema",
"javaType": "org.folio.rest.jaxrs.model.VisibilityData",
"additionalProperties": false,
"properties": {
"isHidden": {
"type": "boolean",
"description": "Whether resource is hidden or not",
"example": false
},
"reason": {
"type": "string",
"description": "Reason why resource is hidden",
"example": "Set by System"
}
}
},
"managedCoverages": {
"type": "array",
"readonly": true,
"description": "List of Managed Coverages information",
"items": {
"type": "object",
"description": "Managed Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
},
"customCoverages": {
"type": "array",
"description": "List of Custom Coverages information. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"items": {
"type": "object",
"description": "Custom Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
},
"proxy": {
"type": "object",
"description": "Proxy. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Proxy Url Schema",
"javaType": "org.folio.rest.jaxrs.model.ProxyUrl",
"additionalProperties": false,
"extends": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Proxy Schema",
"description": "Proxy Schema",
"javaType": "org.folio.rest.jaxrs.model.Proxy",
"type": "object",
"additionalProperties": true,
"properties": {
"id": {
"type": "string",
"description": "Proxy Id",
"example": "EZProxy"
},
"inherited": {
"type": "boolean",
"description": "Whether this proxy is inherited",
"example": true
}
}
},
"properties": {
"proxiedUrl": {
"type": "string",
"description": "Proxied Url",
"example": "https://example.com"
}
}
},
"tags": {
"type": "object",
"description": "Resource tags",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "tags.schema",
"title": "tags",
"properties": {
"tagList": {
"description": "List of tags",
"type": "array",
"items": {
"type": "string"
}
}
},
"additionalProperties": false
},
"userDefinedField1": {
"type": "string",
"description": "User defined field 1",
"maxLength": 100
},
"userDefinedField2": {
"type": "string",
"description": "User defined field 2",
"maxLength": 100
},
"userDefinedField3": {
"type": "string",
"description": "User defined field 3",
"maxLength": 100
},
"userDefinedField4": {
"type": "string",
"description": "User defined field 4",
"maxLength": 100
},
"userDefinedField5": {
"type": "string",
"description": "User defined field 5",
"maxLength": 100
}
}
},
"relationships": {
"type": "object",
"description": "Displays if any relationship is included",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.ResourceRelationships",
"additionalProperties": false,
"properties": {
"provider": {
"type": "object",
"description": "Relationship of provider for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"title": {
"type": "object",
"description": "Relationship of title for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"package": {
"type": "object",
"description": "Relationship of package for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"accessType": {
"type": "object",
"description": "Relationship of access type for a given object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Relationship for a given object",
"javaType": "org.folio.rest.jaxrs.model.HasOneRelationship",
"additionalProperties": false,
"properties": {
"data": {
"type": "object",
"description": "relationship Data Information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Data of relationships for a given object",
"javaType": "org.folio.rest.jaxrs.model.RelationshipData",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"description": "The Type Schema",
"example": "resources"
},
"id": {
"type": "string",
"description": "The Id Schema",
"example": "269-1565-316875"
}
}
},
"meta": {
"type": "object",
"description": "Meta information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
},
"resources": {
"type": "object",
"description": "Resources relationship",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of whether an object is related to this resource",
"javaType": "org.folio.rest.jaxrs.model.MetaIncluded",
"additionalProperties": false,
"properties": {
"meta": {
"type": "object",
"description": "Metadata of whether an object is related to this resource",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Metadata of packages related to a provider",
"javaType": "org.folio.rest.jaxrs.model.MetaDataIncluded",
"additionalProperties": false,
"properties": {
"included": {
"type": "boolean",
"description": "Relationship between objects",
"example": false
}
}
}
}
}
}
},
"included": {
"type": "array",
"description": "List of included objects",
"items": {
"type": "object",
"javaType": "java.lang.Object"
}
}
}
},
"included": {
"type": "array",
"description": "List of included items",
"items": {
"type": "object",
"javaType": "java.lang.Object"
}
},
"jsonapi": {
"type": "object",
"description": "version of json api",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
},
"required": [
"data",
"jsonapi"
]
}
Example:
{
"data": {
"id": "123355-2845510-17059786",
"type": "resources",
"attributes": {
"description": null,
"edition": null,
"isPeerReviewed": false,
"isTitleCustom": true,
"publisherName": null,
"titleId": 17059786,
"contributors": [],
"identifiers": [],
"name": "SD custom title",
"publicationType": "Book",
"subjects": [],
"coverageStatement": "hello",
"customEmbargoPeriod": {
"embargoUnit": "Weeks",
"embargoValue": 4
},
"isPackageCustom": true,
"isSelected": true,
"isTokenNeeded": false,
"locationId": 39248032,
"managedEmbargoPeriod": {
"embargoUnit": null,
"embargoValue": 0
},
"packageId": "123355-2845510",
"packageName": "\"Testing2\"",
"url": "https://hello.io",
"providerId": 123355,
"providerName": "API DEV CORPORATE CUSTOMER",
"visibilityData": {
"isHidden": true,
"reason": ""
},
"managedCoverages": [],
"customCoverages": [{
"beginCoverage": "2018-06-05",
"endCoverage": "2018-06-07"
},
{
"beginCoverage": "2018-06-08",
"endCoverage": "2018-06-10"
}
],
"proxy": {
"id": "<n>",
"inherited": true
}
},
"relationships": {
"provider": {
"meta": {
"included": false
}
},
"title": {
"meta": {
"included": false
}
},
"package": {
"meta": {
"included": false
}
}
}
},
"jsonapi": {
"version": "1.0"
}
}
Bad Request
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [{
"title": "CoverageList cannot contain overlapping dates."
}],
"jsonapi": {
"version": "1.0"
}
}
Not Found
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [{
"title": "Title not found"
}],
"jsonapi": {
"version": "1.0"
}
}
Unprocessable Entity
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [{
"title": "Invalid beginCoverage",
"detail": "Begincoverage must be blank",
"source": {}
},
{
"title": "Invalid endCoverage",
"detail": "Endcoverage must be blank",
"source": {}
}
],
"jsonapi": {
"version": "1.0"
}
}
Delete the association between a custom/managed title and a custom package using resourceId. Note that resourceId is providerId-packageId-titleId If the title is custom and is not associated with any other package, then the title will be deleted from the knowledge base.
DELETE /eholdings/resources/{resourceId}
Identifier of the resource formed from Provider Id, Package Id, Title Id (see example)
Example:
22-1887786-1440285
No Content
Bad Request
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [{
"title": "Invalid resource",
"detail": "Resource cannot be deleted",
"source": {}
}],
"jsonapi": {
"version": "1.0"
}
}
Not Found
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [{
"title": "Title not found"
}],
"jsonapi": {
"version": "1.0"
}
}
POST /eholdings/resources/bulk/fetch
Example:
application/vnd.api+json
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Bulk Fetch object schema",
"description": "Resource Bulk Fetch object schema",
"javaType": "org.folio.rest.jaxrs.model.ResourcePostBulkFetchRequest",
"type": "object",
"additionalProperties": false,
"properties": {
"resources": {
"type": "array",
"uniqueItems": true,
"maxItems": 20,
"description": "A list of resource ids",
"items": {
"type": "string",
"description": "A resource id.",
"pattern": "\\d+-\\d+-\\d+",
"examples": [
"123-122-12354",
"12-3446-67879"
]
}
}
},
"required": [
"resources"
]
}
Example:
{
"resources": ["186-3150130-19087948", "413-3757-904662", "19-2320561-904661", "19-2561032-904662"]
}
OK
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Bulk Fetch object schema",
"description": "Resource Bulk Fetch object schema",
"javaType": "org.folio.rest.jaxrs.model.ResourceBulkFetchCollection",
"type": "object",
"additionalProperties": false,
"properties": {
"included": {
"type": "array",
"description": "List of included resource items",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Bulk Fetch object schema for a collection",
"description": "Resource Bulk Fetch object schema for a collection",
"javaType": "org.folio.rest.jaxrs.model.ResourceBulkFetchCollectionItem",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"description": "Unique identifier of resource - combination of providerId-packageId-titleId",
"example": "583-4345-760027"
},
"type": {
"type": "string",
"description": "Type of resource",
"enum": [
"resources"
],
"example": "resources"
},
"attributes": {
"type": "object",
"description": "Resource object data attributes",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Bulk Fetch Object Data Attributes Schema",
"javaType": "org.folio.rest.jaxrs.model.ResourceBulkFetchDataAttributes",
"additionalProperties": false,
"properties": {
"titleId": {
"type": "integer",
"readonly": true,
"description": "Title Id",
"example": 2985519
},
"name": {
"type": "string",
"description": "Resource name. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"example": "American Journal of Undergraduate Research"
},
"publicationType": {
"type": "string",
"description": "Publication type. Note that this attribute can be updated ONLY FOR A CUSTOM RESOURCE.",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Publication Type schema",
"javaType": "org.folio.rest.jaxrs.model.PublicationType",
"additionalProperties": false,
"enum": [
"All",
"Audiobook",
"Audio book",
"Book",
"Book Series",
"Database",
"Journal",
"Newsletter",
"Newspaper",
"Proceedings",
"Report",
"Streaming Audio",
"Streaming Video",
"Thesis & Dissertation",
"Thesis/Dissertation",
"Website",
"Web site",
"Unspecified"
],
"example": "Journal"
},
"coverageStatement": {
"type": "string",
"description": "Coverage statement. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"example": "Only 2000s issues available."
},
"packageId": {
"type": "string",
"readonly": true,
"description": "Unique package id",
"example": "19-2333046"
},
"providerId": {
"type": "integer",
"readonly": true,
"description": "Provider Id",
"example": 19
},
"providerName": {
"type": "string",
"readonly": true,
"description": "Provider name",
"example": "EBSCO"
},
"managedCoverages": {
"type": "array",
"readonly": true,
"description": "List of Managed Coverages information",
"items": {
"type": "object",
"description": "Managed Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
},
"customCoverages": {
"type": "array",
"description": "List of Custom Coverages information. Note that this attribute can be updated both for CUSTOM AND MANAGED RESOURCES.",
"items": {
"type": "object",
"description": "Custom Coverages information",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Coverage Schema",
"javaType": "org.folio.rest.jaxrs.model.Coverage",
"additionalProperties": false,
"properties": {
"beginCoverage": {
"type": "string",
"description": "Begin Coverage Date",
"example": "2003-01-01"
},
"endCoverage": {
"type": "string",
"description": "End Coverage Date",
"example": "2003-12-01"
}
}
}
}
}
}
}
}
},
"meta": {
"type": "object",
"description": "Metadata of failed resources",
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resources Metadata Schema",
"javaType": "org.folio.rest.jaxrs.model.FailedResourcesInformation",
"properties": {
"failed": {
"type": "object",
"description": "Metadata of failed resources",
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Resource Failed Ids Schema",
"javaType": "org.folio.rest.jaxrs.model.FailedResourceIds",
"properties": {
"resources": {
"type": "array",
"description": "List of failed resource ids",
"items": {
"type": "string",
"description": "Failed resource id"
}
}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "version of json api",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
},
"required": [
"included",
"jsonapi"
]
}
Example:
{
"included": [
{
"id": "19-2561032-904662",
"type": "resources",
"attributes": {
"titleId": 904662,
"name": "A to B",
"publicationType": "Journal",
"packageId": "19-2561032",
"providerId": 19,
"providerName": "EBSCO",
"managedCoverages": [
{
"beginCoverage": "2012-02-01",
"endCoverage": ""
}
],
"customCoverages": []
}
}
],
"meta": {
"failed": {
"resources": [
"186-3150130-190879d48",
"413-3757-9g04662",
"19-2320561-904661"
]
}
},
"jsonapi": {
"version": "1.0"
}
}
Unprocessable Entity
Media type: application/vnd.api+json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response Schema",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiError",
"type": "object",
"additionalProperties": false,
"properties": {
"errors": {
"type": "array",
"description": "Error Response List",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Error Response object",
"description": "Error Response Schema for JSON API",
"javaType": "org.folio.rest.jaxrs.model.JsonapiErrorResponse",
"additionalProperties": false,
"properties": {
"title": {
"type": "string",
"description": "Error Message Title",
"example": "Invalid KB API Credentials"
},
"detail": {
"type": "string",
"description": "Error Message Detail",
"example": "Kb api credentials are invalid"
},
"source": {
"type": "object",
"description": "Source of Error Message",
"example": {}
}
}
}
},
"jsonapi": {
"type": "object",
"description": "JSON API Version",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "JSON API Version Schema",
"javaType": "org.folio.rest.jaxrs.model.JsonAPI",
"additionalProperties": false,
"properties": {
"version": {
"type": "string",
"description": "Version of json api being used",
"example": "1.0"
}
},
"required": [
"version"
]
}
}
}
Example:
{
"errors": [
{
"message": "size must be between 0 and 2",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "resources",
"value": "[186-3150130-19087948, 413-3757-904662, 19-2320561-904661, 19-2561032-904662]"
}
]
}
]
}