Inventory Update (v1.0)

http://localhost

Table of contents

Inventory update APIs

Provides various schemes for creating, updating and deleting instances, holdings records and items in Inventory storage

Create, update, delete instance with holdings and items, based on incoming HRIDs on all three record types

PUT /inventory-upsert-hrid

PUT /inventory-upsert-hrid
Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "An instance record and an array of holdings records with embedded items",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "hrid": {
          "type": "string",
          "description": "The external identifier of the instance; the client's own unique ID for the updating record"
        }
      },
      "required": [
        "hrid"
      ]
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "hrid": {
            "type": "string",
            "description": "The external identifier of the holdings record; the client's own unique ID for the updating record"
          },
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object",
              "properties": {
                "hrid": {
                  "type": "string",
                  "description": "The external identifier of the item; the client's own unique ID for the updating record"
                }
              },
              "required": [
                "hrid"
              ]
            }
          }
        },
        "required": [
          "hrid"
        ]
      }
    },
    "instanceRelations": {
      "description": "Object holding information of different types of Instance-to-Instance relationships to create",
      "properties": {
        "parentInstances": {
          "type": "array",
          "description": "Collection of objects with information required for finding and linking to parent Instances",
          "items": {
            "type": "object",
            "properties": {
              "instanceIdentifier": {
                "type": "object",
                "description": "Object with information required for finding the parent Instance to link to",
                "properties": {
                  "hrid": {
                    "type": "string",
                    "description": "A unique ID for the parent instance to link to"
                  }
                }
              },
              "provisionalInstance": {
                "type": "object",
                "description": "Object with at least the mandatory Instance properties required for creating a provisional Instance if the parent does not yet exist. Other valid Instance properties allowed.",
                "properties": {
                  "title": {
                    "type": "string",
                    "description": "The parent record’s title"
                  },
                  "source": {
                    "type": "string",
                    "description": "The parent record’s source"
                  },
                  "instanceTypeId": {
                    "type": "string",
                    "description": "The parent record’s resource type ID (UUID) "
                  }
                },
                "required": [
                  "title",
                  "source",
                  "instanceTypeId"
                ]
              },
              "instancesRelationshipTypeId": {
                "type": "string",
                "description": "UUID for the type of relationship to establish to a parent instance (article, volume, multipart, series)"
              }
            },
            "required": [
              "instanceIdentifier",
              "instanceRelationshipTypeId"
            ]
          }
        },
        "childInstances": {
          "type": "array",
          "description": "Collection of objects with information required for finding and linking to child Instances",
          "items": {
            "type": "object",
            "properties": {
              "instanceIdentifier": {
                "type": "object",
                "description": "Object with information required for finding the child Instance to link to",
                "properties": {
                  "hrid": {
                    "type": "string",
                    "description": "A unique ID for the child instance to link to"
                  }
                },
                "provisionalInstance": {
                  "type": "object",
                  "description": "Object with at least the mandatory Instance properties required for creating a provisional Instance if the child does not yet exist. Other valid Instance properties allowed.",
                  "properties": {
                    "title": {
                      "type": "string",
                      "description": "The child record’s title"
                    },
                    "source": {
                      "type": "string",
                      "description": "The child record’s source"
                    },
                    "instanceTypeId": {
                      "type": "string",
                      "description": "The child record’s resource type ID (UUID) "
                    }
                  },
                  "required": [
                    "title",
                    "source",
                    "instanceTypeId"
                  ]
                },
                "instancesRelationshipTypeId": {
                  "type": "string",
                  "description": "UUID for the type of relationship to establish to a child instance (article, volume, multipart, series)"
                }
              }
            }
          }
        },
        "precedingTitles": {
          "type": "array",
          "description": "Collection of objects with information required for finding and linking to preceding Instances",
          "items": {
            "type": "object",
            "properties": {
              "instanceIdentifier": {
                "type": "object",
                "description": "Object with information required for finding the preceding Instance to link to",
                "properties": {
                  "hrid": {
                    "type": "string",
                    "description": "A unique ID for the preceding instance to link to"
                  }
                },
                "provisionalInstance": {
                  "type": "object",
                  "description": "Object with at least the mandatory Instance properties required for creating a provisional Instance if the preceding does not yet exist. Other valid Instance properties allowed.",
                  "properties": {
                    "title": {
                      "type": "string",
                      "description": "The preceding Instance’s title"
                    },
                    "source": {
                      "type": "string",
                      "description": "The preceding Instance’s source"
                    },
                    "instanceTypeId": {
                      "type": "string",
                      "description": "The preceding Instance’s resource type ID (UUID) "
                    }
                  },
                  "required": [
                    "title",
                    "source",
                    "instanceTypeId"
                  ]
                }
              }
            }
          }
        },
        "succeedingTitles": {
          "type": "array",
          "description": "Collection of objects with information required for finding and linking to succeeding Instances",
          "items": {
            "type": "object",
            "properties": {
              "instanceIdentifier": {
                "type": "object",
                "description": "Object with information required for finding the succeeding Instance to link to",
                "properties": {
                  "hrid": {
                    "type": "string",
                    "description": "A unique ID for the succeeding instance to link to"
                  }
                },
                "provisionalInstance": {
                  "type": "object",
                  "description": "Object with at least the mandatory Instance properties required for creating a provisional Instance if the succeeding does not yet exist. Other valid Instance properties allowed.",
                  "properties": {
                    "title": {
                      "type": "string",
                      "description": "The succeeding Instance’s title"
                    },
                    "source": {
                      "type": "string",
                      "description": "The succeeding Instance’s source"
                    },
                    "instanceTypeId": {
                      "type": "string",
                      "description": "The succeeding Instance’s resource type ID (UUID) "
                    }
                  },
                  "required": [
                    "title",
                    "source",
                    "instanceTypeId"
                  ]
                }
              }
            }
          }
        }
      }
    },
    "processing": {
      "description": "Processing instructions, for example for value retention on updates.",
      "type": "object",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "item": {
          "description": "Instructions for processing Inventory Items",
          "type": "object",
          "properties": {
            "retainOmittedRecord": {
              "description": "Prevent deletion of item (even though it is omitted from input) if given item property is matched by regex",
              "type": "object",
              "properties": {
                "ifField": {
                  "description": "Name of field to match",
                  "type": "string"
                },
                "matchesPattern": {
                  "description": "Regex pattern to match field by",
                  "type": "string"
                }
              },
              "additionalProperties": false,
              "required": [
                "ifField",
                "matchesPattern"
              ]
            },
            "retainExistingValues": {
              "description": "Instructions for value retention on updates.",
              "type": "object",
              "forOmittedProperties": {
                "description": "If set to true, MIU retains existing properties if they are absent from the incoming record. If set to false (default), MIU removes absent properties from the existing record too.",
                "type": "boolean",
                "default": false
              },
              "forTheseProperties": {
                "description": "List of properties to retain existing values for, whether they are present or not in the incoming record.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "status": {
              "description": "Instructions for retaining or overwriting status when updating an item",
              "type": "object",
              "properties": {
                "policy": {
                  "description": "Update instruction for item status",
                  "type": "string",
                  "enum": [
                    "retain",
                    "overwrite"
                  ]
                },
                "ifStatusWas": {
                  "description": "List of statuses that policy applies to",
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "description": "status name",
                        "type": "string",
                        "enum": [
                          "Aged to lost",
                          "Available",
                          "Awaiting pickup",
                          "Awaiting delivery",
                          "Checked out",
                          "Claimed returned",
                          "Declared lost",
                          "In process",
                          "In process (non-requestable)",
                          "In transit",
                          "Intellectual item",
                          "Long missing",
                          "Lost and paid",
                          "Missing",
                          "On order",
                          "Paged",
                          "Restricted",
                          "Order closed",
                          "Unavailable",
                          "Unknown",
                          "Withdrawn"
                        ]
                      }
                    }
                  }
                }
              },
              "required": [
                "policy"
              ]
            },
            "statisticalCoding": {
              "description": "Configures the statistical codes to set on the item for given events",
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "if": {
                    "type": "string",
                    "description": "The event triggering a statistical coding; currently only one supported event",
                    "enum": [
                      "deleteSkipped"
                    ]
                  },
                  "becauseOf": {
                    "type": "string",
                    "description": "The cause of the event",
                    "enum": [
                      "ITEM_STATUS",
                      "ITEM_PATTERN_MATCH",
                      "HOLDINGS_RECORD_PATTERN_MATCH",
                      "PO_LINE_REFERENCE"
                    ]
                  },
                  "setCode": {
                    "type": "string",
                    "description": "The UUID of the statistical code to set on the inventory record"
                  }
                }
              }
            }
          }
        },
        "holdingsRecord": {
          "description": "Instructions for processing Inventory holdings records",
          "type": "object",
          "properties": {
            "retainExistingValues": {
              "description": "Instructions for value retention on updates.",
              "type": "object",
              "forOmittedProperties": {
                "description": "If set to true, MIU retains existing properties if they are absent from the incoming record. If set to false (default), MIU removes absent properties from the existing record too.",
                "type": "boolean",
                "default": false
              },
              "forTheseProperties": {
                "description": "List of properties to retain existing values for, whether they are present or not in the incoming record.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "statisticalCoding": {
              "description": "Configures the statistical codes to set on the holdings record for given events",
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "if": {
                    "type": "string",
                    "description": "The event triggering a statistical coding; currently only one supported event",
                    "enum": [
                      "deleteSkipped"
                    ]
                  },
                  "becauseOf": {
                    "type": "string",
                    "description": "The cause of the event",
                    "enum": [
                      "ITEM_STATUS",
                      "ITEM_PATTERN_MATCH",
                      "HOLDINGS_RECORD_PATTERN_MATCH",
                      "PO_LINE_REFERENCE"
                    ]
                  },
                  "setCode": {
                    "type": "string",
                    "description": "The UUID of the statistical code to set on the inventory record"
                  }
                }
              }
            }
          }
        },
        "instance": {
          "description": "Instructions for processing Instance records",
          "type": "object",
          "properties": {
            "retainExistingValues": {
              "description": "Instructions for value retention on updates.",
              "type": "object",
              "forOmittedProperties": {
                "description": "If set to true, MIU retains existing properties if they are absent from the incoming record. If set to false (default), MIU removes absent properties from the existing record too.",
                "type": "boolean",
                "default": false
              },
              "forTheseProperties": {
                "description": "List of properties to retain existing values for, whether they are present or not in the incoming record.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "statisticalCoding": {
              "description": "Configures the statistical codes to set on the instance for given events",
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "if": {
                    "type": "string",
                    "description": "The event triggering a statistical coding; currently only one supported event",
                    "enum": [
                      "deleteSkipped"
                    ]
                  },
                  "becauseOf": {
                    "type": "string",
                    "description": "The cause of the event",
                    "enum": [
                      "ITEM_STATUS",
                      "ITEM_PATTERN_MATCH",
                      "HOLDINGS_RECORD_PATTERN_MATCH",
                      "PO_LINE_REFERENCE"
                    ]
                  },
                  "setCode": {
                    "type": "string",
                    "description": "The UUID of the statistical code to set on the inventory record"
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "required": [
    "instance"
  ]
}

Response 200

Inventory recordset successfully created or updated by HRIDs.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a successful upsert request",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set as it was pushed to Inventory storage",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items as it was pushed to Inventory storage",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "instanceRelations": {
      "type": "object",
      "description": "Collection of the Instance's relations to other instances, like parent-child relations or title successions",
      "parentInstances": {
        "type": "array",
        "description": "The Instance's relations to parent instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "childInstances": {
        "type": "array",
        "description": "The Instance's relations to child instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "precedingTitles": {
        "type": "array",
        "description": "The Instance's relation to preceding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title (this Instance)"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "succeedingTitles": {
        "type": "array",
        "description": "The Instance's relation to succeeding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title (this Instance)"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      }
    },
    "metrics": {
      "type": "object",
      "description": "Reports the number of operations performed by record type, transaction type, and outcome",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "INSTANCE": {
          "type": "object",
          "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Instance create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance create operations."
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance create operations."
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Instance update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Instance delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance delete operations (0 or 1)"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance delete operations (0 or 1)"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "HOLDINGS_RECORD": {
          "type": "object",
          "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "ITEM": {
          "type": "object",
          "description": "Reports the number of operations performed on Items by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Item create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Item update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Item delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_RELATIONSHIP": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of relationship create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of relationship delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other Instance was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other Instance failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other Instance was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_TITLE_SUCCESSION": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of title succession create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of title succession delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other title was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other title failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other title was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        }
      }
    }
  }
}

Response 207

Partially successful update of record set. Errors listed in response.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on an upsert request that encountered one or more problems",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set as it was pushed to Inventory storage",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items as it was pushed to Inventory storage",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "metrics": {
      "type": "object",
      "description": "Report of the number of operations performed by record type, transaction type, and outcome",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "INSTANCE": {
          "type": "object",
          "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Instance create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance create operations."
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance create operations."
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Instance update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Instance delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance delete operations (0 or 1)"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance delete operations (0 or 1)"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "HOLDINGS_RECORD": {
          "type": "object",
          "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "ITEM": {
          "type": "object",
          "description": "Reports the number of operations performed on Items by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Item create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Item update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Item delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_RELATIONSHIP": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of relationship create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of relationship delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other Instance was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other Instance failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other Instance was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_TITLE_SUCCESSION": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of title succession create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of title succession delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other title was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other title failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other title was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        }
      }
    },
    "errors": {
      "type": "array",
      "description": "List of problems encountered during an Inventory update or delete request.",
      "items": {
        "type": "object",
        "description": "Description of an individual error conditions",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "properties": {
          "category": {
            "type": "string",
            "description": "Type of problem, usually error category STORAGE."
          },
          "statusCode": {
            "type": "string",
            "description": "The HTTP status code assigned to the error."
          },
          "message": {
            "description": "Error message returned by Inventory storage.",
            "anyOf": [
              {
                "type": "string",
                "description": "Error text returned by Inventory storage."
              },
              {
                "type": "object",
                "description": "JSON object of one or more structured error messages returned by Inventory storage."
              }
            ]
          },
          "shortMessage": {
            "type": "string",
            "description": "A short error message that might be used by the client to count similar error occurrences."
          },
          "entityType": {
            "type": "string",
            "description": "The record type for which a problem occurred."
          },
          "transaction": {
            "type": "string",
            "description": "Type of REST operation for which the problem occurred."
          },
          "entity": {
            "type": "object",
            "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
          },
          "details": {
            "type": "object",
            "description": "Any further details, i.e. additional context for the problem."
          }
        }
      }
    }
  }
}

Response 400

Bad request, for example: empty request body, non-JSON or invalid JSON in request body or JSON not recognized as an inventory record set

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 422

One or more validation errors found in incoming record set. No updates performed.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 500

Internal errors in the module itself or in the modules that it uses.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

DELETE /inventory-upsert-hrid

DELETE /inventory-upsert-hrid
Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Deletion record for deletion by HRID",
  "type": "object",
  "properties": {
    "hrid": {
      "type": "string",
      "description": "The legacy ID for the bibliographic record, as stored in the HRID of the Instance to be deleted."
    },
    "processing": {
      "description": "Processing instructions, for example delete protection for records.",
      "type": "object",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "item": {
          "description": "Instructions for processing Inventory Items during Instance deletion",
          "type": "object",
          "properties": {
            "blockDeletion": {
              "description": "Prevent deletion of an item, and thus the Instance, if given item property is matched by regex",
              "type": "object",
              "properties": {
                "ifField": {
                  "description": "Name of field to match",
                  "type": "string"
                },
                "matchesPattern": {
                  "description": "Regex pattern to match field by",
                  "type": "string"
                }
              },
              "additionalProperties": false,
              "required": [
                "ifField",
                "matchesPattern"
              ]
            },
            "statisticalCoding": {
              "description": "Configures the statistical codes to set on the item for given events",
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "if": {
                    "type": "string",
                    "description": "The event triggering a statistical coding; currently only one supported event",
                    "enum": [
                      "deleteSkipped"
                    ]
                  },
                  "becauseOf": {
                    "type": "string",
                    "description": "The cause of the event",
                    "enum": [
                      "ITEM_STATUS",
                      "ITEM_PATTERN_MATCH",
                      "HOLDINGS_RECORD_PATTERN_MATCH",
                      "PO_LINE_REFERENCE"
                    ]
                  },
                  "setCode": {
                    "type": "string",
                    "description": "The UUID of the statistical code to set on the inventory record"
                  }
                }
              }
            }
          }
        },
        "holdingsRecord": {
          "description": "Instructions for processing Inventory holdings records during Instance deletion",
          "type": "object",
          "properties": {
            "blockDeletion": {
              "description": "Prevent deletion of a holdings record, and thus the Instance, if given holdings record property is matched by regex",
              "type": "object",
              "properties": {
                "ifField": {
                  "description": "Name of field to match",
                  "type": "string"
                },
                "matchesPattern": {
                  "description": "Regex pattern to match field by",
                  "type": "string"
                }
              },
              "additionalProperties": false,
              "required": [
                "ifField",
                "matchesPattern"
              ]
            },
            "statisticalCoding": {
              "description": "Configures the statistical code to set on the holdings record for given events",
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "if": {
                    "type": "string",
                    "description": "The event triggering a statistical coding; currently only one supported event",
                    "enum": [
                      "deleteSkipped"
                    ]
                  },
                  "becauseOf": {
                    "type": "string",
                    "description": "The cause of the event",
                    "enum": [
                      "ITEM_STATUS",
                      "ITEM_PATTERN_MATCH",
                      "HOLDINGS_RECORD_PATTERN_MATCH",
                      "PO_LINE_REFERENCE"
                    ]
                  },
                  "setCode": {
                    "type": "string",
                    "description": "The UUID of the statistical code to set on the inventory record"
                  }
                }
              }
            }
          }
        },
        "instance": {
          "description": "Instructions for processing an Inventory Instance on Instance delete request",
          "type": "object",
          "properties": {
            "blockDeletion": {
              "description": "Prevent deletion of an Instance, if given Instance property is matched by regex",
              "type": "object",
              "properties": {
                "ifField": {
                  "description": "Name of field to match",
                  "type": "string"
                },
                "matchesPattern": {
                  "description": "Regex pattern to match field by",
                  "type": "string"
                }
              },
              "additionalProperties": false,
              "required": [
                "ifField",
                "matchesPattern"
              ]
            },
            "statisticalCoding": {
              "description": "Configures the statistical code to set on the instance for given events",
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "if": {
                    "type": "string",
                    "description": "The event triggering a statistical coding; currently only one supported event",
                    "enum": [
                      "deleteSkipped"
                    ]
                  },
                  "becauseOf": {
                    "type": "string",
                    "description": "The cause of the event",
                    "enum": [
                      "ITEM_STATUS",
                      "ITEM_PATTERN_MATCH",
                      "HOLDINGS_RECORD_PATTERN_MATCH",
                      "PO_LINE_REFERENCE"
                    ]
                  },
                  "setCode": {
                    "type": "string",
                    "description": "The UUID of the statistical code to set on the inventory record"
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "required": [
    "hrid"
  ]
}

Example:

{
  "hrid": "001"
}

Response 200

Record set was successfully found by HRID and deleted

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a successful upsert request",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set as it was pushed to Inventory storage",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items as it was pushed to Inventory storage",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "instanceRelations": {
      "type": "object",
      "description": "Collection of the Instance's relations to other instances, like parent-child relations or title successions",
      "parentInstances": {
        "type": "array",
        "description": "The Instance's relations to parent instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "childInstances": {
        "type": "array",
        "description": "The Instance's relations to child instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "precedingTitles": {
        "type": "array",
        "description": "The Instance's relation to preceding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title (this Instance)"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "succeedingTitles": {
        "type": "array",
        "description": "The Instance's relation to succeeding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title (this Instance)"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      }
    },
    "metrics": {
      "type": "object",
      "description": "Reports the number of operations performed by record type, transaction type, and outcome",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "INSTANCE": {
          "type": "object",
          "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Instance create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance create operations."
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance create operations."
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Instance update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Instance delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance delete operations (0 or 1)"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance delete operations (0 or 1)"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "HOLDINGS_RECORD": {
          "type": "object",
          "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "ITEM": {
          "type": "object",
          "description": "Reports the number of operations performed on Items by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Item create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Item update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Item delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_RELATIONSHIP": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of relationship create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of relationship delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other Instance was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other Instance failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other Instance was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_TITLE_SUCCESSION": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of title succession create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of title succession delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other title was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other title failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other title was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        }
      }
    }
  }
}

Response 400

Bad request, for example: non-JSON in request body; inventory record set without an Instance

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 404

Did not find existing Instance (record set) to delete for provided HRID

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 422

One or more validation errors encountered. No deletion performed.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 500

Internal error in the module or in storage during delete by HRID

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Create or update a batch of instances with holdings and items, based on incoming HRIDs on all three record types

PUT /inventory-batch-upsert-hrid

PUT /inventory-batch-upsert-hrid
Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "A collection of inventory records sets (instances, holdings and items, etc)",
  "type": "object",
  "properties": {
    "inventoryRecordSets": {
      "description": "List of inventory record sets",
      "id": "inventoryRecordSets",
      "type": "array",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "An instance record and an array of holdings records with embedded items",
        "properties": {
          "instance": {
            "type": "object",
            "description": "The Instance, the bibliographic part, of this Inventory record set",
            "$schema": "http://json-schema.org/draft-04/schema#"
          },
          "holdingsRecords": {
            "type": "array",
            "description": "Collection of holdings of the Instance, each holdings record with embedded items",
            "items": {
              "type": "object",
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
              "properties": {
                "items": {
                  "description": "Inventory items for this holdings record",
                  "type": "array",
                  "items": {
                    "$schema": "http://json-schema.org/draft-04/schema#",
                    "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
                    "type": "object"
                  }
                }
              }
            }
          },
          "processing": {
            "type": "object",
            "description": "An object holding supporting pieces of data and/or processing instructions for Inventory update processing",
            "properties": {
              "institutionId": {
                "type": "string",
                "description": "The FOLIO UUID of the institution that provided the source records for the update; necessary for certain clean-up tasks in a shared inventory",
                "$schema": "http://json-schema.org/draft-04/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}$"
              },
              "localIdentifier": {
                "type": "string",
                "description": "The source system's unique identifier for the source record of this update request; necessary for certain clean-up tasks in a shared inventory"
              },
              "identifierTypeId": {
                "type": "string",
                "description": "The FOLIO UUID for the identifier type for the local record IDs coming from the given library",
                "$schema": "http://json-schema.org/draft-04/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}$"
              }
            }
          }
        }
      }
    }
  },
  "required": [
    "inventoryRecordSets"
  ]
}

Response 200

Batch of Inventory record sets successfully created or updated by HRIDs.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "description": "Reports the number of operations performed by record type, transaction type, and outcome",
  "properties": {
    "INSTANCE": {
      "type": "object",
      "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of Instance create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Instance create operations."
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Instance create operations."
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Instance create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "UPDATED": {
          "type": "object",
          "description": "Reports the number of Instance update operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Instance update operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Instance update operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Instance update operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of Instance delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Instance delete operations (0 or 1)"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Instance delete operations (0 or 1)"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Instance delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    },
    "HOLDINGS_RECORD": {
      "type": "object",
      "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of HoldingsRecord create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed HoldingsRecord create operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed HoldingsRecord create operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of HoldingsRecord create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "UPDATED": {
          "type": "object",
          "description": "Reports the number of HoldingsRecord update operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed HoldingsRecord update operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed HoldingsRecord update operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of HoldingsRecord update operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of HoldingsRecord delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed HoldingsRecord delete operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed HoldingsRecord delete operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of HoldingsRecord delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    },
    "ITEM": {
      "type": "object",
      "description": "Reports the number of operations performed on Items by transaction type and outcome",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of Item create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Item create operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Item create operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Item create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "UPDATED": {
          "type": "object",
          "description": "Reports the number of Item update operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Item update operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Item update operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Item update operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of Item delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Item delete operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Item delete operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Item delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    },
    "INSTANCE_RELATIONSHIP": {
      "type": "object",
      "description": "Reports the number of operations performed for the Instance's parent-child relationships",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of relationship create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed relationship create operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed relationship create operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of relationship create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of relationship delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed relationship delete operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed relationship delete operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of relationship delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "PROVISIONAL_INSTANCE": {
          "type": "object",
          "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "1 if the other Instance was successfully created"
            },
            "FAILED": {
              "type": "integer",
              "description": "1 if the creation of the other Instance failed"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "1 if creation of the other Instance was skipped (should always be 0)"
            },
            "PENDING": {
              "type": "integer",
              "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    },
    "INSTANCE_TITLE_SUCCESSION": {
      "type": "object",
      "description": "Reports the number of operations performed for the Instance's parent-child relationships",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of title succession create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed title succession create operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed title succession create operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of title succession create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of title succession delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed title succession delete operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed title succession delete operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of title succession delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "PROVISIONAL_INSTANCE": {
          "type": "object",
          "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "1 if the other title was successfully created"
            },
            "FAILED": {
              "type": "integer",
              "description": "1 if the creation of the other title failed"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "1 if creation of the other title was skipped (should always be 0)"
            },
            "PENDING": {
              "type": "integer",
              "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    }
  }
}

Response 207

Partially successful update of record set. Errors enumerated in response.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a partly successful batch upsert request",
  "type": "object",
  "properties": {
    "metrics": {
      "type": "object",
      "description": "Report of the number of operations performed by record type, transaction type, and outcome",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "INSTANCE": {
          "type": "object",
          "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Instance create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance create operations."
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance create operations."
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Instance update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Instance delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance delete operations (0 or 1)"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance delete operations (0 or 1)"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "HOLDINGS_RECORD": {
          "type": "object",
          "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "ITEM": {
          "type": "object",
          "description": "Reports the number of operations performed on Items by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Item create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Item update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Item delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_RELATIONSHIP": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of relationship create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of relationship delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other Instance was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other Instance failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other Instance was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_TITLE_SUCCESSION": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of title succession create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of title succession delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other title was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other title failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other title was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        }
      }
    },
    "errors": {
      "type": "array",
      "description": "List of problems encountered during an Inventory update or delete request.",
      "items": {
        "type": "object",
        "description": "Description of an individual error conditions",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "properties": {
          "category": {
            "type": "string",
            "description": "Type of problem, usually error category STORAGE."
          },
          "statusCode": {
            "type": "string",
            "description": "The HTTP status code assigned to the error."
          },
          "message": {
            "description": "Error message returned by Inventory storage.",
            "anyOf": [
              {
                "type": "string",
                "description": "Error text returned by Inventory storage."
              },
              {
                "type": "object",
                "description": "JSON object of one or more structured error messages returned by Inventory storage."
              }
            ]
          },
          "shortMessage": {
            "type": "string",
            "description": "A short error message that might be used by the client to count similar error occurrences."
          },
          "entityType": {
            "type": "string",
            "description": "The record type for which a problem occurred."
          },
          "transaction": {
            "type": "string",
            "description": "Type of REST operation for which the problem occurred."
          },
          "entity": {
            "type": "object",
            "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
          },
          "details": {
            "type": "object",
            "description": "Any further details, i.e. additional context for the problem."
          }
        }
      }
    }
  }
}

Example:

{
  "metrics" : {
    "INSTANCE" : {
      "CREATE" : {
        "COMPLETED" : 0,
        "FAILED" : 2,
        "SKIPPED" : 0,
        "PENDING" : 0
      },
      "UPDATE" : {
        "COMPLETED" : 2,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      },
      "DELETE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      }
    },
    "HOLDINGS_RECORD" : {
      "CREATE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 2,
        "PENDING" : 0
      },
      "UPDATE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      },
      "DELETE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      }
    },
    "ITEM" : {
      "CREATE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      },
      "UPDATE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      },
      "DELETE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      }
    },
    "INSTANCE_RELATIONSHIP" : {
      "CREATE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      },
      "DELETE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      }
    },
    "INSTANCE_TITLE_SUCCESSION" : {
      "CREATE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      },
      "DELETE" : {
        "COMPLETED" : 0,
        "FAILED" : 0,
        "SKIPPED" : 0,
        "PENDING" : 0
      }
    }
  },
  "errors" : [ {
    "category" : "STORAGE",
    "message" : {
      "errors" : [ {
        "message" : "must not be null",
        "type" : "1",
        "code" : "javax.validation.constraints.NotNull.message",
        "parameters" : [ {
          "key" : "instances[0].source",
          "value" : "null"
        } ]
      } ]
    },
    "shortMessage" : "must not be null: instances[0].source",
    "entityType" : "INSTANCE",
    "entity" : {
      "hrid" : "0002",
      "title" : "New title",
      "instanceTypeId" : "6312d172-f0cf-40f6-b27d-9fa8feaf332f",
      "id" : "8f2b55de-2b20-4af9-ac57-1805fb191b1e"
    },
    "statusCode" : "422",
    "details" : { }
  }, {
    "category" : "STORAGE",
    "message" : {
      "errors" : [ {
        "message" : "must not be null",
        "type" : "1",
        "code" : "javax.validation.constraints.NotNull.message",
        "parameters" : [ {
          "key" : "instances[0].source",
          "value" : "null"
        } ]
      } ]
    },
    "shortMessage" : "must not be null: instances[0].source",
    "entityType" : "INSTANCE",
    "entity" : {
      "hrid" : "0005",
      "title" : "New title",
      "instanceTypeId" : "6312d172-f0cf-40f6-b27d-9fa8feaf332f",
      "id" : "08eb28cf-efb6-49c9-87cb-90572ac7277a"
    },
    "statusCode" : "422",
    "details" : { }
  } ]
}

Response 400

Bad request, for example: empty request body, non-JSON or invalid JSON in request body or JSON does not contain inventory record sets

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 422

One or more validation errors found in the incoming batch of record sets. No updates performed.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 500

Internal error in the module or in storage during delete by HRID

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Retrieve single Inventory record set either by Instance UUID or HRID

GET /inventory-upsert-hrid/fetch/{id}

GET /inventory-upsert-hrid/fetch/{id}
URI Parameters
  • id: required (string)

Response 200

Inventory record set found

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a successful upsert request",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set as it was pushed to Inventory storage",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items as it was pushed to Inventory storage",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "instanceRelations": {
      "type": "object",
      "description": "Collection of the Instance's relations to other instances, like parent-child relations or title successions",
      "parentInstances": {
        "type": "array",
        "description": "The Instance's relations to parent instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "childInstances": {
        "type": "array",
        "description": "The Instance's relations to child instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "precedingTitles": {
        "type": "array",
        "description": "The Instance's relation to preceding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title (this Instance)"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "succeedingTitles": {
        "type": "array",
        "description": "The Instance's relation to succeeding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title (this Instance)"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      }
    }
  }
}

Create, update, "delete" instance, replace its holdings and items, based on instance match key

PUT /shared-inventory-upsert-matchkey

PUT /shared-inventory-upsert-matchkey
Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "An instance record and an array of holdings records with embedded items",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "processing": {
      "type": "object",
      "description": "An object holding supporting pieces of data and/or processing instructions for Inventory update processing",
      "properties": {
        "institutionId": {
          "type": "string",
          "description": "The FOLIO UUID of the institution that provided the source records for the update; necessary for certain clean-up tasks in a shared inventory",
          "$schema": "http://json-schema.org/draft-04/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}$"
        },
        "localIdentifier": {
          "type": "string",
          "description": "The source system's unique identifier for the source record of this update request; necessary for certain clean-up tasks in a shared inventory"
        },
        "identifierTypeId": {
          "type": "string",
          "description": "The FOLIO UUID for the identifier type for the local record IDs coming from the given library",
          "$schema": "http://json-schema.org/draft-04/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}$"
        }
      }
    }
  }
}

Response 200

Inventory recordset successfully created or updated by match key

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a successful upsert request",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set as it was pushed to Inventory storage",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items as it was pushed to Inventory storage",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "instanceRelations": {
      "type": "object",
      "description": "Collection of the Instance's relations to other instances, like parent-child relations or title successions",
      "parentInstances": {
        "type": "array",
        "description": "The Instance's relations to parent instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "childInstances": {
        "type": "array",
        "description": "The Instance's relations to child instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "precedingTitles": {
        "type": "array",
        "description": "The Instance's relation to preceding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title (this Instance)"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "succeedingTitles": {
        "type": "array",
        "description": "The Instance's relation to succeeding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title (this Instance)"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      }
    },
    "metrics": {
      "type": "object",
      "description": "Reports the number of operations performed by record type, transaction type, and outcome",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "INSTANCE": {
          "type": "object",
          "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Instance create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance create operations."
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance create operations."
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Instance update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Instance delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance delete operations (0 or 1)"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance delete operations (0 or 1)"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "HOLDINGS_RECORD": {
          "type": "object",
          "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "ITEM": {
          "type": "object",
          "description": "Reports the number of operations performed on Items by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Item create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Item update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Item delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_RELATIONSHIP": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of relationship create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of relationship delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other Instance was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other Instance failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other Instance was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_TITLE_SUCCESSION": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of title succession create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of title succession delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other title was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other title failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other title was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        }
      }
    }
  }
}

Response 207

Partially successful update of record set. Errors listed in response.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on an upsert request that encountered one or more problems",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set as it was pushed to Inventory storage",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items as it was pushed to Inventory storage",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "metrics": {
      "type": "object",
      "description": "Report of the number of operations performed by record type, transaction type, and outcome",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "INSTANCE": {
          "type": "object",
          "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Instance create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance create operations."
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance create operations."
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Instance update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Instance delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance delete operations (0 or 1)"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance delete operations (0 or 1)"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "HOLDINGS_RECORD": {
          "type": "object",
          "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "ITEM": {
          "type": "object",
          "description": "Reports the number of operations performed on Items by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Item create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Item update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Item delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_RELATIONSHIP": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of relationship create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of relationship delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other Instance was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other Instance failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other Instance was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_TITLE_SUCCESSION": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of title succession create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of title succession delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other title was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other title failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other title was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        }
      }
    },
    "errors": {
      "type": "array",
      "description": "List of problems encountered during an Inventory update or delete request.",
      "items": {
        "type": "object",
        "description": "Description of an individual error conditions",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "properties": {
          "category": {
            "type": "string",
            "description": "Type of problem, usually error category STORAGE."
          },
          "statusCode": {
            "type": "string",
            "description": "The HTTP status code assigned to the error."
          },
          "message": {
            "description": "Error message returned by Inventory storage.",
            "anyOf": [
              {
                "type": "string",
                "description": "Error text returned by Inventory storage."
              },
              {
                "type": "object",
                "description": "JSON object of one or more structured error messages returned by Inventory storage."
              }
            ]
          },
          "shortMessage": {
            "type": "string",
            "description": "A short error message that might be used by the client to count similar error occurrences."
          },
          "entityType": {
            "type": "string",
            "description": "The record type for which a problem occurred."
          },
          "transaction": {
            "type": "string",
            "description": "Type of REST operation for which the problem occurred."
          },
          "entity": {
            "type": "object",
            "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
          },
          "details": {
            "type": "object",
            "description": "Any further details, i.e. additional context for the problem."
          }
        }
      }
    }
  }
}

Response 400

Bad request, for example: non-JSON in request body; inventory record set without an Instance.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 422

One or more validation errors encountered. No updates performed.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 500

Internal error in the module or in storage module.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

DELETE /shared-inventory-upsert-matchkey

DELETE /shared-inventory-upsert-matchkey
Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Deletion record for deleting a library's contributions to an Instance in a shared index",
  "type": "object",
  "properties": {
    "institutionId": {
      "type": "string",
      "description": "UUID representing the institution who's contributions to a shared Instance should be removed",
      "$schema": "http://json-schema.org/draft-04/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}$"
    },
    "localIdentifier": {
      "type": "string",
      "description": "A library's legacy identifier for a bibliographic record that is to be removed from a shared Instance"
    },
    "oaiIdentifier": {
      "type": "string",
      "description": "The record identifier of an OAI-PMH feed, for a bibliographic record that is to be removed from a shared Instance"
    },
    "identifierTypeId": {
      "type": "string",
      "description": "ID for the identifier type attached to all identifier values from the institution who's contributions to a shared Instance should be removed",
      "$schema": "http://json-schema.org/draft-04/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}$"
    }
  },
  "oneOf": [
    {
      "required": [
        "institutionId",
        "localIdentifier",
        "identifierTypeId"
      ]
    },
    {
      "required": [
        "institutionId",
        "oaiIdentifier",
        "identifierTypeId"
      ]
    }
  ]
}

Response 200

Record set was successfully found by local ID and cleaned up.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a successful upsert request",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set as it was pushed to Inventory storage",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items as it was pushed to Inventory storage",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "instanceRelations": {
      "type": "object",
      "description": "Collection of the Instance's relations to other instances, like parent-child relations or title successions",
      "parentInstances": {
        "type": "array",
        "description": "The Instance's relations to parent instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "childInstances": {
        "type": "array",
        "description": "The Instance's relations to child instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "precedingTitles": {
        "type": "array",
        "description": "The Instance's relation to preceding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title (this Instance)"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "succeedingTitles": {
        "type": "array",
        "description": "The Instance's relation to succeeding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title (this Instance)"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      }
    },
    "metrics": {
      "type": "object",
      "description": "Reports the number of operations performed by record type, transaction type, and outcome",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "INSTANCE": {
          "type": "object",
          "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Instance create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance create operations."
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance create operations."
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Instance update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Instance delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance delete operations (0 or 1)"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance delete operations (0 or 1)"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "HOLDINGS_RECORD": {
          "type": "object",
          "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "ITEM": {
          "type": "object",
          "description": "Reports the number of operations performed on Items by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Item create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Item update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Item delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_RELATIONSHIP": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of relationship create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of relationship delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other Instance was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other Instance failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other Instance was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_TITLE_SUCCESSION": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of title succession create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of title succession delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other title was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other title failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other title was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        }
      }
    }
  }
}

Response 400

Bad request, for example: non-JSON in request body.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 404

Did not find existing Instance (record set) to clean up for given local ID.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 422

One or more validation errors encountered. No deletion performed.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 500

Internal error in the module or in storage during delete by local ID.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Retrieve single Inventory record set either by Instance UUID or HRID

GET /shared-inventory-upsert-matchkey/fetch/{id}

GET /shared-inventory-upsert-matchkey/fetch/{id}
URI Parameters
  • id: required (string)

Response 200

Inventory record set found

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a successful upsert request",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set as it was pushed to Inventory storage",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items as it was pushed to Inventory storage",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "instanceRelations": {
      "type": "object",
      "description": "Collection of the Instance's relations to other instances, like parent-child relations or title successions",
      "parentInstances": {
        "type": "array",
        "description": "The Instance's relations to parent instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "childInstances": {
        "type": "array",
        "description": "The Instance's relations to child instances",
        "items": {
          "type": "object",
          "properties": {
            "subInstanceId": {
              "type": "string",
              "description": "UUID of the child instance"
            },
            "superInstanceId": {
              "type": "string",
              "description": "UUID of the parent instance"
            },
            "instanceRelationshipTypeId": {
              "type": "string",
              "description": "UUID of the type of relations - ie a multipart monograph relation"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "precedingTitles": {
        "type": "array",
        "description": "The Instance's relation to preceding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title (this Instance)"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      },
      "succeedingTitles": {
        "type": "array",
        "description": "The Instance's relation to succeeding title(s)",
        "items": {
          "type": "object",
          "properties": {
            "succeedingInstanceId": {
              "type": "string",
              "description": "UUID of the succeeding title"
            },
            "precedingInstanceId": {
              "type": "string",
              "description": "UUID of the preceding title (this Instance)"
            },
            "CREATE_PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "Provisional Instance required to create this Instance relationship",
              "$schema": "http://json-schema.org/draft-04/schema#"
            }
          }
        }
      }
    }
  }
}

Create or update a batch of instances with holdings and items, based on the match-key for the incoming Instance

PUT /shared-inventory-batch-upsert-matchkey

PUT /shared-inventory-batch-upsert-matchkey
Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "An instance record and an array of holdings records with embedded items",
  "type": "object",
  "properties": {
    "instance": {
      "type": "object",
      "description": "The Instance, the bibliographic part, of this Inventory record set",
      "$schema": "http://json-schema.org/draft-04/schema#"
    },
    "holdingsRecords": {
      "type": "array",
      "description": "Collection of holdings of the Instance, each holdings record with embedded items",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "A holdings record in compliance with the schema of the given version of the underlying `holdings-storage` API, optionally with embedded items",
        "properties": {
          "items": {
            "description": "Inventory items for this holdings record",
            "type": "array",
            "items": {
              "$schema": "http://json-schema.org/draft-04/schema#",
              "description": "An item record in compliance with the schema of the given version of the underlying `item-storage` API",
              "type": "object"
            }
          }
        }
      }
    },
    "processing": {
      "type": "object",
      "description": "An object holding supporting pieces of data and/or processing instructions for Inventory update processing",
      "properties": {
        "institutionId": {
          "type": "string",
          "description": "The FOLIO UUID of the institution that provided the source records for the update; necessary for certain clean-up tasks in a shared inventory",
          "$schema": "http://json-schema.org/draft-04/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}$"
        },
        "localIdentifier": {
          "type": "string",
          "description": "The source system's unique identifier for the source record of this update request; necessary for certain clean-up tasks in a shared inventory"
        },
        "identifierTypeId": {
          "type": "string",
          "description": "The FOLIO UUID for the identifier type for the local record IDs coming from the given library",
          "$schema": "http://json-schema.org/draft-04/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}$"
        }
      }
    }
  }
}

Response 200

Batch of Inventory record sets successfully created or updated by match-key.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "description": "Reports the number of operations performed by record type, transaction type, and outcome",
  "properties": {
    "INSTANCE": {
      "type": "object",
      "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of Instance create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Instance create operations."
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Instance create operations."
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Instance create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "UPDATED": {
          "type": "object",
          "description": "Reports the number of Instance update operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Instance update operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Instance update operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Instance update operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of Instance delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Instance delete operations (0 or 1)"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Instance delete operations (0 or 1)"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Instance delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    },
    "HOLDINGS_RECORD": {
      "type": "object",
      "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of HoldingsRecord create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed HoldingsRecord create operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed HoldingsRecord create operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of HoldingsRecord create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "UPDATED": {
          "type": "object",
          "description": "Reports the number of HoldingsRecord update operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed HoldingsRecord update operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed HoldingsRecord update operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of HoldingsRecord update operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of HoldingsRecord delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed HoldingsRecord delete operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed HoldingsRecord delete operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of HoldingsRecord delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    },
    "ITEM": {
      "type": "object",
      "description": "Reports the number of operations performed on Items by transaction type and outcome",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of Item create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Item create operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Item create operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Item create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "UPDATED": {
          "type": "object",
          "description": "Reports the number of Item update operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Item update operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Item update operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Item update operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of Item delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed Item delete operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed Item delete operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of Item delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    },
    "INSTANCE_RELATIONSHIP": {
      "type": "object",
      "description": "Reports the number of operations performed for the Instance's parent-child relationships",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of relationship create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed relationship create operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed relationship create operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of relationship create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of relationship delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed relationship delete operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed relationship delete operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of relationship delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "PROVISIONAL_INSTANCE": {
          "type": "object",
          "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "1 if the other Instance was successfully created"
            },
            "FAILED": {
              "type": "integer",
              "description": "1 if the creation of the other Instance failed"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "1 if creation of the other Instance was skipped (should always be 0)"
            },
            "PENDING": {
              "type": "integer",
              "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    },
    "INSTANCE_TITLE_SUCCESSION": {
      "type": "object",
      "description": "Reports the number of operations performed for the Instance's parent-child relationships",
      "properties": {
        "CREATED": {
          "type": "object",
          "description": "Reports the number of title succession create operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed title succession create operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed title succession create operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of title succession create operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "DELETED": {
          "type": "object",
          "description": "Reports the number of title succession delete operations by outcome",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "Number of successfully completed title succession delete operations"
            },
            "FAILED": {
              "type": "integer",
              "description": "Number of failed title succession delete operations"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "Number of title succession delete operations that were skipped"
            },
            "PENDING": {
              "type": "integer",
              "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
            }
          }
        },
        "PROVISIONAL_INSTANCE": {
          "type": "object",
          "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
          "properties": {
            "COMPLETED": {
              "type": "integer",
              "description": "1 if the other title was successfully created"
            },
            "FAILED": {
              "type": "integer",
              "description": "1 if the creation of the other title failed"
            },
            "SKIPPED": {
              "type": "integer",
              "description": "1 if creation of the other title was skipped (should always be 0)"
            },
            "PENDING": {
              "type": "integer",
              "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
            }
          }
        }
      }
    }
  }
}

Response 207

Partially successful update of record set. Errors enumerated in response.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a partly successful batch upsert request",
  "type": "object",
  "properties": {
    "metrics": {
      "type": "object",
      "description": "Report of the number of operations performed by record type, transaction type, and outcome",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "properties": {
        "INSTANCE": {
          "type": "object",
          "description": "Reports the number of operations performed on Instance records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Instance create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance create operations."
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance create operations."
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Instance update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Instance delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Instance delete operations (0 or 1)"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Instance delete operations (0 or 1)"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Instance delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Instance delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "HOLDINGS_RECORD": {
          "type": "object",
          "description": "Reports the number of operations performed on holdings records by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of HoldingsRecord delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed HoldingsRecord delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed HoldingsRecord delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of HoldingsRecord delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "ITEM": {
          "type": "object",
          "description": "Reports the number of operations performed on Items by transaction type and outcome",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of Item create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "UPDATED": {
              "type": "object",
              "description": "Reports the number of Item update operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item update operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item update operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item update operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item update operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of Item delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed Item delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed Item delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of Item delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_RELATIONSHIP": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of relationship create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of Item relationship operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of relationship delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed relationship delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed relationship delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of relationship delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of relationship delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the parent or child didn't exist in Inventory yet, this will report on operation for creating a provisional Instance",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other Instance was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other Instance failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other Instance was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        },
        "INSTANCE_TITLE_SUCCESSION": {
          "type": "object",
          "description": "Reports the number of operations performed for the Instance's parent-child relationships",
          "properties": {
            "CREATED": {
              "type": "object",
              "description": "Reports the number of title succession create operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession create operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession create operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession create operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession create operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "DELETED": {
              "type": "object",
              "description": "Reports the number of title succession delete operations by outcome",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "Number of successfully completed title succession delete operations"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "Number of failed title succession delete operations"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "Number of title succession delete operations that were skipped"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "Number of title succession delete operations not completed (0 unless there is a logical error in MIU)"
                }
              }
            },
            "PROVISIONAL_INSTANCE": {
              "type": "object",
              "description": "If the successive title didn't exist in Inventory yet, this will report on operation for creating a provisional title",
              "properties": {
                "COMPLETED": {
                  "type": "integer",
                  "description": "1 if the other title was successfully created"
                },
                "FAILED": {
                  "type": "integer",
                  "description": "1 if the creation of the other title failed"
                },
                "SKIPPED": {
                  "type": "integer",
                  "description": "1 if creation of the other title was skipped (should always be 0)"
                },
                "PENDING": {
                  "type": "integer",
                  "description": "1 if creation was required but not completed (0 unless there is a logical error in MIU)"
                }
              }
            }
          }
        }
      }
    },
    "errors": {
      "type": "array",
      "description": "List of problems encountered during an Inventory update or delete request.",
      "items": {
        "type": "object",
        "description": "Description of an individual error conditions",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "properties": {
          "category": {
            "type": "string",
            "description": "Type of problem, usually error category STORAGE."
          },
          "statusCode": {
            "type": "string",
            "description": "The HTTP status code assigned to the error."
          },
          "message": {
            "description": "Error message returned by Inventory storage.",
            "anyOf": [
              {
                "type": "string",
                "description": "Error text returned by Inventory storage."
              },
              {
                "type": "object",
                "description": "JSON object of one or more structured error messages returned by Inventory storage."
              }
            ]
          },
          "shortMessage": {
            "type": "string",
            "description": "A short error message that might be used by the client to count similar error occurrences."
          },
          "entityType": {
            "type": "string",
            "description": "The record type for which a problem occurred."
          },
          "transaction": {
            "type": "string",
            "description": "Type of REST operation for which the problem occurred."
          },
          "entity": {
            "type": "object",
            "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
          },
          "details": {
            "type": "object",
            "description": "Any further details, i.e. additional context for the problem."
          }
        }
      }
    }
  }
}

Response 400

Bad request, for example: empty request body, non-JSON or invalid JSON in request body or JSON does not contain inventory record sets.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 422

One or more problems encountered when creating/updating a batch of Inventory record sets by match-keys.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}

Response 500

Internal error in the module or in the storage module.

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Response on a unsuccessful upsert request",
  "type": "object",
  "properties": {
    "category": {
      "type": "string",
      "description": "Type of problem, usually error category STORAGE."
    },
    "statusCode": {
      "type": "string",
      "description": "The HTTP status code assigned to the error."
    },
    "message": {
      "description": "Error message returned by Inventory storage.",
      "anyOf": [
        {
          "type": "string",
          "description": "Error text returned by Inventory storage."
        },
        {
          "type": "object",
          "description": "JSON object of one or more structured error messages returned by Inventory storage."
        }
      ]
    },
    "shortMessage": {
      "type": "string",
      "description": "A short error message that might be used by the client to count similar error occurrences."
    },
    "entityType": {
      "type": "string",
      "description": "The record type for which a problem occurred."
    },
    "transaction": {
      "type": "string",
      "description": "Type of REST operation for which the problem occurred."
    },
    "entity": {
      "type": "object",
      "description": "The JSON object that was pushed to Inventory storage when the problem occurred."
    },
    "details": {
      "type": "object",
      "description": "Any further details, i.e. additional context for the problem."
    }
  }
}