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
426 collectionFormat: csv
427 - $ref: "../swagger.yaml#/parameters/match"
428 - $ref: "../swagger.yaml#/parameters/order_by"
429 - $ref: "../swagger.yaml#/parameters/page"
430 - $ref: "../swagger.yaml#/parameters/per_page"
431 - $ref: "../swagger.yaml#/parameters/q_param"
432 - $ref: "../swagger.yaml#/parameters/q_body"
433 - $ref: "../swagger.yaml#/parameters/request_id_header"
436 description: Limit to items that are bookable
445 description: A list of the items attached to the record
449 $ref: "../swagger.yaml#/definitions/item"
451 description: Authentication required
453 $ref: "../swagger.yaml#/definitions/error"
455 description: Access forbidden
457 $ref: "../swagger.yaml#/definitions/error"
459 description: Biblio not found
461 $ref: "../swagger.yaml#/definitions/error"
463 description: Not acceptable
466 description: Accepted content-types
471 Internal server error. Possible `error_code` attribute values:
473 * `internal_server_error`
475 $ref: "../swagger.yaml#/definitions/error"
477 description: Under maintenance
479 $ref: "../swagger.yaml#/definitions/error"
480 x-koha-authorization:
484 x-mojo-to: Biblios#add_item
485 operationId: addBiblioItem
488 summary: Add an item for a biblio
490 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
493 description: A JSON object containing information about the new item
496 $ref: "../swagger.yaml#/definitions/item"
501 description: Item added
503 $ref: "../swagger.yaml#/definitions/item"
505 description: Bad request
507 $ref: "../swagger.yaml#/definitions/error"
509 description: Authentication required
511 $ref: "../swagger.yaml#/definitions/error"
513 description: Access forbidden
515 $ref: "../swagger.yaml#/definitions/error"
517 description: Not found
519 $ref: "../swagger.yaml#/definitions/error"
521 description: Conflict
523 $ref: "../swagger.yaml#/definitions/error"
526 Internal server error. Possible `error_code` attribute values:
528 * `internal_server_error`
530 $ref: "../swagger.yaml#/definitions/error"
532 description: Under maintenance
534 $ref: "../swagger.yaml#/definitions/error"
535 x-koha-authorization:
537 editcatalogue: edit_catalogue
538 "/biblios/{biblio_id}/items/{item_id}":
540 x-mojo-to: Biblios#update_item
541 operationId: updateBiblioItem
544 summary: Update an item for a biblio
546 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
547 - $ref: "../swagger.yaml#/parameters/item_id_pp"
550 description: A JSON object containing information about the item
553 $ref: "../swagger.yaml#/definitions/item"
558 description: Item updated
560 $ref: "../swagger.yaml#/definitions/item"
562 description: Bad request
564 $ref: "../swagger.yaml#/definitions/error"
566 description: Authentication required
568 $ref: "../swagger.yaml#/definitions/error"
570 description: Access forbidden
572 $ref: "../swagger.yaml#/definitions/error"
574 description: Not found
576 $ref: "../swagger.yaml#/definitions/error"
578 description: Conflict
580 $ref: "../swagger.yaml#/definitions/error"
583 Internal server error. Possible `error_code` attribute values:
585 * `internal_server_error`
587 $ref: "../swagger.yaml#/definitions/error"
589 description: Under maintenance
591 $ref: "../swagger.yaml#/definitions/error"
592 x-koha-authorization:
594 editcatalogue: edit_catalogue
595 "/biblios/{biblio_id}/pickup_locations":
597 x-mojo-to: Biblios#pickup_locations
598 operationId: getBiblioPickupLocations
601 summary: Get valid pickup locations for a biblio
603 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
606 description: Internal patron identifier
609 - $ref: "../swagger.yaml#/parameters/match"
610 - $ref: "../swagger.yaml#/parameters/order_by"
611 - $ref: "../swagger.yaml#/parameters/page"
612 - $ref: "../swagger.yaml#/parameters/per_page"
613 - $ref: "../swagger.yaml#/parameters/q_param"
614 - $ref: "../swagger.yaml#/parameters/q_body"
621 description: Biblio pickup locations
625 $ref: "../swagger.yaml#/definitions/library"
627 description: Missing or wrong parameters
629 $ref: "../swagger.yaml#/definitions/error"
631 description: Authentication required
633 $ref: "../swagger.yaml#/definitions/error"
635 description: Access forbidden
637 $ref: "../swagger.yaml#/definitions/error"
639 description: Biblio not found
641 $ref: "../swagger.yaml#/definitions/error"
644 Internal server error. Possible `error_code` attribute values:
646 * `internal_server_error`
648 $ref: "../swagger.yaml#/definitions/error"
650 description: Under maintenance
652 $ref: "../swagger.yaml#/definitions/error"
653 x-koha-authorization:
655 reserveforothers: place_holds
656 "/public/biblios/{biblio_id}":
658 x-mojo-to: Biblios#get_public
659 operationId: getBiblioPublic
662 summary: Get biblio (public)
664 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
666 - application/marcxml+xml
667 - application/marc-in-json
672 description: A biblio
674 description: Authentication required
676 $ref: "../swagger.yaml#/definitions/error"
678 description: Access forbidden
680 $ref: "../swagger.yaml#/definitions/error"
682 description: Biblio not found
684 $ref: "../swagger.yaml#/definitions/error"
686 description: Not acceptable
689 description: Accepted content-types
694 Internal server error. Possible `error_code` attribute values:
696 * `internal_server_error`
698 $ref: "../swagger.yaml#/definitions/error"
700 description: Under maintenance
702 $ref: "../swagger.yaml#/definitions/error"
703 "/public/biblios/{biblio_id}/items":
705 x-mojo-to: Biblios#get_items_public
706 operationId: getBiblioItemsPublic
711 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
712 - $ref: "../swagger.yaml#/parameters/match"
713 - $ref: "../swagger.yaml#/parameters/order_by"
714 - $ref: "../swagger.yaml#/parameters/page"
715 - $ref: "../swagger.yaml#/parameters/per_page"
716 - $ref: "../swagger.yaml#/parameters/q_param"
717 - $ref: "../swagger.yaml#/parameters/q_body"
721 description: Embed list sent as a request header
727 collectionFormat: csv
734 description: A list of the items attached to the record
738 $ref: "../swagger.yaml#/definitions/item"
740 description: Authentication required
742 $ref: "../swagger.yaml#/definitions/error"
744 description: Access forbidden
746 $ref: "../swagger.yaml#/definitions/error"
748 description: Biblio not found
750 $ref: "../swagger.yaml#/definitions/error"
752 description: Not acceptable
755 description: Accepted content-types
760 Internal server error. Possible `error_code` attribute values:
762 * `internal_server_error`
764 $ref: "../swagger.yaml#/definitions/error"
766 description: Under maintenance
768 $ref: "../swagger.yaml#/definitions/error"
769 "/public/biblios/{biblio_id}/ratings":
771 x-mojo-to: Biblios#set_rating
772 operationId: setBiblioRating
775 summary: set biblio rating (public)
777 - $ref: "../swagger.yaml#/parameters/biblio_id_pp"
780 description: A JSON object containing rating information
785 description: the rating
791 additionalProperties: false
796 description: Rating set
801 description: user's rating
806 description: average rating
809 description: number of ratings
811 additionalProperties: false
813 description: Authentication required
815 $ref: "../swagger.yaml#/definitions/error"
817 description: Access forbidden
819 $ref: "../swagger.yaml#/definitions/error"
821 description: Biblio not found
823 $ref: "../swagger.yaml#/definitions/error"
826 Internal server error. Possible `error_code` attribute values:
828 * `internal_server_error`
830 $ref: "../swagger.yaml#/definitions/error"
832 description: Under maintenance
834 $ref: "../swagger.yaml#/definitions/error"