Bug 31794: Add REST endpoint to get an authority
[koha.git] / api / v1 / swagger / swagger.yaml
1 ---
2 swagger: "2.0"
3 basePath: /api/v1
4 definitions:
5   account_line:
6     $ref: ./definitions/account_line.yaml
7   advancededitormacro:
8     $ref: ./definitions/advancededitormacro.yaml
9   allows_renewal:
10     $ref: ./definitions/allows_renewal.yaml
11   authorised_value:
12     $ref: ./definitions/authorised_value.yaml
13   authorised_value_category:
14     $ref: ./definitions/authorised_value_category.yaml
15   identity_provider:
16     "$ref": ./definitions/identity_provider.yaml
17   identity_provider_domain:
18     "$ref": ./definitions/identity_provider_domain.yaml
19   basket:
20     $ref: ./definitions/basket.yaml
21   bundle_link:
22     $ref: ./definitions/bundle_link.yaml
23   cashup:
24     $ref: ./definitions/cashup.yaml
25   checkout:
26     $ref: ./definitions/checkout.yaml
27   checkouts:
28     $ref: ./definitions/checkouts.yaml
29   circ-rule-kind:
30     $ref: ./definitions/circ-rule-kind.yaml
31   city:
32     $ref: ./definitions/city.yaml
33   erm_agreement:
34     $ref: ./definitions/erm_agreement.yaml
35   erm_eholdings_title:
36     $ref: ./definitions/erm_eholdings_title.yaml
37   erm_eholdings_package:
38     $ref: ./definitions/erm_eholdings_package.yaml
39   erm_eholdings_resource:
40     $ref: ./definitions/erm_eholdings_resource.yaml
41   erm_license:
42     $ref: ./definitions/erm_license.yaml
43   error:
44     $ref: ./definitions/error.yaml
45   fund:
46     $ref: ./definitions/fund.yaml
47   hold:
48     $ref: ./definitions/hold.yaml
49   holds:
50     $ref: ./definitions/holds.yaml
51   ill_backend:
52     $ref: ./definitions/ill_backend.yaml
53   ill_backends:
54     $ref: ./definitions/ill_backends.yaml
55   import_batch_profile:
56     $ref: ./definitions/import_batch_profile.yaml
57   import_batch_profiles:
58     $ref: ./definitions/import_batch_profiles.yaml
59   import_record_match:
60     $ref: ./definitions/import_record_match.yaml
61   invoice:
62     $ref: ./definitions/invoice.yaml
63   item:
64     $ref: ./definitions/item.yaml
65   item_group:
66     $ref: ./definitions/item_group.yaml
67   job:
68     $ref: ./definitions/job.yaml
69   library:
70     $ref: ./definitions/library.yaml
71   order:
72     $ref: ./definitions/order.yaml
73   patron:
74     $ref: ./definitions/patron.yaml
75   patron_account_credit:
76     $ref: ./definitions/patron_account_credit.yaml
77   patron_balance:
78     $ref: ./definitions/patron_balance.yaml
79   patron_extended_attribute:
80     $ref: ./definitions/patron_extended_attribute.yaml
81   quote:
82     $ref: ./definitions/quote.yaml
83   renewal:
84     $ref: ./definitions/renewal.yaml
85   renewals:
86     $ref: ./definitions/renewals.yaml
87   return_claim:
88     $ref: ./definitions/return_claim.yaml
89   search_filter:
90     $ref: ./definitions/search_filter.yaml
91   smtp_server:
92     $ref: ./definitions/smtp_server.yaml
93   suggestion:
94     $ref: ./definitions/suggestion.yaml
95   ticket:
96     $ref: ./definitions/ticket.yaml
97   ticket_update:
98     $ref: ./definitions/ticket_update.yaml
99   transfer_limit:
100     $ref: ./definitions/transfer_limit.yaml
101   vendor:
102     $ref: ./definitions/vendor.yaml
103 paths:
104   /acquisitions/baskets/managers:
105     $ref: paths/acquisitions_baskets.yaml#/~1acquisitions~1baskets~1managers
106   /acquisitions/funds:
107     $ref: ./paths/acquisitions_funds.yaml#/~1acquisitions~1funds
108   /acquisitions/funds/owners:
109     $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1owners
110   /acquisitions/funds/users:
111     $ref: paths/acquisitions_funds.yaml#/~1acquisitions~1funds~1users
112   /acquisitions/orders:
113     $ref: ./paths/acquisitions_orders.yaml#/~1acquisitions~1orders
114   "/acquisitions/orders/{order_id}":
115     $ref: "./paths/acquisitions_orders.yaml#/~1acquisitions~1orders~1{order_id}"
116   /acquisitions/vendors:
117     $ref: ./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors
118   "/acquisitions/vendors/{vendor_id}":
119     $ref: "./paths/acquisitions_vendors.yaml#/~1acquisitions~1vendors~1{vendor_id}"
120   /advanced_editor/macros:
121     $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros
122   /advanced_editor/macros/shared:
123     $ref: ./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared
124   /search_filters:
125     $ref: ./paths/search_filters.yaml#/~1search_filters
126   "/search_filters/{search_filter_id}":
127     $ref: "./paths/search_filters.yaml#/~1search_filters~1{search_filter_id}"
128   "/advanced_editor/macros/shared/{advancededitormacro_id}":
129     $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1shared~1{advancededitormacro_id}"
130   "/advanced_editor/macros/{advancededitormacro_id}":
131     $ref: "./paths/advancededitormacros.yaml#/~1advanced_editor~1macros~1{advancededitormacro_id}"
132   "/article_requests/{article_request_id}":
133     $ref: "./paths/article_requests.yaml#/~1article_requests~1{article_request_id}"
134   /auth/otp/token_delivery:
135     $ref: paths/auth.yaml#/~1auth~1otp~1token_delivery
136   "/auth/password/validation":
137     $ref: "./paths/auth.yaml#/~1auth~1password~1validation"
138   /auth/two-factor/registration:
139     $ref: paths/auth.yaml#/~1auth~1two-factor~1registration
140   /auth/two-factor/registration/verification:
141     $ref: paths/auth.yaml#/~1auth~1two-factor~1registration~1verification
142   /auth/identity_providers:
143     $ref: paths/auth.yaml#/~1auth~1identity_providers
144   "/auth/identity_providers/{identity_provider_id}":
145     $ref: paths/auth.yaml#/~1auth~1identity_providers~1{identity_provider_id}
146   "/auth/identity_providers/{identity_provider_id}/domains":
147     $ref: paths/auth.yaml#/~1auth~1identity_providers~1{identity_provider_id}~1domains
148   "/auth/identity_providers/{identity_provider_id}/domains/{identity_provider_domain_id}":
149     $ref: paths/auth.yaml#/~1auth~1identity_providers~1{identity_provider_id}~1domains~1{identity_provider_domain_id}
150   /authorised_value_categories:
151     $ref: paths/authorised_value_categories.yaml#/~1authorised_value_categories
152   "/authorised_value_categories/{authorised_value_category_name}/authorised_values":
153     $ref: "./paths/authorised_values.yaml#/~1authorised_value_categories~1{authorised_value_category_name}~1authorised_values"
154   "/authorities/{authority_id}":
155     $ref: paths/authorities.yaml#/~1authorities~1{authority_id}
156   "/biblios/{biblio_id}":
157     $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}"
158   "/biblios/{biblio_id}/checkouts":
159     $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1checkouts"
160   "/biblios/{biblio_id}/items":
161     $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1items"
162   "/biblios/{biblio_id}/pickup_locations":
163     $ref: "./paths/biblios.yaml#/~1biblios~1{biblio_id}~1pickup_locations"
164   "/biblios/{biblio_id}/item_groups":
165     $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups"
166   "/biblios/{biblio_id}/item_groups/{item_group_id}":
167     $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}"
168   "/biblios/{biblio_id}/item_groups/{item_group_id}/items":
169     $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}~1items"
170   "/biblios/{biblio_id}/item_groups/{item_group_id}/items/{item_id}":
171     $ref: "./paths/biblios_item_groups.yaml#/~1biblios~1{biblio_id}~1item_groups~1{item_group_id}~1items~1{item_id}"
172   "/cash_registers/{cash_register_id}/cashups":
173     $ref: "./paths/cash_registers.yaml#/~1cash_registers~1{cash_register_id}~1cashups"
174   "/cashups/{cashup_id}":
175     $ref: "./paths/cash_registers.yaml#/~1cashups~1{cashup_id}"
176   /checkouts:
177     $ref: ./paths/checkouts.yaml#/~1checkouts
178   "/checkouts/{checkout_id}":
179     $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}"
180   "/checkouts/{checkout_id}/allows_renewal":
181     $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1allows_renewal"
182   "/checkouts/{checkout_id}/renewals":
183     $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1renewals"
184   "/checkouts/{checkout_id}/renewal":
185     $ref: "./paths/checkouts.yaml#/~1checkouts~1{checkout_id}~1renewal"
186   /circulation-rules/kinds:
187     $ref: ./paths/circulation-rules.yaml#/~1circulation-rules~1kinds
188   /cities:
189     $ref: ./paths/cities.yaml#/~1cities
190   "/cities/{city_id}":
191     $ref: "./paths/cities.yaml#/~1cities~1{city_id}"
192   "/clubs/{club_id}/holds":
193     $ref: "./paths/clubs.yaml#/~1clubs~1{club_id}~1holds"
194   /config/smtp_servers:
195     $ref: ./paths/config_smtp_servers.yaml#/~1config~1smtp_servers
196   "/config/smtp_servers/{smtp_server_id}":
197     $ref: "./paths/config_smtp_servers.yaml#/~1config~1smtp_servers~1{smtp_server_id}"
198   /erm/agreements:
199     $ref: ./paths/erm_agreements.yaml#/~1erm~1agreements
200   "/erm/agreements/{agreement_id}":
201     $ref: "./paths/erm_agreements.yaml#/~1erm~1agreements~1{agreement_id}"
202   "/erm/documents/{document_id}/file/content":
203     $ref: "./paths/erm_documents.yaml#/~1erm~1documents~1{document_id}~1file~1content"
204   "/erm/eholdings/{provider}/titles":
205     $ref: "./paths/erm_eholdings_titles.yaml#/~1erm~1eholdings~1{provider}~1titles"
206   /erm/eholdings/local/titles/import:
207     $ref: ./paths/erm_eholdings_titles.yaml#/~1erm~1eholdings~1local~1titles~1import
208   "/erm/eholdings/{provider}/titles/{title_id}":
209     $ref: "./paths/erm_eholdings_titles.yaml#/~1erm~1eholdings~1{provider}~1titles~1{title_id}"
210   "/erm/eholdings/{provider}/titles/{title_id}/resources":
211     $ref: "./paths/erm_eholdings_titles_resources.yaml#/~1erm~1eholdings~1{provider}~1titles~1{title_id}~1resources"
212   "/erm/eholdings/{provider}/packages":
213     $ref: "./paths/erm_eholdings_packages.yaml#/~1erm~1eholdings~1{provider}~1packages"
214   "/erm/eholdings/{provider}/resources":
215     $ref: "./paths/erm_eholdings_resources.yaml#/~1erm~1eholdings~1{provider}~1resources"
216   "/erm/eholdings/{provider}/resources/{resource_id}":
217     $ref: "./paths/erm_eholdings_resources.yaml#/~1erm~1eholdings~1{provider}~1resources~1{resource_id}"
218   "/erm/eholdings/{provider}/packages/{package_id}":
219     $ref: "./paths/erm_eholdings_packages.yaml#/~1erm~1eholdings~1{provider}~1packages~1{package_id}"
220   "/erm/eholdings/{provider}/packages/{package_id}/resources":
221     $ref: "./paths/erm_eholdings_packages_resources.yaml#/~1erm~1eholdings~1{provider}~1packages~1{package_id}~1resources"
222   /erm/licenses:
223     $ref: ./paths/erm_licenses.yaml#/~1erm~1licenses
224   "/erm/licenses/{license_id}":
225     $ref: "./paths/erm_licenses.yaml#/~1erm~1licenses~1{license_id}"
226   /erm/users:
227     $ref: ./paths/erm_users.yaml#/~1erm~1users
228   /holds:
229     $ref: ./paths/holds.yaml#/~1holds
230   "/holds/{hold_id}":
231     $ref: "./paths/holds.yaml#/~1holds~1{hold_id}"
232   "/holds/{hold_id}/pickup_location":
233     $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_location"
234   "/holds/{hold_id}/pickup_locations":
235     $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1pickup_locations"
236   "/holds/{hold_id}/priority":
237     $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1priority"
238   "/holds/{hold_id}/suspension":
239     $ref: "./paths/holds.yaml#/~1holds~1{hold_id}~1suspension"
240   /ill_backends:
241     $ref: ./paths/ill_backends.yaml#/~1ill_backends
242   "/ill_backends/{ill_backend_id}":
243     $ref: "./paths/ill_backends.yaml#/~1ill_backends~1{ill_backend_id}"
244   /illrequests:
245     $ref: ./paths/illrequests.yaml#/~1illrequests
246   "/import_batches/{import_batch_id}/records/{import_record_id}/matches/chosen":
247     $ref: "./paths/import_batches.yaml#/~1import_batches~1{import_batch_id}~1records~1{import_record_id}~1matches~1chosen"
248   /import_batch_profiles:
249     $ref: ./paths/import_batch_profiles.yaml#/~1import_batch_profiles
250   "/import_batch_profiles/{import_batch_profile_id}":
251     $ref: "./paths/import_batch_profiles.yaml#/~1import_batch_profiles~1{import_batch_profile_id}"
252   /items:
253     $ref: ./paths/items.yaml#/~1items
254   "/items/{item_id}":
255     $ref: "./paths/items.yaml#/~1items~1{item_id}"
256   "/items/{item_id}/bundled_items":
257     $ref: ./paths/items.yaml#/~1items~1{item_id}~1bundled_items
258   "/items/{item_id}/bundled_items/{bundled_item_id}":
259     $ref: ./paths/items.yaml#/~1items~1{item_id}~1bundled_items~1{bundled_item_id}
260   "/items/{item_id}/pickup_locations":
261     $ref: "./paths/items.yaml#/~1items~1{item_id}~1pickup_locations"
262   /jobs:
263     $ref: ./paths/jobs.yaml#/~1jobs
264   "/jobs/{job_id}":
265     $ref: "./paths/jobs.yaml#/~1jobs~1{job_id}"
266   /libraries:
267     $ref: ./paths/libraries.yaml#/~1libraries
268   "/libraries/{library_id}":
269     $ref: "./paths/libraries.yaml#/~1libraries~1{library_id}"
270   /oauth/token:
271     $ref: ./paths/oauth.yaml#/~1oauth~1token
272   /patrons:
273     $ref: ./paths/patrons.yaml#/~1patrons
274   "/patrons/{patron_id}":
275     $ref: "./paths/patrons.yaml#/~1patrons~1{patron_id}"
276   "/patrons/{patron_id}/account":
277     $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account"
278   "/patrons/{patron_id}/account/credits":
279     $ref: "./paths/patrons_account.yaml#/~1patrons~1{patron_id}~1account~1credits"
280   "/patrons/{patron_id}/extended_attributes":
281     $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes"
282   "/patrons/{patron_id}/extended_attributes/{extended_attribute_id}":
283     $ref: "./paths/patrons_extended_attributes.yaml#/~1patrons~1{patron_id}~1extended_attributes~1{extended_attribute_id}"
284   "/patrons/{patron_id}/holds":
285     $ref: "./paths/patrons_holds.yaml#/~1patrons~1{patron_id}~1holds"
286   "/patrons/{patron_id}/password":
287     $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password"
288   "/patrons/{patron_id}/password/expiration_date":
289     $ref: "./paths/patrons_password.yaml#/~1patrons~1{patron_id}~1password~1expiration_date"
290   "/public/biblios/{biblio_id}":
291     $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}"
292   "/public/biblios/{biblio_id}/items":
293     $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}~1items"
294   "/public/biblios/{biblio_id}/ratings":
295     $ref: "./paths/biblios.yaml#/~1public~1biblios~1{biblio_id}~1ratings"
296   /public/libraries:
297     $ref: ./paths/libraries.yaml#/~1public~1libraries
298   "/public/libraries/{library_id}":
299     $ref: "./paths/libraries.yaml#/~1public~1libraries~1{library_id}"
300   "/public/oauth/login/{provider_code}/{interface}":
301     $ref: ./paths/public_oauth.yaml#/~1public~1oauth~1login~1{provider_code}~1{interface}
302   "/public/patrons/{patron_id}/article_requests/{article_request_id}":
303     $ref: "./paths/article_requests.yaml#/~1public~1patrons~1{patron_id}~1article_requests~1{article_request_id}"
304   "/public/patrons/{patron_id}/guarantors/can_see_charges":
305     $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_charges"
306   "/public/patrons/{patron_id}/guarantors/can_see_checkouts":
307     $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1guarantors~1can_see_checkouts"
308   "/public/patrons/{patron_id}/password":
309     $ref: "./paths/public_patrons.yaml#/~1public~1patrons~1{patron_id}~1password"
310   "/public/tickets":
311     $ref: "./paths/tickets.yaml#/~1public~1tickets"
312   /quotes:
313     $ref: ./paths/quotes.yaml#/~1quotes
314   "/quotes/{quote_id}":
315     $ref: "./paths/quotes.yaml#/~1quotes~1{quote_id}"
316   /return_claims:
317     $ref: ./paths/return_claims.yaml#/~1return_claims
318   "/return_claims/{claim_id}":
319     $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}"
320   "/return_claims/{claim_id}/notes":
321     $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1notes"
322   "/return_claims/{claim_id}/resolve":
323     $ref: "./paths/return_claims.yaml#/~1return_claims~1{claim_id}~1resolve"
324   "/rotas/{rota_id}/stages/{stage_id}/position":
325     $ref: "./paths/rotas.yaml#/~1rotas~1{rota_id}~1stages~1{stage_id}~1position"
326   /suggestions:
327     $ref: ./paths/suggestions.yaml#/~1suggestions
328   "/suggestions/{suggestion_id}":
329     $ref: "./paths/suggestions.yaml#/~1suggestions~1{suggestion_id}"
330   /suggestions/managers:
331     $ref: paths/suggestions.yaml#/~1suggestions~1managers
332   "/tickets":
333     $ref: "./paths/tickets.yaml#/~1tickets"
334   "/tickets/{ticket_id}":
335     $ref: "./paths/tickets.yaml#/~1tickets~1{ticket_id}"
336   "/tickets/{ticket_id}/updates":
337     $ref: "./paths/tickets.yaml#/~1tickets~1{ticket_id}~1updates"
338   /transfer_limits:
339     $ref: ./paths/transfer_limits.yaml#/~1transfer_limits
340   /transfer_limits/batch:
341     $ref: ./paths/transfer_limits.yaml#/~1transfer_limits~1batch
342   "/transfer_limits/{limit_id}":
343     $ref: "./paths/transfer_limits.yaml#/~1transfer_limits~1{limit_id}"
344 parameters:
345   advancededitormacro_id_pp:
346     description: Advanced editor macro internal identifier
347     in: path
348     name: advancededitormacro_id
349     required: true
350     type: integer
351   agreement_id_pp:
352     description: Agreement internal identifier
353     in: path
354     name: agreement_id
355     required: true
356     type: integer
357   agreement_period_id_pp:
358     description: Agreement period internal identifier
359     in: path
360     name: agreement_period_id
361     required: true
362     type: integer
363   authorised_value_id_pp:
364     description: Authorised value internal identifier
365     in: path
366     name: authorised_value_id
367     required: true
368     type: integer
369   authority_id_pp:
370     description: Authority identifier
371     in: path
372     name: authority_id
373     required: true
374     type: integer
375   identity_provider_id_pp:
376     description: Authentication provider internal identifier
377     in: path
378     name: identity_provider_id
379     required: true
380     type: integer
381   identity_provider_domain_id_pp:
382     description: Authentication provider domain internal identifier
383     in: path
384     name: identity_provider_domain_id
385     required: true
386     type: integer
387   biblio_id_pp:
388     description: Record internal identifier
389     in: path
390     name: biblio_id
391     required: true
392     type: integer
393   candidate_match_id_pp:
394     description: Internal import record match identifier
395     in: path
396     name: candidate_match_id
397     required: true
398     type: integer
399   cash_register_id_pp:
400     description: Cash register internal identifier
401     in: path
402     name: cash_register_id
403     required: true
404     type: integer
405   cashup_id_pp:
406     description: Cashup internal identifier
407     in: path
408     name: cashup_id
409     required: true
410     type: integer
411   checkout_id_pp:
412     description: Internal checkout identifier
413     in: path
414     name: checkout_id
415     required: true
416     type: integer
417   city_id_pp:
418     description: City internal identifier
419     in: path
420     name: city_id
421     required: true
422     type: integer
423   club_id_pp:
424     description: Internal club identifier
425     in: path
426     name: club_id
427     required: true
428     type: integer
429   eholdings_title_id_pp:
430     description: Title internal identifier
431     in: path
432     name: title_id
433     required: true
434     type: integer
435   eholdings_package_id_pp:
436     description: Package internal identifier
437     in: path
438     name: package_id
439     required: true
440     type: string
441   eholdings_resource_id_pp:
442     description: Resource internal identifier
443     in: path
444     name: resource_id
445     required: true
446     type: string
447   fund_id_pp:
448     description: Fund id
449     in: path
450     name: fund_id
451     required: true
452     type: integer
453   hold_id_pp:
454     description: Internal hold identifier
455     in: path
456     name: hold_id
457     required: true
458     type: integer
459   import_batch_profile_id_pp:
460     description: Internal profile identifier
461     in: path
462     name: import_batch_profile_id
463     required: true
464     type: integer
465   import_record_id_pp:
466     description: Internal import record identifier
467     in: path
468     name: import_record_id
469     required: true
470     type: integer
471   item_id_pp:
472     description: Internal item identifier
473     in: path
474     name: item_id
475     required: true
476     type: integer
477   job_id_pp:
478     description: Job internal identifier
479     in: path
480     name: job_id
481     required: true
482     type: integer
483   library_id_pp:
484     description: Internal library identifier
485     in: path
486     name: library_id
487     required: true
488     type: string
489   license_id_pp:
490     description: License internal identifier
491     in: path
492     name: license_id
493     required: true
494     type: integer
495   match:
496     description: Matching criteria
497     enum:
498       - contains
499       - exact
500       - starts_with
501       - ends_with
502     in: query
503     name: _match
504     required: false
505     type: string
506   order_by:
507     collectionFormat: csv
508     description: Sorting criteria
509     in: query
510     items:
511       type: string
512     name: _order_by
513     required: false
514     type: array
515   order_id_pp:
516     description: Internal order identifier
517     in: path
518     name: order_id
519     required: true
520     type: integer
521   page:
522     description: "Page number, for paginated object listing"
523     in: query
524     name: _page
525     required: false
526     type: integer
527   patron_id_pp:
528     description: Internal patron identifier
529     in: path
530     name: patron_id
531     required: true
532     type: integer
533   patron_id_qp:
534     description: Internal patron identifier
535     in: query
536     name: patron_id
537     type: integer
538   per_page:
539     description: "Page size, for paginated object listing"
540     in: query
541     name: _per_page
542     required: false
543     type: integer
544   q_body:
545     description: Query filter sent through request"s body
546     in: body
547     name: query
548     required: false
549     schema:
550       type: object
551   q_header:
552     description: Query filter sent as a request header
553     in: header
554     name: x-koha-query
555     required: false
556     type: string
557   q_param:
558     description: Query filter sent as a request parameter
559     in: query
560     name: q
561     required: false
562     type: array
563     items:
564       type: string
565     collectionFormat: multi
566   quote_id_pp:
567     description: Quote internal identifier
568     in: path
569     name: quote_id
570     required: true
571     type: integer
572   request_id_header:
573     description: Request id header
574     in: header
575     name: x-koha-request-id
576     required: false
577     type: integer
578   search_filter_id_pp:
579     name: search_filter_id
580     in: path
581     description: Search filter internal identifier
582     required: true
583     type: integer
584   seen_pp:
585     description: Item was seen flag
586     in: query
587     name: seen
588     required: false
589     type: integer
590   smtp_server_id_pp:
591     description: SMTP server internal identifier
592     in: path
593     name: smtp_server_id
594     required: true
595     type: integer
596   suggestion_id_pp:
597     description: Internal suggestion identifier
598     in: path
599     name: suggestion_id
600     required: true
601     type: integer
602   ticket_id_pp:
603     description: Internal ticket identifier
604     in: path
605     name: ticket_id
606     required: true
607     type: integer
608   transfer_limit_id_pp:
609     description: Internal transfer limit identifier
610     in: path
611     name: limit_id
612     required: true
613     type: string
614   vendor_id_pp:
615     description: Vendor id
616     in: path
617     name: vendor_id
618     required: true
619     type: integer
620 info:
621   title: Koha REST API
622   version: "1"
623   license:
624     name: "GPL v3,"
625     url: http://www.gnu.org/licenses/gpl.txt
626   contact:
627     name: Koha Development Team
628     url: https://koha-community.org/
629   description: |
630     ## Introduction
631
632     This API is documented in **OpenAPI format**.
633
634     ## Authentication
635
636     The API supports the following authentication mechanisms
637
638     * HTTP Basic authentication
639     * OAuth2 (client credentials grant)
640     * Cookie-based
641
642     Both _Basic authentication_ and the _OAuth2_ flow, need to be enabled
643     by system preferences.
644
645     ## Errors
646
647     The API uses standard HTTP status codes to indicate the success or failure
648     of the API call. The body of the response will be JSON in the following format:
649
650     ```
651     {
652       "error": "Current settings prevent the passed due date to be applied",
653       "error_code": "invalid_due_date"
654     }
655     ```
656
657     Note: Some routes might offer additional attributes in their error responses but that"s
658     subject to change and thus not documented.
659
660     ## Filtering responses
661
662     The API allows for some advanced response filtering using a JSON based query syntax. The
663     query can be added to the requests:
664
665     * as a query parameter `q=`
666     * in the request body
667     * in a special header `x-koha-query`
668
669     For simple field equality matches we can use `{ "fieldname": "value" }` where the fieldname
670     matches one of the fields as described in the particular endpoints response object.
671
672     We can refine that with more complex matching clauses by nesting a the clause into the
673     object; `{ "fieldname": { "clause": "value" } }`.
674
675     Available matching clauses include ">", "<", ">=", "<=", "-like", and "-not_like".
676
677     We can filter on multiple fields by adding them to the JSON respresentation. Adding at `HASH`
678     level will result in an "AND" query, whilst combinding them in an `ARRAY` wilth result in an
679     "OR" query: `{ "field1": "value2", "field2": "value2" }` will filter the response to only those
680     results with both field1 containing value2 AND field2 containing value2 for example.
681
682     Additionally, if you are requesting related data be embedded into the response one can query
683     on the related data using dot notation in the field names.
684
685     ### Examples
686
687     The following request would return any patron with firstname "Henry" and lastname "Acevedo";
688
689     `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": "Acevedo", "firstname": "Henry" }"`
690
691     The following request would return any patron whose lastname begins with "Ace";
692
693     `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": { "-like": "Ace%" }"`
694
695     The following request would return any patron whose lastname is "Acevedo" OR "Bernardo"
696
697     `curl -u koha:koha --request GET "http://127.0.0.1:8081/api/v1/patrons/" --data-raw "{ "surname": [ "Acevedo", "Bernardo" ] }"`
698
699     The following request embeds the related patron extended attributes data and filters on it.
700
701     `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" }'`
702
703     ## Special headers
704
705     ### x-koha-embed
706
707     This optional header allows the api consumer to request additional related data
708     to be returned in the api response.  It also allows for cross referencing in the
709     queries as described above. It accepts a comma delimited list of relation names.
710
711     Relations may on occasion also support dot delimited nesting to allow traversal.
712
713     ### x-koha-library
714
715     This optional header should be passed to give your api request a library
716     context; If it is not included in the request, then the request context
717     will default to using your api comsumer"s assigned home library.
718 tags:
719   - description: "Handle two factor authentication flows\n"
720     name: 2fa
721     x-displayName: Two factor authentication
722   - description: "Manage article requests\n"
723     name: article_requests
724     x-displayName: Article requests
725   - description: "Manage identity providers\n"
726     name: identity_providers
727     x-displayName: Identity providers
728   - description: "Manage baskets for the acquisitions module\n"
729     name: baskets
730     x-displayName: Baskets
731   - description: "Manage bibliographic records\n"
732     name: biblios
733     x-displayName: Biblios
734   - description: "Manage cash register cashups\n"
735     name: cashups
736     x-displayName: Cashups
737   - description: "Manage checkouts\n"
738     name: checkouts
739     x-displayName: Checkouts
740   - description: "Manage circulation rules\n"
741     name: circulation_rules
742     x-displayName: Circulation rules
743   - description: "Manage cities\n"
744     name: cities
745     x-displayName: Cities
746   - description: "Manage patron clubs\n"
747     name: clubs
748     x-displayName: Clubs
749   - description: "Manage funds for the acquisitions module\n"
750     name: funds
751     x-displayName: Funds
752   - description: "Manage holds\n"
753     name: holds
754     x-displayName: Holds
755   - description: "Manage ILL module backends\n"
756     name: illbackends
757     x-displayName: ILL backends
758   - description: "Manage ILL requests\n"
759     name: illrequests
760     x-displayName: ILL requests
761   - description: "Manage import batches\n"
762     name: import_batches
763     x-display-name: Import batches
764   - description: "Manage item groups\n"
765     name: item_groups
766     x-displayName: Item groups
767   - description: "Manage items\n"
768     name: items
769     x-displayName: Items
770   - description: "Manage jobs\n"
771     name: jobs
772     x-displayName: Jobs
773   - description: "Manage libraries\n"
774     name: libraries
775     x-displayName: Libraries
776   - description: "Manage macros\n"
777     name: macros
778     x-displayName: Macros
779   - description: "Manage acquisition orders\n"
780     name: orders
781     x-displayName: Orders
782   - description: "Handle OAuth flows\n"
783     name: oauth
784     x-displayName: OAuth
785   - description: "Manage patrons\n"
786     name: patrons
787     x-displayName: Patrons
788   - description: "Manage quotes\n"
789     name: quotes
790     x-displayName: Quotes
791   - description: "Manage return claims\n"
792     name: return_claims
793     x-displayName: Return claims
794   - description: "Manage rotas\n"
795     name: rotas
796     x-displayName: Rotas
797   - description: "Manage SMTP servers configurations\n"
798     name: smtp_servers
799     x-displayName: SMTP servers
800   - description: "Manage transfer limits\n"
801     name: transfer
802     x-displayName: Transfer limits
803   - description: "Manage purchase suggestions\n"
804     name: suggestions
805     x-displayName: Purchase suggestions
806   - description: "Manage vendors for the acquisitions module\n"
807     name: vendors
808     x-displayName: Vendors
809   - description: "Manage batch import profiles\n"
810     name: batch_import_profiles
811     x-displayName: Batch import profiles