6 $ref: ./definitions/account_line.yaml
8 $ref: ./definitions/advancededitormacro.yaml
10 $ref: ./definitions/allows_renewal.yaml
12 $ref: ./definitions/basket.yaml
14 $ref: ./definitions/bundle_link.yaml
16 $ref: ./definitions/cashup.yaml
18 $ref: ./definitions/checkout.yaml
20 $ref: ./definitions/checkouts.yaml
22 $ref: ./definitions/circ-rule-kind.yaml
24 $ref: ./definitions/city.yaml
26 $ref: ./definitions/erm_agreement.yaml
28 $ref: ./definitions/erm_eholdings_title.yaml
30 $ref: ./definitions/erm_license.yaml
31 erm_eholdings_package:
32 $ref: ./definitions/erm_eholdings_package.yaml
34 $ref: ./definitions/error.yaml
36 $ref: ./definitions/fund.yaml
38 $ref: ./definitions/hold.yaml
40 $ref: ./definitions/holds.yaml
42 $ref: ./definitions/ill_backend.yaml
44 $ref: ./definitions/ill_backends.yaml
46 $ref: ./definitions/import_batch_profile.yaml
47 import_batch_profiles:
48 $ref: ./definitions/import_batch_profiles.yaml
50 $ref: ./definitions/import_record_match.yaml
52 $ref: ./definitions/invoice.yaml
54 $ref: ./definitions/item.yaml
56 $ref: ./definitions/item_group.yaml
58 $ref: ./definitions/job.yaml
60 $ref: ./definitions/library.yaml
62 $ref: ./definitions/order.yaml
64 $ref: ./definitions/patron.yaml
65 patron_account_credit:
66 $ref: ./definitions/patron_account_credit.yaml
68 $ref: ./definitions/patron_balance.yaml
69 patron_extended_attribute:
70 $ref: ./definitions/patron_extended_attribute.yaml
72 $ref: ./definitions/quote.yaml
74 $ref: ./definitions/renewal.yaml
76 $ref: ./definitions/renewals.yaml
78 $ref: ./definitions/return_claim.yaml
80 $ref: ./definitions/search_filter.yaml
82 $ref: ./definitions/smtp_server.yaml
84 $ref: ./definitions/suggestion.yaml
86 $ref: ./definitions/transfer_limit.yaml
88 $ref: ./definitions/vendor.yaml
90 /acquisitions/baskets/managers:
91 $ref: paths/acquisitions_baskets.yaml#/~1acquisitions~1baskets~1managers
93 $ref: ./paths/acquisitions_funds.yaml#/~1acquisitions~1funds
94 /acquisitions/funds/owners:
95 $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1owners
96 /acquisitions/funds/users:
97 $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1users
99 $ref: ./paths/acquisitions_orders.yaml#/~1acquisitions~1orders
100 "/acquisitions/orders/{order_id}":
101 $ref: "./paths/acquisitions_orders.yaml#/~1acquisitions~1orders~1{order_id}"
102 /acquisitions/vendors:
103 $ref: ./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors
104 "/acquisitions/vendors/{vendor_id}":
105 $ref: "./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors~1{vendor_id}"
106 /advanced_editor/macros:
107 $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros
108 /advanced_editor/macros/shared:
109 $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared
111 $ref: ./paths/search_filters.yaml#/~1search_filters
112 "/search_filters/{search_filter_id}":
113 $ref: "./paths/search_filters.yaml#/~1search_filters~1{search_filter_id}"
114 "/advanced_editor/macros/shared/{advancededitormacro_id}":
115 $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared~1{advancededitormacro_id}"
116 "/advanced_editor/macros/{advancededitormacro_id}":
117 $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1{advancededitormacro_id}"
118 "/article_requests/{article_request_id}":
119 $ref: "./paths/article_requests.yaml#/~1article_requests~1{article_request_id}"
120 /auth/otp/token_delivery:
121 $ref: paths/auth.yaml#/~1auth~1otp~1token_delivery
122 /auth/two-factor/registration:
123 $ref: paths/auth.yaml#/~1auth~1two-factor~1registration
124 /auth/two-factor/registration/verification:
125 $ref: paths/auth.yaml#/~1auth~1two-factor~1registration~1verification
126 "/biblios/{biblio_id}":
127 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}"
128 "/biblios/{biblio_id}/checkouts":
129 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1checkouts"
130 "/biblios/{biblio_id}/items":
131 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1items"
132 "/biblios/{biblio_id}/pickup_locations":
133 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1pickup_locations"
134 "/biblios/{biblio_id}/item_groups":
135 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups"
136 "/biblios/{biblio_id}/item_groups/{item_group_id}":
137 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}"
138 "/biblios/{biblio_id}/item_groups/{item_group_id}/items":
139 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}~1items"
140 "/biblios/{biblio_id}/item_groups/{item_group_id}/items/{item_id}":
141 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}~1items~1{item_id}"
142 "/cash_registers/{cash_register_id}/cashups":
143 $ref: "./paths/cash_registers.yaml#/~1cash_registers~1{cash_register_id}~1cashups"
144 "/cashups/{cashup_id}":
145 $ref: "./paths/cash_registers.yaml#/~1cashups~1{cashup_id}"
147 $ref: ./paths/checkouts.yaml#/~1checkouts
148 "/checkouts/{checkout_id}":
149 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}"
150 "/checkouts/{checkout_id}/allows_renewal":
151 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1allows_renewal"
152 "/checkouts/{checkout_id}/renewals":
153 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1renewals"
154 "/checkouts/{checkout_id}/renewal":
155 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1renewal"
156 /circulation-rules/kinds:
157 $ref: ./paths/circulation-rules.yaml#/~1circulation-rules~1kinds
159 $ref: ./paths/cities.yaml#/~1cities
161 $ref: "./paths/cities.yaml#/~1cities~1{city_id}"
162 "/clubs/{club_id}/holds":
163 $ref: "./paths/clubs.yaml#/~1clubs~1{club_id}~1holds"
164 /config/smtp_servers:
165 $ref: ./paths/config_smtp_servers.yaml#/~1config~1smtp_servers
166 "/config/smtp_servers/{smtp_server_id}":
167 $ref: "./paths/config_smtp_servers.yaml#/~1config~1smtp_servers~1{smtp_server_id}"
169 $ref: ./paths/erm_agreements.yaml#/~1erm~1agreements
170 "/erm/agreements/{agreement_id}":
171 $ref: "./paths/erm_agreements.yaml#/~1erm~1agreements~1{agreement_id}"
172 /erm/eholdings/titles:
173 $ref: ./paths/erm_eholdings_titles.yaml#/~1erm~1eholdings~1titles
174 "/erm/eholdings/titles/{title_id}":
175 $ref: "./paths/erm_eholdings_titles.yaml#/~1erm~1eholdings~1titles~1{title_id}"
176 /erm/eholdings/packages:
177 $ref: ./paths/erm_eholdings_packages.yaml#/~1erm~1eholdings~1packages
178 "/erm/eholdings/packages/{package_id}":
179 $ref: "./paths/erm_eholdings_packages.yaml#/~1erm~1eholdings~1packages~1{package_id}"
181 $ref: ./paths/erm_licenses.yaml#/~1erm~1licenses
182 "/erm/licenses/{license_id}":
183 $ref: "./paths/erm_licenses.yaml#/~1erm~1licenses~1{license_id}"
185 $ref: ./paths/erm_users.yaml#/~1erm~1users
187 $ref: ./paths/holds.yaml#/~1holds
189 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}"
190 "/holds/{hold_id}/pickup_location":
191 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_location"
192 "/holds/{hold_id}/pickup_locations":
193 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_locations"
194 "/holds/{hold_id}/priority":
195 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1priority"
196 "/holds/{hold_id}/suspension":
197 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1suspension"
199 $ref: ./paths/ill_backends.yaml#/~1ill_backends
200 "/ill_backends/{ill_backend_id}":
201 $ref: "./paths/ill_backends.yaml#/~1ill_backends~1{ill_backend_id}"
203 $ref: ./paths/illrequests.yaml#/~1illrequests
204 "/import_batches/{import_batch_id}/records/{import_record_id}/matches/chosen":
205 $ref: "./paths/import_batches.yaml#/~1import_batches~1{import_batch_id}~1records~1{import_record_id}~1matches~1chosen"
206 /import_batch_profiles:
207 $ref: ./paths/import_batch_profiles.yaml#/~1import_batch_profiles
208 "/import_batch_profiles/{import_batch_profile_id}":
209 $ref: "./paths/import_batch_profiles.yaml#/~1import_batch_profiles~1{import_batch_profile_id}"
211 $ref: ./paths/items.yaml#/~1items
213 $ref: "./paths/items.yaml#/~1items~1{item_id}"
214 "/items/{item_id}/bundled_items":
215 $ref: ./paths/items.yaml#/~1items~1{item_id}~1bundled_items
216 "/items/{item_id}/bundled_items/{bundled_item_id}":
217 $ref: ./paths/items.yaml#/~1items~1{item_id}~1bundled_items~1{bundled_item_id}
218 "/items/{item_id}/pickup_locations":
219 $ref: "./paths/items.yaml#/~1items~1{item_id}~1pickup_locations"
221 $ref: ./paths/jobs.yaml#/~1jobs
223 $ref: "./paths/jobs.yaml#/~1jobs~1{job_id}"
225 $ref: ./paths/libraries.yaml#/~1libraries
226 "/libraries/{library_id}":
227 $ref: "./paths/libraries.yaml#/~1libraries~1{library_id}"
229 $ref: ./paths/oauth.yaml#/~1oauth~1token
231 $ref: ./paths/patrons.yaml#/~1patrons
232 "/patrons/{patron_id}":
233 $ref: "./paths/patrons.yaml#/~1patrons~1{patron_id}"
234 "/patrons/{patron_id}/account":
235 $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account"
236 "/patrons/{patron_id}/account/credits":
237 $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account~1credits"
238 "/patrons/{patron_id}/extended_attributes":
239 $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes"
240 "/patrons/{patron_id}/extended_attributes/{extended_attribute_id}":
241 $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes~1{extended_attribute_id}"
242 "/patrons/{patron_id}/holds":
243 $ref: "./paths/patrons_holds.yaml#/~1patrons~1{patron_id}~1holds"
244 "/patrons/{patron_id}/password":
245 $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password"
246 "/patrons/{patron_id}/password/expiration_date":
247 $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password~1expiration_date"
248 "/public/biblios/{biblio_id}":
249 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}"
250 "/public/biblios/{biblio_id}/items":
251 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}~1items"
252 "/public/biblios/{biblio_id}/ratings":
253 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}~1ratings"
255 $ref: ./paths/libraries.yaml#/~1public~1libraries
256 "/public/libraries/{library_id}":
257 $ref: "./paths/libraries.yaml#/~1public~1libraries~1{library_id}"
258 "/public/patrons/{patron_id}/article_requests/{article_request_id}":
259 $ref: "./paths/article_requests.yaml#/~1public~1patrons~1{patron_id}~1article_requests~1{article_request_id}"
260 "/public/patrons/{patron_id}/guarantors/can_see_charges":
261 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_charges"
262 "/public/patrons/{patron_id}/guarantors/can_see_checkouts":
263 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_checkouts"
264 "/public/patrons/{patron_id}/password":
265 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1password"
267 $ref: ./paths/quotes.yaml#/~1quotes
268 "/quotes/{quote_id}":
269 $ref: "./paths/quotes.yaml#/~1quotes~1{quote_id}"
271 $ref: ./paths/return_claims.yaml#/~1return_claims
272 "/return_claims/{claim_id}":
273 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}"
274 "/return_claims/{claim_id}/notes":
275 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1notes"
276 "/return_claims/{claim_id}/resolve":
277 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1resolve"
278 "/rotas/{rota_id}/stages/{stage_id}/position":
279 $ref: "./paths/rotas.yaml#/~1rotas~1{rota_id}~1stages~1{stage_id}~1position"
281 $ref: ./paths/suggestions.yaml#/~1suggestions
282 "/suggestions/{suggestion_id}":
283 $ref: "./paths/suggestions.yaml#/~1suggestions~1{suggestion_id}"
284 /suggestions/managers:
285 $ref: paths/suggestions.yaml#/~1suggestions~1managers
287 $ref: ./paths/transfer_limits.yaml#/~1transfer_limits
288 /transfer_limits/batch:
289 $ref: ./paths/transfer_limits.yaml#/~1transfer_limits~1batch
290 "/transfer_limits/{limit_id}":
291 $ref: "./paths/transfer_limits.yaml#/~1transfer_limits~1{limit_id}"
293 advancededitormacro_id_pp:
294 description: Advanced editor macro internal identifier
296 name: advancededitormacro_id
300 description: Agreement internal identifier
305 agreement_period_id_pp:
306 description: Agreement period internal identifier
308 name: agreement_period_id
312 description: Record internal identifier
317 candidate_match_id_pp:
318 description: Internal import record match identifier
320 name: candidate_match_id
324 description: Cash register internal identifier
326 name: cash_register_id
330 description: Cashup internal identifier
336 description: Internal checkout identifier
342 description: City internal identifier
348 description: Internal club identifier
353 eholdings_title_id_pp:
354 description: title internal identifier
359 eholdings_package_id_pp:
360 description: Package internal identifier
372 description: Internal hold identifier
377 import_batch_profile_id_pp:
378 description: Internal profile identifier
380 name: import_batch_profile_id
384 description: Internal import record identifier
386 name: import_record_id
390 description: Internal item identifier
396 description: Job internal identifier
402 description: Internal library identifier
408 description: License internal identifier
414 description: Matching criteria
425 collectionFormat: csv
426 description: Sorting criteria
434 description: Internal order identifier
440 description: "Page number, for paginated object listing"
446 description: Internal patron identifier
452 description: Internal patron identifier
457 description: "Page size, for paginated object listing"
463 description: Query filter sent through request"s body
470 description: Query filter sent as a request header
476 description: Query filter sent as a request parameter
483 collectionFormat: multi
485 description: Quote internal identifier
491 description: Request id header
493 name: x-koha-request-id
497 name: search_filter_id
499 description: Search filter internal identifier
503 description: Item was seen flag
509 description: SMTP server internal identifier
515 description: Internal suggestion identifier
520 transfer_limit_id_pp:
521 description: Internal transfer limit identifier
527 description: Vendor id
537 url: http://www.gnu.org/licenses/gpl.txt
539 name: Koha Development Team
540 url: https://koha-community.org/
544 This API is documented in **OpenAPI format**.
548 The API supports the following authentication mechanisms
550 * HTTP Basic authentication
551 * OAuth2 (client credentials grant)
554 Both _Basic authentication_ and the _OAuth2_ flow, need to be enabled
555 by system preferences.
559 The API uses standard HTTP status codes to indicate the success or failure
560 of the API call. The body of the response will be JSON in the following format:
564 "error": "Current settings prevent the passed due date to be applied",
565 "error_code": "invalid_due_date"
569 Note: Some routes might offer additional attributes in their error responses but that"s
570 subject to change and thus not documented.
572 ## Filtering responses
574 The API allows for some advanced response filtering using a JSON based query syntax. The
575 query can be added to the requests:
577 * as a query parameter `q=`
578 * in the request body
579 * in a special header `x-koha-query`
581 For simple field equality matches we can use `{ "fieldname": "value" }` where the fieldname
582 matches one of the fields as described in the particular endpoints response object.
584 We can refine that with more complex matching clauses by nesting a the clause into the
585 object; `{ "fieldname": { "clause": "value" } }`.
587 Available matching clauses include ">", "<", ">=", "<=", "-like", and "-not_like".
589 We can filter on multiple fields by adding them to the JSON respresentation. Adding at `HASH`
590 level will result in an "AND" query, whilst combinding them in an `ARRAY` wilth result in an
591 "OR" query: `{ "field1": "value2", "field2": "value2" }` will filter the response to only those
592 results with both field1 containing value2 AND field2 containing value2 for example.
594 Additionally, if you are requesting related data be embedded into the response one can query
595 on the related data using dot notation in the field names.
599 The following request would return any patron with firstname "Henry" and lastname "Acevedo";
601 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": "Acevedo", "firstname": "Henry" }"`
603 The following request would return any patron whose lastname begins with "Ace";
605 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": { "-like": "Ace%" }"`
607 The following request would return any patron whose lastname is "Acevedo" OR "Bernardo"
609 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": [ "Acevedo", "Bernardo" ] }"`
611 The following request embeds the related patron extended attributes data and filters on it.
613 `curl -u koha:koha =--request GET 'http://127.0.0.1:8081/api/v1/patrons/' --header 'x-koha-embed: extended_attributes' --data-raw '{ "extended_attributes.code": "internet", "extended_attributes.attribute": "1" }'`
619 This optional header allows the api consumer to request additional related data
620 to be returned in the api response. It also allows for cross referencing in the
621 queries as described above. It accepts a comma delimited list of relation names.
623 Relations may on occasion also support dot delimited nesting to allow traversal.
627 This optional header should be passed to give your api request a library
628 context; If it is not included in the request, then the request context
629 will default to using your api comsumer"s assigned home library.
631 - description: "Handle two factor authentication flows\n"
633 x-displayName: Two factor authentication
634 - description: "Manage article requests\n"
635 name: article_requests
636 x-displayName: Article requests
637 - description: "Manage baskets for the acquisitions module\n"
639 x-displayName: Baskets
640 - description: "Manage bibliographic records\n"
642 x-displayName: Biblios
643 - description: "Manage cash register cashups\n"
645 x-displayName: Cashups
646 - description: "Manage checkouts\n"
648 x-displayName: Checkouts
649 - description: "Manage circulation rules\n"
650 name: circulation_rules
651 x-displayName: Circulation rules
652 - description: "Manage cities\n"
654 x-displayName: Cities
655 - description: "Manage patron clubs\n"
658 - description: "Manage funds for the acquisitions module\n"
661 - description: "Manage holds\n"
664 - description: "Manage ILL module backends\n"
666 x-displayName: ILL backends
667 - description: "Manage ILL requests\n"
669 x-displayName: ILL requests
670 - description: "Manage import batches\n"
672 x-display-name: Import batches
673 - description: "Manage item groups\n"
675 x-displayName: Item groups
676 - description: "Manage items\n"
679 - description: "Manage jobs\n"
682 - description: "Manage libraries\n"
684 x-displayName: Libraries
685 - description: "Manage macros\n"
687 x-displayName: Macros
688 - description: "Manage acquisition orders\n"
690 x-displayName: Orders
691 - description: "Handle OAuth flows\n"
694 - description: "Manage patrons\n"
696 x-displayName: Patrons
697 - description: "Manage quotes\n"
699 x-displayName: Quotes
700 - description: "Manage return claims\n"
702 x-displayName: Return claims
703 - description: "Manage rotas\n"
706 - description: "Manage SMTP servers configurations\n"
708 x-displayName: SMTP servers
709 - description: "Manage transfer limits\n"
711 x-displayName: Transfer limits
712 - description: "Manage purchase suggestions\n"
714 x-displayName: Purchase suggestions
715 - description: "Manage vendors for the acquisitions module\n"
717 x-displayName: Vendors
718 - description: "Manage batch import profiles\n"
719 name: batch_import_profiles
720 x-displayName: Batch import profiles