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/error.yaml
28 $ref: ./definitions/fund.yaml
30 $ref: ./definitions/hold.yaml
32 $ref: ./definitions/holds.yaml
34 $ref: ./definitions/ill_backend.yaml
36 $ref: ./definitions/ill_backends.yaml
38 $ref: ./definitions/import_batch_profile.yaml
39 import_batch_profiles:
40 $ref: ./definitions/import_batch_profiles.yaml
42 $ref: ./definitions/import_record_match.yaml
44 $ref: ./definitions/invoice.yaml
46 $ref: ./definitions/item.yaml
48 $ref: ./definitions/item_group.yaml
50 $ref: ./definitions/job.yaml
52 $ref: ./definitions/library.yaml
54 $ref: ./definitions/order.yaml
56 $ref: ./definitions/patron.yaml
57 patron_account_credit:
58 $ref: ./definitions/patron_account_credit.yaml
60 $ref: ./definitions/patron_balance.yaml
61 patron_extended_attribute:
62 $ref: ./definitions/patron_extended_attribute.yaml
64 $ref: ./definitions/quote.yaml
66 $ref: ./definitions/renewal.yaml
68 $ref: ./definitions/renewals.yaml
70 $ref: ./definitions/return_claim.yaml
72 $ref: ./definitions/search_filter.yaml
74 $ref: ./definitions/smtp_server.yaml
76 $ref: ./definitions/suggestion.yaml
78 $ref: ./definitions/transfer_limit.yaml
80 $ref: ./definitions/vendor.yaml
82 /acquisitions/baskets/managers:
83 $ref: paths/acquisitions_baskets.yaml#/~1acquisitions~1baskets~1managers
85 $ref: ./paths/acquisitions_funds.yaml#/~1acquisitions~1funds
86 /acquisitions/funds/owners:
87 $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1owners
88 /acquisitions/funds/users:
89 $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1users
91 $ref: ./paths/acquisitions_orders.yaml#/~1acquisitions~1orders
92 "/acquisitions/orders/{order_id}":
93 $ref: "./paths/acquisitions_orders.yaml#/~1acquisitions~1orders~1{order_id}"
94 /acquisitions/vendors:
95 $ref: ./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors
96 "/acquisitions/vendors/{vendor_id}":
97 $ref: "./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors~1{vendor_id}"
98 /advanced_editor/macros:
99 $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros
100 /advanced_editor/macros/shared:
101 $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared
103 $ref: ./paths/search_filters.yaml#/~1search_filters
104 "/search_filters/{search_filter_id}":
105 $ref: "./paths/search_filters.yaml#/~1search_filters~1{search_filter_id}"
106 "/advanced_editor/macros/shared/{advancededitormacro_id}":
107 $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared~1{advancededitormacro_id}"
108 "/advanced_editor/macros/{advancededitormacro_id}":
109 $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1{advancededitormacro_id}"
110 "/article_requests/{article_request_id}":
111 $ref: "./paths/article_requests.yaml#/~1article_requests~1{article_request_id}"
112 /auth/otp/token_delivery:
113 $ref: paths/auth.yaml#/~1auth~1otp~1token_delivery
114 /auth/two-factor/registration:
115 $ref: paths/auth.yaml#/~1auth~1two-factor~1registration
116 /auth/two-factor/registration/verification:
117 $ref: paths/auth.yaml#/~1auth~1two-factor~1registration~1verification
118 "/biblios/{biblio_id}":
119 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}"
120 "/biblios/{biblio_id}/checkouts":
121 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1checkouts"
122 "/biblios/{biblio_id}/items":
123 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1items"
124 "/biblios/{biblio_id}/pickup_locations":
125 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1pickup_locations"
126 "/biblios/{biblio_id}/item_groups":
127 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups"
128 "/biblios/{biblio_id}/item_groups/{item_group_id}":
129 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}"
130 "/biblios/{biblio_id}/item_groups/{item_group_id}/items":
131 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}~1items"
132 "/biblios/{biblio_id}/item_groups/{item_group_id}/items/{item_id}":
133 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}~1items~1{item_id}"
134 "/cash_registers/{cash_register_id}/cashups":
135 $ref: "./paths/cash_registers.yaml#/~1cash_registers~1{cash_register_id}~1cashups"
136 "/cashups/{cashup_id}":
137 $ref: "./paths/cash_registers.yaml#/~1cashups~1{cashup_id}"
139 $ref: ./paths/checkouts.yaml#/~1checkouts
140 "/checkouts/{checkout_id}":
141 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}"
142 "/checkouts/{checkout_id}/allows_renewal":
143 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1allows_renewal"
144 "/checkouts/{checkout_id}/renewals":
145 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1renewals"
146 "/checkouts/{checkout_id}/renewal":
147 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1renewal"
148 /circulation-rules/kinds:
149 $ref: ./paths/circulation-rules.yaml#/~1circulation-rules~1kinds
151 $ref: ./paths/cities.yaml#/~1cities
153 $ref: "./paths/cities.yaml#/~1cities~1{city_id}"
154 "/clubs/{club_id}/holds":
155 $ref: "./paths/clubs.yaml#/~1clubs~1{club_id}~1holds"
156 /config/smtp_servers:
157 $ref: ./paths/config_smtp_servers.yaml#/~1config~1smtp_servers
158 "/config/smtp_servers/{smtp_server_id}":
159 $ref: "./paths/config_smtp_servers.yaml#/~1config~1smtp_servers~1{smtp_server_id}"
161 $ref: ./paths/erm_agreements.yaml#/~1erm~1agreements
162 "/erm/agreements/{agreement_id}":
163 $ref: "./paths/erm_agreements.yaml#/~1erm~1agreements~1{agreement_id}"
165 $ref: ./paths/erm_users.yaml#/~1erm~1users
167 $ref: ./paths/holds.yaml#/~1holds
169 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}"
170 "/holds/{hold_id}/pickup_location":
171 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_location"
172 "/holds/{hold_id}/pickup_locations":
173 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_locations"
174 "/holds/{hold_id}/priority":
175 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1priority"
176 "/holds/{hold_id}/suspension":
177 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1suspension"
179 $ref: ./paths/ill_backends.yaml#/~1ill_backends
180 "/ill_backends/{ill_backend_id}":
181 $ref: "./paths/ill_backends.yaml#/~1ill_backends~1{ill_backend_id}"
183 $ref: ./paths/illrequests.yaml#/~1illrequests
184 "/import_batches/{import_batch_id}/records/{import_record_id}/matches/chosen":
185 $ref: "./paths/import_batches.yaml#/~1import_batches~1{import_batch_id}~1records~1{import_record_id}~1matches~1chosen"
186 /import_batch_profiles:
187 $ref: ./paths/import_batch_profiles.yaml#/~1import_batch_profiles
188 "/import_batch_profiles/{import_batch_profile_id}":
189 $ref: "./paths/import_batch_profiles.yaml#/~1import_batch_profiles~1{import_batch_profile_id}"
191 $ref: ./paths/items.yaml#/~1items
193 $ref: "./paths/items.yaml#/~1items~1{item_id}"
194 "/items/{item_id}/bundled_items":
195 $ref: ./paths/items.yaml#/~1items~1{item_id}~1bundled_items
196 "/items/{item_id}/bundled_items/{bundled_item_id}":
197 $ref: ./paths/items.yaml#/~1items~1{item_id}~1bundled_items~1{bundled_item_id}
198 "/items/{item_id}/pickup_locations":
199 $ref: "./paths/items.yaml#/~1items~1{item_id}~1pickup_locations"
201 $ref: ./paths/jobs.yaml#/~1jobs
203 $ref: "./paths/jobs.yaml#/~1jobs~1{job_id}"
205 $ref: ./paths/libraries.yaml#/~1libraries
206 "/libraries/{library_id}":
207 $ref: "./paths/libraries.yaml#/~1libraries~1{library_id}"
209 $ref: ./paths/oauth.yaml#/~1oauth~1token
211 $ref: ./paths/patrons.yaml#/~1patrons
212 "/patrons/{patron_id}":
213 $ref: "./paths/patrons.yaml#/~1patrons~1{patron_id}"
214 "/patrons/{patron_id}/account":
215 $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account"
216 "/patrons/{patron_id}/account/credits":
217 $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account~1credits"
218 "/patrons/{patron_id}/extended_attributes":
219 $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes"
220 "/patrons/{patron_id}/extended_attributes/{extended_attribute_id}":
221 $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes~1{extended_attribute_id}"
222 "/patrons/{patron_id}/holds":
223 $ref: "./paths/patrons_holds.yaml#/~1patrons~1{patron_id}~1holds"
224 "/patrons/{patron_id}/password":
225 $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password"
226 "/patrons/{patron_id}/password/expiration_date":
227 $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password~1expiration_date"
228 "/public/biblios/{biblio_id}":
229 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}"
230 "/public/biblios/{biblio_id}/items":
231 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}~1items"
232 "/public/biblios/{biblio_id}/ratings":
233 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}~1ratings"
235 $ref: ./paths/libraries.yaml#/~1public~1libraries
236 "/public/libraries/{library_id}":
237 $ref: "./paths/libraries.yaml#/~1public~1libraries~1{library_id}"
238 "/public/patrons/{patron_id}/article_requests/{article_request_id}":
239 $ref: "./paths/article_requests.yaml#/~1public~1patrons~1{patron_id}~1article_requests~1{article_request_id}"
240 "/public/patrons/{patron_id}/guarantors/can_see_charges":
241 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_charges"
242 "/public/patrons/{patron_id}/guarantors/can_see_checkouts":
243 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_checkouts"
244 "/public/patrons/{patron_id}/password":
245 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1password"
247 $ref: ./paths/quotes.yaml#/~1quotes
248 "/quotes/{quote_id}":
249 $ref: "./paths/quotes.yaml#/~1quotes~1{quote_id}"
251 $ref: ./paths/return_claims.yaml#/~1return_claims
252 "/return_claims/{claim_id}":
253 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}"
254 "/return_claims/{claim_id}/notes":
255 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1notes"
256 "/return_claims/{claim_id}/resolve":
257 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1resolve"
258 "/rotas/{rota_id}/stages/{stage_id}/position":
259 $ref: "./paths/rotas.yaml#/~1rotas~1{rota_id}~1stages~1{stage_id}~1position"
261 $ref: ./paths/suggestions.yaml#/~1suggestions
262 "/suggestions/{suggestion_id}":
263 $ref: "./paths/suggestions.yaml#/~1suggestions~1{suggestion_id}"
264 /suggestions/managers:
265 $ref: paths/suggestions.yaml#/~1suggestions~1managers
267 $ref: ./paths/transfer_limits.yaml#/~1transfer_limits
268 /transfer_limits/batch:
269 $ref: ./paths/transfer_limits.yaml#/~1transfer_limits~1batch
270 "/transfer_limits/{limit_id}":
271 $ref: "./paths/transfer_limits.yaml#/~1transfer_limits~1{limit_id}"
273 advancededitormacro_id_pp:
274 description: Advanced editor macro internal identifier
276 name: advancededitormacro_id
280 description: Agreement internal identifier
285 agreement_period_id_pp:
286 description: Agreement period internal identifier
288 name: agreement_period_id
292 description: Record internal identifier
297 candidate_match_id_pp:
298 description: Internal import record match identifier
300 name: candidate_match_id
304 description: Cash register internal identifier
306 name: cash_register_id
310 description: Cashup internal identifier
316 description: Internal checkout identifier
322 description: City internal identifier
328 description: Internal club identifier
340 description: Internal hold identifier
345 import_batch_profile_id_pp:
346 description: Internal profile identifier
348 name: import_batch_profile_id
352 description: Internal import record identifier
354 name: import_record_id
358 description: Internal item identifier
364 description: Job internal identifier
370 description: Internal library identifier
376 description: Matching criteria
387 collectionFormat: csv
388 description: Sorting criteria
396 description: Internal order identifier
402 description: "Page number, for paginated object listing"
408 description: Internal patron identifier
414 description: Internal patron identifier
419 description: "Page size, for paginated object listing"
425 description: Query filter sent through request"s body
432 description: Query filter sent as a request header
438 description: Query filter sent as a request parameter
445 collectionFormat: multi
447 description: Quote internal identifier
453 description: Request id header
455 name: x-koha-request-id
459 name: search_filter_id
461 description: Search filter internal identifier
465 description: Item was seen flag
471 description: SMTP server internal identifier
477 description: Internal suggestion identifier
482 transfer_limit_id_pp:
483 description: Internal transfer limit identifier
489 description: Vendor id
499 url: http://www.gnu.org/licenses/gpl.txt
501 name: Koha Development Team
502 url: https://koha-community.org/
506 This API is documented in **OpenAPI format**.
510 The API supports the following authentication mechanisms
512 * HTTP Basic authentication
513 * OAuth2 (client credentials grant)
516 Both _Basic authentication_ and the _OAuth2_ flow, need to be enabled
517 by system preferences.
521 The API uses standard HTTP status codes to indicate the success or failure
522 of the API call. The body of the response will be JSON in the following format:
526 "error": "Current settings prevent the passed due date to be applied",
527 "error_code": "invalid_due_date"
531 Note: Some routes might offer additional attributes in their error responses but that"s
532 subject to change and thus not documented.
534 ## Filtering responses
536 The API allows for some advanced response filtering using a JSON based query syntax. The
537 query can be added to the requests:
539 * as a query parameter `q=`
540 * in the request body
541 * in a special header `x-koha-query`
543 For simple field equality matches we can use `{ "fieldname": "value" }` where the fieldname
544 matches one of the fields as described in the particular endpoints response object.
546 We can refine that with more complex matching clauses by nesting a the clause into the
547 object; `{ "fieldname": { "clause": "value" } }`.
549 Available matching clauses include ">", "<", ">=", "<=", "-like", and "-not_like".
551 We can filter on multiple fields by adding them to the JSON respresentation. Adding at `HASH`
552 level will result in an "AND" query, whilst combinding them in an `ARRAY` wilth result in an
553 "OR" query: `{ "field1": "value2", "field2": "value2" }` will filter the response to only those
554 results with both field1 containing value2 AND field2 containing value2 for example.
556 Additionally, if you are requesting related data be embedded into the response one can query
557 on the related data using dot notation in the field names.
561 The following request would return any patron with firstname "Henry" and lastname "Acevedo";
563 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": "Acevedo", "firstname": "Henry" }"`
565 The following request would return any patron whose lastname begins with "Ace";
567 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": { "-like": "Ace%" }"`
569 The following request would return any patron whose lastname is "Acevedo" OR "Bernardo"
571 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": [ "Acevedo", "Bernardo" ] }"`
573 The following request embeds the related patron extended attributes data and filters on it.
575 `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" }'`
581 This optional header allows the api consumer to request additional related data
582 to be returned in the api response. It also allows for cross referencing in the
583 queries as described above. It accepts a comma delimited list of relation names.
585 Relations may on occasion also support dot delimited nesting to allow traversal.
589 This optional header should be passed to give your api request a library
590 context; If it is not included in the request, then the request context
591 will default to using your api comsumer"s assigned home library.
593 - description: "Handle two factor authentication flows\n"
595 x-displayName: Two factor authentication
596 - description: "Manage article requests\n"
597 name: article_requests
598 x-displayName: Article requests
599 - description: "Manage baskets for the acquisitions module\n"
601 x-displayName: Baskets
602 - description: "Manage bibliographic records\n"
604 x-displayName: Biblios
605 - description: "Manage cash register cashups\n"
607 x-displayName: Cashups
608 - description: "Manage checkouts\n"
610 x-displayName: Checkouts
611 - description: "Manage circulation rules\n"
612 name: circulation_rules
613 x-displayName: Circulation rules
614 - description: "Manage cities\n"
616 x-displayName: Cities
617 - description: "Manage patron clubs\n"
620 - description: "Manage funds for the acquisitions module\n"
623 - description: "Manage holds\n"
626 - description: "Manage ILL module backends\n"
628 x-displayName: ILL backends
629 - description: "Manage ILL requests\n"
631 x-displayName: ILL requests
632 - description: "Manage import batches\n"
634 x-display-name: Import batches
635 - description: "Manage item groups\n"
637 x-displayName: Item groups
638 - description: "Manage items\n"
641 - description: "Manage jobs\n"
644 - description: "Manage libraries\n"
646 x-displayName: Libraries
647 - description: "Manage macros\n"
649 x-displayName: Macros
650 - description: "Manage acquisition orders\n"
652 x-displayName: Orders
653 - description: "Handle OAuth flows\n"
656 - description: "Manage patrons\n"
658 x-displayName: Patrons
659 - description: "Manage quotes\n"
661 x-displayName: Quotes
662 - description: "Manage return claims\n"
664 x-displayName: Return claims
665 - description: "Manage rotas\n"
668 - description: "Manage SMTP servers configurations\n"
670 x-displayName: SMTP servers
671 - description: "Manage transfer limits\n"
673 x-displayName: Transfer limits
674 - description: "Manage purchase suggestions\n"
676 x-displayName: Purchase suggestions
677 - description: "Manage vendors for the acquisitions module\n"
679 x-displayName: Vendors
680 - description: "Manage batch import profiles\n"
681 name: batch_import_profiles
682 x-displayName: Batch import profiles