Pieces version v1
https://github.com/folio-org/mod-orders
Orders Business Logic API
API for managing pieces
Pieces
Create piece record
Retrieve a list of piece items.
Create piece record
get /orders/pieces
Retrieve a list of piece items.
Query Parameters
- totalRecords: (string - default: auto - pattern: exact|estimated|none|auto)
How to calculate the totalRecords property. "exact" for the correct number, "estimated" for an estimation, "auto" to automatically select "exact" or "estimated", "none" for suppressing the totalRecords property. For details see https://github.com/folio-org/raml-module-builder#estimated-totalrecords
Example:
none
- offset: (integer - default: 0 - minimum: 0 - maximum: 2147483647)
Skip over a number of elements by specifying an offset value for the query
Example:
0
- limit: (integer - default: 10 - minimum: 0 - maximum: 2147483647)
Limit the number of elements returned in the response
Example:
10
- query: (string)
A query expressed as a CQL string (see dev.folio.org/reference/glossary#cql) using valid searchable fields. The first example below shows the general form of a full CQL query, but those fields might not be relevant in this context.
using CQL (indexes for piece records)
Example:
(username=="ab*" or personal.firstName=="ab*" or personal.lastName=="ab*") and active=="true" sortby personal.lastName personal.firstName barcode format=="Physical"
HTTP status code 200
Returns a list of piece items
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "collection of piece records",
"type": "object",
"properties": {
"pieces": {
"description": "collection of piece records",
"type": "array",
"id": "pieces",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Piece details",
"javaName": "Piece",
"properties": {
"id": {
"description": "UUID of this piece record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"displaySummary": {
"description": "Display summary information",
"type": "string"
},
"comment": {
"description": "Free form commentary",
"type": "string"
},
"format": {
"description": "The format of the piece",
"type": "string",
"$schema": "http://json-schema.org/draft-04/schema#",
"enum": [
"Physical",
"Electronic",
"Other"
]
},
"itemId": {
"description": "UUID of the associated item record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"bindItemId": {
"description": "UUID of the associated bind item record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"bindItemTenantId": {
"description": "Bind item tenant for ECS-enabled clusters",
"type": "string"
},
"locationId": {
"description": "UUID of the (inventory) location record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"poLineId": {
"description": "UUID of the purchase order line this record is associated with",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"titleId": {
"description": "UUID of the title record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"holdingId": {
"description": "UUID of the holding record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"receivingTenantId": {
"description": "Receiving tenant for ECS-enabled clusters",
"type": "string"
},
"displayOnHolding": {
"description": "Whether or not receiving history should be displayed in holding record view",
"type": "boolean",
"default": false
},
"displayToPublic": {
"description": "Whether or not the piece data should display to patrons at point of receipt",
"type": "boolean",
"default": false
},
"enumeration": {
"type": "string",
"description": "Enumeration is the descriptive information for the numbering scheme of a serial. Synchronized with inventory item."
},
"chronology": {
"type": "string",
"description": "Chronology is the descriptive information for the dating scheme of a serial. Synchronized with inventory item."
},
"barcode": {
"type": "string",
"description": "Barcode is the descriptive information for the barcode of a serial. Synchronized with inventory item."
},
"accessionNumber": {
"type": "string",
"description": "AccessionNumber is the descriptive information for the accession number of a serial. Synchronized with inventory item."
},
"callNumber": {
"type": "string",
"description": "CallNumber is the descriptive information for the call number of a serial. Synchronized with inventory item."
},
"discoverySuppress": {
"type": "boolean",
"description": "Records the fact that the record should not be displayed in a discovery system"
},
"copyNumber": {
"type": "string",
"description": "Copy number of the piece"
},
"receivingStatus": {
"description": "The status of this piece",
"$schema": "http://json-schema.org/draft-04/schema#",
"javaName": "ReceivingStatus",
"type": "string",
"enum": [
"Received",
"Expected",
"Late",
"Claim delayed",
"Claim sent",
"Unreceivable"
],
"default": "Expected"
},
"supplement": {
"description": "Whether or not this is supplementary material",
"type": "boolean"
},
"isBound": {
"description": "Whether or not piece has already been bound",
"type": "boolean",
"default": false
},
"receiptDate": {
"description": "Date that associated item is expected to arrive",
"type": "string",
"format": "date-time"
},
"receivedDate": {
"description": "The date associated item is actually received",
"type": "string",
"format": "date-time"
},
"statusUpdatedDate": {
"description": "Date when the status of this piece was last updated",
"type": "string",
"format": "date-time"
},
"claimingInterval": {
"description": "Time interval (in days) for processing claims related to this piece",
"type": "integer"
},
"internalNote": {
"description": "Internal note for Send Claim action",
"type": "string"
},
"externalNote": {
"description": "External note for Send Claim action to share with Vendor",
"type": "string"
},
"metadata": {
"type": "object",
"readonly": true,
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "metadata.schema",
"title": "Metadata Schema",
"description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
"properties": {
"createdDate": {
"description": "Date and time when the record was created",
"type": "string",
"format": "date-time"
},
"createdByUserId": {
"description": "ID of the user who created the record (when available)",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
},
"createdByUsername": {
"description": "Username of the user who created the record (when available)",
"type": "string"
},
"updatedDate": {
"description": "Date and time when the record was last updated",
"type": "string",
"format": "date-time"
},
"updatedByUserId": {
"description": "ID of the user who last updated the record (when available)",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
},
"updatedByUsername": {
"description": "Username of the user who last updated the record (when available)",
"type": "string"
}
},
"additionalProperties": false,
"required": [
"createdDate"
]
}
},
"additionalProperties": false,
"required": [
"format",
"poLineId",
"titleId",
"receivingStatus"
]
}
},
"totalRecords": {
"description": "The number of objects contained in this collection",
"type": "integer"
}
},
"additionalProperties": false
}
Example:
{
"pieces":
[
{
"id": "5e317dc2-deeb-4429-b2a1-91e5cd0fd5f7",
"displaySummary": "Tutorial Volume 1",
"comment": "Special Edition",
"format": "Electronic",
"itemId": "522a501a-56b5-48d9-b28a-3a8f02482d97",
"bindItemId": "779b89f7-6c0f-42d0-bf50-4b0e30958d2d",
"locationId": "53cf956f-c1df-410b-8bea-27f712cca7c0",
"poLineId": "d471d766-8dbb-4609-999a-02681dea6c22",
"titleId": "9a665b22-9fe5-4c95-b4ee-837a5433c95d",
"receivingTenantId": "diku",
"displayOnHolding": false,
"displayToPublic": false,
"enumeration": "Volume 1",
"chronology": "2021",
"barcode": "0987654111",
"accessionNumber": "2015.1",
"callNumber": "BF2050 .M335 2000",
"discoverySuppress": false,
"copyNumber": "175143",
"receiptDate": "2020-01-10T00:00:00.000Z",
"receivingStatus": "Unreceivable",
"claimingInterval": 0,
"internalNote": "Internal note for Send Claim action",
"externalNote": "External note for Send Claim action to share with Vendor",
"statusUpdatedDate": "2020-01-10T00:00:00.000Z",
"supplement": true,
"isBound": true
},
{
"id": "9ff85e44-a7e2-44b8-86e4-1ab8e9862f22",
"displaySummary": "Tutorial Volume 2",
"comment": "Limited edition",
"format": "Physical",
"itemId": "fefa55b1-a4b3-4f2f-b7a0-39efd7cab54c",
"bindItemId": "e394eb61-ad3e-4b64-aaae-5205fe18382f",
"locationId": "26241f60-5b96-4c10-9873-dcf4343691db",
"poLineId": "3622bc51-d579-48e4-a1c7-1bcdea42be97",
"titleId": "9a665b22-9fe5-4c95-b4ee-837a5433c95d",
"receivingTenantId": "diku",
"displayOnHolding": false,
"displayToPublic": false,
"enumeration": "Volume 2",
"chronology": "2021",
"barcode": "0987654222",
"accessionNumber": "2015.2",
"callNumber": "BF2050 .M335 2001",
"discoverySuppress": false,
"copyNumber": "186323",
"receiptDate": "2018-10-11T00:00:00.000Z",
"receivingStatus": "Received",
"supplement": true,
"isBound": true,
"receivedDate": "2018-10-10T00:00:00.000Z",
"claimingInterval": 0,
"statusUpdatedDate": "2018-10-10T00:00:00.000Z"
},
{
"id": "fabc8ce7-e168-43e6-a079-b214231b8001",
"displaySummary": "Tutorial Volume 3",
"comment": "Deluxe Edition",
"format": "Other",
"poLineId": "d471d766-8dbb-4609-999a-02681dea6c22",
"titleId": "9a665b22-9fe5-4c95-b4ee-837a5433c95d",
"holdingId": "df798357-0bda-4ad4-b0a3-86f5edec3703",
"receivingTenantId": "diku",
"displayOnHolding": true,
"displayToPublic": false,
"enumeration": "Volume 3",
"chronology": "2022",
"barcode": "0987654333",
"accessionNumber": "2015.3",
"callNumber": "BF2050 .M335 2002",
"discoverySuppress": true,
"copyNumber": "108572",
"receivingStatus": "Late",
"supplement": true,
"isBound": false,
"receiptDate": "2018-10-11T00:00:00.000Z",
"receivedDate": "2018-10-10T00:00:00.000Z",
"claimingInterval": 0,
"statusUpdatedDate": "2018-10-11T00:00:00.000Z"
}
],
"totalRecords": 3
}
HTTP status code 400
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
unable to list pieces -- malformed parameter 'query', syntax error at column 6
HTTP status code 401
Not authorized to perform requested action
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
unable to list pieces -- unauthorized
HTTP status code 422
Validation errors
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "errors.schema",
"description": "A set of errors",
"type": "object",
"properties": {
"errors": {
"description": "List of errors",
"id": "errors",
"type": "array",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "error.schema",
"description": "An error",
"properties": {
"message": {
"type": "string",
"description": "Error message text"
},
"type": {
"type": "string",
"description": "Error message type"
},
"code": {
"type": "string",
"description": "Error message code"
},
"parameters": {
"description": "Error message parameters",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "parameters.schema",
"type": "array",
"items": {
"type": "object",
"properties": {
"key": {
"type": "string"
},
"value": {
"type": "string"
}
}
}
}
},
"required": [
"message"
]
}
},
"total_records": {
"description": "Total number of errors",
"type": "integer"
}
}
}
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
internal server error, contact administrator
post /orders/pieces
Create piece record
Query Parameters
- createItem: (boolean - default: false)
Should item will be created for piece
Example:
true
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Piece details",
"type": "object",
"javaName": "Piece",
"properties": {
"id": {
"description": "UUID of this piece record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"displaySummary": {
"description": "Display summary information",
"type": "string"
},
"comment": {
"description": "Free form commentary",
"type": "string"
},
"format": {
"description": "The format of the piece",
"type": "string",
"$schema": "http://json-schema.org/draft-04/schema#",
"enum": [
"Physical",
"Electronic",
"Other"
]
},
"itemId": {
"description": "UUID of the associated item record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"bindItemId": {
"description": "UUID of the associated bind item record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"bindItemTenantId": {
"description": "Bind item tenant for ECS-enabled clusters",
"type": "string"
},
"locationId": {
"description": "UUID of the (inventory) location record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"poLineId": {
"description": "UUID of the purchase order line this record is associated with",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"titleId": {
"description": "UUID of the title record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"holdingId": {
"description": "UUID of the holding record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"receivingTenantId": {
"description": "Receiving tenant for ECS-enabled clusters",
"type": "string"
},
"displayOnHolding": {
"description": "Whether or not receiving history should be displayed in holding record view",
"type": "boolean",
"default": false
},
"displayToPublic": {
"description": "Whether or not the piece data should display to patrons at point of receipt",
"type": "boolean",
"default": false
},
"enumeration": {
"type": "string",
"description": "Enumeration is the descriptive information for the numbering scheme of a serial. Synchronized with inventory item."
},
"chronology": {
"type": "string",
"description": "Chronology is the descriptive information for the dating scheme of a serial. Synchronized with inventory item."
},
"barcode": {
"type": "string",
"description": "Barcode is the descriptive information for the barcode of a serial. Synchronized with inventory item."
},
"accessionNumber": {
"type": "string",
"description": "AccessionNumber is the descriptive information for the accession number of a serial. Synchronized with inventory item."
},
"callNumber": {
"type": "string",
"description": "CallNumber is the descriptive information for the call number of a serial. Synchronized with inventory item."
},
"discoverySuppress": {
"type": "boolean",
"description": "Records the fact that the record should not be displayed in a discovery system"
},
"copyNumber": {
"type": "string",
"description": "Copy number of the piece"
},
"receivingStatus": {
"description": "The status of this piece",
"$schema": "http://json-schema.org/draft-04/schema#",
"javaName": "ReceivingStatus",
"type": "string",
"enum": [
"Received",
"Expected",
"Late",
"Claim delayed",
"Claim sent",
"Unreceivable"
],
"default": "Expected"
},
"supplement": {
"description": "Whether or not this is supplementary material",
"type": "boolean"
},
"isBound": {
"description": "Whether or not piece has already been bound",
"type": "boolean",
"default": false
},
"receiptDate": {
"description": "Date that associated item is expected to arrive",
"type": "string",
"format": "date-time"
},
"receivedDate": {
"description": "The date associated item is actually received",
"type": "string",
"format": "date-time"
},
"statusUpdatedDate": {
"description": "Date when the status of this piece was last updated",
"type": "string",
"format": "date-time"
},
"claimingInterval": {
"description": "Time interval (in days) for processing claims related to this piece",
"type": "integer"
},
"internalNote": {
"description": "Internal note for Send Claim action",
"type": "string"
},
"externalNote": {
"description": "External note for Send Claim action to share with Vendor",
"type": "string"
},
"metadata": {
"type": "object",
"readonly": true,
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "metadata.schema",
"title": "Metadata Schema",
"description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
"properties": {
"createdDate": {
"description": "Date and time when the record was created",
"type": "string",
"format": "date-time"
},
"createdByUserId": {
"description": "ID of the user who created the record (when available)",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
},
"createdByUsername": {
"description": "Username of the user who created the record (when available)",
"type": "string"
},
"updatedDate": {
"description": "Date and time when the record was last updated",
"type": "string",
"format": "date-time"
},
"updatedByUserId": {
"description": "ID of the user who last updated the record (when available)",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
},
"updatedByUsername": {
"description": "Username of the user who last updated the record (when available)",
"type": "string"
}
},
"additionalProperties": false,
"required": [
"createdDate"
]
}
},
"additionalProperties": false,
"required": [
"format",
"poLineId",
"titleId",
"receivingStatus"
]
}
Example:
{
"id": "5e317dc2-deeb-4429-b2a1-91e5cd0fd5f7",
"displaySummary": "Tutorial Volume 5",
"comment": "Special Edition",
"format": "Electronic",
"itemId": "522a501a-56b5-48d9-b28a-3a8f02482d97",
"bindItemId": "779b89f7-6c0f-42d0-bf50-4b0e30958d2d",
"locationId": "53cf956f-c1df-410b-8bea-27f712cca7c0",
"poLineId": "d471d766-8dbb-4609-999a-02681dea6c22",
"titleId": "9a665b22-9fe5-4c95-b4ee-837a5433c95d",
"receivingTenantId": "diku",
"displayOnHolding": false,
"displayToPublic": false,
"enumeration": "Volume 1",
"chronology": "2021",
"barcode": "0987654111",
"accessionNumber": "2015.1",
"callNumber": "BF2050 .M335 1999",
"discoverySuppress": false,
"copyNumber": "94753",
"receivingStatus": "Expected",
"supplement": true,
"isBound": true,
"receiptDate": "2018-10-11T00:00:00.000Z",
"claimingInterval": 0,
"internalNote": "Internal note for Send Claim action",
"externalNote": "External note for Send Claim action to share with Vendor",
"statusUpdatedDate": "2018-10-11T00:00:00.000Z",
"metadata": {
"createdDate": "2018-08-19T00:00:00.000+0000",
"createdByUserId": "28d1057c-d137-11e8-a8d5-f2801f1b9fd1"
}
}
HTTP status code 201
Returns a newly created item, with server-controlled fields like 'id' populated
Headers
- Location: required(string)
URI to the created piece item
Body
Media type: application/json
Type: any
Example:
{
"id": "5e317dc2-deeb-4429-b2a1-91e5cd0fd5f7",
"displaySummary": "Tutorial Volume 5",
"comment": "Special Edition",
"format": "Electronic",
"itemId": "522a501a-56b5-48d9-b28a-3a8f02482d97",
"bindItemId": "779b89f7-6c0f-42d0-bf50-4b0e30958d2d",
"locationId": "53cf956f-c1df-410b-8bea-27f712cca7c0",
"poLineId": "d471d766-8dbb-4609-999a-02681dea6c22",
"titleId": "9a665b22-9fe5-4c95-b4ee-837a5433c95d",
"receivingTenantId": "diku",
"displayOnHolding": false,
"displayToPublic": false,
"enumeration": "Volume 1",
"chronology": "2021",
"barcode": "0987654111",
"accessionNumber": "2015.1",
"callNumber": "BF2050 .M335 1999",
"discoverySuppress": false,
"copyNumber": "94753",
"receivingStatus": "Expected",
"supplement": true,
"isBound": true,
"receiptDate": "2018-10-11T00:00:00.000Z",
"claimingInterval": 0,
"internalNote": "Internal note for Send Claim action",
"externalNote": "External note for Send Claim action to share with Vendor",
"statusUpdatedDate": "2018-10-11T00:00:00.000Z",
"metadata": {
"createdDate": "2018-08-19T00:00:00.000+0000",
"createdByUserId": "28d1057c-d137-11e8-a8d5-f2801f1b9fd1"
}
}
HTTP status code 400
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
"unable to add piece -- malformed JSON at 13:3"
HTTP status code 401
Not authorized to perform requested action
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
unable to create pieces -- unauthorized
HTTP status code 422
Validation errors
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "errors.schema",
"description": "A set of errors",
"type": "object",
"properties": {
"errors": {
"description": "List of errors",
"id": "errors",
"type": "array",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "error.schema",
"description": "An error",
"properties": {
"message": {
"type": "string",
"description": "Error message text"
},
"type": {
"type": "string",
"description": "Error message type"
},
"code": {
"type": "string",
"description": "Error message code"
},
"parameters": {
"description": "Error message parameters",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "parameters.schema",
"type": "array",
"items": {
"type": "object",
"properties": {
"key": {
"type": "string"
},
"value": {
"type": "string"
}
}
}
}
},
"required": [
"message"
]
}
},
"total_records": {
"description": "Total number of errors",
"type": "integer"
}
}
}
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
Internal server error, contact administrator
Entity representing a piece
Return a piece record with given {id}
Update a piece record with given {id}
Delete a piece with given {id}
get /orders/pieces/{id}
Return a piece record with given {id}
URI Parameters
- id: required(string - pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$)
The UUID of a piece record
HTTP status code 200
Returns item with a given ID
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Piece details",
"type": "object",
"javaName": "Piece",
"properties": {
"id": {
"description": "UUID of this piece record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"displaySummary": {
"description": "Display summary information",
"type": "string"
},
"comment": {
"description": "Free form commentary",
"type": "string"
},
"format": {
"description": "The format of the piece",
"type": "string",
"$schema": "http://json-schema.org/draft-04/schema#",
"enum": [
"Physical",
"Electronic",
"Other"
]
},
"itemId": {
"description": "UUID of the associated item record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"bindItemId": {
"description": "UUID of the associated bind item record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"bindItemTenantId": {
"description": "Bind item tenant for ECS-enabled clusters",
"type": "string"
},
"locationId": {
"description": "UUID of the (inventory) location record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"poLineId": {
"description": "UUID of the purchase order line this record is associated with",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"titleId": {
"description": "UUID of the title record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"holdingId": {
"description": "UUID of the holding record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"receivingTenantId": {
"description": "Receiving tenant for ECS-enabled clusters",
"type": "string"
},
"displayOnHolding": {
"description": "Whether or not receiving history should be displayed in holding record view",
"type": "boolean",
"default": false
},
"displayToPublic": {
"description": "Whether or not the piece data should display to patrons at point of receipt",
"type": "boolean",
"default": false
},
"enumeration": {
"type": "string",
"description": "Enumeration is the descriptive information for the numbering scheme of a serial. Synchronized with inventory item."
},
"chronology": {
"type": "string",
"description": "Chronology is the descriptive information for the dating scheme of a serial. Synchronized with inventory item."
},
"barcode": {
"type": "string",
"description": "Barcode is the descriptive information for the barcode of a serial. Synchronized with inventory item."
},
"accessionNumber": {
"type": "string",
"description": "AccessionNumber is the descriptive information for the accession number of a serial. Synchronized with inventory item."
},
"callNumber": {
"type": "string",
"description": "CallNumber is the descriptive information for the call number of a serial. Synchronized with inventory item."
},
"discoverySuppress": {
"type": "boolean",
"description": "Records the fact that the record should not be displayed in a discovery system"
},
"copyNumber": {
"type": "string",
"description": "Copy number of the piece"
},
"receivingStatus": {
"description": "The status of this piece",
"$schema": "http://json-schema.org/draft-04/schema#",
"javaName": "ReceivingStatus",
"type": "string",
"enum": [
"Received",
"Expected",
"Late",
"Claim delayed",
"Claim sent",
"Unreceivable"
],
"default": "Expected"
},
"supplement": {
"description": "Whether or not this is supplementary material",
"type": "boolean"
},
"isBound": {
"description": "Whether or not piece has already been bound",
"type": "boolean",
"default": false
},
"receiptDate": {
"description": "Date that associated item is expected to arrive",
"type": "string",
"format": "date-time"
},
"receivedDate": {
"description": "The date associated item is actually received",
"type": "string",
"format": "date-time"
},
"statusUpdatedDate": {
"description": "Date when the status of this piece was last updated",
"type": "string",
"format": "date-time"
},
"claimingInterval": {
"description": "Time interval (in days) for processing claims related to this piece",
"type": "integer"
},
"internalNote": {
"description": "Internal note for Send Claim action",
"type": "string"
},
"externalNote": {
"description": "External note for Send Claim action to share with Vendor",
"type": "string"
},
"metadata": {
"type": "object",
"readonly": true,
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "metadata.schema",
"title": "Metadata Schema",
"description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
"properties": {
"createdDate": {
"description": "Date and time when the record was created",
"type": "string",
"format": "date-time"
},
"createdByUserId": {
"description": "ID of the user who created the record (when available)",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
},
"createdByUsername": {
"description": "Username of the user who created the record (when available)",
"type": "string"
},
"updatedDate": {
"description": "Date and time when the record was last updated",
"type": "string",
"format": "date-time"
},
"updatedByUserId": {
"description": "ID of the user who last updated the record (when available)",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
},
"updatedByUsername": {
"description": "Username of the user who last updated the record (when available)",
"type": "string"
}
},
"additionalProperties": false,
"required": [
"createdDate"
]
}
},
"additionalProperties": false,
"required": [
"format",
"poLineId",
"titleId",
"receivingStatus"
]
}
Example:
{
"id": "5e317dc2-deeb-4429-b2a1-91e5cd0fd5f7",
"displaySummary": "Tutorial Volume 5",
"comment": "Special Edition",
"format": "Electronic",
"itemId": "522a501a-56b5-48d9-b28a-3a8f02482d97",
"bindItemId": "779b89f7-6c0f-42d0-bf50-4b0e30958d2d",
"locationId": "53cf956f-c1df-410b-8bea-27f712cca7c0",
"poLineId": "d471d766-8dbb-4609-999a-02681dea6c22",
"titleId": "9a665b22-9fe5-4c95-b4ee-837a5433c95d",
"receivingTenantId": "diku",
"displayOnHolding": false,
"displayToPublic": false,
"enumeration": "Volume 1",
"chronology": "2021",
"barcode": "0987654111",
"accessionNumber": "2015.1",
"callNumber": "BF2050 .M335 1999",
"discoverySuppress": false,
"copyNumber": "94753",
"receivingStatus": "Expected",
"supplement": true,
"isBound": true,
"receiptDate": "2018-10-11T00:00:00.000Z",
"claimingInterval": 0,
"internalNote": "Internal note for Send Claim action",
"externalNote": "External note for Send Claim action to share with Vendor",
"statusUpdatedDate": "2018-10-11T00:00:00.000Z",
"metadata": {
"createdDate": "2018-08-19T00:00:00.000+0000",
"createdByUserId": "28d1057c-d137-11e8-a8d5-f2801f1b9fd1"
}
}
HTTP status code 404
Item with a given ID not found
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
"piece not found"
HTTP status code 422
Validation errors
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "errors.schema",
"description": "A set of errors",
"type": "object",
"properties": {
"errors": {
"description": "List of errors",
"id": "errors",
"type": "array",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "error.schema",
"description": "An error",
"properties": {
"message": {
"type": "string",
"description": "Error message text"
},
"type": {
"type": "string",
"description": "Error message type"
},
"code": {
"type": "string",
"description": "Error message code"
},
"parameters": {
"description": "Error message parameters",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "parameters.schema",
"type": "array",
"items": {
"type": "object",
"properties": {
"key": {
"type": "string"
},
"value": {
"type": "string"
}
}
}
}
},
"required": [
"message"
]
}
},
"total_records": {
"description": "Total number of errors",
"type": "integer"
}
}
}
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
internal server error, contact administrator
put /orders/pieces/{id}
Update a piece record with given {id}
URI Parameters
- id: required(string - pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$)
The UUID of a piece record
Query Parameters
- createItem: (boolean - default: false)
Should item will be created for piece
Example:
true
- deleteHolding: (boolean - default: false)
The associated holding should be removed
Example:
true
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Piece details",
"type": "object",
"javaName": "Piece",
"properties": {
"id": {
"description": "UUID of this piece record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"displaySummary": {
"description": "Display summary information",
"type": "string"
},
"comment": {
"description": "Free form commentary",
"type": "string"
},
"format": {
"description": "The format of the piece",
"type": "string",
"$schema": "http://json-schema.org/draft-04/schema#",
"enum": [
"Physical",
"Electronic",
"Other"
]
},
"itemId": {
"description": "UUID of the associated item record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"bindItemId": {
"description": "UUID of the associated bind item record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"bindItemTenantId": {
"description": "Bind item tenant for ECS-enabled clusters",
"type": "string"
},
"locationId": {
"description": "UUID of the (inventory) location record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"poLineId": {
"description": "UUID of the purchase order line this record is associated with",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"titleId": {
"description": "UUID of the title record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"holdingId": {
"description": "UUID of the holding record",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"receivingTenantId": {
"description": "Receiving tenant for ECS-enabled clusters",
"type": "string"
},
"displayOnHolding": {
"description": "Whether or not receiving history should be displayed in holding record view",
"type": "boolean",
"default": false
},
"displayToPublic": {
"description": "Whether or not the piece data should display to patrons at point of receipt",
"type": "boolean",
"default": false
},
"enumeration": {
"type": "string",
"description": "Enumeration is the descriptive information for the numbering scheme of a serial. Synchronized with inventory item."
},
"chronology": {
"type": "string",
"description": "Chronology is the descriptive information for the dating scheme of a serial. Synchronized with inventory item."
},
"barcode": {
"type": "string",
"description": "Barcode is the descriptive information for the barcode of a serial. Synchronized with inventory item."
},
"accessionNumber": {
"type": "string",
"description": "AccessionNumber is the descriptive information for the accession number of a serial. Synchronized with inventory item."
},
"callNumber": {
"type": "string",
"description": "CallNumber is the descriptive information for the call number of a serial. Synchronized with inventory item."
},
"discoverySuppress": {
"type": "boolean",
"description": "Records the fact that the record should not be displayed in a discovery system"
},
"copyNumber": {
"type": "string",
"description": "Copy number of the piece"
},
"receivingStatus": {
"description": "The status of this piece",
"$schema": "http://json-schema.org/draft-04/schema#",
"javaName": "ReceivingStatus",
"type": "string",
"enum": [
"Received",
"Expected",
"Late",
"Claim delayed",
"Claim sent",
"Unreceivable"
],
"default": "Expected"
},
"supplement": {
"description": "Whether or not this is supplementary material",
"type": "boolean"
},
"isBound": {
"description": "Whether or not piece has already been bound",
"type": "boolean",
"default": false
},
"receiptDate": {
"description": "Date that associated item is expected to arrive",
"type": "string",
"format": "date-time"
},
"receivedDate": {
"description": "The date associated item is actually received",
"type": "string",
"format": "date-time"
},
"statusUpdatedDate": {
"description": "Date when the status of this piece was last updated",
"type": "string",
"format": "date-time"
},
"claimingInterval": {
"description": "Time interval (in days) for processing claims related to this piece",
"type": "integer"
},
"internalNote": {
"description": "Internal note for Send Claim action",
"type": "string"
},
"externalNote": {
"description": "External note for Send Claim action to share with Vendor",
"type": "string"
},
"metadata": {
"type": "object",
"readonly": true,
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "metadata.schema",
"title": "Metadata Schema",
"description": "Metadata about creation and changes to records, provided by the server (client should not provide)",
"properties": {
"createdDate": {
"description": "Date and time when the record was created",
"type": "string",
"format": "date-time"
},
"createdByUserId": {
"description": "ID of the user who created the record (when available)",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
},
"createdByUsername": {
"description": "Username of the user who created the record (when available)",
"type": "string"
},
"updatedDate": {
"description": "Date and time when the record was last updated",
"type": "string",
"format": "date-time"
},
"updatedByUserId": {
"description": "ID of the user who last updated the record (when available)",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
},
"updatedByUsername": {
"description": "Username of the user who last updated the record (when available)",
"type": "string"
}
},
"additionalProperties": false,
"required": [
"createdDate"
]
}
},
"additionalProperties": false,
"required": [
"format",
"poLineId",
"titleId",
"receivingStatus"
]
}
Example:
{
"id": "5e317dc2-deeb-4429-b2a1-91e5cd0fd5f7",
"displaySummary": "Tutorial Volume 5",
"comment": "Special Edition",
"format": "Electronic",
"itemId": "522a501a-56b5-48d9-b28a-3a8f02482d97",
"bindItemId": "779b89f7-6c0f-42d0-bf50-4b0e30958d2d",
"locationId": "53cf956f-c1df-410b-8bea-27f712cca7c0",
"poLineId": "d471d766-8dbb-4609-999a-02681dea6c22",
"titleId": "9a665b22-9fe5-4c95-b4ee-837a5433c95d",
"receivingTenantId": "diku",
"displayOnHolding": false,
"displayToPublic": false,
"enumeration": "Volume 1",
"chronology": "2021",
"barcode": "0987654111",
"accessionNumber": "2015.1",
"callNumber": "BF2050 .M335 1999",
"discoverySuppress": false,
"copyNumber": "94753",
"receivingStatus": "Expected",
"supplement": true,
"isBound": true,
"receiptDate": "2018-10-11T00:00:00.000Z",
"claimingInterval": 0,
"internalNote": "Internal note for Send Claim action",
"externalNote": "External note for Send Claim action to share with Vendor",
"statusUpdatedDate": "2018-10-11T00:00:00.000Z",
"metadata": {
"createdDate": "2018-08-19T00:00:00.000+0000",
"createdByUserId": "28d1057c-d137-11e8-a8d5-f2801f1b9fd1"
}
}
HTTP status code 204
Piece record successfully updated
HTTP status code 400
Bad request
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "Bad URL request",
"code": "pieceNotFound"
}
]
}
Media type: text/plain
Type: any
Example:
unable to create Piece -- Bad request
HTTP status code 404
Request id does not exists
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
"piece not found"
HTTP status code 422
Validation errors
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "errors.schema",
"description": "A set of errors",
"type": "object",
"properties": {
"errors": {
"description": "List of errors",
"id": "errors",
"type": "array",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "error.schema",
"description": "An error",
"properties": {
"message": {
"type": "string",
"description": "Error message text"
},
"type": {
"type": "string",
"description": "Error message type"
},
"code": {
"type": "string",
"description": "Error message code"
},
"parameters": {
"description": "Error message parameters",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "parameters.schema",
"type": "array",
"items": {
"type": "object",
"properties": {
"key": {
"type": "string"
},
"value": {
"type": "string"
}
}
}
}
},
"required": [
"message"
]
}
},
"total_records": {
"description": "Total number of errors",
"type": "integer"
}
}
}
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "Internal server error, contact administrator",
"code": "genericError"
}
]
}
Media type: text/plain
Type: any
Example:
unable to create Piece -- Internal server error, e.g. due to misconfiguration
delete /orders/pieces/{id}
Delete a piece with given {id}
URI Parameters
- id: required(string - pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$)
The UUID of a piece record
Query Parameters
- deleteHolding: (boolean - default: false)
The associated holding should be removed
Example:
true
HTTP status code 204
Piece record successfully deleted
HTTP status code 400
Bad request
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "Bad URL request",
"code": "pieceNotFound"
}
]
}
Media type: text/plain
Type: any
Example:
unable to delete Piece -- Bad request
HTTP status code 404
Request id does not exists
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Media type: text/plain
Type: any
Example:
"piece not found"
HTTP status code 422
Validation errors
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "errors.schema",
"description": "A set of errors",
"type": "object",
"properties": {
"errors": {
"description": "List of errors",
"id": "errors",
"type": "array",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "error.schema",
"description": "An error",
"properties": {
"message": {
"type": "string",
"description": "Error message text"
},
"type": {
"type": "string",
"description": "Error message type"
},
"code": {
"type": "string",
"description": "Error message code"
},
"parameters": {
"description": "Error message parameters",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "parameters.schema",
"type": "array",
"items": {
"type": "object",
"properties": {
"key": {
"type": "string"
},
"value": {
"type": "string"
}
}
}
}
},
"required": [
"message"
]
}
},
"total_records": {
"description": "Total number of errors",
"type": "integer"
}
}
}
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: application/json
Type: any
Example:
{
"errors": [
{
"message": "Internal server error, contact administrator",
"code": "genericError"
}
]
}
Media type: text/plain
Type: any
Example:
unable to delete Piece -- Internal server error, e.g. due to misconfiguration