io7m | single-page | multi-page | Cardant User Manual 1.0.0-SNAPSHOT
8. API Access
Previous
8. API Access
Up
9. Security
Next

# 8.1. Inventory Protocol

- 8.1.1. Versioning
- 8.1.2. Health
- 8.1.3. Version 1.0
  - 8.1.3.1. Encoding
  - 8.1.3.2. Login
  - 8.1.3.3. Commands
  - 8.1.3.4. Transactions
  - 8.1.3.5. Schema

## 8.1.1. Versioning

1
The Inventory API service exposes one or more versions of the Inventory protocol. The service uses the ventrad protocol to advertise which versions of the Inventory protocol are available. Executing a GET request to the root endpoint will yield a ventrad message showing which versions of the Inventory protocol are available. The Inventory protocol is assigned the protocol identifier 8ee23158-f8db-317a-a58b-45bd9d702040.
2
As an example, the following shows that the Inventory protocol version 1 is available at /inventory/1/0/:

### 8.1.1.3. Ventrad Example

    $ curl https://cardant.example.com:30000/ | jq
    {
      "%Schema": "urn:com.io7m.ventrad:1",
      "Protocols": [
        {
          "Id": "8ee23158-f8db-317a-a58b-45bd9d702040",
          "VersionMajor": 1,
          "VersionMinor": 0,
          "Endpoint": "/inventory/1/0/",
          "Description": "Cardant Inventory v1.0"
        }
      ]
    }

## 8.1.2. Health

1
The Inventory API service exposes a health check endpoint at /health. The endpoint returns a 200 status code and the string OK if the server's most recent internal health checks succeeded. The server returns a 500 status code and string not equal to OK if the server's most recent internal health checks failed. In both cases, the string is returned directly as a text/plain UTF-8 value.

## 8.1.3. Version 1.0

## 8.1.3.1. Encoding

1
The version 1 Inventory protocol uses JSON-encoded messages over HTTP(s).

## 8.1.3.2. Login

1
Send a CJ1CommandLogin command to /inventory/1/0/login. If the login succeeds, a cookie named CARDANT_INVENTORY_SESSION will be set. This cookie must be included with all subsequent requests.

### 8.1.3.2.2. Login Example

    $ cat message.json
    {
      "@type": "Login",
      "userName": "example",
      "password": "validpassword"
    }

    $ curl -c cookies.txt -d @message.json http://cardant.example.com:30000/inventory/1/0/login | jq
    {
      "@type": "ResponseLogin",
      "requestId": "23d56c39-9582-42af-a3a3-7d94bf944f35",
      "userId": "57733ee9-2c62-4b62-bd7f-b5bbc9cd915a"
    }

    $ cat cookies.txt
    cardant.example.com FALSE /inventory/1/0/ FALSE 1761297157 CARDANT_INVENTORY_SESSION 47E3D6E4133D04FD33125F5A3598B79089F7A7DA3AC507ADB13DAEF12934B88C

## 8.1.3.3. Commands

1
After logging in successfully, send commands of type CJ1CommandType to /inventory/1/0/command. Failed commands will yield a value of type CJ1ResponseError, whilst successful results will yield values of type CJ1Response*.

### 8.1.3.3.2. Command Example

    $ cat message.json
    {
      "@type": "ItemSearchBegin",
      "parameters": {
        "matchName": {
          "@type": "Anything"
        },
        "matchDescription": {
          "@type": "Anything"
        },
        "matchTypes": {
          "@type": "Anything"
        },
        "matchMetadata": {
          "@type": "Specific",
          "packageName": {
            "@type": "Anything"
          },
          "typeName": {
            "@type": "Anything"
          },
          "fieldName": {
            "@type": "Anything"
          },
          "value": {
            "@type": "Anything"
          }
        },
        "includeDeleted": "INCLUDE_ONLY_LIVE",
        "orderBy": {
          "column": "BY_ID",
          "ascending": true
        },
        "pageSize": 5
      }
    }

    $ curl -b cookies.txt -d @message.json http://cardant.example.com:30000/inventory/1/0/command | jq
    {
      "@type": "ResponseItemSearch",
      "requestId": "cf47d6f4-1441-4b79-9cd5-f80e21f1bc11",
      "results": {
        "items": [
          {
            "id": "0214d4fa-1fbb-47b9-bb57-f12d9bf2735e",
            "name": "Siglent SPD1305X DC Power Supply",
            "timeCreated": "2024-07-22T19:34:52.954587Z",
            "timeUpdated": "2024-07-22T19:34:52.954587Z"
          },
          {
            "id": "02f63b7e-4c0a-4f1c-81d6-862da8d2e5ac",
            "name": "Western Digital SN570 1TB",
            "timeCreated": "2024-01-12T21:01:15.973701Z",
            "timeUpdated": "2024-01-12T21:01:15.973701Z"
          },
          {
            "id": "0556121f-9aab-4e89-a413-08214d8ae74d",
            "name": "Seagate Exos X16 16TB",
            "timeCreated": "2024-01-12T21:05:33.547416Z",
            "timeUpdated": "2025-03-09T18:22:22Z"
          },
          {
            "id": "06946960-e508-4eeb-b297-715e1bcec843",
            "name": "Samsung 870 EVO 1TB",
            "timeCreated": "2024-05-18T12:28:43.607659Z",
            "timeUpdated": "2024-05-18T12:28:43.607659Z"
          },
          {
            "id": "0adb8f6a-ed35-479d-baf9-2e2f9a50b622",
            "name": "AMD Ryzen 5 3600",
            "timeCreated": "2024-01-12T21:02:01.738558Z",
            "timeUpdated": "2024-12-07T17:41:22Z"
          }
        ],
        "pageIndex": {
          "value": 1
        },
        "pageCount": {
          "value": 23
        },
        "pageFirstOffset": 0
      }
    }

## 8.1.3.4. Transactions

1
It can sometimes be desirable to send sets of commands that must execute atomically; if a single command in the set fails, it must be as if none of the commands were executed.
2
After logging in successfully, a value of type CJ1Transaction can be sent to /inventory/1/0/transaction.
3
The response from the /inventory/1/0/transaction endpoint will be a value of type CJ1TransactionResponse with a response for each command in the original sequence. If any of the values in the sequence are CJ1ResponseError values, the transaction was rolled back by the server and not committed.

### 8.1.3.4.4. Transaction Example

    $ cat transaction.json
    {
      "@type": "Transaction",
      "commands": [
        {
          "@type": "ItemSearchBegin",
          "parameters": {
            "matchName": {
              "@type": "Anything"
            },
            "matchDescription": {
              "@type": "Anything"
            },
            "matchTypes": {
              "@type": "Anything"
            },
            "matchMetadata": {
              "@type": "Specific",
              "packageName": {
                "@type": "Anything"
              },
              "typeName": {
                "@type": "Anything"
              },
              "fieldName": {
                "@type": "Anything"
              },
              "value": {
                "@type": "Anything"
              }
            },
            "includeDeleted": "INCLUDE_ONLY_LIVE",
            "orderBy": {
              "column": "BY_ID",
              "ascending": true
            },
            "pageSize": 3
          }
        },
        {
          "@type": "ItemSearchNext"
        },
        {
          "@type": "ItemSearchNext"
        }
      ]
    }

    $ curl -b cookies.txt -d @message.json http://cardant.example.com:30000/inventory/1/0/transaction | jq
    {
      "@type": "TransactionResponse",
      "requestId": "7c411039-7ca0-4e53-a9d1-0f7fd1b33919",
      "responses": [
        {
          "@type": "ResponseItemSearch",
          "requestId": "7c411039-7ca0-4e53-a9d1-0f7fd1b33919",
          "results": {
            "items": [
              {
                "id": "16208353-0cd6-4082-89b9-170b87e31000",
                "name": "AMD Radeon RX 5700",
                "timeCreated": "2024-01-12T21:02:28.13536Z",
                "timeUpdated": "2024-12-07T17:37:16Z"
              },
              {
                "id": "c1ef2558-9b2f-4a84-ba75-8a9fe5276e80",
                "name": "AMD Ryzen 3 3200G",
                "timeCreated": "2024-01-12T21:03:44.878024Z",
                "timeUpdated": "2024-12-07T17:38:49Z"
              },
              {
                "id": "0d5e8aca-0826-4e85-8a71-ffd26f4137c1",
                "name": "AMD Ryzen 5 1400",
                "timeCreated": "2024-01-12T21:06:34.568583Z",
                "timeUpdated": "2024-12-07T17:39:31Z"
              }
            ],
            "pageIndex": {
              "value": 1
            },
            "pageCount": {
              "value": 37
            },
            "pageFirstOffset": 0
          }
        },
        {
          "@type": "ResponseItemSearch",
          "requestId": "7c411039-7ca0-4e53-a9d1-0f7fd1b33919",
          "results": {
            "items": [
              {
                "id": "d9e12864-7411-43a4-9030-ebfaf94cd0bf",
                "name": "AMD Ryzen 5 3400G",
                "timeCreated": "2024-01-12T21:02:43.436395Z",
                "timeUpdated": "2024-12-07T17:40:46Z"
              },
              {
                "id": "0adb8f6a-ed35-479d-baf9-2e2f9a50b622",
                "name": "AMD Ryzen 5 3600",
                "timeCreated": "2024-01-12T21:02:01.738558Z",
                "timeUpdated": "2024-12-07T17:41:22Z"
              },
              {
                "id": "a92f27cf-aacc-48fb-aeb9-5afa92af8f46",
                "name": "AMD Ryzen 5 5600G",
                "timeCreated": "2024-01-12T21:03:57.892137Z",
                "timeUpdated": "2024-12-07T17:41:56Z"
              }
            ],
            "pageIndex": {
              "value": 2
            },
            "pageCount": {
              "value": 37
            },
            "pageFirstOffset": 3
          }
        },
        {
          "@type": "ResponseItemSearch",
          "requestId": "7c411039-7ca0-4e53-a9d1-0f7fd1b33919",
          "results": {
            "items": [
              {
                "id": "58794e07-532d-4143-905c-bcb65bdbd1e4",
                "name": "AMD Ryzen 7 3700X",
                "timeCreated": "2024-04-04T16:27:38.009937Z",
                "timeUpdated": "2024-12-07T17:42:35Z"
              },
              {
                "id": "922af91f-761e-438a-aaa9-055efa5d4360",
                "name": "Antec Neo ECO 520",
                "timeCreated": "2025-03-07T11:18:42Z",
                "timeUpdated": "2025-03-07T11:20:40Z"
              },
              {
                "id": "c75b8537-2725-452e-adb1-eaa3dfd5a286",
                "name": "Antec VP450P 450W",
                "timeCreated": "2025-03-07T11:15:24Z",
                "timeUpdated": "2025-03-07T11:16:58Z"
              }
            ],
            "pageIndex": {
              "value": 3
            },
            "pageCount": {
              "value": 37
            },
            "pageFirstOffset": 6
          }
        }
      ]
    }

## 8.1.3.5. Schema

1
The JSON schema for the protocol is as follows:

### 8.1.3.5.2. Schema

    {
      "$schema" : "https://json-schema.org/draft/2020-12/schema",
      "$id" : "urn:com.io7m.cardant.inventory:1.0",
      "title" : "Cardant Inventory 1.0",
      "oneOf" : [ {
        "$ref" : "#/$defs/CJ1MessageType"
      } ],
      "$defs" : {
        "BigDecimal" : {
          "description" : "An arbitrary real number.",
          "type" : "number"
        },
        "CAErrorCode" : {
          "description" : "An error code.",
          "type" : "string",
          "pattern" : "[a-z][a-z\\-]+"
        },
        "CJ1Attachment" : {
          "description" : "An attachment on an item or location.",
          "type" : "object",
          "properties" : {
            "file" : {
              "description" : "The file.",
              "$ref" : "#/$defs/CJ1FileType"
            },
            "relation" : {
              "description" : "The attachment relation.",
              "$ref" : "#/$defs/String"
            }
          },
          "required" : [ "file", "relation" ]
        },
        "CJ1AttachmentItem" : {
          "description" : "An attachment.",
          "type" : "object",
          "properties" : {
            "attachment" : {
              "description" : "The attachment.",
              "$ref" : "#/$defs/CJ1Attachment"
            },
            "key" : {
              "description" : "The attachment key.",
              "$ref" : "#/$defs/CJ1AttachmentKey"
            }
          },
          "required" : [ "attachment", "key" ]
        },
        "CJ1AttachmentKey" : {
          "description" : "An attachment key.",
          "type" : "object",
          "properties" : {
            "file" : {
              "description" : "The attachment file.",
              "$ref" : "#/$defs/UUID"
            },
            "relation" : {
              "description" : "The attachment relation.",
              "$ref" : "#/$defs/String"
            }
          },
          "required" : [ "file", "relation" ]
        },
        "CJ1AuditEvent" : {
          "description" : "An audit event.",
          "type" : "object",
          "properties" : {
            "data" : {
              "description" : "The event data.",
              "$ref" : "#/$defs/Map<String,String>"
            },
            "id" : {
              "description" : "The event ID.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "owner" : {
              "description" : "The event owner.",
              "$ref" : "#/$defs/UUID"
            },
            "time" : {
              "description" : "The event time.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "type" : {
              "description" : "The event type.",
              "$ref" : "#/$defs/String"
            }
          },
          "required" : [ "data", "id", "owner", "time", "type" ]
        },
        "CJ1AuditSearchParameters" : {
          "description" : "Parameters to search for audit events.",
          "type" : "object",
          "properties" : {
            "matchEventType" : {
              "description" : "Include events with types matching the given expression.",
              "$ref" : "#/$defs/CJ1ComparisonExactType<String>"
            },
            "matchOwner" : {
              "description" : "Include audit results for the given user.",
              "$ref" : "#/$defs/Optional<UUID>"
            },
            "matchTimeRange" : {
              "description" : "Include events within the given time range.",
              "$ref" : "#/$defs/CJ1TimeRange"
            },
            "pageSize" : {
              "description" : "The maximum number of events per page.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            }
          },
          "required" : [ "matchEventType", "matchTimeRange", "pageSize" ]
        },
        "CJ1CommandAuditSearchBegin" : {
          "description" : "Start searching for audit events.",
          "type" : "object",
          "properties" : {
            "parameters" : {
              "description" : "The search parameters.",
              "$ref" : "#/$defs/CJ1AuditSearchParameters"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "AuditSearchBegin"
            }
          },
          "required" : [ "@type", "parameters" ]
        },
        "CJ1CommandAuditSearchNext" : {
          "description" : "Get the next page of audit events.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "AuditSearchNext"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandAuditSearchPrevious" : {
          "description" : "Get the previous page of audit events.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "AuditSearchPrevious"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandFileDelete" : {
          "description" : "Delete a file.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The file ID.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "FileDelete"
            }
          },
          "required" : [ "@type", "id" ]
        },
        "CJ1CommandFileGet" : {
          "description" : "Get a file.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The file ID.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "FileGet"
            }
          },
          "required" : [ "@type", "id" ]
        },
        "CJ1CommandFilePut" : {
          "description" : "Create or update a file.",
          "type" : "object",
          "properties" : {
            "file" : {
              "description" : "The file.",
              "$ref" : "#/$defs/CJ1FileType"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "FilePut"
            }
          },
          "required" : [ "@type", "file" ]
        },
        "CJ1CommandFileSearchBegin" : {
          "description" : "Start searching for files.",
          "type" : "object",
          "properties" : {
            "parameters" : {
              "description" : "The search parameters.",
              "$ref" : "#/$defs/CJ1FileSearchParameters"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "FileSearchBegin"
            }
          },
          "required" : [ "@type", "parameters" ]
        },
        "CJ1CommandFileSearchNext" : {
          "description" : "Get the next page of files.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "FileSearchNext"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandFileSearchPrevious" : {
          "description" : "Get the previous page of files.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "FileSearchPrevious"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandItemAttachmentAdd" : {
          "description" : "Add an attachment to an item.",
          "type" : "object",
          "properties" : {
            "file" : {
              "description" : "The file ID.",
              "$ref" : "#/$defs/UUID"
            },
            "item" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "relation" : {
              "description" : "The attachment relation.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemAttachmentAdd"
            }
          },
          "required" : [ "@type", "file", "item", "relation" ]
        },
        "CJ1CommandItemAttachmentRemove" : {
          "description" : "Remove an attachment from an item.",
          "type" : "object",
          "properties" : {
            "file" : {
              "description" : "The file ID.",
              "$ref" : "#/$defs/UUID"
            },
            "item" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "relation" : {
              "description" : "The attachment relation.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemAttachmentRemove"
            }
          },
          "required" : [ "@type", "file", "item", "relation" ]
        },
        "CJ1CommandItemCreate" : {
          "description" : "Create an item.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "name" : {
              "description" : "The item name.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemCreate"
            }
          },
          "required" : [ "@type", "id", "name" ]
        },
        "CJ1CommandItemDelete" : {
          "description" : "Delete an item.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemDelete"
            }
          },
          "required" : [ "@type", "id" ]
        },
        "CJ1CommandItemGet" : {
          "description" : "Retrieve an item.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemGet"
            }
          },
          "required" : [ "@type", "id" ]
        },
        "CJ1CommandItemMetadataPut" : {
          "description" : "Create or update metadata on an item.",
          "type" : "object",
          "properties" : {
            "item" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "metadatas" : {
              "description" : "The item metadata values.",
              "$ref" : "#/$defs/Set<CJ1MetadataType>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemMetadataPut"
            }
          },
          "required" : [ "@type", "item", "metadatas" ]
        },
        "CJ1CommandItemMetadataRemove" : {
          "description" : "Remove metadata from an item.",
          "type" : "object",
          "properties" : {
            "item" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "metadataNames" : {
              "description" : "The item metadata names.",
              "$ref" : "#/$defs/Set<CJ1TypeRecordFieldIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemMetadataRemove"
            }
          },
          "required" : [ "@type", "item", "metadataNames" ]
        },
        "CJ1CommandItemSearchBegin" : {
          "description" : "Start searching for items.",
          "type" : "object",
          "properties" : {
            "parameters" : {
              "description" : "The item search parameters.",
              "$ref" : "#/$defs/CJ1ItemSearchParameters"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemSearchBegin"
            }
          },
          "required" : [ "@type", "parameters" ]
        },
        "CJ1CommandItemSearchNext" : {
          "description" : "Get the next page of items.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "ItemSearchNext"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandItemSearchPrevious" : {
          "description" : "Get the previous page of items.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "ItemSearchPrevious"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandItemSetName" : {
          "description" : "Set the name of an item.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "name" : {
              "description" : "The item name.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemSetName"
            }
          },
          "required" : [ "@type", "id", "name" ]
        },
        "CJ1CommandItemTypesAssign" : {
          "description" : "Assign types to an item.",
          "type" : "object",
          "properties" : {
            "item" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "types" : {
              "description" : "The types.",
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemTypesAssign"
            }
          },
          "required" : [ "@type", "item" ]
        },
        "CJ1CommandItemTypesRevoke" : {
          "description" : "Revoke types from an item.",
          "type" : "object",
          "properties" : {
            "item" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "types" : {
              "description" : "The types.",
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ItemTypesRevoke"
            }
          },
          "required" : [ "@type", "item" ]
        },
        "CJ1CommandLocationAttachmentAdd" : {
          "description" : "Add an attachment to a location.",
          "type" : "object",
          "properties" : {
            "file" : {
              "description" : "The file ID.",
              "$ref" : "#/$defs/UUID"
            },
            "location" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "relation" : {
              "description" : "The attachment relation.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "LocationAttachmentAdd"
            }
          },
          "required" : [ "@type", "file", "location", "relation" ]
        },
        "CJ1CommandLocationAttachmentRemove" : {
          "description" : "Remove an attachment from a location.",
          "type" : "object",
          "properties" : {
            "file" : {
              "description" : "The file ID.",
              "$ref" : "#/$defs/UUID"
            },
            "location" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "relation" : {
              "description" : "The attachment relation.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "LocationAttachmentRemove"
            }
          },
          "required" : [ "@type", "file", "location", "relation" ]
        },
        "CJ1CommandLocationDelete" : {
          "description" : "Delete a location.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "LocationDelete"
            }
          },
          "required" : [ "@type", "id" ]
        },
        "CJ1CommandLocationGet" : {
          "description" : "Retrieve a location.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "LocationGet"
            }
          },
          "required" : [ "@type", "id" ]
        },
        "CJ1CommandLocationList" : {
          "description" : "List locations.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "LocationList"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandLocationMetadataPut" : {
          "description" : "Create or update metadata on a location.",
          "type" : "object",
          "properties" : {
            "location" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "metadatas" : {
              "description" : "The location metadata values.",
              "$ref" : "#/$defs/Set<CJ1MetadataType>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "LocationMetadataPut"
            }
          },
          "required" : [ "@type", "location", "metadatas" ]
        },
        "CJ1CommandLocationMetadataRemove" : {
          "description" : "Remove metadata from a location.",
          "type" : "object",
          "properties" : {
            "location" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "metadataNames" : {
              "description" : "The location metadata names.",
              "$ref" : "#/$defs/Set<CJ1TypeRecordFieldIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "LocationMetadataRemove"
            }
          },
          "required" : [ "@type", "location", "metadataNames" ]
        },
        "CJ1CommandLocationPut" : {
          "description" : "Create or update a location.",
          "type" : "object",
          "properties" : {
            "location" : {
              "description" : "The location.",
              "$ref" : "#/$defs/CJ1Location"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "LocationPut"
            }
          },
          "required" : [ "@type", "location" ]
        },
        "CJ1CommandLocationTypesAssign" : {
          "description" : "Assign types to a location.",
          "type" : "object",
          "properties" : {
            "location" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "types" : {
              "description" : "The location types.",
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "LocationTypesAssign"
            }
          },
          "required" : [ "@type", "location" ]
        },
        "CJ1CommandLocationTypesRevoke" : {
          "description" : "Revoke types from a location.",
          "type" : "object",
          "properties" : {
            "location" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "types" : {
              "description" : "The location type names.",
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "LocationTypesRevoke"
            }
          },
          "required" : [ "@type", "location" ]
        },
        "CJ1CommandLogin" : {
          "description" : "Log in.",
          "type" : "object",
          "properties" : {
            "metadata" : {
              "description" : "The extra metadata.",
              "$ref" : "#/$defs/Map<String,String>"
            },
            "password" : {
              "description" : "The password.",
              "$ref" : "#/$defs/String"
            },
            "userName" : {
              "description" : "The user name.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Login"
            }
          },
          "required" : [ "@type", "password", "userName" ]
        },
        "CJ1CommandRolesAssign" : {
          "description" : "Assign roles to a user.",
          "type" : "object",
          "properties" : {
            "roles" : {
              "description" : "The roles.",
              "$ref" : "#/$defs/Set<String>"
            },
            "user" : {
              "description" : "The user ID.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "RolesAssign"
            }
          },
          "required" : [ "@type", "user" ]
        },
        "CJ1CommandRolesGet" : {
          "description" : "Get roles assigned to a user.",
          "type" : "object",
          "properties" : {
            "user" : {
              "description" : "The user ID.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "RolesGet"
            }
          },
          "required" : [ "@type", "user" ]
        },
        "CJ1CommandRolesRevoke" : {
          "description" : "Revoke roles from a user.",
          "type" : "object",
          "properties" : {
            "roles" : {
              "description" : "The roles.",
              "$ref" : "#/$defs/Set<String>"
            },
            "user" : {
              "description" : "The user ID.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "RolesRevoke"
            }
          },
          "required" : [ "@type", "user" ]
        },
        "CJ1CommandStockCount" : {
          "description" : "Count stock matching the given search parameters.",
          "type" : "object",
          "properties" : {
            "parameters" : {
              "description" : "The stock search parameters.",
              "$ref" : "#/$defs/CJ1StockSearchParameters"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "StockCount"
            }
          },
          "required" : [ "@type", "parameters" ]
        },
        "CJ1CommandStockReposit" : {
          "description" : "Execute a stock reposition.",
          "type" : "object",
          "properties" : {
            "reposit" : {
              "description" : "The stock reposition.",
              "$ref" : "#/$defs/CJ1StockRepositType"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "StockReposit"
            }
          },
          "required" : [ "@type", "reposit" ]
        },
        "CJ1CommandStockSearchBegin" : {
          "description" : "Start searching for stock.",
          "type" : "object",
          "properties" : {
            "parameters" : {
              "description" : "The stock search parameters.",
              "$ref" : "#/$defs/CJ1StockSearchParameters"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "StockSearchBegin"
            }
          },
          "required" : [ "@type", "parameters" ]
        },
        "CJ1CommandStockSearchNext" : {
          "description" : "Get the next page of stock.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "StockSearchNext"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandStockSearchPrevious" : {
          "description" : "Get the previous page of stock.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "StockSearchPrevious"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1CommandAuditSearchBegin"
          }, {
            "$ref" : "#/$defs/CJ1CommandAuditSearchNext"
          }, {
            "$ref" : "#/$defs/CJ1CommandAuditSearchPrevious"
          }, {
            "$ref" : "#/$defs/CJ1CommandFileDelete"
          }, {
            "$ref" : "#/$defs/CJ1CommandFileGet"
          }, {
            "$ref" : "#/$defs/CJ1CommandFilePut"
          }, {
            "$ref" : "#/$defs/CJ1CommandFileSearchBegin"
          }, {
            "$ref" : "#/$defs/CJ1CommandFileSearchNext"
          }, {
            "$ref" : "#/$defs/CJ1CommandFileSearchPrevious"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemAttachmentAdd"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemAttachmentRemove"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemCreate"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemDelete"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemGet"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemMetadataPut"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemMetadataRemove"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemSearchBegin"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemSearchNext"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemSearchPrevious"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemSetName"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemTypesAssign"
          }, {
            "$ref" : "#/$defs/CJ1CommandItemTypesRevoke"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationAttachmentAdd"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationAttachmentRemove"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationDelete"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationGet"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationList"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationMetadataPut"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationMetadataRemove"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationPut"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationTypesAssign"
          }, {
            "$ref" : "#/$defs/CJ1CommandLocationTypesRevoke"
          }, {
            "$ref" : "#/$defs/CJ1CommandLogin"
          }, {
            "$ref" : "#/$defs/CJ1CommandRolesAssign"
          }, {
            "$ref" : "#/$defs/CJ1CommandRolesGet"
          }, {
            "$ref" : "#/$defs/CJ1CommandRolesRevoke"
          }, {
            "$ref" : "#/$defs/CJ1CommandStockCount"
          }, {
            "$ref" : "#/$defs/CJ1CommandStockReposit"
          }, {
            "$ref" : "#/$defs/CJ1CommandStockSearchBegin"
          }, {
            "$ref" : "#/$defs/CJ1CommandStockSearchNext"
          }, {
            "$ref" : "#/$defs/CJ1CommandStockSearchPrevious"
          }, {
            "$ref" : "#/$defs/CJ1CommandTypePackageGetText"
          }, {
            "$ref" : "#/$defs/CJ1CommandTypePackageInstall"
          }, {
            "$ref" : "#/$defs/CJ1CommandTypePackageSearchBegin"
          }, {
            "$ref" : "#/$defs/CJ1CommandTypePackageSearchNext"
          }, {
            "$ref" : "#/$defs/CJ1CommandTypePackageSearchPrevious"
          }, {
            "$ref" : "#/$defs/CJ1CommandTypePackageUninstall"
          }, {
            "$ref" : "#/$defs/CJ1CommandTypePackageUpgrade"
          } ]
        },
        "CJ1CommandTypePackageGetText" : {
          "description" : "Get the text of a type package.",
          "type" : "object",
          "properties" : {
            "identifier" : {
              "description" : "The type package identifier.",
              "$ref" : "#/$defs/CJ1TypePackageIdentifier"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "TypePackageGetText"
            }
          },
          "required" : [ "@type", "identifier" ]
        },
        "CJ1CommandTypePackageInstall" : {
          "description" : "Install a type package.",
          "type" : "object",
          "properties" : {
            "text" : {
              "description" : "The type package text.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "TypePackageInstall"
            }
          },
          "required" : [ "@type", "text" ]
        },
        "CJ1CommandTypePackageSearchBegin" : {
          "description" : "Start searching for type packages.",
          "type" : "object",
          "properties" : {
            "parameters" : {
              "description" : "The type package search parameters.",
              "$ref" : "#/$defs/CJ1TypePackageSearchParameters"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "TypePackageSearchBegin"
            }
          },
          "required" : [ "@type", "parameters" ]
        },
        "CJ1CommandTypePackageSearchNext" : {
          "description" : "Get the next page of type packages.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "TypePackageSearchNext"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandTypePackageSearchPrevious" : {
          "description" : "Get the previous page of type packages.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "TypePackageSearchPrevious"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1CommandTypePackageUninstall" : {
          "description" : "Uninstall a type package.",
          "type" : "object",
          "properties" : {
            "uninstall" : {
              "description" : "The type package uninstall parameters.",
              "$ref" : "#/$defs/CJ1TypePackageUninstall"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "TypePackageUninstall"
            }
          },
          "required" : [ "@type", "uninstall" ]
        },
        "CJ1CommandTypePackageUpgrade" : {
          "description" : "Upgrade a type package.",
          "type" : "object",
          "properties" : {
            "text" : {
              "description" : "The type package text.",
              "$ref" : "#/$defs/String"
            },
            "typeRemovalBehavior" : {
              "description" : "The type removal behavior.",
              "$ref" : "#/$defs/CJ1TypePackageTypeRemovalBehavior"
            },
            "versionBehavior" : {
              "description" : "The type version behavior.",
              "$ref" : "#/$defs/CJ1TypePackageVersionBehavior"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "TypePackageUpgrade"
            }
          },
          "required" : [ "@type", "text", "typeRemovalBehavior", "versionBehavior" ]
        },
        "CJ1ComparisonExactAnything<RDottedName>" : {
          "description" : "Match anything.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "Anything"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1ComparisonExactAnything<String>" : {
          "description" : "Match anything.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "Anything"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1ComparisonExactAnything<UUID>" : {
          "description" : "Match anything.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "Anything"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1ComparisonExactIsEqualTo<RDottedName>" : {
          "description" : "Matches values exactly equal to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/RDottedName"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonExactIsEqualTo<String>" : {
          "description" : "Matches values exactly equal to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonExactIsEqualTo<UUID>" : {
          "description" : "Matches values exactly equal to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonExactIsNotEqualTo<RDottedName>" : {
          "description" : "Matches values not equal to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/RDottedName"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsNotEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonExactIsNotEqualTo<String>" : {
          "description" : "Matches values not equal to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsNotEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonExactIsNotEqualTo<UUID>" : {
          "description" : "Matches values not equal to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsNotEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonExactType<RDottedName>" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1ComparisonExactAnything<RDottedName>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonExactIsEqualTo<RDottedName>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonExactIsNotEqualTo<RDottedName>"
          } ]
        },
        "CJ1ComparisonExactType<String>" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1ComparisonExactAnything<String>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonExactIsEqualTo<String>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonExactIsNotEqualTo<String>"
          } ]
        },
        "CJ1ComparisonExactType<UUID>" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1ComparisonExactAnything<UUID>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonExactIsEqualTo<UUID>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonExactIsNotEqualTo<UUID>"
          } ]
        },
        "CJ1ComparisonFuzzyAnything<String>" : {
          "description" : "Match anything.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "Anything"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1ComparisonFuzzyIsEqualTo<String>" : {
          "description" : "Matches values exactly equal to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonFuzzyIsNotEqualTo<String>" : {
          "description" : "Matches values not equal to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsNotEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonFuzzyIsNotSimilarTo<String>" : {
          "description" : "Matches values not similar to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsNotSimilarTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonFuzzyIsSimilarTo<String>" : {
          "description" : "Matches values similar to the given value.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsSimilarTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonFuzzyType<String>" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1ComparisonFuzzyAnything<String>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonFuzzyIsEqualTo<String>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonFuzzyIsNotEqualTo<String>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonFuzzyIsNotSimilarTo<String>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonFuzzyIsSimilarTo<String>"
          } ]
        },
        "CJ1ComparisonSetAnything<CJ1TypeRecordIdentifier>" : {
          "description" : "Match anything.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "Anything"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1ComparisonSetIsEqualTo<CJ1TypeRecordIdentifier>" : {
          "description" : "Match sets equal to the given set.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonSetIsNotEqualTo<CJ1TypeRecordIdentifier>" : {
          "description" : "Match sets not equal to the given set.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsNotEqualTo"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonSetIsOverlapping<CJ1TypeRecordIdentifier>" : {
          "description" : "Match sets overlapping the given set.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsOverlapping"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonSetIsSubsetOf<CJ1TypeRecordIdentifier>" : {
          "description" : "Match sets that are a subset of the given set.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsSubsetOf"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonSetIsSupersetOf<CJ1TypeRecordIdentifier>" : {
          "description" : "Match sets that are a superset of the given set.",
          "type" : "object",
          "properties" : {
            "value" : {
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IsSupersetOf"
            }
          },
          "required" : [ "@type", "value" ]
        },
        "CJ1ComparisonSetType<CJ1TypeRecordIdentifier>" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1ComparisonSetAnything<CJ1TypeRecordIdentifier>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonSetIsEqualTo<CJ1TypeRecordIdentifier>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonSetIsNotEqualTo<CJ1TypeRecordIdentifier>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonSetIsOverlapping<CJ1TypeRecordIdentifier>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonSetIsSubsetOf<CJ1TypeRecordIdentifier>"
          }, {
            "$ref" : "#/$defs/CJ1ComparisonSetIsSupersetOf<CJ1TypeRecordIdentifier>"
          } ]
        },
        "CJ1FileColumn" : {
          "type" : "string",
          "enum" : [ "BY_ID", "BY_DESCRIPTION" ]
        },
        "CJ1FileColumnOrdering" : {
          "type" : "object",
          "properties" : {
            "ascending" : {
              "$ref" : "#/$defs/boolean"
            },
            "column" : {
              "description" : "The column used to order results.",
              "$ref" : "#/$defs/CJ1FileColumn"
            }
          },
          "required" : [ "ascending", "column" ]
        },
        "CJ1FileSearchParameters" : {
          "description" : "Parameters to search for files.",
          "type" : "object",
          "properties" : {
            "matchDescription" : {
              "description" : "Include files with descriptions matching the given expression.",
              "$ref" : "#/$defs/CJ1ComparisonFuzzyType<String>"
            },
            "matchMediaType" : {
              "description" : "Include files with media types matching the given expression.",
              "$ref" : "#/$defs/CJ1ComparisonFuzzyType<String>"
            },
            "matchSizeRange" : {
              "description" : "Include files with sizes matching the given expression.",
              "$ref" : "#/$defs/CJ1SizeRange"
            },
            "orderBy" : {
              "description" : "The result ordering.",
              "$ref" : "#/$defs/CJ1FileColumnOrdering"
            },
            "pageSize" : {
              "description" : "The maximum number of results per page.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            }
          },
          "required" : [ "matchDescription", "matchMediaType", "matchSizeRange", "orderBy", "pageSize" ]
        },
        "CJ1FileType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1FileWithData"
          }, {
            "$ref" : "#/$defs/CJ1FileWithoutData"
          } ]
        },
        "CJ1FileWithData" : {
          "description" : "A file with the data included.",
          "type" : "object",
          "properties" : {
            "data" : {
              "description" : "The file data.",
              "$ref" : "#/$defs/byte[]"
            },
            "description" : {
              "description" : "The file description.",
              "$ref" : "#/$defs/String"
            },
            "hashAlgorithm" : {
              "description" : "The file hash algorithm.",
              "$ref" : "#/$defs/String"
            },
            "hashValue" : {
              "description" : "The file hash value.",
              "$ref" : "#/$defs/String"
            },
            "id" : {
              "description" : "The file ID.",
              "$ref" : "#/$defs/UUID"
            },
            "mediaType" : {
              "description" : "The file media type.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "FileWithData"
            }
          },
          "required" : [ "@type", "data", "description", "hashAlgorithm", "hashValue", "id", "mediaType" ]
        },
        "CJ1FileWithoutData" : {
          "description" : "A file without the data included.",
          "type" : "object",
          "properties" : {
            "description" : {
              "description" : "The file description.",
              "$ref" : "#/$defs/String"
            },
            "hashAlgorithm" : {
              "description" : "The file hash algorithm.",
              "$ref" : "#/$defs/String"
            },
            "hashValue" : {
              "description" : "The file hash value.",
              "$ref" : "#/$defs/String"
            },
            "id" : {
              "description" : "The file ID.",
              "$ref" : "#/$defs/UUID"
            },
            "mediaType" : {
              "description" : "The file media type.",
              "$ref" : "#/$defs/String"
            },
            "size" : {
              "description" : "The file size.",
              "$ref" : "#/$defs/long"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "FileWithoutData"
            }
          },
          "required" : [ "@type", "description", "hashAlgorithm", "hashValue", "id", "mediaType", "size" ]
        },
        "CJ1IncludeDeleted" : {
          "type" : "string",
          "enum" : [ "INCLUDE_ONLY_LIVE", "INCLUDE_ONLY_DELETED", "INCLUDE_BOTH_LIVE_AND_DELETED" ]
        },
        "CJ1Item" : {
          "description" : "An item.",
          "type" : "object",
          "properties" : {
            "attachments" : {
              "description" : "The item attachments.",
              "$ref" : "#/$defs/List<CJ1AttachmentItem>"
            },
            "id" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "metadata" : {
              "description" : "The item metadata.",
              "$ref" : "#/$defs/Map<CJ1TypeRecordFieldIdentifier,CJ1MetadataType>"
            },
            "name" : {
              "description" : "The item name.",
              "$ref" : "#/$defs/String"
            },
            "timeCreated" : {
              "description" : "The item creation time.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "timeUpdated" : {
              "description" : "The item most recent update time.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "types" : {
              "description" : "The item types.",
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            }
          },
          "required" : [ "id", "name", "timeCreated", "timeUpdated" ]
        },
        "CJ1ItemColumn" : {
          "type" : "string",
          "enum" : [ "BY_ID", "BY_NAME" ]
        },
        "CJ1ItemColumnOrdering" : {
          "type" : "object",
          "properties" : {
            "ascending" : {
              "$ref" : "#/$defs/boolean"
            },
            "column" : {
              "description" : "The column used to order results.",
              "$ref" : "#/$defs/CJ1ItemColumn"
            }
          },
          "required" : [ "ascending", "column" ]
        },
        "CJ1ItemSearchParameters" : {
          "description" : "Parameters to search for items.",
          "type" : "object",
          "properties" : {
            "includeDeleted" : {
              "description" : "Include deleted items.",
              "$ref" : "#/$defs/CJ1IncludeDeleted"
            },
            "matchDescription" : {
              "description" : "Include items with descriptions matching the given expression.",
              "$ref" : "#/$defs/CJ1ComparisonFuzzyType<String>"
            },
            "matchMetadata" : {
              "description" : "Include items with metadata matching the given expression.",
              "$ref" : "#/$defs/CJ1MetadataElementMatchType"
            },
            "matchName" : {
              "description" : "Include items with names matching the given expression.",
              "$ref" : "#/$defs/CJ1ComparisonFuzzyType<String>"
            },
            "matchTypes" : {
              "description" : "Include items with types matching the given expression.",
              "$ref" : "#/$defs/CJ1ComparisonSetType<CJ1TypeRecordIdentifier>"
            },
            "orderBy" : {
              "description" : "The result ordering.",
              "$ref" : "#/$defs/CJ1ItemColumnOrdering"
            },
            "pageSize" : {
              "description" : "The maximum number of results per page.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            }
          },
          "required" : [ "includeDeleted", "matchDescription", "matchMetadata", "matchName", "matchTypes", "orderBy", "pageSize" ]
        },
        "CJ1ItemSerial" : {
          "description" : "A serial number.",
          "type" : "object",
          "properties" : {
            "type" : {
              "description" : "The serial number type.",
              "$ref" : "#/$defs/RDottedName"
            },
            "value" : {
              "description" : "The serial number value.",
              "$ref" : "#/$defs/String"
            }
          },
          "required" : [ "type", "value" ]
        },
        "CJ1ItemSummary" : {
          "description" : "An item summary.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The item ID.",
              "$ref" : "#/$defs/UUID"
            },
            "name" : {
              "description" : "The item name.",
              "$ref" : "#/$defs/String"
            },
            "timeCreated" : {
              "description" : "The item creation time.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "timeUpdated" : {
              "description" : "The item most recent update time.",
              "$ref" : "#/$defs/OffsetDateTime"
            }
          },
          "required" : [ "id", "name", "timeCreated", "timeUpdated" ]
        },
        "CJ1Location" : {
          "description" : "A location.",
          "type" : "object",
          "properties" : {
            "attachments" : {
              "description" : "The location attachments.",
              "$ref" : "#/$defs/List<CJ1AttachmentItem>"
            },
            "id" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "metadata" : {
              "description" : "The location metadata.",
              "$ref" : "#/$defs/Map<CJ1TypeRecordFieldIdentifier,CJ1MetadataType>"
            },
            "parent" : {
              "description" : "The location parent.",
              "$ref" : "#/$defs/Optional<UUID>"
            },
            "path" : {
              "description" : "The location path.",
              "$ref" : "#/$defs/List<String>"
            },
            "timeCreated" : {
              "description" : "The location creation time.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "timeUpdated" : {
              "description" : "The location most recent update time.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "types" : {
              "description" : "The location types.",
              "$ref" : "#/$defs/Set<CJ1TypeRecordIdentifier>"
            }
          },
          "required" : [ "id", "path", "timeCreated", "timeUpdated" ]
        },
        "CJ1LocationMatchAll" : {
          "description" : "Match all locations.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "All"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1LocationMatchExact" : {
          "description" : "Match an exact location.",
          "type" : "object",
          "properties" : {
            "location" : {
              "description" : "The location.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Exact"
            }
          },
          "required" : [ "@type", "location" ]
        },
        "CJ1LocationMatchType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1LocationMatchAll"
          }, {
            "$ref" : "#/$defs/CJ1LocationMatchExact"
          }, {
            "$ref" : "#/$defs/CJ1LocationMatchWithDescendants"
          } ]
        },
        "CJ1LocationMatchWithDescendants" : {
          "description" : "Match an exact location and descendants of that location.",
          "type" : "object",
          "properties" : {
            "location" : {
              "description" : "The location.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "WithDescendants"
            }
          },
          "required" : [ "@type", "location" ]
        },
        "CJ1LocationSummary" : {
          "description" : "A location summary.",
          "type" : "object",
          "properties" : {
            "id" : {
              "description" : "The location ID.",
              "$ref" : "#/$defs/UUID"
            },
            "parent" : {
              "description" : "The location parent.",
              "$ref" : "#/$defs/Optional<UUID>"
            },
            "path" : {
              "description" : "The location path.",
              "$ref" : "#/$defs/List<String>"
            },
            "timeCreated" : {
              "description" : "The location creation time.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "timeUpdated" : {
              "description" : "The location most recent update time.",
              "$ref" : "#/$defs/OffsetDateTime"
            }
          },
          "required" : [ "id", "timeCreated", "timeUpdated" ]
        },
        "CJ1MessageType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1CommandType"
          }, {
            "$ref" : "#/$defs/CJ1ResponseType"
          }, {
            "$ref" : "#/$defs/CJ1Transaction"
          }, {
            "$ref" : "#/$defs/CJ1TransactionResponse"
          } ]
        },
        "CJ1MetadataElementMatchAnd" : {
          "description" : "Match metadata elements that match both expressions.",
          "type" : "object",
          "properties" : {
            "expression0" : {
              "description" : "The left expression.",
              "$ref" : "#/$defs/CJ1MetadataElementMatchType"
            },
            "expression1" : {
              "description" : "The right expression.",
              "$ref" : "#/$defs/CJ1MetadataElementMatchType"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "And"
            }
          },
          "required" : [ "@type", "expression0", "expression1" ]
        },
        "CJ1MetadataElementMatchOr" : {
          "description" : "Match metadata elements that match either expression.",
          "type" : "object",
          "properties" : {
            "expression0" : {
              "description" : "The left expression.",
              "$ref" : "#/$defs/CJ1MetadataElementMatchType"
            },
            "expression1" : {
              "description" : "The right expression.",
              "$ref" : "#/$defs/CJ1MetadataElementMatchType"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Or"
            }
          },
          "required" : [ "@type", "expression0", "expression1" ]
        },
        "CJ1MetadataElementMatchSpecific" : {
          "description" : "Match specific metadata elements.",
          "type" : "object",
          "properties" : {
            "fieldName" : {
              "description" : "An expression that matches metadata field names.",
              "$ref" : "#/$defs/CJ1ComparisonExactType<String>"
            },
            "packageName" : {
              "description" : "An expression that matches metadata package names.",
              "$ref" : "#/$defs/CJ1ComparisonExactType<RDottedName>"
            },
            "typeName" : {
              "description" : "An expression that matches metadata type names.",
              "$ref" : "#/$defs/CJ1ComparisonExactType<String>"
            },
            "value" : {
              "description" : "An expression that matches metadata values.",
              "$ref" : "#/$defs/CJ1MetadataValueMatchType"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Specific"
            }
          },
          "required" : [ "@type", "fieldName", "packageName", "typeName", "value" ]
        },
        "CJ1MetadataElementMatchType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1MetadataElementMatchAnd"
          }, {
            "$ref" : "#/$defs/CJ1MetadataElementMatchOr"
          }, {
            "$ref" : "#/$defs/CJ1MetadataElementMatchSpecific"
          } ]
        },
        "CJ1MetadataIntegral" : {
          "description" : "An integral metadata value.",
          "type" : "object",
          "properties" : {
            "name" : {
              "description" : "The metadata field name.",
              "$ref" : "#/$defs/CJ1TypeRecordFieldIdentifier"
            },
            "value" : {
              "description" : "The metadata value.",
              "$ref" : "#/$defs/long"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Integral"
            }
          },
          "required" : [ "@type", "name", "value" ]
        },
        "CJ1MetadataMonetary" : {
          "description" : "A monetary metadata value.",
          "type" : "object",
          "properties" : {
            "currency" : {
              "description" : "The metadata currency value.",
              "$ref" : "#/$defs/CurrencyUnit"
            },
            "name" : {
              "description" : "The metadata field name.",
              "$ref" : "#/$defs/CJ1TypeRecordFieldIdentifier"
            },
            "value" : {
              "description" : "The metadata value.",
              "$ref" : "#/$defs/BigDecimal"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Monetary"
            }
          },
          "required" : [ "@type", "currency", "name", "value" ]
        },
        "CJ1MetadataReal" : {
          "description" : "A real metadata value.",
          "type" : "object",
          "properties" : {
            "name" : {
              "description" : "The metadata field name.",
              "$ref" : "#/$defs/CJ1TypeRecordFieldIdentifier"
            },
            "value" : {
              "description" : "The metadata value.",
              "$ref" : "#/$defs/double"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Real"
            }
          },
          "required" : [ "@type", "name", "value" ]
        },
        "CJ1MetadataText" : {
          "description" : "A text metadata value.",
          "type" : "object",
          "properties" : {
            "name" : {
              "description" : "The metadata field name.",
              "$ref" : "#/$defs/CJ1TypeRecordFieldIdentifier"
            },
            "value" : {
              "description" : "The metadata value.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Text"
            }
          },
          "required" : [ "@type", "name", "value" ]
        },
        "CJ1MetadataTime" : {
          "description" : "A time metadata value.",
          "type" : "object",
          "properties" : {
            "name" : {
              "description" : "The metadata field name.",
              "$ref" : "#/$defs/CJ1TypeRecordFieldIdentifier"
            },
            "value" : {
              "description" : "The metadata value.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Time"
            }
          },
          "required" : [ "@type", "name", "value" ]
        },
        "CJ1MetadataType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1MetadataIntegral"
          }, {
            "$ref" : "#/$defs/CJ1MetadataMonetary"
          }, {
            "$ref" : "#/$defs/CJ1MetadataReal"
          }, {
            "$ref" : "#/$defs/CJ1MetadataText"
          }, {
            "$ref" : "#/$defs/CJ1MetadataTime"
          } ]
        },
        "CJ1MetadataValueMatchAnyValue" : {
          "description" : "Match any metadata value.",
          "type" : "object",
          "properties" : {
            "@type" : {
              "type" : "string",
              "pattern" : "Anything"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1MetadataValueMatchIntegralType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1MetadataValueMatchIntegralWithinRange"
          } ]
        },
        "CJ1MetadataValueMatchIntegralWithinRange" : {
          "description" : "Match an integral metadata value within the given range.",
          "type" : "object",
          "properties" : {
            "lower" : {
              "description" : "The lower bound.",
              "$ref" : "#/$defs/long"
            },
            "upper" : {
              "description" : "The upper bound.",
              "$ref" : "#/$defs/long"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "IntegralWithinRange"
            }
          },
          "required" : [ "@type", "lower", "upper" ]
        },
        "CJ1MetadataValueMatchMonetaryType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1MetadataValueMatchMonetaryWithCurrency"
          }, {
            "$ref" : "#/$defs/CJ1MetadataValueMatchMonetaryWithinRange"
          } ]
        },
        "CJ1MetadataValueMatchMonetaryWithCurrency" : {
          "description" : "Match monetary metadata values with the given currency.",
          "type" : "object",
          "properties" : {
            "currency" : {
              "description" : "The currency unit.",
              "$ref" : "#/$defs/CurrencyUnit"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "MonetaryWithCurrency"
            }
          },
          "required" : [ "@type", "currency" ]
        },
        "CJ1MetadataValueMatchMonetaryWithinRange" : {
          "description" : "Match a monetary metadata value within the given range.",
          "type" : "object",
          "properties" : {
            "lower" : {
              "description" : "The lower bound.",
              "$ref" : "#/$defs/BigDecimal"
            },
            "upper" : {
              "description" : "The upper bound.",
              "$ref" : "#/$defs/BigDecimal"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "MonetaryWithinRange"
            }
          },
          "required" : [ "@type", "lower", "upper" ]
        },
        "CJ1MetadataValueMatchRealType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1MetadataValueMatchRealWithinRange"
          } ]
        },
        "CJ1MetadataValueMatchRealWithinRange" : {
          "description" : "Match a real metadata value within the given range.",
          "type" : "object",
          "properties" : {
            "lower" : {
              "description" : "The lower bound.",
              "$ref" : "#/$defs/double"
            },
            "upper" : {
              "description" : "The upper bound.",
              "$ref" : "#/$defs/double"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "RealWithinRange"
            }
          },
          "required" : [ "@type", "lower", "upper" ]
        },
        "CJ1MetadataValueMatchTextExact" : {
          "description" : "Match a text metadata value with the given text.",
          "type" : "object",
          "properties" : {
            "text" : {
              "description" : "The text value.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "TextExact"
            }
          },
          "required" : [ "@type", "text" ]
        },
        "CJ1MetadataValueMatchTextSearch" : {
          "description" : "Match a text metadata value with the given search query.",
          "type" : "object",
          "properties" : {
            "query" : {
              "description" : "The search query.",
              "$ref" : "#/$defs/String"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "TextSearch"
            }
          },
          "required" : [ "@type", "query" ]
        },
        "CJ1MetadataValueMatchTextType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1MetadataValueMatchTextExact"
          }, {
            "$ref" : "#/$defs/CJ1MetadataValueMatchTextSearch"
          } ]
        },
        "CJ1MetadataValueMatchTimeType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1MetadataValueMatchTimeWithinRange"
          } ]
        },
        "CJ1MetadataValueMatchTimeWithinRange" : {
          "description" : "Match a time metadata value within the given range.",
          "type" : "object",
          "properties" : {
            "lower" : {
              "description" : "The lower bound.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "upper" : {
              "description" : "The upper bound.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "TimeWithinRange"
            }
          },
          "required" : [ "@type", "lower", "upper" ]
        },
        "CJ1MetadataValueMatchType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1MetadataValueMatchAnyValue"
          }, {
            "$ref" : "#/$defs/CJ1MetadataValueMatchIntegralType"
          }, {
            "$ref" : "#/$defs/CJ1MetadataValueMatchMonetaryType"
          }, {
            "$ref" : "#/$defs/CJ1MetadataValueMatchRealType"
          }, {
            "$ref" : "#/$defs/CJ1MetadataValueMatchTextType"
          }, {
            "$ref" : "#/$defs/CJ1MetadataValueMatchTimeType"
          } ]
        },
        "CJ1Page<CJ1AuditEvent>" : {
          "description" : "A page of results.",
          "type" : "object",
          "properties" : {
            "items" : {
              "description" : "The results.",
              "$ref" : "#/$defs/List<CJ1AuditEvent>"
            },
            "pageCount" : {
              "description" : "The total number of pages.",
              "$ref" : "#/$defs/CJ1UnsignedInt"
            },
            "pageFirstOffset" : {
              "description" : "The offset of the first result in the page.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "pageIndex" : {
              "description" : "The page number.",
              "$ref" : "#/$defs/CJ1UnsignedInt"
            }
          },
          "required" : [ "items", "pageCount", "pageFirstOffset", "pageIndex" ]
        },
        "CJ1Page<CJ1FileWithoutData>" : {
          "description" : "A page of results.",
          "type" : "object",
          "properties" : {
            "items" : {
              "description" : "The results.",
              "$ref" : "#/$defs/List<CJ1FileWithoutData>"
            },
            "pageCount" : {
              "description" : "The total number of pages.",
              "$ref" : "#/$defs/CJ1UnsignedInt"
            },
            "pageFirstOffset" : {
              "description" : "The offset of the first result in the page.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "pageIndex" : {
              "description" : "The page number.",
              "$ref" : "#/$defs/CJ1UnsignedInt"
            }
          },
          "required" : [ "items", "pageCount", "pageFirstOffset", "pageIndex" ]
        },
        "CJ1Page<CJ1ItemSummary>" : {
          "description" : "A page of results.",
          "type" : "object",
          "properties" : {
            "items" : {
              "description" : "The results.",
              "$ref" : "#/$defs/List<CJ1ItemSummary>"
            },
            "pageCount" : {
              "description" : "The total number of pages.",
              "$ref" : "#/$defs/CJ1UnsignedInt"
            },
            "pageFirstOffset" : {
              "description" : "The offset of the first result in the page.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "pageIndex" : {
              "description" : "The page number.",
              "$ref" : "#/$defs/CJ1UnsignedInt"
            }
          },
          "required" : [ "items", "pageCount", "pageFirstOffset", "pageIndex" ]
        },
        "CJ1Page<CJ1StockOccurrenceType>" : {
          "description" : "A page of results.",
          "type" : "object",
          "properties" : {
            "items" : {
              "description" : "The results.",
              "$ref" : "#/$defs/List<CJ1StockOccurrenceType>"
            },
            "pageCount" : {
              "description" : "The total number of pages.",
              "$ref" : "#/$defs/CJ1UnsignedInt"
            },
            "pageFirstOffset" : {
              "description" : "The offset of the first result in the page.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "pageIndex" : {
              "description" : "The page number.",
              "$ref" : "#/$defs/CJ1UnsignedInt"
            }
          },
          "required" : [ "items", "pageCount", "pageFirstOffset", "pageIndex" ]
        },
        "CJ1ResponseAuditSearch" : {
          "description" : "A response to AuditSearch.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "results" : {
              "$ref" : "#/$defs/CJ1Page<CJ1AuditEvent>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseAuditSearch"
            }
          },
          "required" : [ "@type", "requestId", "results" ]
        },
        "CJ1ResponseBlame" : {
          "type" : "string",
          "enum" : [ "BLAME_CLIENT", "BLAME_SERVER" ]
        },
        "CJ1ResponseError" : {
          "type" : "object",
          "properties" : {
            "attributes" : {
              "$ref" : "#/$defs/Map<String,String>"
            },
            "blame" : {
              "$ref" : "#/$defs/CJ1ResponseBlame"
            },
            "errorCode" : {
              "$ref" : "#/$defs/CAErrorCode"
            },
            "extras" : {
              "$ref" : "#/$defs/List<CJ1StructuredError>"
            },
            "message" : {
              "$ref" : "#/$defs/String"
            },
            "remediatingAction" : {
              "$ref" : "#/$defs/Optional<String>"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseError"
            }
          },
          "required" : [ "@type", "errorCode", "message", "requestId" ]
        },
        "CJ1ResponseFileDelete" : {
          "description" : "A response to FileDelete.",
          "type" : "object",
          "properties" : {
            "file" : {
              "$ref" : "#/$defs/UUID"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseFileDelete"
            }
          },
          "required" : [ "@type", "file", "requestId" ]
        },
        "CJ1ResponseFileGet" : {
          "description" : "A response to FileGet.",
          "type" : "object",
          "properties" : {
            "file" : {
              "$ref" : "#/$defs/CJ1FileWithoutData"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseFileGet"
            }
          },
          "required" : [ "@type", "file", "requestId" ]
        },
        "CJ1ResponseFilePut" : {
          "description" : "A response to FilePut.",
          "type" : "object",
          "properties" : {
            "file" : {
              "$ref" : "#/$defs/CJ1FileType"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseFilePut"
            }
          },
          "required" : [ "@type", "file", "requestId" ]
        },
        "CJ1ResponseFileSearch" : {
          "description" : "A response to FileSearch.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "results" : {
              "$ref" : "#/$defs/CJ1Page<CJ1FileWithoutData>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseFileSearch"
            }
          },
          "required" : [ "@type", "requestId", "results" ]
        },
        "CJ1ResponseItemAttachmentAdd" : {
          "description" : "A response to ItemAttachmentAdd.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/CJ1Item"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemAttachmentAdd"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseItemAttachmentRemove" : {
          "description" : "A response to ItemAttachmentRemove.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/CJ1Item"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemAttachmentRemove"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseItemCreate" : {
          "description" : "A response to ItemCreate.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/CJ1Item"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemCreate"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseItemDelete" : {
          "description" : "A response to ItemDelete.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/UUID"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemDelete"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseItemGet" : {
          "description" : "A response to ItemGet.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/CJ1Item"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemGet"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseItemMetadataPut" : {
          "description" : "A response to ItemMetadataPut.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/CJ1Item"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemMetadataPut"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseItemMetadataRemove" : {
          "description" : "A response to ItemMetadataRemove.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/CJ1Item"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemMetadataRemove"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseItemSearch" : {
          "description" : "A response to ItemSearch.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "results" : {
              "$ref" : "#/$defs/CJ1Page<CJ1ItemSummary>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemSearch"
            }
          },
          "required" : [ "@type", "requestId", "results" ]
        },
        "CJ1ResponseItemSetName" : {
          "description" : "A response to ItemSetName.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/CJ1Item"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemSetName"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseItemTypesAssign" : {
          "description" : "A response to ItemTypesAssign.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/CJ1Item"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemTypesAssign"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseItemTypesRevoke" : {
          "description" : "A response to ItemTypesRevoke.",
          "type" : "object",
          "properties" : {
            "item" : {
              "$ref" : "#/$defs/CJ1Item"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseItemTypesRevoke"
            }
          },
          "required" : [ "@type", "item", "requestId" ]
        },
        "CJ1ResponseLocationAttachmentAdd" : {
          "description" : "A response to LocationAttachmentAdd.",
          "type" : "object",
          "properties" : {
            "location" : {
              "$ref" : "#/$defs/CJ1Location"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationAttachmentAdd"
            }
          },
          "required" : [ "@type", "location", "requestId" ]
        },
        "CJ1ResponseLocationAttachmentRemove" : {
          "description" : "A response to LocationAttachmentRemove.",
          "type" : "object",
          "properties" : {
            "location" : {
              "$ref" : "#/$defs/CJ1Location"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationAttachmentRemove"
            }
          },
          "required" : [ "@type", "location", "requestId" ]
        },
        "CJ1ResponseLocationDelete" : {
          "description" : "A response to LocationDelete.",
          "type" : "object",
          "properties" : {
            "location" : {
              "$ref" : "#/$defs/UUID"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationDelete"
            }
          },
          "required" : [ "@type", "location", "requestId" ]
        },
        "CJ1ResponseLocationGet" : {
          "description" : "A response to LocationGet.",
          "type" : "object",
          "properties" : {
            "location" : {
              "$ref" : "#/$defs/CJ1Location"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationGet"
            }
          },
          "required" : [ "@type", "location", "requestId" ]
        },
        "CJ1ResponseLocationList" : {
          "description" : "A response to LocationList.",
          "type" : "object",
          "properties" : {
            "locations" : {
              "$ref" : "#/$defs/Map<UUID,CJ1LocationSummary>"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationList"
            }
          },
          "required" : [ "@type", "requestId" ]
        },
        "CJ1ResponseLocationMetadataPut" : {
          "description" : "A response to LocationMetadataPut.",
          "type" : "object",
          "properties" : {
            "location" : {
              "$ref" : "#/$defs/CJ1Location"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationMetadataPut"
            }
          },
          "required" : [ "@type", "location", "requestId" ]
        },
        "CJ1ResponseLocationMetadataRemove" : {
          "description" : "A response to LocationMetadataRemove.",
          "type" : "object",
          "properties" : {
            "location" : {
              "$ref" : "#/$defs/CJ1Location"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationMetadataRemove"
            }
          },
          "required" : [ "@type", "location", "requestId" ]
        },
        "CJ1ResponseLocationPut" : {
          "description" : "A response to LocationPut.",
          "type" : "object",
          "properties" : {
            "location" : {
              "$ref" : "#/$defs/CJ1Location"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationPut"
            }
          },
          "required" : [ "@type", "location", "requestId" ]
        },
        "CJ1ResponseLocationTypesAssign" : {
          "description" : "A response to LocationTypesAssign.",
          "type" : "object",
          "properties" : {
            "location" : {
              "$ref" : "#/$defs/CJ1Location"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationTypesAssign"
            }
          },
          "required" : [ "@type", "location", "requestId" ]
        },
        "CJ1ResponseLocationTypesRevoke" : {
          "description" : "A response to LocationTypesRevoke.",
          "type" : "object",
          "properties" : {
            "location" : {
              "$ref" : "#/$defs/CJ1Location"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLocationTypesRevoke"
            }
          },
          "required" : [ "@type", "location", "requestId" ]
        },
        "CJ1ResponseLogin" : {
          "description" : "A response to Login.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "userId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseLogin"
            }
          },
          "required" : [ "@type", "requestId", "userId" ]
        },
        "CJ1ResponseRolesAssign" : {
          "description" : "A response to RolesAssign.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseRolesAssign"
            }
          },
          "required" : [ "@type", "requestId" ]
        },
        "CJ1ResponseRolesGet" : {
          "description" : "A response to RolesGet.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "roles" : {
              "$ref" : "#/$defs/Set<String>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseRolesGet"
            }
          },
          "required" : [ "@type", "requestId" ]
        },
        "CJ1ResponseRolesRevoke" : {
          "description" : "A response to RolesRevoke.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseRolesRevoke"
            }
          },
          "required" : [ "@type", "requestId" ]
        },
        "CJ1ResponseStockCount" : {
          "description" : "A response to StockCount.",
          "type" : "object",
          "properties" : {
            "count" : {
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseStockCount"
            }
          },
          "required" : [ "@type", "count", "requestId" ]
        },
        "CJ1ResponseStockReposit" : {
          "description" : "A response to StockReposit.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "stockOccurrence" : {
              "$ref" : "#/$defs/Optional<CJ1StockOccurrenceType>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseStockReposit"
            }
          },
          "required" : [ "@type", "requestId" ]
        },
        "CJ1ResponseStockSearch" : {
          "description" : "A response to StockSearch.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "results" : {
              "$ref" : "#/$defs/CJ1Page<CJ1StockOccurrenceType>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseStockSearch"
            }
          },
          "required" : [ "@type", "requestId", "results" ]
        },
        "CJ1ResponseType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1ResponseAuditSearch"
          }, {
            "$ref" : "#/$defs/CJ1ResponseError"
          }, {
            "$ref" : "#/$defs/CJ1ResponseFileDelete"
          }, {
            "$ref" : "#/$defs/CJ1ResponseFileGet"
          }, {
            "$ref" : "#/$defs/CJ1ResponseFilePut"
          }, {
            "$ref" : "#/$defs/CJ1ResponseFileSearch"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemAttachmentAdd"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemAttachmentRemove"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemCreate"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemDelete"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemGet"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemMetadataPut"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemMetadataRemove"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemSearch"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemSetName"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemTypesAssign"
          }, {
            "$ref" : "#/$defs/CJ1ResponseItemTypesRevoke"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationAttachmentAdd"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationAttachmentRemove"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationDelete"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationGet"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationList"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationMetadataPut"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationMetadataRemove"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationPut"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationTypesAssign"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLocationTypesRevoke"
          }, {
            "$ref" : "#/$defs/CJ1ResponseLogin"
          }, {
            "$ref" : "#/$defs/CJ1ResponseRolesAssign"
          }, {
            "$ref" : "#/$defs/CJ1ResponseRolesGet"
          }, {
            "$ref" : "#/$defs/CJ1ResponseRolesRevoke"
          }, {
            "$ref" : "#/$defs/CJ1ResponseStockCount"
          }, {
            "$ref" : "#/$defs/CJ1ResponseStockReposit"
          }, {
            "$ref" : "#/$defs/CJ1ResponseStockSearch"
          }, {
            "$ref" : "#/$defs/CJ1ResponseTypePackageGetText"
          }, {
            "$ref" : "#/$defs/CJ1ResponseTypePackageInstall"
          }, {
            "$ref" : "#/$defs/CJ1ResponseTypePackageSearch"
          }, {
            "$ref" : "#/$defs/CJ1ResponseTypePackageUninstall"
          }, {
            "$ref" : "#/$defs/CJ1ResponseTypePackageUpgrade"
          } ]
        },
        "CJ1ResponseTypePackageGetText" : {
          "description" : "A response to TypePackageGetText.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseTypePackageGetText"
            }
          },
          "required" : [ "@type", "requestId" ]
        },
        "CJ1ResponseTypePackageInstall" : {
          "description" : "A response to TypePackageInstall.",
          "type" : "object",
          "properties" : {
            "identifier" : {
              "$ref" : "#/$defs/CJ1TypePackageIdentifier"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseTypePackageInstall"
            }
          },
          "required" : [ "@type", "identifier", "requestId" ]
        },
        "CJ1ResponseTypePackageSearch" : {
          "description" : "A response to TypePackageSearch.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseTypePackageSearch"
            }
          },
          "required" : [ "@type", "requestId" ]
        },
        "CJ1ResponseTypePackageUninstall" : {
          "description" : "A response to TypePackageUninstall.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseTypePackageUninstall"
            }
          },
          "required" : [ "@type", "requestId" ]
        },
        "CJ1ResponseTypePackageUpgrade" : {
          "description" : "A response to TypePackageUpgrade.",
          "type" : "object",
          "properties" : {
            "identifier" : {
              "$ref" : "#/$defs/CJ1TypePackageIdentifier"
            },
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "ResponseTypePackageUpgrade"
            }
          },
          "required" : [ "@type", "identifier", "requestId" ]
        },
        "CJ1SizeRange" : {
          "type" : "object",
          "properties" : {
            "sizeMaximum" : {
              "description" : "The inclusive upper bound.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "sizeMinimum" : {
              "description" : "The inclusive lower bound.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            }
          },
          "required" : [ "sizeMaximum", "sizeMinimum" ]
        },
        "CJ1StockOccurrenceKind" : {
          "type" : "string",
          "enum" : [ "SERIAL", "SET" ]
        },
        "CJ1StockOccurrenceSerial" : {
          "type" : "object",
          "properties" : {
            "instance" : {
              "$ref" : "#/$defs/UUID"
            },
            "item" : {
              "$ref" : "#/$defs/CJ1ItemSummary"
            },
            "location" : {
              "$ref" : "#/$defs/CJ1LocationSummary"
            },
            "serials" : {
              "$ref" : "#/$defs/List<CJ1ItemSerial>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Serial"
            }
          },
          "required" : [ "@type", "instance", "item", "location" ]
        },
        "CJ1StockOccurrenceSet" : {
          "type" : "object",
          "properties" : {
            "count" : {
              "$ref" : "#/$defs/long"
            },
            "instance" : {
              "$ref" : "#/$defs/UUID"
            },
            "item" : {
              "$ref" : "#/$defs/CJ1ItemSummary"
            },
            "location" : {
              "$ref" : "#/$defs/CJ1LocationSummary"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Set"
            }
          },
          "required" : [ "@type", "count", "instance", "item", "location" ]
        },
        "CJ1StockOccurrenceType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1StockOccurrenceSerial"
          }, {
            "$ref" : "#/$defs/CJ1StockOccurrenceSet"
          } ]
        },
        "CJ1StockRepositRemove" : {
          "description" : "Remove the given stock occurrence.",
          "type" : "object",
          "properties" : {
            "instance" : {
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Remove"
            }
          },
          "required" : [ "@type", "instance" ]
        },
        "CJ1StockRepositSerialIntroduce" : {
          "description" : "Introduce a new serial stock occurrence.",
          "type" : "object",
          "properties" : {
            "instance" : {
              "description" : "The stock occurrence.",
              "$ref" : "#/$defs/UUID"
            },
            "item" : {
              "description" : "The item.",
              "$ref" : "#/$defs/UUID"
            },
            "location" : {
              "description" : "The location.",
              "$ref" : "#/$defs/UUID"
            },
            "serial" : {
              "description" : "The serial number.",
              "$ref" : "#/$defs/CJ1ItemSerial"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "SerialIntroduce"
            }
          },
          "required" : [ "@type", "instance", "item", "location", "serial" ]
        },
        "CJ1StockRepositSerialMove" : {
          "description" : "Move a serial stock occurrence to a new location.",
          "type" : "object",
          "properties" : {
            "instance" : {
              "description" : "The stock occurrence.",
              "$ref" : "#/$defs/UUID"
            },
            "toLocation" : {
              "description" : "The new location.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "SerialMove"
            }
          },
          "required" : [ "@type", "instance", "toLocation" ]
        },
        "CJ1StockRepositSerialNumberAdd" : {
          "description" : "Add a new serial number to a stock occurrence.",
          "type" : "object",
          "properties" : {
            "instance" : {
              "description" : "The stock occurrence.",
              "$ref" : "#/$defs/UUID"
            },
            "serial" : {
              "description" : "The serial number.",
              "$ref" : "#/$defs/CJ1ItemSerial"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "SerialNumberAdd"
            }
          },
          "required" : [ "@type", "instance", "serial" ]
        },
        "CJ1StockRepositSerialNumberRemove" : {
          "description" : "Remove a serial number from a stock occurrence.",
          "type" : "object",
          "properties" : {
            "instance" : {
              "description" : "The stock occurrence.",
              "$ref" : "#/$defs/UUID"
            },
            "serial" : {
              "description" : "The serial number.",
              "$ref" : "#/$defs/CJ1ItemSerial"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "SerialNumberRemove"
            }
          },
          "required" : [ "@type", "instance", "serial" ]
        },
        "CJ1StockRepositSetAdd" : {
          "description" : "Add to an existing set stock occurrence.",
          "type" : "object",
          "properties" : {
            "count" : {
              "description" : "The number of items to add.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "instance" : {
              "description" : "The stock occurrence.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "SetAdd"
            }
          },
          "required" : [ "@type", "count", "instance" ]
        },
        "CJ1StockRepositSetIntroduce" : {
          "description" : "Introduce a new set stock occurrence.",
          "type" : "object",
          "properties" : {
            "count" : {
              "description" : "The number of items to introduce.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "instance" : {
              "description" : "The stock occurrence.",
              "$ref" : "#/$defs/UUID"
            },
            "item" : {
              "description" : "The item.",
              "$ref" : "#/$defs/UUID"
            },
            "location" : {
              "description" : "The location.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "SetIntroduce"
            }
          },
          "required" : [ "@type", "count", "instance", "item", "location" ]
        },
        "CJ1StockRepositSetMove" : {
          "description" : "Move between stock occurrences.",
          "type" : "object",
          "properties" : {
            "count" : {
              "description" : "The number of items to move.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "instanceSource" : {
              "description" : "The source stock occurrence.",
              "$ref" : "#/$defs/UUID"
            },
            "instanceTarget" : {
              "description" : "The target stock occurrence.",
              "$ref" : "#/$defs/UUID"
            },
            "toLocation" : {
              "description" : "The new location.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "SetMove"
            }
          },
          "required" : [ "@type", "count", "instanceSource", "instanceTarget", "toLocation" ]
        },
        "CJ1StockRepositSetRemove" : {
          "description" : "Remove from a set stock occurrence.",
          "type" : "object",
          "properties" : {
            "count" : {
              "description" : "The number of items to remove.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            },
            "instance" : {
              "description" : "The stock occurrence.",
              "$ref" : "#/$defs/UUID"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "SetRemove"
            }
          },
          "required" : [ "@type", "count", "instance" ]
        },
        "CJ1StockRepositType" : {
          "oneOf" : [ {
            "$ref" : "#/$defs/CJ1StockRepositRemove"
          }, {
            "$ref" : "#/$defs/CJ1StockRepositSerialIntroduce"
          }, {
            "$ref" : "#/$defs/CJ1StockRepositSerialMove"
          }, {
            "$ref" : "#/$defs/CJ1StockRepositSerialNumberAdd"
          }, {
            "$ref" : "#/$defs/CJ1StockRepositSerialNumberRemove"
          }, {
            "$ref" : "#/$defs/CJ1StockRepositSetAdd"
          }, {
            "$ref" : "#/$defs/CJ1StockRepositSetIntroduce"
          }, {
            "$ref" : "#/$defs/CJ1StockRepositSetMove"
          }, {
            "$ref" : "#/$defs/CJ1StockRepositSetRemove"
          } ]
        },
        "CJ1StockSearchParameters" : {
          "description" : "Parameters to search for stock.",
          "type" : "object",
          "properties" : {
            "includeDeleted" : {
              "description" : "Include deleted stock.",
              "$ref" : "#/$defs/CJ1IncludeDeleted"
            },
            "includeOccurrences" : {
              "description" : "Include stock of the given occurrence kinds.",
              "$ref" : "#/$defs/Set<CJ1StockOccurrenceKind>"
            },
            "matchItem" : {
              "description" : "Include stock with items matching the given expression.",
              "$ref" : "#/$defs/CJ1ComparisonExactType<UUID>"
            },
            "matchLocation" : {
              "description" : "Include stock with locations matching the given expression.",
              "$ref" : "#/$defs/CJ1LocationMatchType"
            },
            "pageSize" : {
              "description" : "The maximum number of results per page.",
              "$ref" : "#/$defs/CJ1UnsignedLong"
            }
          },
          "required" : [ "includeDeleted", "includeOccurrences", "matchItem", "matchLocation", "pageSize" ]
        },
        "CJ1StructuredError" : {
          "description" : "A structured error value.",
          "type" : "object",
          "properties" : {
            "attributes" : {
              "description" : "The error attributes.",
              "$ref" : "#/$defs/Map<String,String>"
            },
            "errorCode" : {
              "description" : "The error code.",
              "$ref" : "#/$defs/String"
            },
            "message" : {
              "description" : "The error message.",
              "$ref" : "#/$defs/String"
            },
            "remediatingAction" : {
              "description" : "The remediating action.",
              "$ref" : "#/$defs/Optional<String>"
            }
          },
          "required" : [ "errorCode", "message" ]
        },
        "CJ1TimeRange" : {
          "description" : "A range of time.",
          "type" : "object",
          "properties" : {
            "lower" : {
              "description" : "The inclusive lower bound.",
              "$ref" : "#/$defs/OffsetDateTime"
            },
            "upper" : {
              "description" : "The inclusive upper bound.",
              "$ref" : "#/$defs/OffsetDateTime"
            }
          },
          "required" : [ "lower", "upper" ]
        },
        "CJ1Transaction" : {
          "description" : "A set of commands to execute in a single transaction.",
          "type" : "object",
          "properties" : {
            "commands" : {
              "description" : "The commands that will be executed in the given order.",
              "$ref" : "#/$defs/List<CJ1CommandType>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "Transaction"
            }
          },
          "required" : [ "@type" ]
        },
        "CJ1TransactionResponse" : {
          "description" : "A transaction response.",
          "type" : "object",
          "properties" : {
            "requestId" : {
              "$ref" : "#/$defs/UUID"
            },
            "responses" : {
              "description" : "The command responses.",
              "$ref" : "#/$defs/List<CJ1ResponseType>"
            },
            "@type" : {
              "type" : "string",
              "pattern" : "TransactionResponse"
            }
          },
          "required" : [ "@type", "requestId", "responses" ]
        },
        "CJ1TypePackageIdentifier" : {
          "description" : "A type package identifier.",
          "type" : "string"
        },
        "CJ1TypePackageSearchParameters" : {
          "description" : "Parameters to search for type packages.",
          "type" : "object",
          "properties" : {
            "matchDescription" : {
              "description" : "Include packages with descriptions matching the given expression.",
              "$ref" : "#/$defs/CJ1ComparisonFuzzyType<String>"
            },
            "pageSize" : {
              "description" : "The maximum number of results per page.",
              "$ref" : "#/$defs/long"
            }
          },
          "required" : [ "matchDescription", "pageSize" ]
        },
        "CJ1TypePackageTypeRemovalBehavior" : {
          "description" : "Type package removal behavior.",
          "type" : "string",
          "enum" : [ "TYPE_REMOVAL_FAIL_IF_TYPES_REFERENCED", "TYPE_REMOVAL_REVOKE_TYPES" ]
        },
        "CJ1TypePackageUninstall" : {
          "description" : "Parameters for uninstalling type packages.",
          "type" : "object",
          "properties" : {
            "packageIdentifier" : {
              "description" : "The type package identifier.",
              "$ref" : "#/$defs/CJ1TypePackageIdentifier"
            },
            "typeRemovalBehavior" : {
              "description" : "The type removal behavior.",
              "$ref" : "#/$defs/CJ1TypePackageTypeRemovalBehavior"
            }
          },
          "required" : [ "packageIdentifier", "typeRemovalBehavior" ]
        },
        "CJ1TypePackageVersionBehavior" : {
          "description" : "Type package version behavior.",
          "type" : "string",
          "enum" : [ "VERSION_ALLOW_DOWNGRADES", "VERSION_DISALLOW_DOWNGRADES" ]
        },
        "CJ1TypeRecordFieldIdentifier" : {
          "description" : "A type record field identifier.",
          "type" : "string"
        },
        "CJ1TypeRecordIdentifier" : {
          "description" : "A type record identifier.",
          "type" : "string"
        },
        "CJ1UnsignedInt" : {
          "description" : "A 32-bit unsigned integer value.",
          "type" : "number",
          "minimum" : 0,
          "exclusiveMaximum" : 4294967296
        },
        "CJ1UnsignedLong" : {
          "description" : "A 64-bit unsigned integer value.",
          "type" : "number",
          "minimum" : 0,
          "exclusiveMaximum" : 18446744073709551616
        },
        "CurrencyUnit" : {
          "description" : "An ISO 4217 currency code.",
          "type" : "string",
          "pattern" : "[A-Z][A-Z][A-Z]"
        },
        "List<CJ1AttachmentItem>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1AttachmentItem"
          }
        },
        "List<CJ1AuditEvent>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1AuditEvent"
          }
        },
        "List<CJ1CommandType>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1CommandType"
          }
        },
        "List<CJ1FileWithoutData>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1FileWithoutData"
          }
        },
        "List<CJ1ItemSerial>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1ItemSerial"
          }
        },
        "List<CJ1ItemSummary>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1ItemSummary"
          }
        },
        "List<CJ1ResponseType>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1ResponseType"
          }
        },
        "List<CJ1StockOccurrenceType>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1StockOccurrenceType"
          }
        },
        "List<CJ1StructuredError>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1StructuredError"
          }
        },
        "List<String>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/String"
          }
        },
        "Map<CJ1TypeRecordFieldIdentifier,CJ1MetadataType>" : {
          "type" : "object",
          "additionalProperties" : {
            "$ref" : "#/$defs/CJ1MetadataType"
          }
        },
        "Map<String,String>" : {
          "type" : "object",
          "additionalProperties" : {
            "$ref" : "#/$defs/String"
          }
        },
        "Map<UUID,CJ1LocationSummary>" : {
          "type" : "object",
          "additionalProperties" : {
            "$ref" : "#/$defs/CJ1LocationSummary"
          }
        },
        "OffsetDateTime" : {
          "description" : "An ISO 8601 timestamp.",
          "type" : "string",
          "format" : "date-time"
        },
        "Optional<CJ1StockOccurrenceType>" : {
          "$ref" : "#/$defs/CJ1StockOccurrenceType"
        },
        "Optional<String>" : {
          "$ref" : "#/$defs/String"
        },
        "Optional<UUID>" : {
          "$ref" : "#/$defs/UUID"
        },
        "RDottedName" : {
          "type" : "string",
          "description" : "A Lanark dotted name.",
          "pattern" : "([a-z][a-z0-9_-]{0,63})(\\.[a-z][a-z0-9_-]{0,62}){0,15}"
        },
        "Set<CJ1MetadataType>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1MetadataType"
          }
        },
        "Set<CJ1StockOccurrenceKind>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1StockOccurrenceKind"
          }
        },
        "Set<CJ1TypeRecordFieldIdentifier>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1TypeRecordFieldIdentifier"
          }
        },
        "Set<CJ1TypeRecordIdentifier>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/CJ1TypeRecordIdentifier"
          }
        },
        "Set<String>" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/$defs/String"
          }
        },
        "String" : {
          "type" : "string"
        },
        "UUID" : {
          "description" : "An RFC 9562 UUID string.",
          "type" : "string",
          "format" : "uuid"
        },
        "boolean" : { },
        "byte[]" : {
          "description" : "An RFC 4648 'standard' base64 encoded byte array.",
          "type" : "string",
          "format" : "base64"
        },
        "double" : { },
        "long" : { }
      }
    }

8. API Access
Previous
8. API Access
Up
9. Security
Next
io7m | single-page | multi-page | Cardant User Manual 1.0.0-SNAPSHOT