Koha REST API

Version 1

Resources

Base URL

GET /api/v1/holds

Operation ID: listHolds

This resource is not documented.

Parameters

Name In Type Required Description
hold_id query integer No Internal reserve identifier
patron_id query integer No Internal patron identifier
hold_date query string No Hold
biblio_id query integer No Internal biblio identifier
pickup_library_id query string No Internal library identifier for the pickup library
cancelation_date query string No The date the hold was cancelled
notes query string No Notes related to this hold
priority query integer No Where in the queue the patron sits
status query string No Found status
timestamp query string No Time of latest update
item_id query integer No Internal item identifier
waiting_date query string No Date the item was marked as waiting for the patron
expiration_date query string No Date the hold expires
lowest_priority query boolean No Lowest priority
suspended query boolean No Suspended
suspended_until query string No Suspended until

Response 200

A list of holds

{
  "items": {
    "properties": {
      "biblio_id": {
        "description": "Internal biblio identifier",
        "type": "integer"
      },
      "cancelation_date": {
        "description": "The date the hold was cancelled",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "expiration_date": {
        "description": "The date the hold expires",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "hold_date": {
        "description": "The date the hold was placed",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "hold_id": {
        "description": "Internal hold identifier",
        "type": "integer"
      },
      "item_id": {
        "description": "Internal item identifier",
        "type": [
          "string",
          "null"
        ]
      },
      "item_type": {
        "description": "If record level hold, the optional itemtype of the item the patron is requesting",
        "type": [
          "string",
          "null"
        ]
      },
      "lowest_priority": {
        "description": "Controls if the hold is given the lowest priority on the queue",
        "type": "boolean"
      },
      "notes": {
        "description": "Notes related to this hold",
        "type": [
          "string",
          "null"
        ]
      },
      "patron_id": {
        "description": "Internal patron identifier",
        "type": "integer"
      },
      "pickup_library_id": {
        "description": "Internal library identifier for the pickup library",
        "type": [
          "string",
          "null"
        ]
      },
      "priority": {
        "description": "Where in the queue the patron sits",
        "type": [
          "integer",
          "null"
        ]
      },
      "status": {
        "description": "A one letter code defining what the status of the hold is after it has been confirmed",
        "type": [
          "string",
          "null"
        ]
      },
      "suspended": {
        "description": "Controls if the hold is suspended",
        "type": "boolean"
      },
      "suspended_until": {
        "description": "Date until which the hold has been suspended",
        "format": "date-time",
        "type": [
          "string",
          "null"
        ]
      },
      "timestamp": {
        "description": "Timestamp for the latest hold update",
        "format": "date-time",
        "type": "string"
      },
      "waiting_date": {
        "description": "The date the item was marked as waiting for the patron at the library",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      }
    },
    "type": "object"
  },
  "type": "array"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Hold not allowed

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Borrower not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/holds

Operation ID: addHold

This resource is not documented.

Parameters

Name In Type Required Description
body body Yes A JSON object containing informations about the new hold

Body

{
  "properties": {
    "biblio_id": {
      "description": "Internal biblio identifier",
      "type": [
        "integer",
        "null"
      ]
    },
    "expiration_date": {
      "description": "Hold end date",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "item_id": {
      "description": "Internal item identifier",
      "type": [
        "integer",
        "null"
      ]
    },
    "item_type": {
      "description": "Limit hold on one itemtype (ignored for item-level holds)",
      "type": [
        "string",
        "null"
      ]
    },
    "notes": {
      "description": "Notes related to this hold",
      "type": [
        "string",
        "null"
      ]
    },
    "patron_id": {
      "description": "Internal patron identifier",
      "type": "integer"
    },
    "pickup_library_id": {
      "description": "Internal library identifier for the pickup library",
      "type": "string"
    }
  },
  "required": [
    "patron_id",
    "pickup_library_id"
  ],
  "type": "object"
}

Response 201

Created hold

{
  "properties": {
    "biblio_id": {
      "description": "Internal biblio identifier",
      "type": "integer"
    },
    "cancelation_date": {
      "description": "The date the hold was cancelled",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "expiration_date": {
      "description": "The date the hold expires",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "hold_date": {
      "description": "The date the hold was placed",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "hold_id": {
      "description": "Internal hold identifier",
      "type": "integer"
    },
    "item_id": {
      "description": "Internal item identifier",
      "type": [
        "string",
        "null"
      ]
    },
    "item_type": {
      "description": "If record level hold, the optional itemtype of the item the patron is requesting",
      "type": [
        "string",
        "null"
      ]
    },
    "lowest_priority": {
      "description": "Controls if the hold is given the lowest priority on the queue",
      "type": "boolean"
    },
    "notes": {
      "description": "Notes related to this hold",
      "type": [
        "string",
        "null"
      ]
    },
    "patron_id": {
      "description": "Internal patron identifier",
      "type": "integer"
    },
    "pickup_library_id": {
      "description": "Internal library identifier for the pickup library",
      "type": [
        "string",
        "null"
      ]
    },
    "priority": {
      "description": "Where in the queue the patron sits",
      "type": [
        "integer",
        "null"
      ]
    },
    "status": {
      "description": "A one letter code defining what the status of the hold is after it has been confirmed",
      "type": [
        "string",
        "null"
      ]
    },
    "suspended": {
      "description": "Controls if the hold is suspended",
      "type": "boolean"
    },
    "suspended_until": {
      "description": "Date until which the hold has been suspended",
      "format": "date-time",
      "type": [
        "string",
        "null"
      ]
    },
    "timestamp": {
      "description": "Timestamp for the latest hold update",
      "format": "date-time",
      "type": "string"
    },
    "waiting_date": {
      "description": "The date the item was marked as waiting for the patron at the library",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "type": "object"
}

Response 400

Missing or wrong parameters

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Hold not allowed

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Borrower not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/cities

Operation ID: listCities

This resource is not documented.

Parameters

Name In Type Required Description
name query string No Case insensative search on city name
state query string No Case insensative search on city state
country query string No Case insensative search on city country
postal_code query string No Case Insensative search on city postal code

Response 200

A list of cities

{
  "items": {
    "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
    "properties": {
      "city_id": {
        "description": "internally assigned city identifier",
        "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
        "type": "integer"
      },
      "country": {
        "description": "city country",
        "type": [
          "string",
          "null"
        ]
      },
      "name": {
        "description": "city name",
        "type": "string"
      },
      "postal_code": {
        "description": "city postal code",
        "type": [
          "string",
          "null"
        ]
      },
      "state": {
        "description": "city state",
        "type": [
          "string",
          "null"
        ]
      }
    },
    "required": [
      "name",
      "state",
      "postal_code",
      "country"
    ],
    "type": "object"
  },
  "type": "array"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/cities

Operation ID: addCity

This resource is not documented.

Parameters

Name In Type Required Description
body body Yes A JSON object containing informations about the new hold

Body

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "city_id": {
      "description": "internally assigned city identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "country": {
      "description": "city country",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "city name",
      "type": "string"
    },
    "postal_code": {
      "description": "city postal code",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "city state",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name",
    "state",
    "postal_code",
    "country"
  ],
  "type": "object"
}

Response 200

City added

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "city_id": {
      "description": "internally assigned city identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "country": {
      "description": "city country",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "city name",
      "type": "string"
    },
    "postal_code": {
      "description": "city postal code",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "city state",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name",
    "state",
    "postal_code",
    "country"
  ],
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/patrons

Operation ID: listPatrons

This resource is not documented.

Parameters

Name In Type Required Description
patron_id query string No Search on patron_id
cardnumber query string No Case insensitive search on cardnumber
surname query string No Case insensitive search on surname
firstname query string No Case insensitive search on firstname
title query string No Case insensitive search on title
other_name query string No Case insensitive search on othernames
initials query string No Case insensitive search on initials
street_number query string No Case insensitive search on streetnumber
street_type query string No Case insensitive search on streettype
address query string No Case insensitive search on address
address2 query string No Case insensitive search on address2
city query string No Case insensitive search on city
state query string No Case insensitive search on state
postal_code query string No Case insensitive search on zipcode
country query string No Case insensitive search on country
email query string No Case insensitive search on email
phone query string No Case insensitive search on phone
mobile query string No Case insensitive search on mobile
fax query string No Case insensitive search on fax
secondary_email query string No Case insensitive search on secondary_email
secondary_phone query string No Case insensitive search on secondary_phone
altaddress_street_number query string No Case insensitive search on altaddress_street_number
altaddress_street_type query string No Case insensitive search on altaddress_street_type
altaddress_address query string No Case insensitive search on altaddress_address
altaddress_address2 query string No Case insensitive search on altaddress_address2
altaddress_city query string No Case insensitive search on altaddress_city
altaddress_state query string No Case insensitive search on altaddress_state
altaddress_postal_code query string No Case insensitive search on altaddress_postal_code
altaddress_country query string No Case insensitive search on altaddress_country
altaddress_email query string No Case insensitive search on altaddress_email
altaddress_phone query string No Case insensitive search on altaddress_phone
date_of_birth query string No Case insensitive search on date_of_birth
library_id query string No Case insensitive search on library_id
category_id query string No Case insensitive search on category_id
date_enrolled query string No Case insensitive search on date_enrolled
expiry_date query string No Case insensitive search on expiry_date
incorrect_address query boolean No Search on incorrect_address
patron_card_lost query boolean No Search on patron_card_lost
restricted query boolean No Filter search by restricted
guarantor_id query string No Search on guarantor_id
staff_notes query string No Case insensitive search on staff_notes
relationship_type query string No Case insensitive search on relationship_type
gender query string No Case insensitive search on gender
userid query string No Case insensitive search on userid
opac_notes query string No Case insensitive search on opac_notes
altaddress_notes query string No Case insensitive search on altaddress_notes
statistics_1 query string No Case insensitive search on statistics_1
statistics_2 query string No Case insensitive search on statistics_2
altcontact_firstname query string No Case insensitive search on altcontact_firstname
altcontact_surname query string No Case insensitive search on altcontact_surname
altcontact_address query string No Case insensitive search on altcontact_address
altcontact_address2 query string No Case insensitive search on altcontact_address2
altcontact_city query string No Case insensitive search on altcontact_city
altcontact_state query string No Case insensitive search on altcontact_state
altcontact_postal_code query string No Case insensitive search on altcontact_postal_code
altcontact_country query string No Case insensitive search on altcontact_country
altcontact_phone query string No Case insensitive search on altcontact_phone
sms_number query string No Case insensitive search on sms_number
sms_provider_id query string No Case insensitive search on sms_provider_id
privacy query string No Search on privacy
privacy_guarantor_checkouts query string No Search on privacy_guarantor_checkouts
check_previous_checkout query string No Case insensitive search on check_previous_checkout
updated_on query string No Search on updated_on
last_seen query string No Case insensitive search on last_seen
lang query string No Case insensitive search on lang
login_attempts query string No Search on login_attempts
_match query string No Matching criteria
_order_by query array No Sorting criteria
_page query integer No Page number, for paginated object listing
_per_page query integer No Page size, for paginated object listing

Response 200

A list of patrons

{
  "items": {
    "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
    "properties": {
      "address": {
        "description": "first address line of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "address2": {
        "description": "second address line of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_address": {
        "description": "first address line of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_address2": {
        "description": "second address line of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_city": {
        "description": "city or town of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_country": {
        "description": "country of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_email": {
        "description": "email address for patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_notes": {
        "description": "a note related to patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_phone": {
        "description": "phone number for patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_postal_code": {
        "description": "zip or postal code of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_state": {
        "description": "state or province of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_street_number": {
        "description": "street number of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_street_type": {
        "description": "street type of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_address": {
        "description": "the first address line for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_address2": {
        "description": "the second address line for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_city": {
        "description": "the city for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_country": {
        "description": "the country for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_firstname": {
        "description": "first name of alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_phone": {
        "description": "the phone number for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_postal_code": {
        "description": "the zipcode for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_state": {
        "description": "the state for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_surname": {
        "description": "surname or last name of the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "cardnumber": {
        "description": "library assigned user identifier",
        "type": [
          "string",
          "null"
        ]
      },
      "category_id": {
        "description": "Internal identifier for the patron's category",
        "type": "string"
      },
      "check_previous_checkout": {
        "description": "produce a warning for this patron if this item has previously been checked out to this patron if 'yes', not if 'no', defer to category setting if 'inherit'",
        "type": "string"
      },
      "city": {
        "description": "city or town of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "country": {
        "description": "country of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "date_enrolled": {
        "description": "date the patron was added to Koha",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "date_of_birth": {
        "description": "patron's date of birth",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "date_renewed": {
        "description": "date the patron's card was last renewed",
        "type": [
          "string",
          "null"
        ]
      },
      "email": {
        "description": "primary email address for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "expiry_date": {
        "description": "date the patron's card is set to expire",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "fax": {
        "description": "fax number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "firstname": {
        "description": "patron's first name",
        "type": [
          "string",
          "null"
        ]
      },
      "gender": {
        "description": "patron's gender",
        "type": [
          "string",
          "null"
        ]
      },
      "guarantor_id": {
        "description": "patron_id used for children or professionals to link them to guarantor or organizations",
        "type": [
          "integer",
          "null"
        ]
      },
      "incorrect_address": {
        "description": "set to 1 if library marked this patron as having an unconfirmed address",
        "type": [
          "boolean",
          "null"
        ]
      },
      "initials": {
        "description": "initials of the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "lang": {
        "description": "lang to use to send notices to this patron",
        "type": "string"
      },
      "last_seen": {
        "description": "last time a patron has been seen (connected at the OPAC or staff interface)",
        "format": "date-time",
        "type": [
          "string",
          "null"
        ]
      },
      "library_id": {
        "description": "Internal identifier for the patron's home library",
        "type": "string"
      },
      "login_attempts": {
        "description": "number of failed login attemps",
        "type": [
          "integer",
          "null"
        ]
      },
      "mobile": {
        "description": "the other phone number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "opac_notes": {
        "description": "a note on the patron's account visible in OPAC and staff client",
        "type": [
          "string",
          "null"
        ]
      },
      "other_name": {
        "description": "any other names associated with the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "overdrive_auth_token": {
        "description": "persist OverDrive auth token",
        "type": [
          "string",
          "null"
        ]
      },
      "patron_card_lost": {
        "description": "set to 1 if library marked this patron as having lost his card",
        "type": [
          "boolean",
          "null"
        ]
      },
      "patron_id": {
        "description": "Internal patron identifier",
        "type": "integer"
      },
      "phone": {
        "description": "primary phone number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "postal_code": {
        "description": "zip or postal code of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "privacy": {
        "description": "patron's privacy settings related to their reading history",
        "type": "integer"
      },
      "privacy_guarantor_checkouts": {
        "description": "controls if relatives can see this patron's checkouts",
        "type": "integer"
      },
      "relationship_type": {
        "description": "used for children to include the relationship to their guarantor",
        "type": [
          "string",
          "null"
        ]
      },
      "restricted": {
        "description": "If any restriction applies to the patron",
        "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
        "type": "boolean"
      },
      "secondary_email": {
        "description": "secondary email address for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "secondary_phone": {
        "description": "secondary phone number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "sms_number": {
        "description": "the mobile phone number where the patron would like to receive notices (if SMS turned on)",
        "type": [
          "string",
          "null"
        ]
      },
      "sms_provider_id": {
        "description": "the provider of the mobile phone number defined in smsalertnumber",
        "type": [
          "integer",
          "null"
        ]
      },
      "staff_notes": {
        "description": "a note on the patron's account",
        "type": [
          "string",
          "null"
        ]
      },
      "state": {
        "description": "state or province of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "statistics_1": {
        "description": "a field that can be used for any information unique to the library",
        "type": [
          "string",
          "null"
        ]
      },
      "statistics_2": {
        "description": "a field that can be used for any information unique to the library",
        "type": [
          "string",
          "null"
        ]
      },
      "street_number": {
        "description": "street number of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "street_type": {
        "description": "street type of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "surname": {
        "description": "patron's last name",
        "type": "string"
      },
      "title": {
        "description": "patron's title",
        "type": [
          "string",
          "null"
        ]
      },
      "updated_on": {
        "description": "time of last change could be useful for synchronization with external systems (among others)",
        "format": "date-time",
        "type": "string"
      },
      "userid": {
        "description": "patron's login",
        "type": [
          "string",
          "null"
        ]
      }
    },
    "required": [
      "surname",
      "address",
      "city",
      "library_id",
      "category_id"
    ],
    "type": "object"
  },
  "type": "array"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/patrons

Operation ID: addPatron

This resource is not documented.

Parameters

Name In Type Required Description
body body Yes A JSON object containing information about the new patron

Body

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "address": {
      "description": "first address line of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "second address line of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_address": {
      "description": "first address line of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_address2": {
      "description": "second address line of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_city": {
      "description": "city or town of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_country": {
      "description": "country of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_email": {
      "description": "email address for patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_notes": {
      "description": "a note related to patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_phone": {
      "description": "phone number for patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_postal_code": {
      "description": "zip or postal code of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_state": {
      "description": "state or province of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_street_number": {
      "description": "street number of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_street_type": {
      "description": "street type of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_address": {
      "description": "the first address line for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_address2": {
      "description": "the second address line for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_city": {
      "description": "the city for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_country": {
      "description": "the country for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_firstname": {
      "description": "first name of alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_phone": {
      "description": "the phone number for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_postal_code": {
      "description": "the zipcode for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_state": {
      "description": "the state for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_surname": {
      "description": "surname or last name of the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "cardnumber": {
      "description": "library assigned user identifier",
      "type": [
        "string",
        "null"
      ]
    },
    "category_id": {
      "description": "Internal identifier for the patron's category",
      "type": "string"
    },
    "check_previous_checkout": {
      "description": "produce a warning for this patron if this item has previously been checked out to this patron if 'yes', not if 'no', defer to category setting if 'inherit'",
      "type": "string"
    },
    "city": {
      "description": "city or town of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "country": {
      "description": "country of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "date_enrolled": {
      "description": "date the patron was added to Koha",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "date_of_birth": {
      "description": "patron's date of birth",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "date_renewed": {
      "description": "date the patron's card was last renewed",
      "type": [
        "string",
        "null"
      ]
    },
    "email": {
      "description": "primary email address for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "expiry_date": {
      "description": "date the patron's card is set to expire",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "fax": {
      "description": "fax number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "firstname": {
      "description": "patron's first name",
      "type": [
        "string",
        "null"
      ]
    },
    "gender": {
      "description": "patron's gender",
      "type": [
        "string",
        "null"
      ]
    },
    "guarantor_id": {
      "description": "patron_id used for children or professionals to link them to guarantor or organizations",
      "type": [
        "integer",
        "null"
      ]
    },
    "incorrect_address": {
      "description": "set to 1 if library marked this patron as having an unconfirmed address",
      "type": [
        "boolean",
        "null"
      ]
    },
    "initials": {
      "description": "initials of the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "lang": {
      "description": "lang to use to send notices to this patron",
      "type": "string"
    },
    "last_seen": {
      "description": "last time a patron has been seen (connected at the OPAC or staff interface)",
      "format": "date-time",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "Internal identifier for the patron's home library",
      "type": "string"
    },
    "login_attempts": {
      "description": "number of failed login attemps",
      "type": [
        "integer",
        "null"
      ]
    },
    "mobile": {
      "description": "the other phone number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "opac_notes": {
      "description": "a note on the patron's account visible in OPAC and staff client",
      "type": [
        "string",
        "null"
      ]
    },
    "other_name": {
      "description": "any other names associated with the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "overdrive_auth_token": {
      "description": "persist OverDrive auth token",
      "type": [
        "string",
        "null"
      ]
    },
    "patron_card_lost": {
      "description": "set to 1 if library marked this patron as having lost his card",
      "type": [
        "boolean",
        "null"
      ]
    },
    "patron_id": {
      "description": "Internal patron identifier",
      "type": "integer"
    },
    "phone": {
      "description": "primary phone number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "postal_code": {
      "description": "zip or postal code of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "privacy": {
      "description": "patron's privacy settings related to their reading history",
      "type": "integer"
    },
    "privacy_guarantor_checkouts": {
      "description": "controls if relatives can see this patron's checkouts",
      "type": "integer"
    },
    "relationship_type": {
      "description": "used for children to include the relationship to their guarantor",
      "type": [
        "string",
        "null"
      ]
    },
    "restricted": {
      "description": "If any restriction applies to the patron",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "boolean"
    },
    "secondary_email": {
      "description": "secondary email address for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "secondary_phone": {
      "description": "secondary phone number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "sms_number": {
      "description": "the mobile phone number where the patron would like to receive notices (if SMS turned on)",
      "type": [
        "string",
        "null"
      ]
    },
    "sms_provider_id": {
      "description": "the provider of the mobile phone number defined in smsalertnumber",
      "type": [
        "integer",
        "null"
      ]
    },
    "staff_notes": {
      "description": "a note on the patron's account",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "state or province of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "statistics_1": {
      "description": "a field that can be used for any information unique to the library",
      "type": [
        "string",
        "null"
      ]
    },
    "statistics_2": {
      "description": "a field that can be used for any information unique to the library",
      "type": [
        "string",
        "null"
      ]
    },
    "street_number": {
      "description": "street number of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "street_type": {
      "description": "street type of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "surname": {
      "description": "patron's last name",
      "type": "string"
    },
    "title": {
      "description": "patron's title",
      "type": [
        "string",
        "null"
      ]
    },
    "updated_on": {
      "description": "time of last change could be useful for synchronization with external systems (among others)",
      "format": "date-time",
      "type": "string"
    },
    "userid": {
      "description": "patron's login",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "surname",
    "address",
    "city",
    "library_id",
    "category_id"
  ],
  "type": "object"
}

Response 201

A successfully created patron

{
  "items": {
    "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
    "properties": {
      "address": {
        "description": "first address line of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "address2": {
        "description": "second address line of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_address": {
        "description": "first address line of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_address2": {
        "description": "second address line of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_city": {
        "description": "city or town of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_country": {
        "description": "country of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_email": {
        "description": "email address for patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_notes": {
        "description": "a note related to patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_phone": {
        "description": "phone number for patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_postal_code": {
        "description": "zip or postal code of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_state": {
        "description": "state or province of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_street_number": {
        "description": "street number of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_street_type": {
        "description": "street type of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_address": {
        "description": "the first address line for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_address2": {
        "description": "the second address line for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_city": {
        "description": "the city for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_country": {
        "description": "the country for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_firstname": {
        "description": "first name of alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_phone": {
        "description": "the phone number for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_postal_code": {
        "description": "the zipcode for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_state": {
        "description": "the state for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_surname": {
        "description": "surname or last name of the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "cardnumber": {
        "description": "library assigned user identifier",
        "type": [
          "string",
          "null"
        ]
      },
      "category_id": {
        "description": "Internal identifier for the patron's category",
        "type": "string"
      },
      "check_previous_checkout": {
        "description": "produce a warning for this patron if this item has previously been checked out to this patron if 'yes', not if 'no', defer to category setting if 'inherit'",
        "type": "string"
      },
      "city": {
        "description": "city or town of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "country": {
        "description": "country of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "date_enrolled": {
        "description": "date the patron was added to Koha",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "date_of_birth": {
        "description": "patron's date of birth",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "date_renewed": {
        "description": "date the patron's card was last renewed",
        "type": [
          "string",
          "null"
        ]
      },
      "email": {
        "description": "primary email address for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "expiry_date": {
        "description": "date the patron's card is set to expire",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "fax": {
        "description": "fax number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "firstname": {
        "description": "patron's first name",
        "type": [
          "string",
          "null"
        ]
      },
      "gender": {
        "description": "patron's gender",
        "type": [
          "string",
          "null"
        ]
      },
      "guarantor_id": {
        "description": "patron_id used for children or professionals to link them to guarantor or organizations",
        "type": [
          "integer",
          "null"
        ]
      },
      "incorrect_address": {
        "description": "set to 1 if library marked this patron as having an unconfirmed address",
        "type": [
          "boolean",
          "null"
        ]
      },
      "initials": {
        "description": "initials of the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "lang": {
        "description": "lang to use to send notices to this patron",
        "type": "string"
      },
      "last_seen": {
        "description": "last time a patron has been seen (connected at the OPAC or staff interface)",
        "format": "date-time",
        "type": [
          "string",
          "null"
        ]
      },
      "library_id": {
        "description": "Internal identifier for the patron's home library",
        "type": "string"
      },
      "login_attempts": {
        "description": "number of failed login attemps",
        "type": [
          "integer",
          "null"
        ]
      },
      "mobile": {
        "description": "the other phone number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "opac_notes": {
        "description": "a note on the patron's account visible in OPAC and staff client",
        "type": [
          "string",
          "null"
        ]
      },
      "other_name": {
        "description": "any other names associated with the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "overdrive_auth_token": {
        "description": "persist OverDrive auth token",
        "type": [
          "string",
          "null"
        ]
      },
      "patron_card_lost": {
        "description": "set to 1 if library marked this patron as having lost his card",
        "type": [
          "boolean",
          "null"
        ]
      },
      "patron_id": {
        "description": "Internal patron identifier",
        "type": "integer"
      },
      "phone": {
        "description": "primary phone number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "postal_code": {
        "description": "zip or postal code of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "privacy": {
        "description": "patron's privacy settings related to their reading history",
        "type": "integer"
      },
      "privacy_guarantor_checkouts": {
        "description": "controls if relatives can see this patron's checkouts",
        "type": "integer"
      },
      "relationship_type": {
        "description": "used for children to include the relationship to their guarantor",
        "type": [
          "string",
          "null"
        ]
      },
      "restricted": {
        "description": "If any restriction applies to the patron",
        "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
        "type": "boolean"
      },
      "secondary_email": {
        "description": "secondary email address for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "secondary_phone": {
        "description": "secondary phone number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "sms_number": {
        "description": "the mobile phone number where the patron would like to receive notices (if SMS turned on)",
        "type": [
          "string",
          "null"
        ]
      },
      "sms_provider_id": {
        "description": "the provider of the mobile phone number defined in smsalertnumber",
        "type": [
          "integer",
          "null"
        ]
      },
      "staff_notes": {
        "description": "a note on the patron's account",
        "type": [
          "string",
          "null"
        ]
      },
      "state": {
        "description": "state or province of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "statistics_1": {
        "description": "a field that can be used for any information unique to the library",
        "type": [
          "string",
          "null"
        ]
      },
      "statistics_2": {
        "description": "a field that can be used for any information unique to the library",
        "type": [
          "string",
          "null"
        ]
      },
      "street_number": {
        "description": "street number of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "street_type": {
        "description": "street type of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "surname": {
        "description": "patron's last name",
        "type": "string"
      },
      "title": {
        "description": "patron's title",
        "type": [
          "string",
          "null"
        ]
      },
      "updated_on": {
        "description": "time of last change could be useful for synchronization with external systems (among others)",
        "format": "date-time",
        "type": "string"
      },
      "userid": {
        "description": "patron's login",
        "type": [
          "string",
          "null"
        ]
      }
    },
    "required": [
      "surname",
      "address",
      "city",
      "library_id",
      "category_id"
    ],
    "type": "object"
  }
}

Response 400

Bad parameter

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Resource not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 409

Conflict in creating resource

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/libraries

Operation ID: listLibrary

This resource is not documented.

Parameters

Name In Type Required Description
name query string No Case insensitive 'starts-with' search on name
address1 query string No Case insensitive 'starts-with' search on address1
address2 query string No Case insensitive 'starts-with' search on address2
address3 query string No Case insensitive 'starts-with' search on address3
postal_code query string No Case insensitive 'starts-with' search on postal code
city query string No Case insensitive 'starts-with' search on city
state query string No Case insensitive 'starts-with' search on state
country query string No Case insensitive 'starts_with' search on country
phone query string No Case insensitive 'starts_with' search on phone number
fax query string No Case insensitive 'starts_with' search on fax number
email query string No Case insensitive 'starts_with' search on email address
reply_to_email query string No Case insensitive 'starts_with' search on Reply-To email address
return_path_email query string No Case insensitive 'starts_with' search on Return-Path email address
url query string No Case insensitive 'starts_with' search on website URL
ip query string No Case insensitive 'starts_with' search on IP address
notes query string No Case insensitive 'starts_with' search on notes
opac_info query string No Case insensitive 'starts-with' search on OPAC info

Response 200

A list of libraries

{
  "items": {
    "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
    "properties": {
      "address1": {
        "description": "the first address line of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "address2": {
        "description": "the second address line of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "address3": {
        "description": "the third address line of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "city": {
        "description": "the city or province of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "country": {
        "description": "the county of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "email": {
        "description": "the primary email address of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "fax": {
        "description": "the fax number of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "geolocation": {
        "description": "geolocation of your library",
        "type": [
          "string",
          "null"
        ]
      },
      "ip": {
        "description": "the IP address for your library or branch",
        "type": [
          "string",
          "null"
        ]
      },
      "library_id": {
        "description": "internally assigned library identifier",
        "maxLength": 10,
        "minLength": 1,
        "type": "string"
      },
      "marc_org_code": {
        "description": "MARC Organization Code, see http://www.loc.gov/marc/organizations/orgshome.html, when empty defaults to syspref MARCOrgCode",
        "type": [
          "string",
          "null"
        ]
      },
      "name": {
        "description": "Printable name of library",
        "type": "string"
      },
      "notes": {
        "description": "notes related to your library or branch",
        "type": [
          "string",
          "null"
        ]
      },
      "opac_info": {
        "description": "HTML that displays in OPAC",
        "type": [
          "string",
          "null"
        ]
      },
      "phone": {
        "description": "the primary phone of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "pickup_location": {
        "description": "If the library can act as a pickup location",
        "type": "boolean"
      },
      "postal_code": {
        "description": "the postal code of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "reply_to_email": {
        "description": "the email to be used as a Reply-To",
        "type": [
          "string",
          "null"
        ]
      },
      "return_path_email": {
        "description": "the email to be used as Return-Path",
        "type": [
          "string",
          "null"
        ]
      },
      "state": {
        "description": "the reqional state of the library",
        "type": [
          "string",
          "null"
        ]
      },
      "url": {
        "description": "the URL for your library or branch's website",
        "type": [
          "string",
          "null"
        ]
      }
    },
    "required": [
      "library_id",
      "name"
    ],
    "type": "object"
  },
  "type": "array"
}

Response 500

Internal error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/libraries

Operation ID: addLibrary

This resource is not documented.

Parameters

Name In Type Required Description
body body Yes A JSON object containing informations about the new library

Body

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "address1": {
      "description": "the first address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "the second address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "the third address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "city": {
      "description": "the city or province of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "country": {
      "description": "the county of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "email": {
      "description": "the primary email address of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "fax": {
      "description": "the fax number of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "geolocation": {
      "description": "geolocation of your library",
      "type": [
        "string",
        "null"
      ]
    },
    "ip": {
      "description": "the IP address for your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "internally assigned library identifier",
      "maxLength": 10,
      "minLength": 1,
      "type": "string"
    },
    "marc_org_code": {
      "description": "MARC Organization Code, see http://www.loc.gov/marc/organizations/orgshome.html, when empty defaults to syspref MARCOrgCode",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "Printable name of library",
      "type": "string"
    },
    "notes": {
      "description": "notes related to your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "opac_info": {
      "description": "HTML that displays in OPAC",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "the primary phone of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "pickup_location": {
      "description": "If the library can act as a pickup location",
      "type": "boolean"
    },
    "postal_code": {
      "description": "the postal code of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "reply_to_email": {
      "description": "the email to be used as a Reply-To",
      "type": [
        "string",
        "null"
      ]
    },
    "return_path_email": {
      "description": "the email to be used as Return-Path",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "the reqional state of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "url": {
      "description": "the URL for your library or branch's website",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "library_id",
    "name"
  ],
  "type": "object"
}

Response 201

Library added

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "address1": {
      "description": "the first address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "the second address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "the third address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "city": {
      "description": "the city or province of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "country": {
      "description": "the county of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "email": {
      "description": "the primary email address of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "fax": {
      "description": "the fax number of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "geolocation": {
      "description": "geolocation of your library",
      "type": [
        "string",
        "null"
      ]
    },
    "ip": {
      "description": "the IP address for your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "internally assigned library identifier",
      "maxLength": 10,
      "minLength": 1,
      "type": "string"
    },
    "marc_org_code": {
      "description": "MARC Organization Code, see http://www.loc.gov/marc/organizations/orgshome.html, when empty defaults to syspref MARCOrgCode",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "Printable name of library",
      "type": "string"
    },
    "notes": {
      "description": "notes related to your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "opac_info": {
      "description": "HTML that displays in OPAC",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "the primary phone of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "pickup_location": {
      "description": "If the library can act as a pickup location",
      "type": "boolean"
    },
    "postal_code": {
      "description": "the postal code of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "reply_to_email": {
      "description": "the email to be used as a Reply-To",
      "type": [
        "string",
        "null"
      ]
    },
    "return_path_email": {
      "description": "the email to be used as Return-Path",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "the reqional state of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "url": {
      "description": "the URL for your library or branch's website",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "library_id",
    "name"
  ],
  "type": "object"
}

Response 400

Bad request

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 409

Conflict in creating resource

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/checkouts

Operation ID: listCheckouts

This resource is not documented.

Parameters

Name In Type Required Description
patron_id query integer No Internal patron identifier

Response 200

A list of checkouts

{
  "items": {
    "properties": {
      "auto_renew": {
        "description": "Auto renewal",
        "type": "boolean"
      },
      "auto_renew_error": {
        "description": "Auto renewal error",
        "type": [
          "string",
          "null"
        ]
      },
      "checkin_date": {
        "description": "Date the item was returned",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "checkout_date": {
        "description": "Date the item was issued",
        "format": "date-time",
        "type": "string"
      },
      "checkout_id": {
        "description": "internally assigned checkout identifier",
        "type": "integer"
      },
      "due_date": {
        "description": "Due date",
        "format": "date-time",
        "type": "string"
      },
      "item_id": {
        "description": "internal identifier of checked out item",
        "type": "integer"
      },
      "last_renewed_date": {
        "description": "Date the item was last renewed",
        "format": "date-time",
        "type": [
          "string",
          "null"
        ]
      },
      "library_id": {
        "description": "code of the library the item was checked out",
        "type": [
          "string",
          "null"
        ]
      },
      "note": {
        "description": "Issue note text",
        "type": [
          "string",
          "null"
        ]
      },
      "note_date": {
        "description": "Datetime of the issue note",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "onsite_checkout": {
        "description": "On site checkout",
        "type": "boolean"
      },
      "patron_id": {
        "description": "Internal patron identifier",
        "type": "integer"
      },
      "renewals": {
        "description": "Number of renewals",
        "type": [
          "integer",
          "null"
        ]
      },
      "timestamp": {
        "description": "Last update time",
        "type": "string"
      }
    },
    "type": "object"
  },
  "type": "array"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Patron not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/oauth/token

Operation ID: tokenOAuth

This resource is not documented.

Parameters

Name In Type Required Description
grant_type formData string Yes grant type (client_credentials)
client_id formData string No client id
client_secret formData string No client secret

Response 200

OK

{
  "properties": {
    "access_token": {
      "type": "string"
    },
    "expires_in": {
      "type": "integer"
    },
    "token_type": {
      "type": "string"
    }
  },
  "type": "object"
}

Response 400

Bad Request

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/illrequests

Operation ID: listIllrequests

This resource is not documented.

Parameters

Name In Type Required Description
embed query array No Additional objects that should be embedded in the response
backend query string No The name of a ILL backend
orderid query string No The order ID of a request
biblionumber query integer No Internal biblio identifier
borrowernumber query integer No Internal patron identifier
completed query string No The date the request was considered completed
status query string No A full status string e.g. REQREV
cost query number No The quoted cost of the request
price_paid query number No The final cost of the request
medium query string No The medium of the requested item
updated query string No The last updated date of the request
placed query string No The date the request was placed
branchcode query string No Library ID

Response 200

A list of ILL requests

undef

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

ILL requests not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

DELETE /api/v1/holds/{hold_id}

Operation ID: deleteHold

This resource is not documented.

Parameters

Name In Type Required Description
hold_id path integer Yes Internal hold identifier

Response 200

Successful deletion

{
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Hold not allowed

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Hold not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

PUT /api/v1/holds/{hold_id}

Operation ID: editHold

This resource is not documented.

Parameters

Name In Type Required Description
hold_id path integer Yes Internal hold identifier
body body Yes A JSON object containing fields to modify

Body

{
  "properties": {
    "branchcode": {
      "description": "Pickup location",
      "type": "string"
    },
    "priority": {
      "description": "Position in waiting queue",
      "minimum": 1,
      "type": "integer"
    },
    "suspend_until": {
      "description": "Suspend until",
      "format": "date",
      "type": "string"
    }
  },
  "type": "object"
}

Response 200

Updated hold

{
  "properties": {
    "biblio_id": {
      "description": "Internal biblio identifier",
      "type": "integer"
    },
    "cancelation_date": {
      "description": "The date the hold was cancelled",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "expiration_date": {
      "description": "The date the hold expires",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "hold_date": {
      "description": "The date the hold was placed",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "hold_id": {
      "description": "Internal hold identifier",
      "type": "integer"
    },
    "item_id": {
      "description": "Internal item identifier",
      "type": [
        "string",
        "null"
      ]
    },
    "item_type": {
      "description": "If record level hold, the optional itemtype of the item the patron is requesting",
      "type": [
        "string",
        "null"
      ]
    },
    "lowest_priority": {
      "description": "Controls if the hold is given the lowest priority on the queue",
      "type": "boolean"
    },
    "notes": {
      "description": "Notes related to this hold",
      "type": [
        "string",
        "null"
      ]
    },
    "patron_id": {
      "description": "Internal patron identifier",
      "type": "integer"
    },
    "pickup_library_id": {
      "description": "Internal library identifier for the pickup library",
      "type": [
        "string",
        "null"
      ]
    },
    "priority": {
      "description": "Where in the queue the patron sits",
      "type": [
        "integer",
        "null"
      ]
    },
    "status": {
      "description": "A one letter code defining what the status of the hold is after it has been confirmed",
      "type": [
        "string",
        "null"
      ]
    },
    "suspended": {
      "description": "Controls if the hold is suspended",
      "type": "boolean"
    },
    "suspended_until": {
      "description": "Date until which the hold has been suspended",
      "format": "date-time",
      "type": [
        "string",
        "null"
      ]
    },
    "timestamp": {
      "description": "Timestamp for the latest hold update",
      "format": "date-time",
      "type": "string"
    },
    "waiting_date": {
      "description": "The date the item was marked as waiting for the patron at the library",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "type": "object"
}

Response 400

Missing or wrong parameters

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Hold not allowed

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Hold not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

DELETE /api/v1/cities/{city_id}

Operation ID: deleteCity

This resource is not documented.

Parameters

Name In Type Required Description
city_id path integer Yes City internal identifier

Response 200

City deleted

{
  "type": "string"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

City not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/cities/{city_id}

Operation ID: getCity

This resource is not documented.

Parameters

Name In Type Required Description
city_id path integer Yes City internal identifier

Response 200

A city

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "city_id": {
      "description": "internally assigned city identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "country": {
      "description": "city country",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "city name",
      "type": "string"
    },
    "postal_code": {
      "description": "city postal code",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "city state",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name",
    "state",
    "postal_code",
    "country"
  ],
  "type": "object"
}

Response 404

City not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

PUT /api/v1/cities/{city_id}

Operation ID: updateCity

This resource is not documented.

Parameters

Name In Type Required Description
city_id path integer Yes City internal identifier
body body Yes A city object

Body

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "city_id": {
      "description": "internally assigned city identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "country": {
      "description": "city country",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "city name",
      "type": "string"
    },
    "postal_code": {
      "description": "city postal code",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "city state",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name",
    "state",
    "postal_code",
    "country"
  ],
  "type": "object"
}

Response 200

A city

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "city_id": {
      "description": "internally assigned city identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "country": {
      "description": "city country",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "city name",
      "type": "string"
    },
    "postal_code": {
      "description": "city postal code",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "city state",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name",
    "state",
    "postal_code",
    "country"
  ],
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

City not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/acquisitions/funds

Operation ID: listFunds

This resource is not documented.

Parameters

Name In Type Required Description
name query string No Case insensitive search on fund name
fund_owner_id query integer No Display only the funds that belongs to the given patron ID

Response 200

A list of funds

{
  "items": {
    "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
    "properties": {
      "budget_id": {
        "description": "Internal identifier for the budget",
        "type": [
          "number",
          "null"
        ]
      },
      "code": {
        "description": "Code assigned to the fund by the user",
        "type": [
          "string",
          "null"
        ]
      },
      "fund_access": {
        "description": "Level of permission for this fund (1: owner, 2: owner, users and library, 3: owner and users)",
        "type": [
          "number",
          "null"
        ]
      },
      "fund_id": {
        "description": "internally assigned fund identifier",
        "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
        "type": "integer"
      },
      "fund_owner_id": {
        "description": "Internal identifier for the fund owner",
        "type": [
          "number",
          "null"
        ]
      },
      "library_id": {
        "description": "Internal identifier for the library that this fund belongs to",
        "type": [
          "string",
          "null"
        ]
      },
      "name": {
        "description": "Name assigned to the fund by the user",
        "type": [
          "string",
          "null"
        ]
      },
      "notes": {
        "description": "Notes related to this fund",
        "type": [
          "string",
          "null"
        ]
      },
      "statistic1_auth_value_category": {
        "description": "Statistical category for this fund",
        "type": [
          "string",
          "null"
        ]
      },
      "statistic2_auth_value_category": {
        "description": "Second statistical category for this fund",
        "type": [
          "string",
          "null"
        ]
      },
      "timestamp": {
        "description": "Timestamp",
        "format": "date-time",
        "type": [
          "string"
        ]
      },
      "total_amount": {
        "description": "Total amount for this fund",
        "type": [
          "number",
          "null"
        ]
      },
      "warn_at_amount": {
        "description": "Warning at amount",
        "type": [
          "number",
          "null"
        ]
      },
      "warn_at_percentage": {
        "description": "Warning at percentage",
        "type": [
          "number",
          "null"
        ]
      }
    },
    "required": [
      "name"
    ],
    "type": "object"
  },
  "type": "array"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Fund not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

DELETE /api/v1/patrons/{patron_id}

Operation ID: deletePatron

This resource is not documented.

Parameters

Name In Type Required Description
patron_id path integer Yes Internal patron identifier

Response 200

Patron deleted successfully

{
  "type": "object"
}

Response 400

Patron deletion failed

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Patron not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/patrons/{patron_id}

Operation ID: getPatron

This resource is not documented.

Parameters

Name In Type Required Description
patron_id path integer Yes Internal patron identifier

Response 200

A patron

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "address": {
      "description": "first address line of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "second address line of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_address": {
      "description": "first address line of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_address2": {
      "description": "second address line of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_city": {
      "description": "city or town of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_country": {
      "description": "country of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_email": {
      "description": "email address for patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_notes": {
      "description": "a note related to patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_phone": {
      "description": "phone number for patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_postal_code": {
      "description": "zip or postal code of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_state": {
      "description": "state or province of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_street_number": {
      "description": "street number of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_street_type": {
      "description": "street type of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_address": {
      "description": "the first address line for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_address2": {
      "description": "the second address line for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_city": {
      "description": "the city for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_country": {
      "description": "the country for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_firstname": {
      "description": "first name of alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_phone": {
      "description": "the phone number for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_postal_code": {
      "description": "the zipcode for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_state": {
      "description": "the state for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_surname": {
      "description": "surname or last name of the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "cardnumber": {
      "description": "library assigned user identifier",
      "type": [
        "string",
        "null"
      ]
    },
    "category_id": {
      "description": "Internal identifier for the patron's category",
      "type": "string"
    },
    "check_previous_checkout": {
      "description": "produce a warning for this patron if this item has previously been checked out to this patron if 'yes', not if 'no', defer to category setting if 'inherit'",
      "type": "string"
    },
    "city": {
      "description": "city or town of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "country": {
      "description": "country of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "date_enrolled": {
      "description": "date the patron was added to Koha",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "date_of_birth": {
      "description": "patron's date of birth",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "date_renewed": {
      "description": "date the patron's card was last renewed",
      "type": [
        "string",
        "null"
      ]
    },
    "email": {
      "description": "primary email address for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "expiry_date": {
      "description": "date the patron's card is set to expire",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "fax": {
      "description": "fax number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "firstname": {
      "description": "patron's first name",
      "type": [
        "string",
        "null"
      ]
    },
    "gender": {
      "description": "patron's gender",
      "type": [
        "string",
        "null"
      ]
    },
    "guarantor_id": {
      "description": "patron_id used for children or professionals to link them to guarantor or organizations",
      "type": [
        "integer",
        "null"
      ]
    },
    "incorrect_address": {
      "description": "set to 1 if library marked this patron as having an unconfirmed address",
      "type": [
        "boolean",
        "null"
      ]
    },
    "initials": {
      "description": "initials of the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "lang": {
      "description": "lang to use to send notices to this patron",
      "type": "string"
    },
    "last_seen": {
      "description": "last time a patron has been seen (connected at the OPAC or staff interface)",
      "format": "date-time",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "Internal identifier for the patron's home library",
      "type": "string"
    },
    "login_attempts": {
      "description": "number of failed login attemps",
      "type": [
        "integer",
        "null"
      ]
    },
    "mobile": {
      "description": "the other phone number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "opac_notes": {
      "description": "a note on the patron's account visible in OPAC and staff client",
      "type": [
        "string",
        "null"
      ]
    },
    "other_name": {
      "description": "any other names associated with the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "overdrive_auth_token": {
      "description": "persist OverDrive auth token",
      "type": [
        "string",
        "null"
      ]
    },
    "patron_card_lost": {
      "description": "set to 1 if library marked this patron as having lost his card",
      "type": [
        "boolean",
        "null"
      ]
    },
    "patron_id": {
      "description": "Internal patron identifier",
      "type": "integer"
    },
    "phone": {
      "description": "primary phone number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "postal_code": {
      "description": "zip or postal code of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "privacy": {
      "description": "patron's privacy settings related to their reading history",
      "type": "integer"
    },
    "privacy_guarantor_checkouts": {
      "description": "controls if relatives can see this patron's checkouts",
      "type": "integer"
    },
    "relationship_type": {
      "description": "used for children to include the relationship to their guarantor",
      "type": [
        "string",
        "null"
      ]
    },
    "restricted": {
      "description": "If any restriction applies to the patron",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "boolean"
    },
    "secondary_email": {
      "description": "secondary email address for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "secondary_phone": {
      "description": "secondary phone number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "sms_number": {
      "description": "the mobile phone number where the patron would like to receive notices (if SMS turned on)",
      "type": [
        "string",
        "null"
      ]
    },
    "sms_provider_id": {
      "description": "the provider of the mobile phone number defined in smsalertnumber",
      "type": [
        "integer",
        "null"
      ]
    },
    "staff_notes": {
      "description": "a note on the patron's account",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "state or province of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "statistics_1": {
      "description": "a field that can be used for any information unique to the library",
      "type": [
        "string",
        "null"
      ]
    },
    "statistics_2": {
      "description": "a field that can be used for any information unique to the library",
      "type": [
        "string",
        "null"
      ]
    },
    "street_number": {
      "description": "street number of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "street_type": {
      "description": "street type of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "surname": {
      "description": "patron's last name",
      "type": "string"
    },
    "title": {
      "description": "patron's title",
      "type": [
        "string",
        "null"
      ]
    },
    "updated_on": {
      "description": "time of last change could be useful for synchronization with external systems (among others)",
      "format": "date-time",
      "type": "string"
    },
    "userid": {
      "description": "patron's login",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "surname",
    "address",
    "city",
    "library_id",
    "category_id"
  ],
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Patron not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

PUT /api/v1/patrons/{patron_id}

Operation ID: updatePatron

This resource is not documented.

Parameters

Name In Type Required Description
patron_id path integer Yes Internal patron identifier
body body Yes A JSON object containing new information about existing patron

Body

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "address": {
      "description": "first address line of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "second address line of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_address": {
      "description": "first address line of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_address2": {
      "description": "second address line of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_city": {
      "description": "city or town of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_country": {
      "description": "country of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_email": {
      "description": "email address for patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_notes": {
      "description": "a note related to patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_phone": {
      "description": "phone number for patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_postal_code": {
      "description": "zip or postal code of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_state": {
      "description": "state or province of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_street_number": {
      "description": "street number of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altaddress_street_type": {
      "description": "street type of patron's alternate address",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_address": {
      "description": "the first address line for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_address2": {
      "description": "the second address line for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_city": {
      "description": "the city for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_country": {
      "description": "the country for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_firstname": {
      "description": "first name of alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_phone": {
      "description": "the phone number for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_postal_code": {
      "description": "the zipcode for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_state": {
      "description": "the state for the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "altcontact_surname": {
      "description": "surname or last name of the alternate contact for the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "cardnumber": {
      "description": "library assigned user identifier",
      "type": [
        "string",
        "null"
      ]
    },
    "category_id": {
      "description": "Internal identifier for the patron's category",
      "type": "string"
    },
    "check_previous_checkout": {
      "description": "produce a warning for this patron if this item has previously been checked out to this patron if 'yes', not if 'no', defer to category setting if 'inherit'",
      "type": "string"
    },
    "city": {
      "description": "city or town of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "country": {
      "description": "country of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "date_enrolled": {
      "description": "date the patron was added to Koha",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "date_of_birth": {
      "description": "patron's date of birth",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "date_renewed": {
      "description": "date the patron's card was last renewed",
      "type": [
        "string",
        "null"
      ]
    },
    "email": {
      "description": "primary email address for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "expiry_date": {
      "description": "date the patron's card is set to expire",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "fax": {
      "description": "fax number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "firstname": {
      "description": "patron's first name",
      "type": [
        "string",
        "null"
      ]
    },
    "gender": {
      "description": "patron's gender",
      "type": [
        "string",
        "null"
      ]
    },
    "guarantor_id": {
      "description": "patron_id used for children or professionals to link them to guarantor or organizations",
      "type": [
        "integer",
        "null"
      ]
    },
    "incorrect_address": {
      "description": "set to 1 if library marked this patron as having an unconfirmed address",
      "type": [
        "boolean",
        "null"
      ]
    },
    "initials": {
      "description": "initials of the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "lang": {
      "description": "lang to use to send notices to this patron",
      "type": "string"
    },
    "last_seen": {
      "description": "last time a patron has been seen (connected at the OPAC or staff interface)",
      "format": "date-time",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "Internal identifier for the patron's home library",
      "type": "string"
    },
    "login_attempts": {
      "description": "number of failed login attemps",
      "type": [
        "integer",
        "null"
      ]
    },
    "mobile": {
      "description": "the other phone number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "opac_notes": {
      "description": "a note on the patron's account visible in OPAC and staff client",
      "type": [
        "string",
        "null"
      ]
    },
    "other_name": {
      "description": "any other names associated with the patron",
      "type": [
        "string",
        "null"
      ]
    },
    "overdrive_auth_token": {
      "description": "persist OverDrive auth token",
      "type": [
        "string",
        "null"
      ]
    },
    "patron_card_lost": {
      "description": "set to 1 if library marked this patron as having lost his card",
      "type": [
        "boolean",
        "null"
      ]
    },
    "patron_id": {
      "description": "Internal patron identifier",
      "type": "integer"
    },
    "phone": {
      "description": "primary phone number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "postal_code": {
      "description": "zip or postal code of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "privacy": {
      "description": "patron's privacy settings related to their reading history",
      "type": "integer"
    },
    "privacy_guarantor_checkouts": {
      "description": "controls if relatives can see this patron's checkouts",
      "type": "integer"
    },
    "relationship_type": {
      "description": "used for children to include the relationship to their guarantor",
      "type": [
        "string",
        "null"
      ]
    },
    "restricted": {
      "description": "If any restriction applies to the patron",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "boolean"
    },
    "secondary_email": {
      "description": "secondary email address for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "secondary_phone": {
      "description": "secondary phone number for patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "sms_number": {
      "description": "the mobile phone number where the patron would like to receive notices (if SMS turned on)",
      "type": [
        "string",
        "null"
      ]
    },
    "sms_provider_id": {
      "description": "the provider of the mobile phone number defined in smsalertnumber",
      "type": [
        "integer",
        "null"
      ]
    },
    "staff_notes": {
      "description": "a note on the patron's account",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "state or province of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "statistics_1": {
      "description": "a field that can be used for any information unique to the library",
      "type": [
        "string",
        "null"
      ]
    },
    "statistics_2": {
      "description": "a field that can be used for any information unique to the library",
      "type": [
        "string",
        "null"
      ]
    },
    "street_number": {
      "description": "street number of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "street_type": {
      "description": "street type of patron's primary address",
      "type": [
        "string",
        "null"
      ]
    },
    "surname": {
      "description": "patron's last name",
      "type": "string"
    },
    "title": {
      "description": "patron's title",
      "type": [
        "string",
        "null"
      ]
    },
    "updated_on": {
      "description": "time of last change could be useful for synchronization with external systems (among others)",
      "format": "date-time",
      "type": "string"
    },
    "userid": {
      "description": "patron's login",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "surname",
    "address",
    "city",
    "library_id",
    "category_id"
  ],
  "type": "object"
}

Response 200

A successfully updated patron

{
  "items": {
    "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
    "properties": {
      "address": {
        "description": "first address line of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "address2": {
        "description": "second address line of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_address": {
        "description": "first address line of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_address2": {
        "description": "second address line of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_city": {
        "description": "city or town of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_country": {
        "description": "country of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_email": {
        "description": "email address for patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_notes": {
        "description": "a note related to patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_phone": {
        "description": "phone number for patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_postal_code": {
        "description": "zip or postal code of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_state": {
        "description": "state or province of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_street_number": {
        "description": "street number of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altaddress_street_type": {
        "description": "street type of patron's alternate address",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_address": {
        "description": "the first address line for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_address2": {
        "description": "the second address line for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_city": {
        "description": "the city for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_country": {
        "description": "the country for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_firstname": {
        "description": "first name of alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_phone": {
        "description": "the phone number for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_postal_code": {
        "description": "the zipcode for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_state": {
        "description": "the state for the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "altcontact_surname": {
        "description": "surname or last name of the alternate contact for the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "cardnumber": {
        "description": "library assigned user identifier",
        "type": [
          "string",
          "null"
        ]
      },
      "category_id": {
        "description": "Internal identifier for the patron's category",
        "type": "string"
      },
      "check_previous_checkout": {
        "description": "produce a warning for this patron if this item has previously been checked out to this patron if 'yes', not if 'no', defer to category setting if 'inherit'",
        "type": "string"
      },
      "city": {
        "description": "city or town of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "country": {
        "description": "country of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "date_enrolled": {
        "description": "date the patron was added to Koha",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "date_of_birth": {
        "description": "patron's date of birth",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "date_renewed": {
        "description": "date the patron's card was last renewed",
        "type": [
          "string",
          "null"
        ]
      },
      "email": {
        "description": "primary email address for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "expiry_date": {
        "description": "date the patron's card is set to expire",
        "format": "date",
        "type": [
          "string",
          "null"
        ]
      },
      "fax": {
        "description": "fax number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "firstname": {
        "description": "patron's first name",
        "type": [
          "string",
          "null"
        ]
      },
      "gender": {
        "description": "patron's gender",
        "type": [
          "string",
          "null"
        ]
      },
      "guarantor_id": {
        "description": "patron_id used for children or professionals to link them to guarantor or organizations",
        "type": [
          "integer",
          "null"
        ]
      },
      "incorrect_address": {
        "description": "set to 1 if library marked this patron as having an unconfirmed address",
        "type": [
          "boolean",
          "null"
        ]
      },
      "initials": {
        "description": "initials of the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "lang": {
        "description": "lang to use to send notices to this patron",
        "type": "string"
      },
      "last_seen": {
        "description": "last time a patron has been seen (connected at the OPAC or staff interface)",
        "format": "date-time",
        "type": [
          "string",
          "null"
        ]
      },
      "library_id": {
        "description": "Internal identifier for the patron's home library",
        "type": "string"
      },
      "login_attempts": {
        "description": "number of failed login attemps",
        "type": [
          "integer",
          "null"
        ]
      },
      "mobile": {
        "description": "the other phone number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "opac_notes": {
        "description": "a note on the patron's account visible in OPAC and staff client",
        "type": [
          "string",
          "null"
        ]
      },
      "other_name": {
        "description": "any other names associated with the patron",
        "type": [
          "string",
          "null"
        ]
      },
      "overdrive_auth_token": {
        "description": "persist OverDrive auth token",
        "type": [
          "string",
          "null"
        ]
      },
      "patron_card_lost": {
        "description": "set to 1 if library marked this patron as having lost his card",
        "type": [
          "boolean",
          "null"
        ]
      },
      "patron_id": {
        "description": "Internal patron identifier",
        "type": "integer"
      },
      "phone": {
        "description": "primary phone number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "postal_code": {
        "description": "zip or postal code of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "privacy": {
        "description": "patron's privacy settings related to their reading history",
        "type": "integer"
      },
      "privacy_guarantor_checkouts": {
        "description": "controls if relatives can see this patron's checkouts",
        "type": "integer"
      },
      "relationship_type": {
        "description": "used for children to include the relationship to their guarantor",
        "type": [
          "string",
          "null"
        ]
      },
      "restricted": {
        "description": "If any restriction applies to the patron",
        "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
        "type": "boolean"
      },
      "secondary_email": {
        "description": "secondary email address for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "secondary_phone": {
        "description": "secondary phone number for patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "sms_number": {
        "description": "the mobile phone number where the patron would like to receive notices (if SMS turned on)",
        "type": [
          "string",
          "null"
        ]
      },
      "sms_provider_id": {
        "description": "the provider of the mobile phone number defined in smsalertnumber",
        "type": [
          "integer",
          "null"
        ]
      },
      "staff_notes": {
        "description": "a note on the patron's account",
        "type": [
          "string",
          "null"
        ]
      },
      "state": {
        "description": "state or province of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "statistics_1": {
        "description": "a field that can be used for any information unique to the library",
        "type": [
          "string",
          "null"
        ]
      },
      "statistics_2": {
        "description": "a field that can be used for any information unique to the library",
        "type": [
          "string",
          "null"
        ]
      },
      "street_number": {
        "description": "street number of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "street_type": {
        "description": "street type of patron's primary address",
        "type": [
          "string",
          "null"
        ]
      },
      "surname": {
        "description": "patron's last name",
        "type": "string"
      },
      "title": {
        "description": "patron's title",
        "type": [
          "string",
          "null"
        ]
      },
      "updated_on": {
        "description": "time of last change could be useful for synchronization with external systems (among others)",
        "format": "date-time",
        "type": "string"
      },
      "userid": {
        "description": "patron's login",
        "type": [
          "string",
          "null"
        ]
      }
    },
    "required": [
      "surname",
      "address",
      "city",
      "library_id",
      "category_id"
    ],
    "type": "object"
  }
}

Response 202

Accepted and waiting for librarian verification

{
  "type": "object"
}

Response 204

No Content

{
  "type": "object"
}

Response 400

Bad parameter

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Resource not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 409

Conflict in updating resource

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/acquisitions/vendors

Operation ID: listVendors

This resource is not documented.

Parameters

Name In Type Required Description
name query string No Case insensitive search on vendor name
accountnumber query string No Case insensitive search on vendor's account number

Response 200

A list of vendors

{
  "items": {
    "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
    "properties": {
      "accountnumber": {
        "description": "Vendor account number",
        "type": [
          "string",
          "null"
        ]
      },
      "active": {
        "description": "Is this vendor active",
        "type": [
          "boolean",
          "null"
        ]
      },
      "address1": {
        "description": "Vendor physical address (line 1)",
        "type": [
          "string",
          "null"
        ]
      },
      "address2": {
        "description": "Vendor physical address (line 2)",
        "type": [
          "string",
          "null"
        ]
      },
      "address3": {
        "description": "Vendor physical address (line 3)",
        "type": [
          "string",
          "null"
        ]
      },
      "address4": {
        "description": "Vendor physical address (line 4)",
        "type": [
          "string",
          "null"
        ]
      },
      "deliverytime": {
        "description": "Expected delivery time (in days)",
        "type": [
          "integer",
          "null"
        ]
      },
      "discount": {
        "description": "Default discount rate for items ordered from this vendor",
        "type": [
          "number",
          "null"
        ]
      },
      "fax": {
        "description": "Vendor fax number",
        "type": [
          "string",
          "null"
        ]
      },
      "gst": {
        "description": "Is the library taxed when buying from this vendor",
        "type": [
          "boolean",
          "null"
        ]
      },
      "id": {
        "description": "internally assigned vendor identifier",
        "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
        "type": "integer"
      },
      "invoice_currency": {
        "description": "Invoice prices currency",
        "type": [
          "string",
          "null"
        ]
      },
      "invoice_includes_gst": {
        "description": "Invoice prices include taxes",
        "type": [
          "boolean",
          "null"
        ]
      },
      "list_currency": {
        "description": "List prices currency",
        "type": [
          "string",
          "null"
        ]
      },
      "list_includes_gst": {
        "description": "List prices include taxes",
        "type": [
          "boolean",
          "null"
        ]
      },
      "name": {
        "description": "Vendor name",
        "type": [
          "string"
        ]
      },
      "notes": {
        "description": "Vendor notes",
        "type": [
          "string",
          "null"
        ]
      },
      "phone": {
        "description": "Vendor phone number",
        "type": [
          "string",
          "null"
        ]
      },
      "postal": {
        "description": "Vendor postal address",
        "type": [
          "string",
          "null"
        ]
      },
      "tax_rate": {
        "description": "Default tax rate for items ordered from this vendor",
        "type": [
          "number",
          "null"
        ]
      },
      "url": {
        "description": "Vendor web address",
        "type": [
          "string",
          "null"
        ]
      }
    },
    "required": [
      "name"
    ],
    "type": "object"
  },
  "type": "array"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Vendor not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/acquisitions/vendors

Operation ID: addVendor

This resource is not documented.

Parameters

Name In Type Required Description
body body Yes A JSON object representing a vendor

Body

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "accountnumber": {
      "description": "Vendor account number",
      "type": [
        "string",
        "null"
      ]
    },
    "active": {
      "description": "Is this vendor active",
      "type": [
        "boolean",
        "null"
      ]
    },
    "address1": {
      "description": "Vendor physical address (line 1)",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "Vendor physical address (line 2)",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "Vendor physical address (line 3)",
      "type": [
        "string",
        "null"
      ]
    },
    "address4": {
      "description": "Vendor physical address (line 4)",
      "type": [
        "string",
        "null"
      ]
    },
    "deliverytime": {
      "description": "Expected delivery time (in days)",
      "type": [
        "integer",
        "null"
      ]
    },
    "discount": {
      "description": "Default discount rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "fax": {
      "description": "Vendor fax number",
      "type": [
        "string",
        "null"
      ]
    },
    "gst": {
      "description": "Is the library taxed when buying from this vendor",
      "type": [
        "boolean",
        "null"
      ]
    },
    "id": {
      "description": "internally assigned vendor identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "invoice_currency": {
      "description": "Invoice prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "invoice_includes_gst": {
      "description": "Invoice prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "list_currency": {
      "description": "List prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "list_includes_gst": {
      "description": "List prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "name": {
      "description": "Vendor name",
      "type": [
        "string"
      ]
    },
    "notes": {
      "description": "Vendor notes",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "Vendor phone number",
      "type": [
        "string",
        "null"
      ]
    },
    "postal": {
      "description": "Vendor postal address",
      "type": [
        "string",
        "null"
      ]
    },
    "tax_rate": {
      "description": "Default tax rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "url": {
      "description": "Vendor web address",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name"
  ],
  "type": "object"
}

Response 200

Vendor added

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "accountnumber": {
      "description": "Vendor account number",
      "type": [
        "string",
        "null"
      ]
    },
    "active": {
      "description": "Is this vendor active",
      "type": [
        "boolean",
        "null"
      ]
    },
    "address1": {
      "description": "Vendor physical address (line 1)",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "Vendor physical address (line 2)",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "Vendor physical address (line 3)",
      "type": [
        "string",
        "null"
      ]
    },
    "address4": {
      "description": "Vendor physical address (line 4)",
      "type": [
        "string",
        "null"
      ]
    },
    "deliverytime": {
      "description": "Expected delivery time (in days)",
      "type": [
        "integer",
        "null"
      ]
    },
    "discount": {
      "description": "Default discount rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "fax": {
      "description": "Vendor fax number",
      "type": [
        "string",
        "null"
      ]
    },
    "gst": {
      "description": "Is the library taxed when buying from this vendor",
      "type": [
        "boolean",
        "null"
      ]
    },
    "id": {
      "description": "internally assigned vendor identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "invoice_currency": {
      "description": "Invoice prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "invoice_includes_gst": {
      "description": "Invoice prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "list_currency": {
      "description": "List prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "list_includes_gst": {
      "description": "List prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "name": {
      "description": "Vendor name",
      "type": [
        "string"
      ]
    },
    "notes": {
      "description": "Vendor notes",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "Vendor phone number",
      "type": [
        "string",
        "null"
      ]
    },
    "postal": {
      "description": "Vendor postal address",
      "type": [
        "string",
        "null"
      ]
    },
    "tax_rate": {
      "description": "Default tax rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "url": {
      "description": "Vendor web address",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name"
  ],
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Vendor not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

DELETE /api/v1/libraries/{library_id}

Operation ID: deleteLibrary

This resource is not documented.

Parameters

Name In Type Required Description
library_id path string Yes Internal library identifier

Response 204

Library deleted

{
  "type": "string"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Library not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/libraries/{library_id}

Operation ID: getLibrary

This resource is not documented.

Parameters

Name In Type Required Description
library_id path string Yes Internal library identifier

Response 200

A library

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "address1": {
      "description": "the first address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "the second address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "the third address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "city": {
      "description": "the city or province of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "country": {
      "description": "the county of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "email": {
      "description": "the primary email address of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "fax": {
      "description": "the fax number of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "geolocation": {
      "description": "geolocation of your library",
      "type": [
        "string",
        "null"
      ]
    },
    "ip": {
      "description": "the IP address for your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "internally assigned library identifier",
      "maxLength": 10,
      "minLength": 1,
      "type": "string"
    },
    "marc_org_code": {
      "description": "MARC Organization Code, see http://www.loc.gov/marc/organizations/orgshome.html, when empty defaults to syspref MARCOrgCode",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "Printable name of library",
      "type": "string"
    },
    "notes": {
      "description": "notes related to your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "opac_info": {
      "description": "HTML that displays in OPAC",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "the primary phone of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "pickup_location": {
      "description": "If the library can act as a pickup location",
      "type": "boolean"
    },
    "postal_code": {
      "description": "the postal code of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "reply_to_email": {
      "description": "the email to be used as a Reply-To",
      "type": [
        "string",
        "null"
      ]
    },
    "return_path_email": {
      "description": "the email to be used as Return-Path",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "the reqional state of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "url": {
      "description": "the URL for your library or branch's website",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "library_id",
    "name"
  ],
  "type": "object"
}

Response 404

Library not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

PUT /api/v1/libraries/{library_id}

Operation ID: updateLibrary

This resource is not documented.

Parameters

Name In Type Required Description
library_id path string Yes Internal library identifier
body body Yes A JSON object containing information on the library

Body

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "address1": {
      "description": "the first address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "the second address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "the third address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "city": {
      "description": "the city or province of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "country": {
      "description": "the county of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "email": {
      "description": "the primary email address of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "fax": {
      "description": "the fax number of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "geolocation": {
      "description": "geolocation of your library",
      "type": [
        "string",
        "null"
      ]
    },
    "ip": {
      "description": "the IP address for your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "internally assigned library identifier",
      "maxLength": 10,
      "minLength": 1,
      "type": "string"
    },
    "marc_org_code": {
      "description": "MARC Organization Code, see http://www.loc.gov/marc/organizations/orgshome.html, when empty defaults to syspref MARCOrgCode",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "Printable name of library",
      "type": "string"
    },
    "notes": {
      "description": "notes related to your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "opac_info": {
      "description": "HTML that displays in OPAC",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "the primary phone of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "pickup_location": {
      "description": "If the library can act as a pickup location",
      "type": "boolean"
    },
    "postal_code": {
      "description": "the postal code of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "reply_to_email": {
      "description": "the email to be used as a Reply-To",
      "type": [
        "string",
        "null"
      ]
    },
    "return_path_email": {
      "description": "the email to be used as Return-Path",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "the reqional state of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "url": {
      "description": "the URL for your library or branch's website",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "library_id",
    "name"
  ],
  "type": "object"
}

Response 200

A library

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "address1": {
      "description": "the first address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "the second address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "the third address line of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "city": {
      "description": "the city or province of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "country": {
      "description": "the county of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "email": {
      "description": "the primary email address of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "fax": {
      "description": "the fax number of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "geolocation": {
      "description": "geolocation of your library",
      "type": [
        "string",
        "null"
      ]
    },
    "ip": {
      "description": "the IP address for your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "internally assigned library identifier",
      "maxLength": 10,
      "minLength": 1,
      "type": "string"
    },
    "marc_org_code": {
      "description": "MARC Organization Code, see http://www.loc.gov/marc/organizations/orgshome.html, when empty defaults to syspref MARCOrgCode",
      "type": [
        "string",
        "null"
      ]
    },
    "name": {
      "description": "Printable name of library",
      "type": "string"
    },
    "notes": {
      "description": "notes related to your library or branch",
      "type": [
        "string",
        "null"
      ]
    },
    "opac_info": {
      "description": "HTML that displays in OPAC",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "the primary phone of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "pickup_location": {
      "description": "If the library can act as a pickup location",
      "type": "boolean"
    },
    "postal_code": {
      "description": "the postal code of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "reply_to_email": {
      "description": "the email to be used as a Reply-To",
      "type": [
        "string",
        "null"
      ]
    },
    "return_path_email": {
      "description": "the email to be used as Return-Path",
      "type": [
        "string",
        "null"
      ]
    },
    "state": {
      "description": "the reqional state of the library",
      "type": [
        "string",
        "null"
      ]
    },
    "url": {
      "description": "the URL for your library or branch's website",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "library_id",
    "name"
  ],
  "type": "object"
}

Response 400

Bad request

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Library not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/checkouts/{checkout_id}

Operation ID: getCheckout

This resource is not documented.

Parameters

Name In Type Required Description
checkout_id path integer Yes Internal checkout identifier

Response 200

Updated borrower's checkout

{
  "properties": {
    "auto_renew": {
      "description": "Auto renewal",
      "type": "boolean"
    },
    "auto_renew_error": {
      "description": "Auto renewal error",
      "type": [
        "string",
        "null"
      ]
    },
    "checkin_date": {
      "description": "Date the item was returned",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "checkout_date": {
      "description": "Date the item was issued",
      "format": "date-time",
      "type": "string"
    },
    "checkout_id": {
      "description": "internally assigned checkout identifier",
      "type": "integer"
    },
    "due_date": {
      "description": "Due date",
      "format": "date-time",
      "type": "string"
    },
    "item_id": {
      "description": "internal identifier of checked out item",
      "type": "integer"
    },
    "last_renewed_date": {
      "description": "Date the item was last renewed",
      "format": "date-time",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "code of the library the item was checked out",
      "type": [
        "string",
        "null"
      ]
    },
    "note": {
      "description": "Issue note text",
      "type": [
        "string",
        "null"
      ]
    },
    "note_date": {
      "description": "Datetime of the issue note",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "onsite_checkout": {
      "description": "On site checkout",
      "type": "boolean"
    },
    "patron_id": {
      "description": "Internal patron identifier",
      "type": "integer"
    },
    "renewals": {
      "description": "Number of renewals",
      "type": [
        "integer",
        "null"
      ]
    },
    "timestamp": {
      "description": "Last update time",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Checkout not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

DELETE /api/v1/holds/{hold_id}/suspension

Operation ID: resumeHold

This resource is not documented.

Parameters

Name In Type Required Description
hold_id path integer Yes Internal hold identifier

Response 204

Hold resumed

undef

Response 400

Missing or wrong parameters

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Hold not allowed

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Hold not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/holds/{hold_id}/suspension

Operation ID: suspendHold

This resource is not documented.

Parameters

Name In Type Required Description
hold_id path integer Yes Internal hold identifier
body body No A JSON object containing fields to modify

Body

{
  "properties": {
    "end_date": {
      "description": "Date the hold suspension expires",
      "format": "date",
      "type": "string"
    }
  },
  "type": "object"
}

Response 201

Hold suspended

undef

Response 400

Missing or wrong parameters

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Hold not allowed

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Hold not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/patrons/{patron_id}/account

Operation ID: getPatronAccount

This resource is not documented.

Parameters

Name In Type Required Description
patron_id path integer Yes Internal patron identifier

Response 200

Patron's account balance

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "balance": {
      "description": "Signed decimal number",
      "type": "number"
    },
    "outstanding_credits": {
      "properties": {
        "lines": {
          "items": {
            "properties": {
              "account_line_id": {
                "description": "Internal account line identifier",
                "type": "integer"
              },
              "account_type": {
                "description": "Account line type",
                "type": "string"
              },
              "amount": {
                "description": "Account line amount",
                "type": "number"
              },
              "amount_outstanding": {
                "description": "Outstanding amount",
                "type": "number"
              },
              "checkout_id": {
                "description": "Internal identifier for the checkout the account line is related to",
                "type": [
                  "integer",
                  "null"
                ]
              },
              "date": {
                "description": "Date the account line was created",
                "format": "date",
                "type": "string"
              },
              "description": {
                "description": "Account line description",
                "type": [
                  "string",
                  "null"
                ]
              },
              "internal_note": {
                "description": "Internal note",
                "type": [
                  "string",
                  "null"
                ]
              },
              "item_id": {
                "description": "Internal identifier for the item the account line is related to",
                "type": [
                  "integer",
                  "null"
                ]
              },
              "last_increment": {
                "description": "The amount the line was increased last time",
                "type": [
                  "number",
                  "null"
                ]
              },
              "patron_id": {
                "description": "Internal identifier for the patron the account line belongs to",
                "type": "integer"
              },
              "payment_type": {
                "description": "Payment type",
                "type": [
                  "string",
                  "null"
                ]
              },
              "timestamp": {
                "description": "Timestamp for the latest line update",
                "format": "date-time",
                "type": "string"
              },
              "user_id": {
                "description": "Internal patron identifier for the staff member that introduced the account line",
                "type": "integer"
              }
            },
            "type": "object"
          },
          "type": "array"
        },
        "total": {
          "type": "number"
        }
      }
    },
    "outstanding_debits": {
      "properties": {
        "lines": {
          "items": {
            "properties": $VAR1->{"properties"}{"outstanding_credits"}{"properties"}{"lines"}{"items"}{"properties"},
            "type": "object"
          },
          "type": "array"
        },
        "total": {
          "type": "number"
        }
      },
      "type": "object"
    }
  },
  "required": [
    "balance"
  ],
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Patron not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/patrons/{patron_id}/password

Operation ID: setPatronPassword

This resource is not documented.

Parameters

Name In Type Required Description
patron_id path integer Yes Internal patron identifier
body body No A JSON object containing password information

Body

{
  "properties": {
    "password": {
      "description": "New password (plain text)",
      "type": "string"
    },
    "password_2": {
      "description": "Repeated new password (plain text)",
      "type": "string"
    }
  },
  "required": [
    "password",
    "password_2"
  ],
  "type": "object"
}

Response 200

Password changed

undef

Response 400

Bad request

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Patron not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/checkouts/{checkout_id}/renewal

Operation ID: renewCheckout

This resource is not documented.

Parameters

Name In Type Required Description
checkout_id path integer Yes Internal checkout identifier

Response 201

Updated borrower's checkout

{
  "properties": {
    "auto_renew": {
      "description": "Auto renewal",
      "type": "boolean"
    },
    "auto_renew_error": {
      "description": "Auto renewal error",
      "type": [
        "string",
        "null"
      ]
    },
    "checkin_date": {
      "description": "Date the item was returned",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "checkout_date": {
      "description": "Date the item was issued",
      "format": "date-time",
      "type": "string"
    },
    "checkout_id": {
      "description": "internally assigned checkout identifier",
      "type": "integer"
    },
    "due_date": {
      "description": "Due date",
      "format": "date-time",
      "type": "string"
    },
    "item_id": {
      "description": "internal identifier of checked out item",
      "type": "integer"
    },
    "last_renewed_date": {
      "description": "Date the item was last renewed",
      "format": "date-time",
      "type": [
        "string",
        "null"
      ]
    },
    "library_id": {
      "description": "code of the library the item was checked out",
      "type": [
        "string",
        "null"
      ]
    },
    "note": {
      "description": "Issue note text",
      "type": [
        "string",
        "null"
      ]
    },
    "note_date": {
      "description": "Datetime of the issue note",
      "format": "date",
      "type": [
        "string",
        "null"
      ]
    },
    "onsite_checkout": {
      "description": "On site checkout",
      "type": "boolean"
    },
    "patron_id": {
      "description": "Internal patron identifier",
      "type": "integer"
    },
    "renewals": {
      "description": "Number of renewals",
      "type": [
        "integer",
        "null"
      ]
    },
    "timestamp": {
      "description": "Last update time",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Cannot renew checkout

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Checkout not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

DELETE /api/v1/acquisitions/vendors/{vendor_id}

Operation ID: deleteVendor

This resource is not documented.

Parameters

Name In Type Required Description
vendor_id path integer Yes Vendor id

Response 200

Vendor deleted

{
  "type": "string"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Vendor not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

GET /api/v1/acquisitions/vendors/{vendor_id}

Operation ID: getVendor

This resource is not documented.

Parameters

Name In Type Required Description
vendor_id path integer Yes Vendor id

Response 200

A vendor

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "accountnumber": {
      "description": "Vendor account number",
      "type": [
        "string",
        "null"
      ]
    },
    "active": {
      "description": "Is this vendor active",
      "type": [
        "boolean",
        "null"
      ]
    },
    "address1": {
      "description": "Vendor physical address (line 1)",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "Vendor physical address (line 2)",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "Vendor physical address (line 3)",
      "type": [
        "string",
        "null"
      ]
    },
    "address4": {
      "description": "Vendor physical address (line 4)",
      "type": [
        "string",
        "null"
      ]
    },
    "deliverytime": {
      "description": "Expected delivery time (in days)",
      "type": [
        "integer",
        "null"
      ]
    },
    "discount": {
      "description": "Default discount rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "fax": {
      "description": "Vendor fax number",
      "type": [
        "string",
        "null"
      ]
    },
    "gst": {
      "description": "Is the library taxed when buying from this vendor",
      "type": [
        "boolean",
        "null"
      ]
    },
    "id": {
      "description": "internally assigned vendor identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "invoice_currency": {
      "description": "Invoice prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "invoice_includes_gst": {
      "description": "Invoice prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "list_currency": {
      "description": "List prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "list_includes_gst": {
      "description": "List prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "name": {
      "description": "Vendor name",
      "type": [
        "string"
      ]
    },
    "notes": {
      "description": "Vendor notes",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "Vendor phone number",
      "type": [
        "string",
        "null"
      ]
    },
    "postal": {
      "description": "Vendor postal address",
      "type": [
        "string",
        "null"
      ]
    },
    "tax_rate": {
      "description": "Default tax rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "url": {
      "description": "Vendor web address",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name"
  ],
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Vendor not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

PUT /api/v1/acquisitions/vendors/{vendor_id}

Operation ID: updateVendor

This resource is not documented.

Parameters

Name In Type Required Description
vendor_id path integer Yes Vendor id
body body Yes A JSON object representing a vendor

Body

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "accountnumber": {
      "description": "Vendor account number",
      "type": [
        "string",
        "null"
      ]
    },
    "active": {
      "description": "Is this vendor active",
      "type": [
        "boolean",
        "null"
      ]
    },
    "address1": {
      "description": "Vendor physical address (line 1)",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "Vendor physical address (line 2)",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "Vendor physical address (line 3)",
      "type": [
        "string",
        "null"
      ]
    },
    "address4": {
      "description": "Vendor physical address (line 4)",
      "type": [
        "string",
        "null"
      ]
    },
    "deliverytime": {
      "description": "Expected delivery time (in days)",
      "type": [
        "integer",
        "null"
      ]
    },
    "discount": {
      "description": "Default discount rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "fax": {
      "description": "Vendor fax number",
      "type": [
        "string",
        "null"
      ]
    },
    "gst": {
      "description": "Is the library taxed when buying from this vendor",
      "type": [
        "boolean",
        "null"
      ]
    },
    "id": {
      "description": "internally assigned vendor identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "invoice_currency": {
      "description": "Invoice prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "invoice_includes_gst": {
      "description": "Invoice prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "list_currency": {
      "description": "List prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "list_includes_gst": {
      "description": "List prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "name": {
      "description": "Vendor name",
      "type": [
        "string"
      ]
    },
    "notes": {
      "description": "Vendor notes",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "Vendor phone number",
      "type": [
        "string",
        "null"
      ]
    },
    "postal": {
      "description": "Vendor postal address",
      "type": [
        "string",
        "null"
      ]
    },
    "tax_rate": {
      "description": "Default tax rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "url": {
      "description": "Vendor web address",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name"
  ],
  "type": "object"
}

Response 200

A vendor

{
  "additionalProperties": bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ),
  "properties": {
    "accountnumber": {
      "description": "Vendor account number",
      "type": [
        "string",
        "null"
      ]
    },
    "active": {
      "description": "Is this vendor active",
      "type": [
        "boolean",
        "null"
      ]
    },
    "address1": {
      "description": "Vendor physical address (line 1)",
      "type": [
        "string",
        "null"
      ]
    },
    "address2": {
      "description": "Vendor physical address (line 2)",
      "type": [
        "string",
        "null"
      ]
    },
    "address3": {
      "description": "Vendor physical address (line 3)",
      "type": [
        "string",
        "null"
      ]
    },
    "address4": {
      "description": "Vendor physical address (line 4)",
      "type": [
        "string",
        "null"
      ]
    },
    "deliverytime": {
      "description": "Expected delivery time (in days)",
      "type": [
        "integer",
        "null"
      ]
    },
    "discount": {
      "description": "Default discount rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "fax": {
      "description": "Vendor fax number",
      "type": [
        "string",
        "null"
      ]
    },
    "gst": {
      "description": "Is the library taxed when buying from this vendor",
      "type": [
        "boolean",
        "null"
      ]
    },
    "id": {
      "description": "internally assigned vendor identifier",
      "readOnly": bless( do{\(my $o = 1)}, 'JSON::PP::Boolean' ),
      "type": "integer"
    },
    "invoice_currency": {
      "description": "Invoice prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "invoice_includes_gst": {
      "description": "Invoice prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "list_currency": {
      "description": "List prices currency",
      "type": [
        "string",
        "null"
      ]
    },
    "list_includes_gst": {
      "description": "List prices include taxes",
      "type": [
        "boolean",
        "null"
      ]
    },
    "name": {
      "description": "Vendor name",
      "type": [
        "string"
      ]
    },
    "notes": {
      "description": "Vendor notes",
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "description": "Vendor phone number",
      "type": [
        "string",
        "null"
      ]
    },
    "postal": {
      "description": "Vendor postal address",
      "type": [
        "string",
        "null"
      ]
    },
    "tax_rate": {
      "description": "Default tax rate for items ordered from this vendor",
      "type": [
        "number",
        "null"
      ]
    },
    "url": {
      "description": "Vendor web address",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "name"
  ],
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Vendor not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

POST /api/v1/patrons/{patron_id}/account/credits

Operation ID: addPatronCredit

This resource is not documented.

Parameters

Name In Type Required Description
patron_id path integer Yes Internal patron identifier
body body Yes A JSON object containing credit information

Body

{
  "properties": {
    "account_lines_ids": {
      "description": "List of account line ids the credit goes against (optional)",
      "items": {
        "type": "integer"
      },
      "type": "array"
    },
    "amount": {
      "description": "Credit amount",
      "minimum": 0,
      "type": "number"
    },
    "credit_type": {
      "description": "Type of credit ('credit', 'forgiven', 'lost_item_return', 'payment', 'writeoff' )",
      "type": "string"
    },
    "date": {
      "description": "Date the credit was recorded (optional)",
      "format": "date",
      "type": "string"
    },
    "description": {
      "description": "Description",
      "type": "string"
    },
    "note": {
      "description": "Internal note",
      "type": "string"
    },
    "payment_type": {
      "description": "Payment type (only applies when credit_type=payment)",
      "type": "string"
    }
  },
  "required": [
    "amount"
  ],
  "type": "object"
}

Response 200

Credit added

{
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Patron not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

PUT /api/v1/rotas/{rota_id}/stages/{stage_id}/position

Operation ID: moveStage

This resource is not documented.

Parameters

Name In Type Required Description
rota_id path integer Yes A rotas ID
stage_id path integer Yes A stages ID
position body Yes A stages position in the rota

Body

{
  "type": "integer"
}

Response 200

OK

undef

Response 400

Bad request

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 401

Authentication required

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 403

Access forbidden

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 404

Position not found

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 500

Internal server error

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

Response 503

Under maintenance

{
  "properties": {
    "error": {
      "description": "Error message",
      "type": "string"
    }
  },
  "type": "object"
}

License

GPL v3

Contact information

https://koha-community.org/