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/library.yaml
52 $ref: ./definitions/order.yaml
54 $ref: ./definitions/patron.yaml
55 patron_account_credit:
56 $ref: ./definitions/patron_account_credit.yaml
58 $ref: ./definitions/patron_balance.yaml
59 patron_extended_attribute:
60 $ref: ./definitions/patron_extended_attribute.yaml
62 $ref: ./definitions/quote.yaml
64 $ref: ./definitions/renewal.yaml
66 $ref: ./definitions/renewals.yaml
68 $ref: ./definitions/return_claim.yaml
70 $ref: ./definitions/smtp_server.yaml
72 $ref: ./definitions/suggestion.yaml
74 $ref: ./definitions/transfer_limit.yaml
76 $ref: ./definitions/vendor.yaml
78 /acquisitions/baskets/managers:
79 $ref: paths/acquisitions_baskets.yaml#/~1acquisitions~1baskets~1managers
81 $ref: ./paths/acquisitions_funds.yaml#/~1acquisitions~1funds
82 /acquisitions/funds/owners:
83 $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1owners
84 /acquisitions/funds/users:
85 $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1users
87 $ref: ./paths/acquisitions_orders.yaml#/~1acquisitions~1orders
88 "/acquisitions/orders/{order_id}":
89 $ref: "./paths/acquisitions_orders.yaml#/~1acquisitions~1orders~1{order_id}"
90 /acquisitions/vendors:
91 $ref: ./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors
92 "/acquisitions/vendors/{vendor_id}":
93 $ref: "./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors~1{vendor_id}"
94 /advanced_editor/macros:
95 $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros
96 /advanced_editor/macros/shared:
97 $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared
98 "/advanced_editor/macros/shared/{advancededitormacro_id}":
99 $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared~1{advancededitormacro_id}"
100 "/advanced_editor/macros/{advancededitormacro_id}":
101 $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1{advancededitormacro_id}"
102 "/article_requests/{article_request_id}":
103 $ref: "./paths/article_requests.yaml#/~1article_requests~1{article_request_id}"
104 /auth/otp/token_delivery:
105 $ref: paths/auth.yaml#/~1auth~1otp~1token_delivery
106 "/biblios/{biblio_id}":
107 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}"
108 "/biblios/{biblio_id}/checkouts":
109 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1checkouts"
110 "/biblios/{biblio_id}/items":
111 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1items"
112 "/biblios/{biblio_id}/pickup_locations":
113 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1pickup_locations"
114 "/biblios/{biblio_id}/item_groups":
115 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups"
116 "/biblios/{biblio_id}/item_groups/{item_group_id}":
117 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}"
118 "/biblios/{biblio_id}/item_groups/{item_group_id}/items":
119 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}~1items"
120 "/biblios/{biblio_id}/item_groups/{item_group_id}/items/{item_id}":
121 $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}~1items~1{item_id}"
122 "/cash_registers/{cash_register_id}/cashups":
123 $ref: "./paths/cash_registers.yaml#/~1cash_registers~1{cash_register_id}~1cashups"
124 "/cashups/{cashup_id}":
125 $ref: "./paths/cash_registers.yaml#/~1cashups~1{cashup_id}"
127 $ref: ./paths/checkouts.yaml#/~1checkouts
128 "/checkouts/{checkout_id}":
129 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}"
130 "/checkouts/{checkout_id}/allows_renewal":
131 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1allows_renewal"
132 "/checkouts/{checkout_id}/renewals":
133 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1renewals"
134 "/checkouts/{checkout_id}/renewal":
135 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1renewal"
136 /circulation-rules/kinds:
137 $ref: ./paths/circulation-rules.yaml#/~1circulation-rules~1kinds
139 $ref: ./paths/cities.yaml#/~1cities
141 $ref: "./paths/cities.yaml#/~1cities~1{city_id}"
142 "/clubs/{club_id}/holds":
143 $ref: "./paths/clubs.yaml#/~1clubs~1{club_id}~1holds"
144 /config/smtp_servers:
145 $ref: ./paths/config_smtp_servers.yaml#/~1config~1smtp_servers
146 "/config/smtp_servers/{smtp_server_id}":
147 $ref: "./paths/config_smtp_servers.yaml#/~1config~1smtp_servers~1{smtp_server_id}"
149 $ref: ./paths/holds.yaml#/~1holds
151 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}"
152 "/holds/{hold_id}/pickup_location":
153 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_location"
154 "/holds/{hold_id}/pickup_locations":
155 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_locations"
156 "/holds/{hold_id}/priority":
157 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1priority"
158 "/holds/{hold_id}/suspension":
159 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1suspension"
161 $ref: ./paths/ill_backends.yaml#/~1ill_backends
162 "/ill_backends/{ill_backend_id}":
163 $ref: "./paths/ill_backends.yaml#/~1ill_backends~1{ill_backend_id}"
165 $ref: ./paths/illrequests.yaml#/~1illrequests
166 "/import_batches/{import_batch_id}/records/{import_record_id}/matches/chosen":
167 $ref: "./paths/import_batches.yaml#/~1import_batches~1{import_batch_id}~1records~1{import_record_id}~1matches~1chosen"
168 /import_batch_profiles:
169 $ref: ./paths/import_batch_profiles.yaml#/~1import_batch_profiles
170 "/import_batch_profiles/{import_batch_profile_id}":
171 $ref: "./paths/import_batch_profiles.yaml#/~1import_batch_profiles~1{import_batch_profile_id}"
173 $ref: ./paths/items.yaml#/~1items
175 $ref: "./paths/items.yaml#/~1items~1{item_id}"
176 "/items/{item_id}/bundled_items":
177 $ref: ./paths/items.yaml#/~1items~1{item_id}~1bundled_items
178 "/items/{item_id}/bundled_items/{bundled_item_id}":
179 $ref: ./paths/items.yaml#/~1items~1{item_id}~1bundled_items~1{bundled_item_id}
180 "/items/{item_id}/pickup_locations":
181 $ref: "./paths/items.yaml#/~1items~1{item_id}~1pickup_locations"
183 $ref: ./paths/libraries.yaml#/~1libraries
184 "/libraries/{library_id}":
185 $ref: "./paths/libraries.yaml#/~1libraries~1{library_id}"
187 $ref: ./paths/oauth.yaml#/~1oauth~1token
189 $ref: ./paths/patrons.yaml#/~1patrons
190 "/patrons/{patron_id}":
191 $ref: "./paths/patrons.yaml#/~1patrons~1{patron_id}"
192 "/patrons/{patron_id}/account":
193 $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account"
194 "/patrons/{patron_id}/account/credits":
195 $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account~1credits"
196 "/patrons/{patron_id}/extended_attributes":
197 $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes"
198 "/patrons/{patron_id}/extended_attributes/{extended_attribute_id}":
199 $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes~1{extended_attribute_id}"
200 "/patrons/{patron_id}/holds":
201 $ref: "./paths/patrons_holds.yaml#/~1patrons~1{patron_id}~1holds"
202 "/patrons/{patron_id}/password":
203 $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password"
204 "/patrons/{patron_id}/password/expiration_date":
205 $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password~1expiration_date"
206 "/public/biblios/{biblio_id}":
207 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}"
208 "/public/biblios/{biblio_id}/items":
209 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}~1items"
211 $ref: ./paths/libraries.yaml#/~1public~1libraries
212 "/public/libraries/{library_id}":
213 $ref: "./paths/libraries.yaml#/~1public~1libraries~1{library_id}"
214 "/public/patrons/{patron_id}/article_requests/{article_request_id}":
215 $ref: "./paths/article_requests.yaml#/~1public~1patrons~1{patron_id}~1article_requests~1{article_request_id}"
216 "/public/patrons/{patron_id}/guarantors/can_see_charges":
217 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_charges"
218 "/public/patrons/{patron_id}/guarantors/can_see_checkouts":
219 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_checkouts"
220 "/public/patrons/{patron_id}/password":
221 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1password"
223 $ref: ./paths/quotes.yaml#/~1quotes
224 "/quotes/{quote_id}":
225 $ref: "./paths/quotes.yaml#/~1quotes~1{quote_id}"
227 $ref: ./paths/return_claims.yaml#/~1return_claims
228 "/return_claims/{claim_id}":
229 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}"
230 "/return_claims/{claim_id}/notes":
231 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1notes"
232 "/return_claims/{claim_id}/resolve":
233 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1resolve"
234 "/rotas/{rota_id}/stages/{stage_id}/position":
235 $ref: "./paths/rotas.yaml#/~1rotas~1{rota_id}~1stages~1{stage_id}~1position"
237 $ref: ./paths/suggestions.yaml#/~1suggestions
238 "/suggestions/{suggestion_id}":
239 $ref: "./paths/suggestions.yaml#/~1suggestions~1{suggestion_id}"
240 /suggestions/managers:
241 $ref: paths/suggestions.yaml#/~1suggestions~1managers
243 $ref: ./paths/transfer_limits.yaml#/~1transfer_limits
244 /transfer_limits/batch:
245 $ref: ./paths/transfer_limits.yaml#/~1transfer_limits~1batch
246 "/transfer_limits/{limit_id}":
247 $ref: "./paths/transfer_limits.yaml#/~1transfer_limits~1{limit_id}"
249 advancededitormacro_id_pp:
250 description: Advanced editor macro internal identifier
252 name: advancededitormacro_id
256 description: Record internal identifier
261 candidate_match_id_pp:
262 description: Internal import record match identifier
264 name: candidate_match_id
268 description: Cash register internal identifier
270 name: cash_register_id
274 description: Cashup internal identifier
280 description: Internal checkout identifier
286 description: City internal identifier
292 description: Internal club identifier
304 description: Internal hold identifier
309 import_batch_profile_id_pp:
310 description: Internal profile identifier
312 name: import_batch_profile_id
316 description: Internal import record identifier
318 name: import_record_id
322 description: Internal item identifier
328 description: Internal library identifier
334 description: Matching criteria
345 collectionFormat: csv
346 description: Sorting criteria
354 description: Internal order identifier
360 description: "Page number, for paginated object listing"
366 description: Internal patron identifier
372 description: Internal patron identifier
377 description: "Page size, for paginated object listing"
383 description: Query filter sent through request"s body
390 description: Query filter sent as a request header
396 description: Query filter sent as a request parameter
403 collectionFormat: multi
405 description: Quote internal identifier
411 description: Request id header
413 name: x-koha-request-id
417 description: Item was seen flag
423 description: SMTP server internal identifier
429 description: Internal suggestion identifier
434 transfer_limit_id_pp:
435 description: Internal transfer limit identifier
441 description: Vendor id
451 url: http://www.gnu.org/licenses/gpl.txt
453 name: Koha Development Team
454 url: https://koha-community.org/
458 This API is documented in **OpenAPI format**.
462 The API supports the following authentication mechanisms
464 * HTTP Basic authentication
465 * OAuth2 (client credentials grant)
468 Both _Basic authentication_ and the _OAuth2_ flow, need to be enabled
469 by system preferences.
473 The API uses standard HTTP status codes to indicate the success or failure
474 of the API call. The body of the response will be JSON in the following format:
478 "error": "Current settings prevent the passed due date to be applied",
479 "error_code": "invalid_due_date"
483 Note: Some routes might offer additional attributes in their error responses but that"s
484 subject to change and thus not documented.
486 ## Filtering responses
488 The API allows for some advanced response filtering using a JSON based query syntax. The
489 query can be added to the requests:
491 * as a query parameter `q=`
492 * in the request body
493 * in a special header `x-koha-query`
495 For simple field equality matches we can use `{ "fieldname": "value" }` where the fieldname
496 matches one of the fields as described in the particular endpoints response object.
498 We can refine that with more complex matching clauses by nesting a the clause into the
499 object; `{ "fieldname": { "clause": "value" } }`.
501 Available matching clauses include ">", "<", ">=", "<=", "-like", and "-not_like".
503 We can filter on multiple fields by adding them to the JSON respresentation. Adding at `HASH`
504 level will result in an "AND" query, whilst combinding them in an `ARRAY` wilth result in an
505 "OR" query: `{ "field1": "value2", "field2": "value2" }` will filter the response to only those
506 results with both field1 containing value2 AND field2 containing value2 for example.
508 Additionally, if you are requesting related data be embedded into the response one can query
509 on the related data using dot notation in the field names.
513 The following request would return any patron with firstname "Henry" and lastname "Acevedo";
515 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": "Acevedo", "firstname": "Henry" }"`
517 The following request would return any patron whose lastname begins with "Ace";
519 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": { "-like": "Ace%" }"`
521 The following request would return any patron whose lastname is "Acevedo" OR "Bernardo"
523 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": [ "Acevedo", "Bernardo" ] }"`
525 The following request embeds the related patron extended attributes data and filters on it.
527 `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" }'`
533 This optional header allows the api consumer to request additional related data
534 to be returned in the api response. It also allows for cross referencing in the
535 queries as described above. It accepts a comma delimited list of relation names.
537 Relations may on occasion also support dot delimited nesting to allow traversal.
541 This optional header should be passed to give your api request a library
542 context; If it is not included in the request, then the request context
543 will default to using your api comsumer"s assigned home library.
545 - description: "Handle two factor authentication flows\n"
547 x-displayName: Two factor authentication
548 - description: "Manage article requests\n"
549 name: article_requests
550 x-displayName: Article requests
551 - description: "Manage baskets for the acquisitions module\n"
553 x-displayName: Baskets
554 - description: "Manage bibliographic records\n"
556 x-displayName: Biblios
557 - description: "Manage cash register cashups\n"
559 x-displayName: Cashups
560 - description: "Manage checkouts\n"
562 x-displayName: Checkouts
563 - description: "Manage circulation rules\n"
564 name: circulation_rules
565 x-displayName: Circulation rules
566 - description: "Manage cities\n"
568 x-displayName: Cities
569 - description: "Manage patron clubs\n"
572 - description: "Manage funds for the acquisitions module\n"
575 - description: "Manage holds\n"
578 - description: "Manage ILL module backends\n"
580 x-displayName: ILL backends
581 - description: "Manage ILL requests\n"
583 x-displayName: ILL requests
584 - description: "Manage import batches\n"
586 x-display-name: Import batches
587 - description: "Manage items\n"
590 - description: "Manage libraries\n"
592 x-displayName: Libraries
593 - description: "Manage macros\n"
595 x-displayName: Macros
596 - description: "Manage acquisition orders\n"
598 x-displayName: Orders
599 - description: "Handle OAuth flows\n"
602 - description: "Manage patrons\n"
604 x-displayName: Patrons
605 - description: "Manage quotes\n"
607 x-displayName: Quotes
608 - description: "Manage return claims\n"
610 x-displayName: Return claims
611 - description: "Manage rotas\n"
614 - description: "Manage SMTP servers configurations\n"
616 x-displayName: SMTP servers
617 - description: "Manage transfer limits\n"
619 x-displayName: Transfer limits
620 - description: "Manage purchase suggestions\n"
622 x-displayName: Purchase suggestions
623 - description: "Manage vendors for the acquisitions module\n"
625 x-displayName: Vendors
626 - description: "Manage batch import profiles\n"
627 name: batch_import_profiles
628 x-displayName: Batch import profiles