Actual Cost Record Storage (v0.7)

http://localhost:9130

Table of contents

Actual cost record API

Storage for actual cost record

/actual-cost-record-storage

GET /actual-cost-record-storage/actual-cost-records

Retrieve a list of actual-cost-record items.

GET /actual-cost-record-storage/actual-cost-records
Query Parameters
  • totalRecords: (string - default: auto - pattern: exact|estimated|none|auto)

    How to calculate the totalRecords property. "exact" for the correct number, "estimated" for an estimation, "auto" to automatically select "exact" or "estimated", "none" for suppressing the totalRecords property. For details see https://github.com/folio-org/raml-module-builder#estimated-totalrecords

    Example:

    none
  • offset: (integer - default: 0 - minimum: 0 - maximum: 2147483647)

    Skip over a number of elements by specifying an offset value for the query

    Example:

    0
  • limit: (integer - default: 10 - minimum: 0 - maximum: 2147483647)

    Limit the number of elements returned in the response. Using limit=0 will return totalRecords with the exact value. For details about totalRecords see https://github.com/folio-org/raml-module-builder#estimated-totalrecords

    Example:

    10
  • query: (string)

    A query expressed as a CQL string (see dev.folio.org/reference/glossary#cql) using valid searchable fields. The first example below shows the general form of a full CQL query, but those fields might not be relevant in this context.

    by using CQL

    Example:

    (username=="ab*" or personal.firstName=="ab*" or personal.lastName=="ab*") and active=="true" sortby personal.lastName personal.firstName barcode
    
    lossType="Aged to lost"
    

Response 200

Returns a list of actual-cost-record items

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Collection of Actual cost records",
  "type": "object",
  "properties": {
    "actualCostRecords": {
      "description": "List of Actual cost records",
      "id": "actualCostRecords",
      "type": "array",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "description": "Actual cost record",
        "properties": {
          "id": {
            "description": "Actual cost record ID",
            "type": "string",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "id": "uuid.schema",
            "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
          },
          "lossType": {
            "description": "Type of the item loss",
            "type": "string",
            "enum": [
              "Aged to lost",
              "Declared lost"
            ]
          },
          "lossDate": {
            "description": "Date and time when the item was lost",
            "type": "string",
            "format": "date-time"
          },
          "expirationDate": {
            "description": "Expiration date and time of actual cost record",
            "type": "string",
            "format": "date-time"
          },
          "user": {
            "description": "User info",
            "type": "object",
            "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordUser",
            "properties": {
              "id": {
                "description": "User ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "barcode": {
                "description": "User barcode",
                "type": "string"
              },
              "firstName": {
                "description": "User first name",
                "type": "string"
              },
              "lastName": {
                "description": "User last name",
                "type": "string"
              },
              "middleName": {
                "description": "User middle name",
                "type": "string"
              },
              "patronGroupId": {
                "description": "Patron group ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "patronGroup": {
                "description": "Patron group name",
                "type": "string"
              }
            },
            "additionalProperties": false,
            "required": [
              "id",
              "lastName"
            ]
          },
          "loan": {
            "description": "Loan info",
            "type": "object",
            "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordLoan",
            "properties": {
              "id": {
                "description": "Loan ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              }
            },
            "additionalProperties": false,
            "required": [
              "id"
            ]
          },
          "item": {
            "description": "Item info",
            "type": "object",
            "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordItem",
            "properties": {
              "id": {
                "description": "Item ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "barcode": {
                "description": "Item barcode",
                "type": "string"
              },
              "materialTypeId": {
                "description": "Material type ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "materialType": {
                "description": "Material type name",
                "type": "string"
              },
              "permanentLocationId": {
                "description": "Permanent location ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "permanentLocation": {
                "description": "Permanent location name",
                "type": "string"
              },
              "effectiveLocationId": {
                "description": "Effective location ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "effectiveLocation": {
                "description": "Effective location name",
                "type": "string"
              },
              "loanTypeId": {
                "description": "Loan type ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "loanType": {
                "description": "Loan type name",
                "type": "string"
              },
              "holdingsRecordId": {
                "description": "Holdings record ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "effectiveCallNumberComponents": {
                "type": "object",
                "description": "Elements of a full call number generated from the item or holding",
                "properties": {
                  "callNumber": {
                    "type": "string",
                    "description": "Effective Call Number is an identifier assigned to an item or its holding and associated with the item."
                  },
                  "prefix": {
                    "type": "string",
                    "description": "Effective Call Number Prefix is the prefix of the identifier assigned to an item or its holding and associated with the item."
                  },
                  "suffix": {
                    "type": "string",
                    "description": "Effective Call Number Suffix is the suffix of the identifier assigned to an item or its holding and associated with the item."
                  }
                },
                "additionalProperties": false
              },
              "volume": {
                "type": "string",
                "description": "Volume is intended for monographs when a multipart monograph (e.g. a biography of George Bernard Shaw in three volumes)."
              },
              "enumeration": {
                "type": "string",
                "description": "Enumeration is the descriptive information for the numbering scheme of a serial."
              },
              "chronology": {
                "type": "string",
                "description": "Chronology is the descriptive information for the dating scheme of a serial."
              },
              "displaySummary": {
                "description": "Display summary about the item",
                "type": "string"
              },
              "copyNumber": {
                "type": "string",
                "description": "Copy number is the piece identifier. The copy number reflects if the library has a copy of a single-volume monograph; one copy of a multi-volume, (e.g. Copy 1, or C.7.)"
              }
            },
            "additionalProperties": false,
            "required": [
              "id",
              "materialTypeId",
              "materialType",
              "loanTypeId",
              "loanType",
              "holdingsRecordId"
            ]
          },
          "instance": {
            "description": "Instance info",
            "type": "object",
            "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordInstance",
            "properties": {
              "id": {
                "description": "Instance ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "title": {
                "description": "Instance title",
                "type": "string"
              },
              "identifiers": {
                "type": "array",
                "description": "An extensible set of name-value pairs of identifiers associated with the resource",
                "minItems": 0,
                "items": {
                  "type": "object",
                  "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordIdentifier",
                  "properties": {
                    "value": {
                      "type": "string",
                      "description": "Resource identifier value"
                    },
                    "identifierType": {
                      "type": "string",
                      "description": "Name of resource identifier type (e.g. ISBN, ISSN, LCCN, CODEN, Locally defined identifiers)"
                    },
                    "identifierTypeId": {
                      "type": "string",
                      "description": "UUID of resource identifier type (e.g. ISBN, ISSN, LCCN, CODEN, Locally defined identifiers)",
                      "$schema": "http://json-schema.org/draft-04/schema#",
                      "id": "uuid.schema",
                      "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
                    }
                  },
                  "additionalProperties": false,
                  "required": [
                    "value",
                    "identifierType",
                    "identifierTypeId"
                  ]
                }
              },
              "contributors": {
                "type": "array",
                "description": "List of contributors",
                "minItems": 0,
                "items": {
                  "type": "object",
                  "properties": {
                    "name": {
                      "type": "string",
                      "description": "Contributor name"
                    }
                  },
                  "additionalProperties": false,
                  "required": [
                    "name"
                  ]
                }
              }
            },
            "additionalProperties": false,
            "required": [
              "id",
              "title"
            ]
          },
          "feeFine": {
            "description": "Fee/fine info",
            "type": "object",
            "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordFeeFine",
            "properties": {
              "accountId": {
                "description": "ID of the fee/fine (\"account\") instance",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "billedAmount": {
                "description": "Initial amount of a fee/fine created upon billing",
                "type": "number",
                "minimum": 0
              },
              "ownerId": {
                "description": "Fee/fine owner ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "owner": {
                "description": "Fee/fine owner name",
                "type": "string"
              },
              "typeId": {
                "description": "Fee/fine type ID",
                "type": "string",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              },
              "type": {
                "description": "Fee/fine type name",
                "type": "string"
              }
            },
            "additionalProperties": false,
            "required": [
              "ownerId",
              "owner",
              "typeId",
              "type"
            ]
          },
          "status": {
            "description": "Status of the actual cost record",
            "type": "string",
            "enum": [
              "Open",
              "Billed",
              "Cancelled",
              "Expired"
            ],
            "default": "Open"
          },
          "additionalInfoForStaff": {
            "description": "Additional information for staff",
            "type": "string"
          },
          "additionalInfoForPatron": {
            "description": "Additional information for a patron",
            "type": "string"
          },
          "metadata": {
            "description": "Metadata about creation and changes, provided by the server (client should not provide)",
            "type": "object",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "id": "metadata.schema",
            "title": "Metadata Schema",
            "properties": {
              "createdDate": {
                "description": "Date and time when the record was created",
                "type": "string",
                "format": "date-time"
              },
              "createdByUserId": {
                "description": "ID of the user who created the record (when available)",
                "type": "string",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
              },
              "createdByUsername": {
                "description": "Username of the user who created the record (when available)",
                "type": "string"
              },
              "updatedDate": {
                "description": "Date and time when the record was last updated",
                "type": "string",
                "format": "date-time"
              },
              "updatedByUserId": {
                "description": "ID of the user who last updated the record (when available)",
                "type": "string",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
              },
              "updatedByUsername": {
                "description": "Username of the user who last updated the record (when available)",
                "type": "string"
              }
            },
            "additionalProperties": false,
            "required": [
              "createdDate"
            ]
          }
        },
        "additionalProperties": false,
        "required": [
          "lossType",
          "lossDate",
          "user",
          "loan",
          "item",
          "instance",
          "feeFine",
          "status"
        ]
      }
    },
    "totalRecords": {
      "type": "integer"
    }
  },
  "required": [
    "actualCostRecords",
    "totalRecords"
  ]
}

Example:

{
  "actualCostRecords" : [
    {
      "id": "89105c06-dbdb-4aa0-9695-d4d19c733270",
      "lossType": "Aged to lost",
      "lossDate": "2022-01-01T22:25:37.000+00:00",
      "expirationDate": "2022-02-01T23:59:59.000+00:00",
      "user": {
        "id": "88805c06-dbdb-4aa0-9695-d4d19c733221",
        "barcode": "777",
        "firstName": "John",
        "lastName": "Doe",
        "middleName": "Robert",
        "patronGroupId": "4bb563d9-3f9d-4e1e-8d1d-04e75666d68f",
        "patronGroup": "librarian"
      },
      "loan": {
        "id": "65de6432-be11-48ba-9686-a65101634040"
      },
      "item": {
        "id": "b7bee7e9-f41d-4136-b7eb-af00c2f6d274",
        "barcode": "123456",
        "materialTypeId": "57a578ab-4dde-4f75-909c-edc74772d09b",
        "materialType": "book",
        "permanentLocationId": "9da9dcdd-474f-4e16-bb83-21e64e5eb288",
        "permanentLocation": "Main library",
        "effectiveLocationId": "5513cf26-a45c-482e-a25a-3ce5c32e619c",
        "effectiveLocation": "Annex",
        "loanTypeId": "e1e17294-dd52-44ae-8a94-b96aa08ef3b5",
        "loanType": "Can circulate",
        "holdingsRecordId": "68190dd4-9a88-4dbe-af1a-9048be222ac8",
        "effectiveCallNumberComponents": {
          "callNumber": "TX809.M17J66",
          "prefix": "f",
          "suffix": "1993"
        },
        "volume": "v. 2",
        "enumeration": "v.73:no.1-6",
        "chronology": "1985:July-Dec.",
        "displaySummary": "v.73:no.1-6 v. 2 1985:July-Dec.",
        "copyNumber": "c.1"
      },
      "instance": {
        "id": "9dfe10e5-6db9-4f80-b574-7edc0f960288",
        "title": "Nod",
        "identifiers": [
          {
            "value": "9781466636897",
            "identifierType": "ISBN",
            "identifierTypeId": "8261054f-be78-422d-bd51-4ed9f33c3422"
          }
        ],
        "contributors": [
          {
            "name": "Schmitz, Bettina"
          }
        ]
      },
      "feeFine": {
        "accountId": "306339a5-539b-4652-be7c-ab041a286c8c",
        "billedAmount": 9.99,
        "ownerId": "a2e1729a-2593-4a2a-8069-2fee39d9ae31",
        "owner": "Default owner",
        "typeId": "92ef9706-f1af-430d-9edd-78035689efa2",
        "type": "Overdue fine"
      },
      "status": "Billed",
      "additionalInfoForStaff": "Additional information for staff",
      "additionalInfoForPatron": "Additional information for a patron",
      "metadata": {
        "createdDate": "2022-09-19T14:09:41.284+00:00",
        "createdByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f",
        "updatedDate": "2022-09-19T14:09:41.284+00:00",
        "updatedByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f"
      }
    }
  ],
  "totalRecords": 1
}

Response 400

Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.

Body

Media type: text/plain

Type: any

Example:

unable to list actual-cost-records -- malformed parameter 'query', syntax error at column 6

Response 401

Not authorized to perform requested action

Body

Media type: text/plain

Type: any

Example:

unable to list actual-cost-records -- unauthorized

Response 500

Internal server error, e.g. due to misconfiguration

Body

Media type: text/plain

Type: any

Example:

internal server error, contact administrator

POST /actual-cost-record-storage/actual-cost-records

Create a new actual-cost-record item.

POST /actual-cost-record-storage/actual-cost-records
Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "description": "Actual cost record",
  "properties": {
    "id": {
      "description": "Actual cost record ID",
      "type": "string",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "id": "uuid.schema",
      "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
    },
    "lossType": {
      "description": "Type of the item loss",
      "type": "string",
      "enum": [
        "Aged to lost",
        "Declared lost"
      ]
    },
    "lossDate": {
      "description": "Date and time when the item was lost",
      "type": "string",
      "format": "date-time"
    },
    "expirationDate": {
      "description": "Expiration date and time of actual cost record",
      "type": "string",
      "format": "date-time"
    },
    "user": {
      "description": "User info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordUser",
      "properties": {
        "id": {
          "description": "User ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "barcode": {
          "description": "User barcode",
          "type": "string"
        },
        "firstName": {
          "description": "User first name",
          "type": "string"
        },
        "lastName": {
          "description": "User last name",
          "type": "string"
        },
        "middleName": {
          "description": "User middle name",
          "type": "string"
        },
        "patronGroupId": {
          "description": "Patron group ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "patronGroup": {
          "description": "Patron group name",
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "id",
        "lastName"
      ]
    },
    "loan": {
      "description": "Loan info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordLoan",
      "properties": {
        "id": {
          "description": "Loan ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        }
      },
      "additionalProperties": false,
      "required": [
        "id"
      ]
    },
    "item": {
      "description": "Item info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordItem",
      "properties": {
        "id": {
          "description": "Item ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "barcode": {
          "description": "Item barcode",
          "type": "string"
        },
        "materialTypeId": {
          "description": "Material type ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "materialType": {
          "description": "Material type name",
          "type": "string"
        },
        "permanentLocationId": {
          "description": "Permanent location ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "permanentLocation": {
          "description": "Permanent location name",
          "type": "string"
        },
        "effectiveLocationId": {
          "description": "Effective location ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "effectiveLocation": {
          "description": "Effective location name",
          "type": "string"
        },
        "loanTypeId": {
          "description": "Loan type ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "loanType": {
          "description": "Loan type name",
          "type": "string"
        },
        "holdingsRecordId": {
          "description": "Holdings record ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "effectiveCallNumberComponents": {
          "type": "object",
          "description": "Elements of a full call number generated from the item or holding",
          "properties": {
            "callNumber": {
              "type": "string",
              "description": "Effective Call Number is an identifier assigned to an item or its holding and associated with the item."
            },
            "prefix": {
              "type": "string",
              "description": "Effective Call Number Prefix is the prefix of the identifier assigned to an item or its holding and associated with the item."
            },
            "suffix": {
              "type": "string",
              "description": "Effective Call Number Suffix is the suffix of the identifier assigned to an item or its holding and associated with the item."
            }
          },
          "additionalProperties": false
        },
        "volume": {
          "type": "string",
          "description": "Volume is intended for monographs when a multipart monograph (e.g. a biography of George Bernard Shaw in three volumes)."
        },
        "enumeration": {
          "type": "string",
          "description": "Enumeration is the descriptive information for the numbering scheme of a serial."
        },
        "chronology": {
          "type": "string",
          "description": "Chronology is the descriptive information for the dating scheme of a serial."
        },
        "displaySummary": {
          "description": "Display summary about the item",
          "type": "string"
        },
        "copyNumber": {
          "type": "string",
          "description": "Copy number is the piece identifier. The copy number reflects if the library has a copy of a single-volume monograph; one copy of a multi-volume, (e.g. Copy 1, or C.7.)"
        }
      },
      "additionalProperties": false,
      "required": [
        "id",
        "materialTypeId",
        "materialType",
        "loanTypeId",
        "loanType",
        "holdingsRecordId"
      ]
    },
    "instance": {
      "description": "Instance info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordInstance",
      "properties": {
        "id": {
          "description": "Instance ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "title": {
          "description": "Instance title",
          "type": "string"
        },
        "identifiers": {
          "type": "array",
          "description": "An extensible set of name-value pairs of identifiers associated with the resource",
          "minItems": 0,
          "items": {
            "type": "object",
            "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordIdentifier",
            "properties": {
              "value": {
                "type": "string",
                "description": "Resource identifier value"
              },
              "identifierType": {
                "type": "string",
                "description": "Name of resource identifier type (e.g. ISBN, ISSN, LCCN, CODEN, Locally defined identifiers)"
              },
              "identifierTypeId": {
                "type": "string",
                "description": "UUID of resource identifier type (e.g. ISBN, ISSN, LCCN, CODEN, Locally defined identifiers)",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              }
            },
            "additionalProperties": false,
            "required": [
              "value",
              "identifierType",
              "identifierTypeId"
            ]
          }
        },
        "contributors": {
          "type": "array",
          "description": "List of contributors",
          "minItems": 0,
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "description": "Contributor name"
              }
            },
            "additionalProperties": false,
            "required": [
              "name"
            ]
          }
        }
      },
      "additionalProperties": false,
      "required": [
        "id",
        "title"
      ]
    },
    "feeFine": {
      "description": "Fee/fine info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordFeeFine",
      "properties": {
        "accountId": {
          "description": "ID of the fee/fine (\"account\") instance",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "billedAmount": {
          "description": "Initial amount of a fee/fine created upon billing",
          "type": "number",
          "minimum": 0
        },
        "ownerId": {
          "description": "Fee/fine owner ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "owner": {
          "description": "Fee/fine owner name",
          "type": "string"
        },
        "typeId": {
          "description": "Fee/fine type ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "type": {
          "description": "Fee/fine type name",
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "ownerId",
        "owner",
        "typeId",
        "type"
      ]
    },
    "status": {
      "description": "Status of the actual cost record",
      "type": "string",
      "enum": [
        "Open",
        "Billed",
        "Cancelled",
        "Expired"
      ],
      "default": "Open"
    },
    "additionalInfoForStaff": {
      "description": "Additional information for staff",
      "type": "string"
    },
    "additionalInfoForPatron": {
      "description": "Additional information for a patron",
      "type": "string"
    },
    "metadata": {
      "description": "Metadata about creation and changes, provided by the server (client should not provide)",
      "type": "object",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "id": "metadata.schema",
      "title": "Metadata Schema",
      "properties": {
        "createdDate": {
          "description": "Date and time when the record was created",
          "type": "string",
          "format": "date-time"
        },
        "createdByUserId": {
          "description": "ID of the user who created the record (when available)",
          "type": "string",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
        },
        "createdByUsername": {
          "description": "Username of the user who created the record (when available)",
          "type": "string"
        },
        "updatedDate": {
          "description": "Date and time when the record was last updated",
          "type": "string",
          "format": "date-time"
        },
        "updatedByUserId": {
          "description": "ID of the user who last updated the record (when available)",
          "type": "string",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
        },
        "updatedByUsername": {
          "description": "Username of the user who last updated the record (when available)",
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "createdDate"
      ]
    }
  },
  "additionalProperties": false,
  "required": [
    "lossType",
    "lossDate",
    "user",
    "loan",
    "item",
    "instance",
    "feeFine",
    "status"
  ]
}

Example:

{
  "id": "89105c06-dbdb-4aa0-9695-d4d19c733270",
  "lossType": "Aged to lost",
  "lossDate": "2022-01-01T22:25:37.000+00:00",
  "expirationDate": "2022-02-01T23:59:59.000+00:00",
  "user": {
    "id": "88805c06-dbdb-4aa0-9695-d4d19c733221",
    "barcode": "777",
    "firstName": "John",
    "lastName": "Doe",
    "middleName": "Robert",
    "patronGroupId": "4bb563d9-3f9d-4e1e-8d1d-04e75666d68f",
    "patronGroup": "librarian"
  },
  "loan": {
    "id": "65de6432-be11-48ba-9686-a65101634040"
  },
  "item": {
    "id": "b7bee7e9-f41d-4136-b7eb-af00c2f6d274",
    "barcode": "123456",
    "materialTypeId": "57a578ab-4dde-4f75-909c-edc74772d09b",
    "materialType": "book",
    "permanentLocationId": "9da9dcdd-474f-4e16-bb83-21e64e5eb288",
    "permanentLocation": "Main library",
    "effectiveLocationId": "5513cf26-a45c-482e-a25a-3ce5c32e619c",
    "effectiveLocation": "Annex",
    "loanTypeId": "e1e17294-dd52-44ae-8a94-b96aa08ef3b5",
    "loanType": "Can circulate",
    "holdingsRecordId": "68190dd4-9a88-4dbe-af1a-9048be222ac8",
    "effectiveCallNumberComponents": {
      "callNumber": "TX809.M17J66",
      "prefix": "f",
      "suffix": "1993"
    },
    "volume": "v. 2",
    "enumeration": "v.73:no.1-6",
    "chronology": "1985:July-Dec.",
    "displaySummary": "v.73:no.1-6 v. 2 1985:July-Dec.",
    "copyNumber": "c.1"
  },
  "instance": {
    "id": "9dfe10e5-6db9-4f80-b574-7edc0f960288",
    "title": "Nod",
    "identifiers": [
      {
        "value": "9781466636897",
        "identifierType": "ISBN",
        "identifierTypeId": "8261054f-be78-422d-bd51-4ed9f33c3422"
      }
    ],
    "contributors": [
      {
        "name": "Schmitz, Bettina"
      }
    ]
  },
  "feeFine": {
    "accountId": "306339a5-539b-4652-be7c-ab041a286c8c",
    "billedAmount": 9.99,
    "ownerId": "a2e1729a-2593-4a2a-8069-2fee39d9ae31",
    "owner": "Default owner",
    "typeId": "92ef9706-f1af-430d-9edd-78035689efa2",
    "type": "Overdue fine"
  },
  "status": "Billed",
  "additionalInfoForStaff": "Additional information for staff",
  "additionalInfoForPatron": "Additional information for a patron",
  "metadata": {
    "createdDate": "2022-09-19T14:09:41.284+00:00",
    "createdByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f",
    "updatedDate": "2022-09-19T14:09:41.284+00:00",
    "updatedByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f"
  }
}

Response 201

Returns a newly created item, with server-controlled fields like 'id' populated

Headers
  • Location: required (string)

    URI to the created actual-cost-record item

Body

Media type: application/json

Type: any

Example:

{
  "id": "89105c06-dbdb-4aa0-9695-d4d19c733270",
  "lossType": "Aged to lost",
  "lossDate": "2022-01-01T22:25:37.000+00:00",
  "expirationDate": "2022-02-01T23:59:59.000+00:00",
  "user": {
    "id": "88805c06-dbdb-4aa0-9695-d4d19c733221",
    "barcode": "777",
    "firstName": "John",
    "lastName": "Doe",
    "middleName": "Robert",
    "patronGroupId": "4bb563d9-3f9d-4e1e-8d1d-04e75666d68f",
    "patronGroup": "librarian"
  },
  "loan": {
    "id": "65de6432-be11-48ba-9686-a65101634040"
  },
  "item": {
    "id": "b7bee7e9-f41d-4136-b7eb-af00c2f6d274",
    "barcode": "123456",
    "materialTypeId": "57a578ab-4dde-4f75-909c-edc74772d09b",
    "materialType": "book",
    "permanentLocationId": "9da9dcdd-474f-4e16-bb83-21e64e5eb288",
    "permanentLocation": "Main library",
    "effectiveLocationId": "5513cf26-a45c-482e-a25a-3ce5c32e619c",
    "effectiveLocation": "Annex",
    "loanTypeId": "e1e17294-dd52-44ae-8a94-b96aa08ef3b5",
    "loanType": "Can circulate",
    "holdingsRecordId": "68190dd4-9a88-4dbe-af1a-9048be222ac8",
    "effectiveCallNumberComponents": {
      "callNumber": "TX809.M17J66",
      "prefix": "f",
      "suffix": "1993"
    },
    "volume": "v. 2",
    "enumeration": "v.73:no.1-6",
    "chronology": "1985:July-Dec.",
    "displaySummary": "v.73:no.1-6 v. 2 1985:July-Dec.",
    "copyNumber": "c.1"
  },
  "instance": {
    "id": "9dfe10e5-6db9-4f80-b574-7edc0f960288",
    "title": "Nod",
    "identifiers": [
      {
        "value": "9781466636897",
        "identifierType": "ISBN",
        "identifierTypeId": "8261054f-be78-422d-bd51-4ed9f33c3422"
      }
    ],
    "contributors": [
      {
        "name": "Schmitz, Bettina"
      }
    ]
  },
  "feeFine": {
    "accountId": "306339a5-539b-4652-be7c-ab041a286c8c",
    "billedAmount": 9.99,
    "ownerId": "a2e1729a-2593-4a2a-8069-2fee39d9ae31",
    "owner": "Default owner",
    "typeId": "92ef9706-f1af-430d-9edd-78035689efa2",
    "type": "Overdue fine"
  },
  "status": "Billed",
  "additionalInfoForStaff": "Additional information for staff",
  "additionalInfoForPatron": "Additional information for a patron",
  "metadata": {
    "createdDate": "2022-09-19T14:09:41.284+00:00",
    "createdByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f",
    "updatedDate": "2022-09-19T14:09:41.284+00:00",
    "updatedByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f"
  }
}

Response 400

Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.

Body

Media type: text/plain

Type: any

Example:

"unable to add actual-cost-record -- malformed JSON at 13:3"

Response 401

Not authorized to perform requested action

Body

Media type: text/plain

Type: any

Example:

unable to create actual-cost-records -- unauthorized

Response 422

Validation errors

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "id": "errors.schema",
  "description": "A set of errors",
  "type": "object",
  "properties": {
    "errors": {
      "description": "List of errors",
      "id": "errors",
      "type": "array",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "id": "error.schema",
        "description": "An error",
        "properties": {
          "message": {
            "type": "string",
            "description": "Error message text"
          },
          "type": {
            "type": "string",
            "description": "Error message type"
          },
          "code": {
            "type": "string",
            "description": "Error message code"
          },
          "parameters": {
            "description": "Error message parameters",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "id": "parameters.schema",
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string"
                },
                "value": {
                  "type": "string"
                }
              }
            }
          }
        },
        "required": [
          "message"
        ]
      }
    },
    "total_records": {
      "description": "Total number of errors",
      "type": "integer"
    }
  }
}

Example:

{
  "errors": [
    {
      "message": "may not be null",
      "type": "1",
      "code": "-1",
      "parameters": [
        {
          "key": "moduleTo",
          "value": "null"
        }
      ]
    }
  ]
}

Response 500

Internal server error, e.g. due to misconfiguration

Body

Media type: text/plain

Type: any

Example:

Internal server error, contact administrator

GET /actual-cost-record-storage/actual-cost-records/{id}

Get actual cost record

GET /actual-cost-record-storage/actual-cost-records/{id}
URI Parameters
  • id: required (string)

Response 200

Returns item with a given ID

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "description": "Actual cost record",
  "properties": {
    "id": {
      "description": "Actual cost record ID",
      "type": "string",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "id": "uuid.schema",
      "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
    },
    "lossType": {
      "description": "Type of the item loss",
      "type": "string",
      "enum": [
        "Aged to lost",
        "Declared lost"
      ]
    },
    "lossDate": {
      "description": "Date and time when the item was lost",
      "type": "string",
      "format": "date-time"
    },
    "expirationDate": {
      "description": "Expiration date and time of actual cost record",
      "type": "string",
      "format": "date-time"
    },
    "user": {
      "description": "User info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordUser",
      "properties": {
        "id": {
          "description": "User ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "barcode": {
          "description": "User barcode",
          "type": "string"
        },
        "firstName": {
          "description": "User first name",
          "type": "string"
        },
        "lastName": {
          "description": "User last name",
          "type": "string"
        },
        "middleName": {
          "description": "User middle name",
          "type": "string"
        },
        "patronGroupId": {
          "description": "Patron group ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "patronGroup": {
          "description": "Patron group name",
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "id",
        "lastName"
      ]
    },
    "loan": {
      "description": "Loan info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordLoan",
      "properties": {
        "id": {
          "description": "Loan ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        }
      },
      "additionalProperties": false,
      "required": [
        "id"
      ]
    },
    "item": {
      "description": "Item info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordItem",
      "properties": {
        "id": {
          "description": "Item ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "barcode": {
          "description": "Item barcode",
          "type": "string"
        },
        "materialTypeId": {
          "description": "Material type ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "materialType": {
          "description": "Material type name",
          "type": "string"
        },
        "permanentLocationId": {
          "description": "Permanent location ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "permanentLocation": {
          "description": "Permanent location name",
          "type": "string"
        },
        "effectiveLocationId": {
          "description": "Effective location ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "effectiveLocation": {
          "description": "Effective location name",
          "type": "string"
        },
        "loanTypeId": {
          "description": "Loan type ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "loanType": {
          "description": "Loan type name",
          "type": "string"
        },
        "holdingsRecordId": {
          "description": "Holdings record ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "effectiveCallNumberComponents": {
          "type": "object",
          "description": "Elements of a full call number generated from the item or holding",
          "properties": {
            "callNumber": {
              "type": "string",
              "description": "Effective Call Number is an identifier assigned to an item or its holding and associated with the item."
            },
            "prefix": {
              "type": "string",
              "description": "Effective Call Number Prefix is the prefix of the identifier assigned to an item or its holding and associated with the item."
            },
            "suffix": {
              "type": "string",
              "description": "Effective Call Number Suffix is the suffix of the identifier assigned to an item or its holding and associated with the item."
            }
          },
          "additionalProperties": false
        },
        "volume": {
          "type": "string",
          "description": "Volume is intended for monographs when a multipart monograph (e.g. a biography of George Bernard Shaw in three volumes)."
        },
        "enumeration": {
          "type": "string",
          "description": "Enumeration is the descriptive information for the numbering scheme of a serial."
        },
        "chronology": {
          "type": "string",
          "description": "Chronology is the descriptive information for the dating scheme of a serial."
        },
        "displaySummary": {
          "description": "Display summary about the item",
          "type": "string"
        },
        "copyNumber": {
          "type": "string",
          "description": "Copy number is the piece identifier. The copy number reflects if the library has a copy of a single-volume monograph; one copy of a multi-volume, (e.g. Copy 1, or C.7.)"
        }
      },
      "additionalProperties": false,
      "required": [
        "id",
        "materialTypeId",
        "materialType",
        "loanTypeId",
        "loanType",
        "holdingsRecordId"
      ]
    },
    "instance": {
      "description": "Instance info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordInstance",
      "properties": {
        "id": {
          "description": "Instance ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "title": {
          "description": "Instance title",
          "type": "string"
        },
        "identifiers": {
          "type": "array",
          "description": "An extensible set of name-value pairs of identifiers associated with the resource",
          "minItems": 0,
          "items": {
            "type": "object",
            "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordIdentifier",
            "properties": {
              "value": {
                "type": "string",
                "description": "Resource identifier value"
              },
              "identifierType": {
                "type": "string",
                "description": "Name of resource identifier type (e.g. ISBN, ISSN, LCCN, CODEN, Locally defined identifiers)"
              },
              "identifierTypeId": {
                "type": "string",
                "description": "UUID of resource identifier type (e.g. ISBN, ISSN, LCCN, CODEN, Locally defined identifiers)",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              }
            },
            "additionalProperties": false,
            "required": [
              "value",
              "identifierType",
              "identifierTypeId"
            ]
          }
        },
        "contributors": {
          "type": "array",
          "description": "List of contributors",
          "minItems": 0,
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "description": "Contributor name"
              }
            },
            "additionalProperties": false,
            "required": [
              "name"
            ]
          }
        }
      },
      "additionalProperties": false,
      "required": [
        "id",
        "title"
      ]
    },
    "feeFine": {
      "description": "Fee/fine info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordFeeFine",
      "properties": {
        "accountId": {
          "description": "ID of the fee/fine (\"account\") instance",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "billedAmount": {
          "description": "Initial amount of a fee/fine created upon billing",
          "type": "number",
          "minimum": 0
        },
        "ownerId": {
          "description": "Fee/fine owner ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "owner": {
          "description": "Fee/fine owner name",
          "type": "string"
        },
        "typeId": {
          "description": "Fee/fine type ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "type": {
          "description": "Fee/fine type name",
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "ownerId",
        "owner",
        "typeId",
        "type"
      ]
    },
    "status": {
      "description": "Status of the actual cost record",
      "type": "string",
      "enum": [
        "Open",
        "Billed",
        "Cancelled",
        "Expired"
      ],
      "default": "Open"
    },
    "additionalInfoForStaff": {
      "description": "Additional information for staff",
      "type": "string"
    },
    "additionalInfoForPatron": {
      "description": "Additional information for a patron",
      "type": "string"
    },
    "metadata": {
      "description": "Metadata about creation and changes, provided by the server (client should not provide)",
      "type": "object",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "id": "metadata.schema",
      "title": "Metadata Schema",
      "properties": {
        "createdDate": {
          "description": "Date and time when the record was created",
          "type": "string",
          "format": "date-time"
        },
        "createdByUserId": {
          "description": "ID of the user who created the record (when available)",
          "type": "string",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
        },
        "createdByUsername": {
          "description": "Username of the user who created the record (when available)",
          "type": "string"
        },
        "updatedDate": {
          "description": "Date and time when the record was last updated",
          "type": "string",
          "format": "date-time"
        },
        "updatedByUserId": {
          "description": "ID of the user who last updated the record (when available)",
          "type": "string",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
        },
        "updatedByUsername": {
          "description": "Username of the user who last updated the record (when available)",
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "createdDate"
      ]
    }
  },
  "additionalProperties": false,
  "required": [
    "lossType",
    "lossDate",
    "user",
    "loan",
    "item",
    "instance",
    "feeFine",
    "status"
  ]
}

Example:

{
  "id": "89105c06-dbdb-4aa0-9695-d4d19c733270",
  "lossType": "Aged to lost",
  "lossDate": "2022-01-01T22:25:37.000+00:00",
  "expirationDate": "2022-02-01T23:59:59.000+00:00",
  "user": {
    "id": "88805c06-dbdb-4aa0-9695-d4d19c733221",
    "barcode": "777",
    "firstName": "John",
    "lastName": "Doe",
    "middleName": "Robert",
    "patronGroupId": "4bb563d9-3f9d-4e1e-8d1d-04e75666d68f",
    "patronGroup": "librarian"
  },
  "loan": {
    "id": "65de6432-be11-48ba-9686-a65101634040"
  },
  "item": {
    "id": "b7bee7e9-f41d-4136-b7eb-af00c2f6d274",
    "barcode": "123456",
    "materialTypeId": "57a578ab-4dde-4f75-909c-edc74772d09b",
    "materialType": "book",
    "permanentLocationId": "9da9dcdd-474f-4e16-bb83-21e64e5eb288",
    "permanentLocation": "Main library",
    "effectiveLocationId": "5513cf26-a45c-482e-a25a-3ce5c32e619c",
    "effectiveLocation": "Annex",
    "loanTypeId": "e1e17294-dd52-44ae-8a94-b96aa08ef3b5",
    "loanType": "Can circulate",
    "holdingsRecordId": "68190dd4-9a88-4dbe-af1a-9048be222ac8",
    "effectiveCallNumberComponents": {
      "callNumber": "TX809.M17J66",
      "prefix": "f",
      "suffix": "1993"
    },
    "volume": "v. 2",
    "enumeration": "v.73:no.1-6",
    "chronology": "1985:July-Dec.",
    "displaySummary": "v.73:no.1-6 v. 2 1985:July-Dec.",
    "copyNumber": "c.1"
  },
  "instance": {
    "id": "9dfe10e5-6db9-4f80-b574-7edc0f960288",
    "title": "Nod",
    "identifiers": [
      {
        "value": "9781466636897",
        "identifierType": "ISBN",
        "identifierTypeId": "8261054f-be78-422d-bd51-4ed9f33c3422"
      }
    ],
    "contributors": [
      {
        "name": "Schmitz, Bettina"
      }
    ]
  },
  "feeFine": {
    "accountId": "306339a5-539b-4652-be7c-ab041a286c8c",
    "billedAmount": 9.99,
    "ownerId": "a2e1729a-2593-4a2a-8069-2fee39d9ae31",
    "owner": "Default owner",
    "typeId": "92ef9706-f1af-430d-9edd-78035689efa2",
    "type": "Overdue fine"
  },
  "status": "Billed",
  "additionalInfoForStaff": "Additional information for staff",
  "additionalInfoForPatron": "Additional information for a patron",
  "metadata": {
    "createdDate": "2022-09-19T14:09:41.284+00:00",
    "createdByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f",
    "updatedDate": "2022-09-19T14:09:41.284+00:00",
    "updatedByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f"
  }
}

Response 404

Item with a given ID not found

Body

Media type: text/plain

Type: any

Example:

"actual-cost-record not found"

Response 500

Internal server error, e.g. due to misconfiguration

Body

Media type: text/plain

Type: any

Example:

internal server error, contact administrator

PUT /actual-cost-record-storage/actual-cost-records/{id}

Update actual cost record

PUT /actual-cost-record-storage/actual-cost-records/{id}
URI Parameters
  • id: required (string)
Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "description": "Actual cost record",
  "properties": {
    "id": {
      "description": "Actual cost record ID",
      "type": "string",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "id": "uuid.schema",
      "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
    },
    "lossType": {
      "description": "Type of the item loss",
      "type": "string",
      "enum": [
        "Aged to lost",
        "Declared lost"
      ]
    },
    "lossDate": {
      "description": "Date and time when the item was lost",
      "type": "string",
      "format": "date-time"
    },
    "expirationDate": {
      "description": "Expiration date and time of actual cost record",
      "type": "string",
      "format": "date-time"
    },
    "user": {
      "description": "User info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordUser",
      "properties": {
        "id": {
          "description": "User ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "barcode": {
          "description": "User barcode",
          "type": "string"
        },
        "firstName": {
          "description": "User first name",
          "type": "string"
        },
        "lastName": {
          "description": "User last name",
          "type": "string"
        },
        "middleName": {
          "description": "User middle name",
          "type": "string"
        },
        "patronGroupId": {
          "description": "Patron group ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "patronGroup": {
          "description": "Patron group name",
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "id",
        "lastName"
      ]
    },
    "loan": {
      "description": "Loan info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordLoan",
      "properties": {
        "id": {
          "description": "Loan ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        }
      },
      "additionalProperties": false,
      "required": [
        "id"
      ]
    },
    "item": {
      "description": "Item info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordItem",
      "properties": {
        "id": {
          "description": "Item ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "barcode": {
          "description": "Item barcode",
          "type": "string"
        },
        "materialTypeId": {
          "description": "Material type ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "materialType": {
          "description": "Material type name",
          "type": "string"
        },
        "permanentLocationId": {
          "description": "Permanent location ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "permanentLocation": {
          "description": "Permanent location name",
          "type": "string"
        },
        "effectiveLocationId": {
          "description": "Effective location ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "effectiveLocation": {
          "description": "Effective location name",
          "type": "string"
        },
        "loanTypeId": {
          "description": "Loan type ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "loanType": {
          "description": "Loan type name",
          "type": "string"
        },
        "holdingsRecordId": {
          "description": "Holdings record ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "effectiveCallNumberComponents": {
          "type": "object",
          "description": "Elements of a full call number generated from the item or holding",
          "properties": {
            "callNumber": {
              "type": "string",
              "description": "Effective Call Number is an identifier assigned to an item or its holding and associated with the item."
            },
            "prefix": {
              "type": "string",
              "description": "Effective Call Number Prefix is the prefix of the identifier assigned to an item or its holding and associated with the item."
            },
            "suffix": {
              "type": "string",
              "description": "Effective Call Number Suffix is the suffix of the identifier assigned to an item or its holding and associated with the item."
            }
          },
          "additionalProperties": false
        },
        "volume": {
          "type": "string",
          "description": "Volume is intended for monographs when a multipart monograph (e.g. a biography of George Bernard Shaw in three volumes)."
        },
        "enumeration": {
          "type": "string",
          "description": "Enumeration is the descriptive information for the numbering scheme of a serial."
        },
        "chronology": {
          "type": "string",
          "description": "Chronology is the descriptive information for the dating scheme of a serial."
        },
        "displaySummary": {
          "description": "Display summary about the item",
          "type": "string"
        },
        "copyNumber": {
          "type": "string",
          "description": "Copy number is the piece identifier. The copy number reflects if the library has a copy of a single-volume monograph; one copy of a multi-volume, (e.g. Copy 1, or C.7.)"
        }
      },
      "additionalProperties": false,
      "required": [
        "id",
        "materialTypeId",
        "materialType",
        "loanTypeId",
        "loanType",
        "holdingsRecordId"
      ]
    },
    "instance": {
      "description": "Instance info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordInstance",
      "properties": {
        "id": {
          "description": "Instance ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "title": {
          "description": "Instance title",
          "type": "string"
        },
        "identifiers": {
          "type": "array",
          "description": "An extensible set of name-value pairs of identifiers associated with the resource",
          "minItems": 0,
          "items": {
            "type": "object",
            "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordIdentifier",
            "properties": {
              "value": {
                "type": "string",
                "description": "Resource identifier value"
              },
              "identifierType": {
                "type": "string",
                "description": "Name of resource identifier type (e.g. ISBN, ISSN, LCCN, CODEN, Locally defined identifiers)"
              },
              "identifierTypeId": {
                "type": "string",
                "description": "UUID of resource identifier type (e.g. ISBN, ISSN, LCCN, CODEN, Locally defined identifiers)",
                "$schema": "http://json-schema.org/draft-04/schema#",
                "id": "uuid.schema",
                "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
              }
            },
            "additionalProperties": false,
            "required": [
              "value",
              "identifierType",
              "identifierTypeId"
            ]
          }
        },
        "contributors": {
          "type": "array",
          "description": "List of contributors",
          "minItems": 0,
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "description": "Contributor name"
              }
            },
            "additionalProperties": false,
            "required": [
              "name"
            ]
          }
        }
      },
      "additionalProperties": false,
      "required": [
        "id",
        "title"
      ]
    },
    "feeFine": {
      "description": "Fee/fine info",
      "type": "object",
      "javaType": "org.folio.rest.jaxrs.model.ActualCostRecordFeeFine",
      "properties": {
        "accountId": {
          "description": "ID of the fee/fine (\"account\") instance",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "billedAmount": {
          "description": "Initial amount of a fee/fine created upon billing",
          "type": "number",
          "minimum": 0
        },
        "ownerId": {
          "description": "Fee/fine owner ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "owner": {
          "description": "Fee/fine owner name",
          "type": "string"
        },
        "typeId": {
          "description": "Fee/fine type ID",
          "type": "string",
          "$schema": "http://json-schema.org/draft-04/schema#",
          "id": "uuid.schema",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
        },
        "type": {
          "description": "Fee/fine type name",
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "ownerId",
        "owner",
        "typeId",
        "type"
      ]
    },
    "status": {
      "description": "Status of the actual cost record",
      "type": "string",
      "enum": [
        "Open",
        "Billed",
        "Cancelled",
        "Expired"
      ],
      "default": "Open"
    },
    "additionalInfoForStaff": {
      "description": "Additional information for staff",
      "type": "string"
    },
    "additionalInfoForPatron": {
      "description": "Additional information for a patron",
      "type": "string"
    },
    "metadata": {
      "description": "Metadata about creation and changes, provided by the server (client should not provide)",
      "type": "object",
      "$schema": "http://json-schema.org/draft-04/schema#",
      "id": "metadata.schema",
      "title": "Metadata Schema",
      "properties": {
        "createdDate": {
          "description": "Date and time when the record was created",
          "type": "string",
          "format": "date-time"
        },
        "createdByUserId": {
          "description": "ID of the user who created the record (when available)",
          "type": "string",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
        },
        "createdByUsername": {
          "description": "Username of the user who created the record (when available)",
          "type": "string"
        },
        "updatedDate": {
          "description": "Date and time when the record was last updated",
          "type": "string",
          "format": "date-time"
        },
        "updatedByUserId": {
          "description": "ID of the user who last updated the record (when available)",
          "type": "string",
          "pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
        },
        "updatedByUsername": {
          "description": "Username of the user who last updated the record (when available)",
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "createdDate"
      ]
    }
  },
  "additionalProperties": false,
  "required": [
    "lossType",
    "lossDate",
    "user",
    "loan",
    "item",
    "instance",
    "feeFine",
    "status"
  ]
}

Example:

{
  "id": "89105c06-dbdb-4aa0-9695-d4d19c733270",
  "lossType": "Aged to lost",
  "lossDate": "2022-01-01T22:25:37.000+00:00",
  "expirationDate": "2022-02-01T23:59:59.000+00:00",
  "user": {
    "id": "88805c06-dbdb-4aa0-9695-d4d19c733221",
    "barcode": "777",
    "firstName": "John",
    "lastName": "Doe",
    "middleName": "Robert",
    "patronGroupId": "4bb563d9-3f9d-4e1e-8d1d-04e75666d68f",
    "patronGroup": "librarian"
  },
  "loan": {
    "id": "65de6432-be11-48ba-9686-a65101634040"
  },
  "item": {
    "id": "b7bee7e9-f41d-4136-b7eb-af00c2f6d274",
    "barcode": "123456",
    "materialTypeId": "57a578ab-4dde-4f75-909c-edc74772d09b",
    "materialType": "book",
    "permanentLocationId": "9da9dcdd-474f-4e16-bb83-21e64e5eb288",
    "permanentLocation": "Main library",
    "effectiveLocationId": "5513cf26-a45c-482e-a25a-3ce5c32e619c",
    "effectiveLocation": "Annex",
    "loanTypeId": "e1e17294-dd52-44ae-8a94-b96aa08ef3b5",
    "loanType": "Can circulate",
    "holdingsRecordId": "68190dd4-9a88-4dbe-af1a-9048be222ac8",
    "effectiveCallNumberComponents": {
      "callNumber": "TX809.M17J66",
      "prefix": "f",
      "suffix": "1993"
    },
    "volume": "v. 2",
    "enumeration": "v.73:no.1-6",
    "chronology": "1985:July-Dec.",
    "displaySummary": "v.73:no.1-6 v. 2 1985:July-Dec.",
    "copyNumber": "c.1"
  },
  "instance": {
    "id": "9dfe10e5-6db9-4f80-b574-7edc0f960288",
    "title": "Nod",
    "identifiers": [
      {
        "value": "9781466636897",
        "identifierType": "ISBN",
        "identifierTypeId": "8261054f-be78-422d-bd51-4ed9f33c3422"
      }
    ],
    "contributors": [
      {
        "name": "Schmitz, Bettina"
      }
    ]
  },
  "feeFine": {
    "accountId": "306339a5-539b-4652-be7c-ab041a286c8c",
    "billedAmount": 9.99,
    "ownerId": "a2e1729a-2593-4a2a-8069-2fee39d9ae31",
    "owner": "Default owner",
    "typeId": "92ef9706-f1af-430d-9edd-78035689efa2",
    "type": "Overdue fine"
  },
  "status": "Billed",
  "additionalInfoForStaff": "Additional information for staff",
  "additionalInfoForPatron": "Additional information for a patron",
  "metadata": {
    "createdDate": "2022-09-19T14:09:41.284+00:00",
    "createdByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f",
    "updatedDate": "2022-09-19T14:09:41.284+00:00",
    "updatedByUserId": "5bcadcf1-2608-4cd3-b4e2-947ffe58d15f"
  }
}

Response 204

Item successfully updated

Response 400

Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.

Body

Media type: text/plain

Type: any

Example:

"unable to update actual-cost-record -- malformed JSON at 13:4"

Response 404

Item with a given ID not found

Body

Media type: text/plain

Type: any

Example:

"actual-cost-record not found"

Response 409

Optimistic locking version conflict

Body

Media type: text/plain

Type: any

Example:

version conflict

Response 422

Validation errors

Body

Media type: application/json

Type: json

Content:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "id": "errors.schema",
  "description": "A set of errors",
  "type": "object",
  "properties": {
    "errors": {
      "description": "List of errors",
      "id": "errors",
      "type": "array",
      "items": {
        "type": "object",
        "$schema": "http://json-schema.org/draft-04/schema#",
        "id": "error.schema",
        "description": "An error",
        "properties": {
          "message": {
            "type": "string",
            "description": "Error message text"
          },
          "type": {
            "type": "string",
            "description": "Error message type"
          },
          "code": {
            "type": "string",
            "description": "Error message code"
          },
          "parameters": {
            "description": "Error message parameters",
            "$schema": "http://json-schema.org/draft-04/schema#",
            "id": "parameters.schema",
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string"
                },
                "value": {
                  "type": "string"
                }
              }
            }
          }
        },
        "required": [
          "message"
        ]
      }
    },
    "total_records": {
      "description": "Total number of errors",
      "type": "integer"
    }
  }
}

Example:

{
  "errors": [
    {
      "message": "may not be null",
      "type": "1",
      "code": "-1",
      "parameters": [
        {
          "key": "moduleTo",
          "value": "null"
        }
      ]
    }
  ]
}

Response 500

Internal server error, e.g. due to misconfiguration

Body

Media type: text/plain

Type: any

Example:

internal server error, contact administrator

DELETE /actual-cost-record-storage/actual-cost-records/{id}

Delete actual cost record

DELETE /actual-cost-record-storage/actual-cost-records/{id}
URI Parameters
  • id: required (string)

Response 204

Item deleted successfully

Response 400

Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.

Body

Media type: text/plain

Type: any

Example:

"unable to delete actual-cost-record -- constraint violation"

Response 404

Item with a given ID not found

Body

Media type: text/plain

Type: any

Example:

"actual-cost-record not found"

Response 500

Internal server error, e.g. due to misconfiguration

Body

Media type: text/plain

Type: any

Example:

Internal server error, contact administrator