10 Add a bibliographic record to Koha. An optional `x-framework-id`
11 may be passed to specify the cataloguing framework to be used (instead
14 The request body is expected to contain a MARC record in the format specified in
15 the `Content-type` header you pass. Possible values for this header and the corresponding
16 record formats expected are listed below:
18 * application/marcxml+xml: MARCXML
19 * application/marc-in-json: MARC-in-JSON
20 * application/marc: Raw USMARC binary data
22 - $ref: "../swagger.yaml#/parameters/framework_id_header"
23 - $ref: "../swagger.yaml#/parameters/marc_schema_header"
24 - $ref: "../swagger.yaml#/parameters/confirm_not_duplicate_header"
31 description: Bad request
33 $ref: "../swagger.yaml#/definitions/error"
35 description: Authentication required
37 $ref: "../swagger.yaml#/definitions/error"
39 description: Access forbidden
41 $ref: "../swagger.yaml#/definitions/error"
43 description: Not acceptable
46 description: Accepted content-types
51 Internal server error. Possible `error_code` attribute values:
53 * `internal_server_error`
55 $ref: "../swagger.yaml#/definitions/error"
57 description: Under maintenance
59 $ref: "../swagger.yaml#/definitions/error"
62 editcatalogue: edit_catalogue
64 x-mojo-to: Biblios#list
65 operationId: listBiblio
70 - $ref: "../swagger.yaml#/parameters/page"
71 - $ref: "../swagger.yaml#/parameters/per_page"
72 - $ref: "../swagger.yaml#/parameters/match"
73 - $ref: "../swagger.yaml#/parameters/order_by"
74 - $ref: "../swagger.yaml#/parameters/q_param"
75 - $ref: "../swagger.yaml#/parameters/q_body"
76 - $ref: "../swagger.yaml#/parameters/request_id_header"
79 - application/marcxml+xml
80 - application/marc-in-json
85 description: A list of biblios
87 description: Authentication required
89 $ref: "../swagger.yaml#/definitions/error"
91 description: Access forbidden
93 $ref: "../swagger.yaml#/definitions/error"
95 description: Biblio not found
97 $ref: "../swagger.yaml#/definitions/error"
99 description: Not acceptable
102 description: Accepted content-types
107 Internal server error. Possible `error_code` attribute values:
109 * `internal_server_error`
111 $ref: "../swagger.yaml#/definitions/error"
113 description: Under maintenance
115 $ref: "../swagger.yaml#/definitions/error"
116 x-koha-authorization:
119 "/biblios/{biblio_id}":
121 x-mojo-to: Biblios#get
122 operationId: getBiblio
127 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
130 - application/marcxml+xml
131 - application/marc-in-json
136 description: A biblio
138 description: Authentication required
140 $ref: "../swagger.yaml#/definitions/error"
142 description: Access forbidden
144 $ref: "../swagger.yaml#/definitions/error"
146 description: Biblio not found
148 $ref: "../swagger.yaml#/definitions/error"
150 description: Not acceptable
153 description: Accepted content-types
158 Internal server error. Possible `error_code` attribute values:
160 * `internal_server_error`
162 $ref: "../swagger.yaml#/definitions/error"
164 description: Under maintenance
166 $ref: "../swagger.yaml#/definitions/error"
167 x-koha-authorization:
171 x-mojo-to: Biblios#delete
172 operationId: deleteBiblio
175 summary: Delete biblio
177 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
182 description: Biblio deleted
186 description: Authentication required
188 $ref: "../swagger.yaml#/definitions/error"
190 description: Access forbidden
192 $ref: "../swagger.yaml#/definitions/error"
194 description: Biblio not found
196 $ref: "../swagger.yaml#/definitions/error"
198 description: Unable to perform action on biblio
200 $ref: "../swagger.yaml#/definitions/error"
202 description: Internal error
204 $ref: "../swagger.yaml#/definitions/error"
206 description: Under maintenance
208 $ref: "../swagger.yaml#/definitions/error"
209 x-koha-authorization:
211 editcatalogue: edit_catalogue
213 x-mojo-to: Biblios#update
214 operationId: updateBiblio
217 summary: Update biblio
219 Updates a bibliographic record to Koha. An optional `x-framework-id`
220 may be passed, to specify the cataloguing framework to be used (instead
223 The request body is expected to contain a MARC record in the format specified by
224 the `Content-type` header passed. Possible values for this headers and the corresponding
225 record formats expected are listed below:
227 * application/marcxml+xml: MARCXML
228 * application/marc-in-json: MARC-in-JSON
229 * application/marc: Raw USMARC binary data
231 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
232 - $ref: "../swagger.yaml#/parameters/framework_id_header"
233 - $ref: "../swagger.yaml#/parameters/marc_schema_header"
234 - $ref: "../swagger.yaml#/parameters/confirm_not_duplicate_header"
239 description: A biblio
241 description: Bad request
243 $ref: "../swagger.yaml#/definitions/error"
245 description: Authentication required
247 $ref: "../swagger.yaml#/definitions/error"
249 description: Access forbidden
251 $ref: "../swagger.yaml#/definitions/error"
253 description: Biblio not found
255 $ref: "../swagger.yaml#/definitions/error"
257 description: Not acceptable
260 description: Accepted content-types
265 Internal server error. Possible `error_code` attribute values:
267 * `internal_server_error`
269 $ref: "../swagger.yaml#/definitions/error"
271 description: Under maintenance
273 $ref: "../swagger.yaml#/definitions/error"
274 x-koha-authorization:
276 editcatalogue: edit_catalogue
277 "/biblios/{biblio_id}/bookings":
279 x-mojo-to: Biblios#get_bookings
280 operationId: getBiblioBookings
283 summary: Get bookings for a biblio
285 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
286 - $ref: "../swagger.yaml#/parameters/match"
287 - $ref: "../swagger.yaml#/parameters/order_by"
288 - $ref: "../swagger.yaml#/parameters/page"
289 - $ref: "../swagger.yaml#/parameters/per_page"
290 - $ref: "../swagger.yaml#/parameters/q_param"
291 - $ref: "../swagger.yaml#/parameters/q_body"
295 description: Embed list sent as a request header
302 collectionFormat: csv
309 description: A list of the bookings attached to the record
313 $ref: ../swagger.yaml#/definitions/booking
315 description: Authentication required
317 $ref: ../swagger.yaml#/definitions/error
319 description: Access forbidden
321 $ref: ../swagger.yaml#/definitions/error
323 description: Biblio not found
325 $ref: ../swagger.yaml#/definitions/error
327 description: Not acceptable
330 description: Accepted content-types
334 description: Internal server error
336 $ref: ../swagger.yaml#/definitions/error
338 description: Under maintenance
340 $ref: ../swagger.yaml#/definitions/error
341 x-koha-authorization:
343 circulate: "manage_bookings"
344 "/biblios/{biblio_id}/checkouts":
346 x-mojo-to: Biblios#get_checkouts
347 operationId: listBiblioCheckouts
350 summary: List checkouts for a biblio
352 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
353 - $ref: "../swagger.yaml#/parameters/page"
354 - $ref: "../swagger.yaml#/parameters/per_page"
355 - $ref: "../swagger.yaml#/parameters/match"
356 - $ref: "../swagger.yaml#/parameters/order_by"
357 - $ref: "../swagger.yaml#/parameters/q_param"
358 - $ref: "../swagger.yaml#/parameters/q_body"
359 - $ref: "../swagger.yaml#/parameters/request_id_header"
363 description: Embed list sent as a request header
372 collectionFormat: csv
375 description: By default, current checkouts are returned, when this is true then
376 checked in checkouts are returned as result.
382 description: A list of checkouts
384 $ref: "../swagger.yaml#/definitions/checkouts"
386 description: Access forbidden
388 $ref: "../swagger.yaml#/definitions/error"
390 description: Biblio not found
392 $ref: "../swagger.yaml#/definitions/error"
395 Internal server error. Possible `error_code` attribute values:
397 * `internal_server_error`
399 $ref: "../swagger.yaml#/definitions/error"
401 description: Under maintenance
403 $ref: "../swagger.yaml#/definitions/error"
404 x-koha-authorization:
406 - circulate: circulate_remaining_permissions
407 - circulate: manage_bookings
408 "/biblios/{biblio_id}/items":
410 x-mojo-to: Biblios#get_items
411 operationId: getBiblioItems
414 summary: Get items for a biblio
416 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
420 description: Embed list sent as a request header
427 collectionFormat: csv
428 - $ref: "../swagger.yaml#/parameters/match"
429 - $ref: "../swagger.yaml#/parameters/order_by"
430 - $ref: "../swagger.yaml#/parameters/page"
431 - $ref: "../swagger.yaml#/parameters/per_page"
432 - $ref: "../swagger.yaml#/parameters/q_param"
433 - $ref: "../swagger.yaml#/parameters/q_body"
434 - $ref: "../swagger.yaml#/parameters/request_id_header"
437 description: Limit to items that are bookable
446 description: A list of the items attached to the record
450 $ref: "../swagger.yaml#/definitions/item"
452 description: Authentication required
454 $ref: "../swagger.yaml#/definitions/error"
456 description: Access forbidden
458 $ref: "../swagger.yaml#/definitions/error"
460 description: Biblio not found
462 $ref: "../swagger.yaml#/definitions/error"
464 description: Not acceptable
467 description: Accepted content-types
472 Internal server error. Possible `error_code` attribute values:
474 * `internal_server_error`
476 $ref: "../swagger.yaml#/definitions/error"
478 description: Under maintenance
480 $ref: "../swagger.yaml#/definitions/error"
481 x-koha-authorization:
485 x-mojo-to: Biblios#add_item
486 operationId: addBiblioItem
489 summary: Add an item for a biblio
491 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
494 description: A JSON object containing information about the new item
497 $ref: "../swagger.yaml#/definitions/item"
502 description: Item added
504 $ref: "../swagger.yaml#/definitions/item"
506 description: Bad request
508 $ref: "../swagger.yaml#/definitions/error"
510 description: Authentication required
512 $ref: "../swagger.yaml#/definitions/error"
514 description: Access forbidden
516 $ref: "../swagger.yaml#/definitions/error"
518 description: Not found
520 $ref: "../swagger.yaml#/definitions/error"
522 description: Conflict
524 $ref: "../swagger.yaml#/definitions/error"
527 Internal server error. Possible `error_code` attribute values:
529 * `internal_server_error`
531 $ref: "../swagger.yaml#/definitions/error"
533 description: Under maintenance
535 $ref: "../swagger.yaml#/definitions/error"
536 x-koha-authorization:
538 editcatalogue: edit_catalogue
539 "/biblios/{biblio_id}/items/{item_id}":
541 x-mojo-to: Biblios#update_item
542 operationId: updateBiblioItem
545 summary: Update an item for a biblio
547 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
548 - $ref: "../swagger.yaml#/parameters/item_id_pp"
551 description: A JSON object containing information about the item
554 $ref: "../swagger.yaml#/definitions/item"
559 description: Item updated
561 $ref: "../swagger.yaml#/definitions/item"
563 description: Bad request
565 $ref: "../swagger.yaml#/definitions/error"
567 description: Authentication required
569 $ref: "../swagger.yaml#/definitions/error"
571 description: Access forbidden
573 $ref: "../swagger.yaml#/definitions/error"
575 description: Not found
577 $ref: "../swagger.yaml#/definitions/error"
579 description: Conflict
581 $ref: "../swagger.yaml#/definitions/error"
584 Internal server error. Possible `error_code` attribute values:
586 * `internal_server_error`
588 $ref: "../swagger.yaml#/definitions/error"
590 description: Under maintenance
592 $ref: "../swagger.yaml#/definitions/error"
593 x-koha-authorization:
595 editcatalogue: edit_catalogue
596 "/biblios/{biblio_id}/pickup_locations":
598 x-mojo-to: Biblios#pickup_locations
599 operationId: getBiblioPickupLocations
602 summary: Get valid pickup locations for a biblio
604 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
607 description: Internal patron identifier
610 - $ref: "../swagger.yaml#/parameters/match"
611 - $ref: "../swagger.yaml#/parameters/order_by"
612 - $ref: "../swagger.yaml#/parameters/page"
613 - $ref: "../swagger.yaml#/parameters/per_page"
614 - $ref: "../swagger.yaml#/parameters/q_param"
615 - $ref: "../swagger.yaml#/parameters/q_body"
622 description: Biblio pickup locations
626 $ref: "../swagger.yaml#/definitions/library"
628 description: Missing or wrong parameters
630 $ref: "../swagger.yaml#/definitions/error"
632 description: Authentication required
634 $ref: "../swagger.yaml#/definitions/error"
636 description: Access forbidden
638 $ref: "../swagger.yaml#/definitions/error"
640 description: Biblio not found
642 $ref: "../swagger.yaml#/definitions/error"
645 Internal server error. Possible `error_code` attribute values:
647 * `internal_server_error`
649 $ref: "../swagger.yaml#/definitions/error"
651 description: Under maintenance
653 $ref: "../swagger.yaml#/definitions/error"
654 x-koha-authorization:
656 reserveforothers: place_holds
657 "/public/biblios/{biblio_id}":
659 x-mojo-to: Biblios#get_public
660 operationId: getBiblioPublic
663 summary: Get biblio (public)
665 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
667 - application/marcxml+xml
668 - application/marc-in-json
673 description: A biblio
675 description: Authentication required
677 $ref: "../swagger.yaml#/definitions/error"
679 description: Access forbidden
681 $ref: "../swagger.yaml#/definitions/error"
683 description: Biblio not found
685 $ref: "../swagger.yaml#/definitions/error"
687 description: Not acceptable
690 description: Accepted content-types
695 Internal server error. Possible `error_code` attribute values:
697 * `internal_server_error`
699 $ref: "../swagger.yaml#/definitions/error"
701 description: Under maintenance
703 $ref: "../swagger.yaml#/definitions/error"
704 "/public/biblios/{biblio_id}/items":
706 x-mojo-to: Biblios#get_items_public
707 operationId: getBiblioItemsPublic
712 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
713 - $ref: "../swagger.yaml#/parameters/match"
714 - $ref: "../swagger.yaml#/parameters/order_by"
715 - $ref: "../swagger.yaml#/parameters/page"
716 - $ref: "../swagger.yaml#/parameters/per_page"
717 - $ref: "../swagger.yaml#/parameters/q_param"
718 - $ref: "../swagger.yaml#/parameters/q_body"
722 description: Embed list sent as a request header
728 collectionFormat: csv
735 description: A list of the items attached to the record
739 $ref: "../swagger.yaml#/definitions/item"
741 description: Authentication required
743 $ref: "../swagger.yaml#/definitions/error"
745 description: Access forbidden
747 $ref: "../swagger.yaml#/definitions/error"
749 description: Biblio not found
751 $ref: "../swagger.yaml#/definitions/error"
753 description: Not acceptable
756 description: Accepted content-types
761 Internal server error. Possible `error_code` attribute values:
763 * `internal_server_error`
765 $ref: "../swagger.yaml#/definitions/error"
767 description: Under maintenance
769 $ref: "../swagger.yaml#/definitions/error"
770 "/public/biblios/{biblio_id}/ratings":
772 x-mojo-to: Biblios#set_rating
773 operationId: setBiblioRating
776 summary: set biblio rating (public)
778 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
781 description: A JSON object containing rating information
786 description: the rating
792 additionalProperties: false
797 description: Rating set
802 description: user's rating
807 description: average rating
810 description: number of ratings
812 additionalProperties: false
814 description: Authentication required
816 $ref: "../swagger.yaml#/definitions/error"
818 description: Access forbidden
820 $ref: "../swagger.yaml#/definitions/error"
822 description: Biblio not found
824 $ref: "../swagger.yaml#/definitions/error"
827 Internal server error. Possible `error_code` attribute values:
829 * `internal_server_error`
831 $ref: "../swagger.yaml#/definitions/error"
833 description: Under maintenance
835 $ref: "../swagger.yaml#/definitions/error"