foliolib.folio.api.inventoryStorage.InstanceStorageBatch
- class foliolib.folio.api.inventoryStorage.InstanceStorageBatch(tenant: str)
Bases:
foliolib.folio.FolioApiDeprecated Inventory Storage Instance Batch API
Deprecated Batch API for managing Inventory Instances, use /instance-storage/sync instead.
Base class of the Folio API
- Parameters
tenant (str) – Tenant id
Methods
set_instance(instance)Create collection of instances in one request - deprecated, use /instance-storage/sync instead
- set_instance(instance: dict)
Create collection of instances in one request - deprecated, use /instance-storage/sync instead
POST /instance-storage/batch/instances- Parameters
instance (dict) – See Schema below
- Returns
See Schema below
- Return type
dict
- Raises
OkapiRequestFatalError – Server Error
Schema
{ "$schema": "http://json-schema.org/draft-04/schema#", "description": "A collection of instance records", "type": "object", "properties": { "instances": { "description": "List of instance records", "id": "instances", "type": "array", "items": { "type": "object", "$ref": "instance.json" } }, "totalRecords": { "description": "Estimated or exact total number of records", "type": "integer" }, "resultInfo": { "$ref": "raml-util/schemas/resultInfo.schema", "readonly": true } }, "required": [ "instances", "totalRecords" ] }
{ "$schema": "http://json-schema.org/draft-04/schema#", "description": "Response schema for instances batch request", "type": "object", "properties": { "instances": { "id": "instancesList", "description": "List of all successfully saved Instances", "type": "array", "items": { "type": "object", "$ref": "instance.json" } }, "errorMessages": { "id": "errorMessagesList", "description": "List of error messages", "type": "array", "items": { "type": "string" } }, "totalRecords": { "description": "Total number of successfully saved instances", "type": "integer" } }, "required": [ "instances", "errorMessages", "totalRecords" ] }