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/cashup.yaml
16 $ref: ./definitions/checkout.yaml
18 $ref: ./definitions/checkouts.yaml
20 $ref: ./definitions/circ-rule-kind.yaml
22 $ref: ./definitions/city.yaml
24 $ref: ./definitions/error.yaml
26 $ref: ./definitions/fund.yaml
28 $ref: ./definitions/hold.yaml
30 $ref: ./definitions/holds.yaml
32 $ref: ./definitions/ill_backend.yaml
34 $ref: ./definitions/ill_backends.yaml
36 $ref: ./definitions/import_batch_profile.yaml
37 import_batch_profiles:
38 $ref: ./definitions/import_batch_profiles.yaml
40 $ref: ./definitions/import_record_match.yaml
42 $ref: ./definitions/invoice.yaml
44 $ref: ./definitions/item.yaml
46 $ref: ./definitions/job.yaml
48 $ref: ./definitions/library.yaml
50 $ref: ./definitions/order.yaml
52 $ref: ./definitions/patron.yaml
53 patron_account_credit:
54 $ref: ./definitions/patron_account_credit.yaml
56 $ref: ./definitions/patron_balance.yaml
57 patron_extended_attribute:
58 $ref: ./definitions/patron_extended_attribute.yaml
60 $ref: ./definitions/quote.yaml
62 $ref: ./definitions/return_claim.yaml
64 $ref: ./definitions/smtp_server.yaml
66 $ref: ./definitions/suggestion.yaml
68 $ref: ./definitions/transfer_limit.yaml
70 $ref: ./definitions/vendor.yaml
72 /acquisitions/baskets/managers:
73 $ref: paths/acquisitions_baskets.yaml#/~1acquisitions~1baskets~1managers
75 $ref: ./paths/acquisitions_funds.yaml#/~1acquisitions~1funds
76 /acquisitions/funds/owners:
77 $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1owners
78 /acquisitions/funds/users:
79 $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1users
81 $ref: ./paths/acquisitions_orders.yaml#/~1acquisitions~1orders
82 "/acquisitions/orders/{order_id}":
83 $ref: "./paths/acquisitions_orders.yaml#/~1acquisitions~1orders~1{order_id}"
84 /acquisitions/vendors:
85 $ref: ./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors
86 "/acquisitions/vendors/{vendor_id}":
87 $ref: "./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors~1{vendor_id}"
88 /advanced_editor/macros:
89 $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros
90 /advanced_editor/macros/shared:
91 $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared
92 "/advanced_editor/macros/shared/{advancededitormacro_id}":
93 $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared~1{advancededitormacro_id}"
94 "/advanced_editor/macros/{advancededitormacro_id}":
95 $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1{advancededitormacro_id}"
96 "/article_requests/{article_request_id}":
97 $ref: "./paths/article_requests.yaml#/~1article_requests~1{article_request_id}"
98 "/biblios/{biblio_id}":
99 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}"
100 "/biblios/{biblio_id}/checkouts":
101 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1checkouts"
102 "/biblios/{biblio_id}/items":
103 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1items"
104 "/biblios/{biblio_id}/pickup_locations":
105 $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1pickup_locations"
106 "/cash_registers/{cash_register_id}/cashups":
107 $ref: "./paths/cash_registers.yaml#/~1cash_registers~1{cash_register_id}~1cashups"
108 "/cashups/{cashup_id}":
109 $ref: "./paths/cash_registers.yaml#/~1cashups~1{cashup_id}"
111 $ref: ./paths/checkouts.yaml#/~1checkouts
112 "/checkouts/{checkout_id}":
113 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}"
114 "/checkouts/{checkout_id}/allows_renewal":
115 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1allows_renewal"
116 "/checkouts/{checkout_id}/renewal":
117 $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1renewal"
118 /circulation-rules/kinds:
119 $ref: ./paths/circulation-rules.yaml#/~1circulation-rules~1kinds
121 $ref: ./paths/cities.yaml#/~1cities
123 $ref: "./paths/cities.yaml#/~1cities~1{city_id}"
124 "/clubs/{club_id}/holds":
125 $ref: "./paths/clubs.yaml#/~1clubs~1{club_id}~1holds"
126 /config/smtp_servers:
127 $ref: ./paths/config_smtp_servers.yaml#/~1config~1smtp_servers
128 "/config/smtp_servers/{smtp_server_id}":
129 $ref: "./paths/config_smtp_servers.yaml#/~1config~1smtp_servers~1{smtp_server_id}"
131 $ref: ./paths/holds.yaml#/~1holds
133 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}"
134 "/holds/{hold_id}/pickup_location":
135 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_location"
136 "/holds/{hold_id}/pickup_locations":
137 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_locations"
138 "/holds/{hold_id}/priority":
139 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1priority"
140 "/holds/{hold_id}/suspension":
141 $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1suspension"
143 $ref: ./paths/ill_backends.yaml#/~1ill_backends
144 "/ill_backends/{ill_backend_id}":
145 $ref: "./paths/ill_backends.yaml#/~1ill_backends~1{ill_backend_id}"
147 $ref: ./paths/illrequests.yaml#/~1illrequests
148 "/import_batches/{import_batch_id}/records/{import_record_id}/matches/chosen":
149 $ref: "./paths/import_batches.yaml#/~1import_batches~1{import_batch_id}~1records~1{import_record_id}~1matches~1chosen"
150 /import_batch_profiles:
151 $ref: ./paths/import_batch_profiles.yaml#/~1import_batch_profiles
152 "/import_batch_profiles/{import_batch_profile_id}":
153 $ref: "./paths/import_batch_profiles.yaml#/~1import_batch_profiles~1{import_batch_profile_id}"
155 $ref: ./paths/items.yaml#/~1items
157 $ref: "./paths/items.yaml#/~1items~1{item_id}"
158 "/items/{item_id}/pickup_locations":
159 $ref: "./paths/items.yaml#/~1items~1{item_id}~1pickup_locations"
161 $ref: ./paths/jobs.yaml#/~1jobs
163 $ref: "./paths/jobs.yaml#/~1jobs~1{job_id}"
165 $ref: ./paths/libraries.yaml#/~1libraries
166 "/libraries/{library_id}":
167 $ref: "./paths/libraries.yaml#/~1libraries~1{library_id}"
169 $ref: ./paths/oauth.yaml#/~1oauth~1token
171 $ref: ./paths/patrons.yaml#/~1patrons
172 "/patrons/{patron_id}":
173 $ref: "./paths/patrons.yaml#/~1patrons~1{patron_id}"
174 "/patrons/{patron_id}/account":
175 $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account"
176 "/patrons/{patron_id}/account/credits":
177 $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account~1credits"
178 "/patrons/{patron_id}/extended_attributes":
179 $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes"
180 "/patrons/{patron_id}/extended_attributes/{extended_attribute_id}":
181 $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes~1{extended_attribute_id}"
182 "/patrons/{patron_id}/holds":
183 $ref: "./paths/patrons_holds.yaml#/~1patrons~1{patron_id}~1holds"
184 "/patrons/{patron_id}/password":
185 $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password"
186 "/patrons/{patron_id}/password/expiration_date":
187 $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password~1expiration_date"
188 "/public/biblios/{biblio_id}":
189 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}"
190 "/public/biblios/{biblio_id}/items":
191 $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}~1items"
193 $ref: ./paths/libraries.yaml#/~1public~1libraries
194 "/public/libraries/{library_id}":
195 $ref: "./paths/libraries.yaml#/~1public~1libraries~1{library_id}"
196 "/public/patrons/{patron_id}/article_requests/{article_request_id}":
197 $ref: "./paths/article_requests.yaml#/~1public~1patrons~1{patron_id}~1article_requests~1{article_request_id}"
198 "/public/patrons/{patron_id}/guarantors/can_see_charges":
199 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_charges"
200 "/public/patrons/{patron_id}/guarantors/can_see_checkouts":
201 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_checkouts"
202 "/public/patrons/{patron_id}/password":
203 $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1password"
205 $ref: ./paths/quotes.yaml#/~1quotes
206 "/quotes/{quote_id}":
207 $ref: "./paths/quotes.yaml#/~1quotes~1{quote_id}"
209 $ref: ./paths/return_claims.yaml#/~1return_claims
210 "/return_claims/{claim_id}":
211 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}"
212 "/return_claims/{claim_id}/notes":
213 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1notes"
214 "/return_claims/{claim_id}/resolve":
215 $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1resolve"
216 "/rotas/{rota_id}/stages/{stage_id}/position":
217 $ref: "./paths/rotas.yaml#/~1rotas~1{rota_id}~1stages~1{stage_id}~1position"
219 $ref: ./paths/suggestions.yaml#/~1suggestions
220 "/suggestions/{suggestion_id}":
221 $ref: "./paths/suggestions.yaml#/~1suggestions~1{suggestion_id}"
222 /suggestions/managers:
223 $ref: paths/suggestions.yaml#/~1suggestions~1managers
225 $ref: ./paths/transfer_limits.yaml#/~1transfer_limits
226 /transfer_limits/batch:
227 $ref: ./paths/transfer_limits.yaml#/~1transfer_limits~1batch
228 "/transfer_limits/{limit_id}":
229 $ref: "./paths/transfer_limits.yaml#/~1transfer_limits~1{limit_id}"
231 advancededitormacro_id_pp:
232 description: Advanced editor macro internal identifier
234 name: advancededitormacro_id
238 description: Record internal identifier
243 candidate_match_id_pp:
244 description: Internal import record match identifier
246 name: candidate_match_id
250 description: Cash register internal identifier
252 name: cash_register_id
256 description: Cashup internal identifier
262 description: Internal checkout identifier
268 description: City internal identifier
274 description: Internal club identifier
286 description: Internal hold identifier
291 import_batch_profile_id_pp:
292 description: Internal profile identifier
294 name: import_batch_profile_id
298 description: Internal import record identifier
300 name: import_record_id
304 description: Internal item identifier
310 description: Job internal identifier
316 description: Internal library identifier
322 description: Matching criteria
333 collectionFormat: csv
334 description: Sorting criteria
342 description: Internal order identifier
348 description: "Page number, for paginated object listing"
354 description: Internal patron identifier
360 description: Internal patron identifier
365 description: "Page size, for paginated object listing"
371 description: Query filter sent through request"s body
378 description: Query filter sent as a request header
384 description: Query filter sent as a request parameter
391 collectionFormat: multi
393 description: Quote internal identifier
399 description: Request id header
401 name: x-koha-request-id
405 description: Item was seen flag
411 description: SMTP server internal identifier
417 description: Internal suggestion identifier
422 transfer_limit_id_pp:
423 description: Internal transfer limit identifier
429 description: Vendor id
439 url: http://www.gnu.org/licenses/gpl.txt
441 name: Koha Development Team
442 url: https://koha-community.org/
446 This API is documented in **OpenAPI format**.
450 The API supports the following authentication mechanisms
452 * HTTP Basic authentication
453 * OAuth2 (client credentials grant)
456 Both _Basic authentication_ and the _OAuth2_ flow, need to be enabled
457 by system preferences.
461 The API uses standard HTTP status codes to indicate the success or failure
462 of the API call. The body of the response will be JSON in the following format:
466 "error": "Current settings prevent the passed due date to be applied",
467 "error_code": "invalid_due_date"
471 Note: Some routes might offer additional attributes in their error responses but that"s
472 subject to change and thus not documented.
474 ## Filtering responses
476 The API allows for some advanced response filtering using a JSON based query syntax. The
477 query can be added to the requests:
479 * as a query parameter `q=`
480 * in the request body
481 * in a special header `x-koha-query`
483 For simple field equality matches we can use `{ "fieldname": "value" }` where the fieldname
484 matches one of the fields as described in the particular endpoints response object.
486 We can refine that with more complex matching clauses by nesting a the clause into the
487 object; `{ "fieldname": { "clause": "value" } }`.
489 Available matching clauses include ">", "<", ">=", "<=", "-like", and "-not_like".
491 We can filter on multiple fields by adding them to the JSON respresentation. Adding at `HASH`
492 level will result in an "AND" query, whilst combinding them in an `ARRAY` wilth result in an
493 "OR" query: `{ "field1": "value2", "field2": "value2" }` will filter the response to only those
494 results with both field1 containing value2 AND field2 containing value2 for example.
496 Additionally, if you are requesting related data be embedded into the response one can query
497 on the related data using dot notation in the field names.
501 The following request would return any patron with firstname "Henry" and lastname "Acevedo";
503 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": "Acevedo", "firstname": "Henry" }"`
505 The following request would return any patron whose lastname begins with "Ace";
507 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": { "-like": "Ace%" }"`
509 The following request would return any patron whose lastname is "Acevedo" OR "Bernardo"
511 `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": [ "Acevedo", "Bernardo" ] }"`
513 The following request embeds the related patron extended attributes data and filters on it.
515 `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" }'`
521 This optional header allows the api consumer to request additional related data
522 to be returned in the api response. It also allows for cross referencing in the
523 queries as described above. It accepts a comma delimited list of relation names.
525 Relations may on occasion also support dot delimited nesting to allow traversal.
529 This optional header should be passed to give your api request a library
530 context; If it is not included in the request, then the request context
531 will default to using your api comsumer"s assigned home library.
533 - description: "Manage article requests\n"
534 name: article_requests
535 x-displayName: Article requests
536 - description: "Manage baskets for the acquisitions module\n"
538 x-displayName: Baskets
539 - description: "Manage bibliographic records\n"
541 x-displayName: Biblios
542 - description: "Manage cash register cashups\n"
544 x-displayName: Cashups
545 - description: "Manage checkouts\n"
547 x-displayName: Checkouts
548 - description: "Manage circulation rules\n"
549 name: circulation_rules
550 x-displayName: Circulation rules
551 - description: "Manage cities\n"
553 x-displayName: Cities
554 - description: "Manage patron clubs\n"
557 - description: "Manage funds for the acquisitions module\n"
560 - description: "Manage holds\n"
563 - description: "Manage ILL module backends\n"
565 x-displayName: ILL backends
566 - description: "Manage ILL requests\n"
568 x-displayName: ILL requests
569 - description: "Manage import batches\n"
571 x-display-name: Import batches
572 - description: "Manage items\n"
575 - description: "Manage jobs\n"
578 - description: "Manage libraries\n"
580 x-displayName: Libraries
581 - description: "Manage macros\n"
583 x-displayName: Macros
584 - description: "Manage acquisition orders\n"
586 x-displayName: Orders
587 - description: "Handle OAuth flows\n"
590 - description: "Manage patrons\n"
592 x-displayName: Patrons
593 - description: "Manage quotes\n"
595 x-displayName: Quotes
596 - description: "Manage return claims\n"
598 x-displayName: Return claims
599 - description: "Manage rotas\n"
602 - description: "Manage SMTP servers configurations\n"
604 x-displayName: SMTP servers
605 - description: "Manage transfer limits\n"
607 x-displayName: Transfer limits
608 - description: "Manage purchase suggestions\n"
610 x-displayName: Purchase suggestions
611 - description: "Manage vendors for the acquisitions module\n"
613 x-displayName: Vendors
614 - description: "Manage batch import profiles\n"
615 name: batch_import_profiles
616 x-displayName: Batch import profiles