Koha/api/v1/swagger/paths/illrequests.yaml
Tomas Cohen Arazi b7b6a85de5 Bug 28020: (follow-up) Add docs about error_code on the API
This patch intends to be a guide for inserting Markdown documentation
for error codes. The idea is that it can be copied and pasted as-is in
new routes. And adapted to new error codes.

To test:
1. Apply this patch
2. Run:
   $ npx redoc-cli@0.10.4 bundle --cdn --output index.html \
            api/v1/swagger/swagger.yaml
=> SUCCESS: It builds correctly
3. Open index.tml on your browser
4. Pick a route, and see the 500 status description includes information
   about the possible `error_code` values.
5. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2022-01-05 13:33:46 -10:00

131 lines
3.5 KiB
YAML

---
/illrequests:
get:
x-mojo-to: Illrequests#list
operationId: listIllrequests
tags:
- illrequests
summary: List ILL requests
parameters:
- name: embed
in: query
description: Additional objects that should be embedded in the response
required: false
type: array
collectionFormat: csv
items:
type: string
enum:
- patron
- library
- capabilities
- metadata
- requested_partners
- comments
- status_alias
- name: backend
in: query
description: The name of a ILL backend
required: false
type: string
- name: orderid
in: query
description: The order ID of a request
required: false
type: string
- name: biblionumber
in: query
description: Internal biblio identifier
required: false
type: integer
- name: borrowernumber
in: query
description: Internal patron identifier
required: false
type: integer
- name: completed
in: query
description: The date the request was considered completed
required: false
type: string
- name: completed_formatted
in: query
description: The date the request was considered complete formatted
required: false
type: string
- name: status
in: query
description: A full status string e.g. REQREV
required: false
type: string
- name: cost
in: query
description: The quoted cost of the request
required: false
type: number
- name: price_paid
in: query
description: The final cost of the request
required: false
type: number
- name: medium
in: query
description: The medium of the requested item
required: false
type: string
- name: updated
in: query
description: The last updated date of the request
required: false
type: string
- name: updated_formatted
in: query
description: The last updated date of the request formatted
required: false
type: string
- name: placed
in: query
description: The date the request was placed
required: false
type: string
- name: placed_formatted
in: query
description: The date the request was placed formatted
required: false
type: string
- name: branchcode
in: query
description: Library ID
required: false
type: string
produces:
- application/json
responses:
"200":
description: A list of ILL requests
"401":
description: Authentication required
schema:
$ref: ../definitions.yaml#/error
"403":
description: Access forbidden
schema:
$ref: ../definitions.yaml#/error
"404":
description: ILL requests not found
schema:
$ref: ../definitions.yaml#/error
"500":
description: |
Internal server error. Possible `error_code` attribute values:
* `internal_server_error`
schema:
$ref: ../definitions.yaml#/error
"503":
description: Under maintenance
schema:
$ref: ../definitions.yaml#/error
x-koha-authorization:
permissions:
ill: "1"