View | Details | Raw Unified | Return to bug 37018
Collapse All | Expand All

(-)a/Koha/REST/Plugin/Exceptions.pm (-1 / +1 lines)
Lines 61-67 sub register { Link Here
61
61
62
            if ( blessed $exception && ref($exception) eq 'Koha::Exceptions::REST::Query::InvalidOperator' ) {
62
            if ( blessed $exception && ref($exception) eq 'Koha::Exceptions::REST::Query::InvalidOperator' ) {
63
                return $c->render(
63
                return $c->render(
64
                    status => 500,
64
                    status => 400,
65
                    json   => {
65
                    json   => {
66
                        error      => printf( "Invalid operator in query: %s", $exception->operator ),
66
                        error      => printf( "Invalid operator in query: %s", $exception->operator ),
67
                        error_code => 'invalid_query',
67
                        error_code => 'invalid_query',
(-)a/api/v1/swagger/paths/acquisitions_baskets.yaml (+7 lines)
Lines 33-38 Link Here
33
          type: array
33
          type: array
34
          items:
34
          items:
35
            $ref: "../swagger.yaml#/definitions/patron"
35
            $ref: "../swagger.yaml#/definitions/patron"
36
      "400":
37
        description: |
38
          Bad request. Possible `error_code` attribute values:
39
40
            * `invalid_query`
41
        schema:
42
          $ref: "../swagger.yaml#/definitions/error"
36
      "403":
43
      "403":
37
        description: Access forbidden
44
        description: Access forbidden
38
        schema:
45
        schema:
(-)a/api/v1/swagger/paths/acquisitions_funds.yaml (+21 lines)
Lines 33-38 Link Here
33
          type: array
33
          type: array
34
          items:
34
          items:
35
            $ref: "../swagger.yaml#/definitions/fund"
35
            $ref: "../swagger.yaml#/definitions/fund"
36
      "400":
37
        description: |
38
          Bad request. Possible `error_code` attribute values:
39
40
            * `invalid_query`
41
        schema:
42
          $ref: "../swagger.yaml#/definitions/error"
36
      "401":
43
      "401":
37
        description: Authentication required
44
        description: Authentication required
38
        schema:
45
        schema:
Lines 93-98 Link Here
93
          type: array
100
          type: array
94
          items:
101
          items:
95
            $ref: "../swagger.yaml#/definitions/patron"
102
            $ref: "../swagger.yaml#/definitions/patron"
103
      "400":
104
        description: |
105
          Bad request. Possible `error_code` attribute values:
106
107
            * `invalid_query`
108
        schema:
109
          $ref: "../swagger.yaml#/definitions/error"
96
      "403":
110
      "403":
97
        description: Access forbidden
111
        description: Access forbidden
98
        schema:
112
        schema:
Lines 145-150 Link Here
145
          type: array
159
          type: array
146
          items:
160
          items:
147
            $ref: "../swagger.yaml#/definitions/patron"
161
            $ref: "../swagger.yaml#/definitions/patron"
162
      "400":
163
        description: |
164
          Bad request. Possible `error_code` attribute values:
165
166
            * `invalid_query`
167
        schema:
168
          $ref: "../swagger.yaml#/definitions/error"
148
      "403":
169
      "403":
149
        description: Access forbidden
170
        description: Access forbidden
150
        schema:
171
        schema:
(-)a/api/v1/swagger/paths/acquisitions_orders.yaml (+19 lines)
Lines 74-79 Link Here
74
          type: array
74
          type: array
75
          items:
75
          items:
76
            $ref: "../swagger.yaml#/definitions/order"
76
            $ref: "../swagger.yaml#/definitions/order"
77
      "400":
78
        description: |
79
          Bad request. Possible `error_code` attribute values:
80
81
            * `invalid_query`
82
        schema:
83
          $ref: "../swagger.yaml#/definitions/error"
77
      "401":
84
      "401":
78
        description: Authentication required
85
        description: Authentication required
79
        schema:
86
        schema:
Lines 191-196 Link Here
191
        description: An order
198
        description: An order
192
        schema:
199
        schema:
193
          $ref: "../swagger.yaml#/definitions/order"
200
          $ref: "../swagger.yaml#/definitions/order"
201
      "400":
202
        description: Bad request
203
        schema:
204
          $ref: "../swagger.yaml#/definitions/error"
194
      "401":
205
      "401":
195
        description: Authentication required
206
        description: Authentication required
196
        schema:
207
        schema:
Lines 238-243 Link Here
238
        description: An order
249
        description: An order
239
        schema:
250
        schema:
240
          $ref: "../swagger.yaml#/definitions/order"
251
          $ref: "../swagger.yaml#/definitions/order"
252
      "400":
253
        description: Bad request
254
        schema:
255
          $ref: "../swagger.yaml#/definitions/error"
241
      "401":
256
      "401":
242
        description: Authentication required
257
        description: Authentication required
243
        schema:
258
        schema:
Lines 277-282 Link Here
277
    responses:
292
    responses:
278
      "204":
293
      "204":
279
        description: Order deleted
294
        description: Order deleted
295
      "400":
296
        description: Bad request
297
        schema:
298
          $ref: "../swagger.yaml#/definitions/error"
280
      "401":
299
      "401":
281
        description: Authentication required
300
        description: Authentication required
282
        schema:
301
        schema:
(-)a/api/v1/swagger/paths/acquisitions_vendor_issues.yaml (+7 lines)
Lines 64-69 Link Here
64
          type: array
64
          type: array
65
          items:
65
          items:
66
            $ref: "../swagger.yaml#/definitions/vendor_issue"
66
            $ref: "../swagger.yaml#/definitions/vendor_issue"
67
      "400":
68
        description: |
69
          Bad request. Possible `error_code` attribute values:
70
71
            * `invalid_query`
72
        schema:
73
          $ref: "../swagger.yaml#/definitions/error"
67
      "401":
74
      "401":
68
        description: Authentication required
75
        description: Authentication required
69
        schema:
76
        schema:
(-)a/api/v1/swagger/paths/acquisitions_vendors.yaml (+23 lines)
Lines 43-48 Link Here
43
          type: array
43
          type: array
44
          items:
44
          items:
45
            $ref: "../swagger.yaml#/definitions/vendor"
45
            $ref: "../swagger.yaml#/definitions/vendor"
46
      "400":
47
        description: |
48
          Bad request. Possible `error_code` attribute values:
49
50
            * `invalid_query`
51
        schema:
52
          $ref: "../swagger.yaml#/definitions/error"
46
      "401":
53
      "401":
47
        description: Authentication required
54
        description: Authentication required
48
        schema:
55
        schema:
Lines 89-94 Link Here
89
        description: Vendor added
96
        description: Vendor added
90
        schema:
97
        schema:
91
          $ref: "../swagger.yaml#/definitions/vendor"
98
          $ref: "../swagger.yaml#/definitions/vendor"
99
      "400":
100
        description: Bad request
101
        schema:
102
          $ref: "../swagger.yaml#/definitions/error"
92
      "401":
103
      "401":
93
        description: Authentication required
104
        description: Authentication required
94
        schema:
105
        schema:
Lines 131-136 Link Here
131
        description: A vendor
142
        description: A vendor
132
        schema:
143
        schema:
133
          $ref: "../swagger.yaml#/definitions/vendor"
144
          $ref: "../swagger.yaml#/definitions/vendor"
145
      "400":
146
        description: Bad request
147
        schema:
148
          $ref: "../swagger.yaml#/definitions/error"
134
      "401":
149
      "401":
135
        description: Authentication required
150
        description: Authentication required
136
        schema:
151
        schema:
Lines 178-183 Link Here
178
        description: A vendor
193
        description: A vendor
179
        schema:
194
        schema:
180
          $ref: "../swagger.yaml#/definitions/vendor"
195
          $ref: "../swagger.yaml#/definitions/vendor"
196
      "400":
197
        description: Bad request
198
        schema:
199
          $ref: "../swagger.yaml#/definitions/error"
181
      "401":
200
      "401":
182
        description: Authentication required
201
        description: Authentication required
183
        schema:
202
        schema:
Lines 217-222 Link Here
217
    responses:
236
    responses:
218
      "204":
237
      "204":
219
        description: Vendor deleted
238
        description: Vendor deleted
239
      "400":
240
        description: Bad request
241
        schema:
242
          $ref: "../swagger.yaml#/definitions/error"
220
      "401":
243
      "401":
221
        description: Authentication required
244
        description: Authentication required
222
        schema:
245
        schema:
(-)a/api/v1/swagger/paths/advancededitormacros.yaml (+39 lines)
Lines 43-48 Link Here
43
          type: array
43
          type: array
44
          items:
44
          items:
45
            $ref: "../swagger.yaml#/definitions/advancededitormacro"
45
            $ref: "../swagger.yaml#/definitions/advancededitormacro"
46
      "400":
47
        description: |
48
          Bad request. Possible `error_code` attribute values:
49
50
            * `invalid_query`
51
        schema:
52
          $ref: "../swagger.yaml#/definitions/error"
46
      "403":
53
      "403":
47
        description: Access forbidden
54
        description: Access forbidden
48
        schema:
55
        schema:
Lines 81-86 Link Here
81
        description: Macro added
88
        description: Macro added
82
        schema:
89
        schema:
83
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
90
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
91
      "400":
92
        description: Bad request
93
        schema:
94
          $ref: "../swagger.yaml#/definitions/error"
84
      "401":
95
      "401":
85
        description: Authentication required
96
        description: Authentication required
86
        schema:
97
        schema:
Lines 121-126 Link Here
121
        description: Macro added
132
        description: Macro added
122
        schema:
133
        schema:
123
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
134
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
135
      "400":
136
        description: Bad request
137
        schema:
138
          $ref: "../swagger.yaml#/definitions/error"
124
      "401":
139
      "401":
125
        description: Authentication required
140
        description: Authentication required
126
        schema:
141
        schema:
Lines 158-163 Link Here
158
        description: A macro
173
        description: A macro
159
        schema:
174
        schema:
160
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
175
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
176
      "400":
177
        description: Bad request
178
        schema:
179
          $ref: "../swagger.yaml#/definitions/error"
161
      "403":
180
      "403":
162
        description: Access forbidden
181
        description: Access forbidden
163
        schema:
182
        schema:
Lines 198-203 Link Here
198
        description: An advanced editor macro
217
        description: An advanced editor macro
199
        schema:
218
        schema:
200
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
219
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
220
      "400":
221
        description: Bad request
222
        schema:
223
          $ref: "../swagger.yaml#/definitions/error"
201
      "401":
224
      "401":
202
        description: Authentication required
225
        description: Authentication required
203
        schema:
226
        schema:
Lines 236-241 Link Here
236
        description: Advanced editor macro deleted
259
        description: Advanced editor macro deleted
237
        schema:
260
        schema:
238
          type: string
261
          type: string
262
      "400":
263
        description: Bad request
264
        schema:
265
          $ref: "../swagger.yaml#/definitions/error"
239
      "401":
266
      "401":
240
        description: Authentication required
267
        description: Authentication required
241
        schema:
268
        schema:
Lines 275-280 Link Here
275
        description: A macro
302
        description: A macro
276
        schema:
303
        schema:
277
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
304
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
305
      "400":
306
        description: Bad request
307
        schema:
308
          $ref: "../swagger.yaml#/definitions/error"
278
      "403":
309
      "403":
279
        description: Access forbidden
310
        description: Access forbidden
280
        schema:
311
        schema:
Lines 315-320 Link Here
315
        description: An advanced editor macro
346
        description: An advanced editor macro
316
        schema:
347
        schema:
317
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
348
          $ref: "../swagger.yaml#/definitions/advancededitormacro"
349
      "400":
350
        description: Bad request
351
        schema:
352
          $ref: "../swagger.yaml#/definitions/error"
318
      "401":
353
      "401":
319
        description: Authentication required
354
        description: Authentication required
320
        schema:
355
        schema:
Lines 355-360 Link Here
355
        description: Advanced editor macro deleted
390
        description: Advanced editor macro deleted
356
        schema:
391
        schema:
357
          type: string
392
          type: string
393
      "400":
394
        description: Bad request
395
        schema:
396
          $ref: "../swagger.yaml#/definitions/error"
358
      "401":
397
      "401":
359
        description: Authentication required
398
        description: Authentication required
360
        schema:
399
        schema:
(-)a/api/v1/swagger/paths/auth.yaml (-15 / +67 lines)
Lines 22-28 Link Here
22
              type: integer
22
              type: integer
23
          additionalProperties: false
23
          additionalProperties: false
24
      "400":
24
      "400":
25
        description: Bad Request
25
        description: Bad request
26
        schema:
26
        schema:
27
          $ref: "../swagger.yaml#/definitions/error"
27
          $ref: "../swagger.yaml#/definitions/error"
28
      "403":
28
      "403":
Lines 65-71 Link Here
65
              type: string
65
              type: string
66
          additionalProperties: false
66
          additionalProperties: false
67
      "400":
67
      "400":
68
        description: Bad Request
68
        description: Bad request
69
        schema:
69
        schema:
70
          $ref: "../swagger.yaml#/definitions/error"
70
          $ref: "../swagger.yaml#/definitions/error"
71
      "403":
71
      "403":
Lines 111-117 Link Here
111
        schema:
111
        schema:
112
          $ref: "../swagger.yaml#/definitions/error"
112
          $ref: "../swagger.yaml#/definitions/error"
113
      "400":
113
      "400":
114
        description: Bad Request
114
        description: Bad request
115
        schema:
115
        schema:
116
          $ref: "../swagger.yaml#/definitions/error"
116
          $ref: "../swagger.yaml#/definitions/error"
117
      "403":
117
      "403":
Lines 163-171 Link Here
163
          items:
163
          items:
164
            $ref: ../swagger.yaml#/definitions/auth_provider
164
            $ref: ../swagger.yaml#/definitions/auth_provider
165
      "400":
165
      "400":
166
        description: Bad Request
166
        description: |
167
          Bad request. Possible `error_code` attribute values:
168
169
            * `invalid_query`
167
        schema:
170
        schema:
168
          $ref: ../swagger.yaml#/definitions/error
171
          $ref: "../swagger.yaml#/definitions/error"
169
      "403":
172
      "403":
170
        description: Access forbidden
173
        description: Access forbidden
171
        schema:
174
        schema:
Lines 225-231 Link Here
225
        schema:
228
        schema:
226
          $ref: ../swagger.yaml#/definitions/auth_provider
229
          $ref: ../swagger.yaml#/definitions/auth_provider
227
      "400":
230
      "400":
228
        description: Bad Request
231
        description: Bad request
229
        schema:
232
        schema:
230
          $ref: ../swagger.yaml#/definitions/error
233
          $ref: ../swagger.yaml#/definitions/error
231
      "403":
234
      "403":
Lines 272-277 Link Here
272
        description: An identity provider
275
        description: An identity provider
273
        schema:
276
        schema:
274
          $ref: ../swagger.yaml#/definitions/auth_provider
277
          $ref: ../swagger.yaml#/definitions/auth_provider
278
      "400":
279
        description: Bad request
280
        schema:
281
          $ref: "../swagger.yaml#/definitions/error"
275
      "404":
282
      "404":
276
        description: Object not found
283
        description: Object not found
277
        schema:
284
        schema:
Lines 332-338 Link Here
332
        schema:
339
        schema:
333
          $ref: ../swagger.yaml#/definitions/auth_provider
340
          $ref: ../swagger.yaml#/definitions/auth_provider
334
      "400":
341
      "400":
335
        description: Bad Request
342
        description: Bad request
336
        schema:
343
        schema:
337
          $ref: ../swagger.yaml#/definitions/error
344
          $ref: ../swagger.yaml#/definitions/error
338
      "403":
345
      "403":
Lines 370-375 Link Here
370
    responses:
377
    responses:
371
      "204":
378
      "204":
372
        description: identity provider deleted
379
        description: identity provider deleted
380
      "400":
381
        description: Bad request
382
        schema:
383
          $ref: "../swagger.yaml#/definitions/error"
373
      "401":
384
      "401":
374
        description: Authentication required
385
        description: Authentication required
375
        schema:
386
        schema:
Lines 428-433 Link Here
428
        schema:
439
        schema:
429
          items:
440
          items:
430
            $ref: ../swagger.yaml#/definitions/auth_provider_domain
441
            $ref: ../swagger.yaml#/definitions/auth_provider_domain
442
      "400":
443
        description: |
444
          Bad request. Possible `error_code` attribute values:
445
446
            * `invalid_query`
447
        schema:
448
          $ref: "../swagger.yaml#/definitions/error"
431
      "404":
449
      "404":
432
        description: Object not found
450
        description: Object not found
433
        schema:
451
        schema:
Lines 468-474 Link Here
468
        schema:
486
        schema:
469
          $ref: ../swagger.yaml#/definitions/auth_provider_domain
487
          $ref: ../swagger.yaml#/definitions/auth_provider_domain
470
      "400":
488
      "400":
471
        description: Bad Request
489
        description: Bad request
472
        schema:
490
        schema:
473
          $ref: ../swagger.yaml#/definitions/error
491
          $ref: ../swagger.yaml#/definitions/error
474
      "403":
492
      "403":
Lines 510-515 Link Here
510
        description: An identity provider
528
        description: An identity provider
511
        schema:
529
        schema:
512
          $ref: ../swagger.yaml#/definitions/auth_provider_domain
530
          $ref: ../swagger.yaml#/definitions/auth_provider_domain
531
      "400":
532
        description: Bad request
533
        schema:
534
          $ref: "../swagger.yaml#/definitions/error"
513
      "404":
535
      "404":
514
        description: Object not found
536
        description: Object not found
515
        schema:
537
        schema:
Lines 542-547 Link Here
542
    responses:
564
    responses:
543
      "204":
565
      "204":
544
        description: identity provider deleted
566
        description: identity provider deleted
567
      "400":
568
        description: Bad request
569
        schema:
570
          $ref: "../swagger.yaml#/definitions/error"
545
      "401":
571
      "401":
546
        description: Authentication required
572
        description: Authentication required
547
        schema:
573
        schema:
Lines 601-609 Link Here
601
          items:
627
          items:
602
            $ref: ../swagger.yaml#/definitions/identity_provider
628
            $ref: ../swagger.yaml#/definitions/identity_provider
603
      "400":
629
      "400":
604
        description: Bad Request
630
        description: |
631
          Bad request. Possible `error_code` attribute values:
632
633
            * `invalid_query`
605
        schema:
634
        schema:
606
          $ref: ../swagger.yaml#/definitions/error
635
          $ref: "../swagger.yaml#/definitions/error"
607
      "403":
636
      "403":
608
        description: Access forbidden
637
        description: Access forbidden
609
        schema:
638
        schema:
Lines 663-669 Link Here
663
        schema:
692
        schema:
664
          $ref: ../swagger.yaml#/definitions/identity_provider
693
          $ref: ../swagger.yaml#/definitions/identity_provider
665
      "400":
694
      "400":
666
        description: Bad Request
695
        description: Bad request
667
        schema:
696
        schema:
668
          $ref: ../swagger.yaml#/definitions/error
697
          $ref: ../swagger.yaml#/definitions/error
669
      "403":
698
      "403":
Lines 710-715 Link Here
710
        description: An identity provider
739
        description: An identity provider
711
        schema:
740
        schema:
712
          $ref: ../swagger.yaml#/definitions/identity_provider
741
          $ref: ../swagger.yaml#/definitions/identity_provider
742
      "400":
743
        description: Bad request
744
        schema:
745
          $ref: "../swagger.yaml#/definitions/error"
713
      "404":
746
      "404":
714
        description: Object not found
747
        description: Object not found
715
        schema:
748
        schema:
Lines 770-776 Link Here
770
        schema:
803
        schema:
771
          $ref: ../swagger.yaml#/definitions/identity_provider
804
          $ref: ../swagger.yaml#/definitions/identity_provider
772
      "400":
805
      "400":
773
        description: Bad Request
806
        description: Bad request
774
        schema:
807
        schema:
775
          $ref: ../swagger.yaml#/definitions/error
808
          $ref: ../swagger.yaml#/definitions/error
776
      "403":
809
      "403":
Lines 807-813 Link Here
807
      - application/json
840
      - application/json
808
    responses:
841
    responses:
809
      "204":
842
      "204":
810
        description: identity provider deleted
843
        description: Identity provider deleted
844
      "400":
845
        description: Bad request
846
        schema:
847
          $ref: "../swagger.yaml#/definitions/error"
811
      "401":
848
      "401":
812
        description: Authentication required
849
        description: Authentication required
813
        schema:
850
        schema:
Lines 866-871 Link Here
866
        schema:
903
        schema:
867
          items:
904
          items:
868
            $ref: ../swagger.yaml#/definitions/identity_provider_domain
905
            $ref: ../swagger.yaml#/definitions/identity_provider_domain
906
      "400":
907
        description: |
908
          Bad request. Possible `error_code` attribute values:
909
910
            * `invalid_query`
911
        schema:
912
          $ref: "../swagger.yaml#/definitions/error"
869
      "404":
913
      "404":
870
        description: Object not found
914
        description: Object not found
871
        schema:
915
        schema:
Lines 906-912 Link Here
906
        schema:
950
        schema:
907
          $ref: ../swagger.yaml#/definitions/identity_provider_domain
951
          $ref: ../swagger.yaml#/definitions/identity_provider_domain
908
      "400":
952
      "400":
909
        description: Bad Request
953
        description: Bad request
910
        schema:
954
        schema:
911
          $ref: ../swagger.yaml#/definitions/error
955
          $ref: ../swagger.yaml#/definitions/error
912
      "403":
956
      "403":
Lines 948-953 Link Here
948
        description: An identity provider
992
        description: An identity provider
949
        schema:
993
        schema:
950
          $ref: ../swagger.yaml#/definitions/identity_provider_domain
994
          $ref: ../swagger.yaml#/definitions/identity_provider_domain
995
      "400":
996
        description: Bad request
997
        schema:
998
          $ref: "../swagger.yaml#/definitions/error"
951
      "404":
999
      "404":
952
        description: Object not found
1000
        description: Object not found
953
        schema:
1001
        schema:
Lines 989-995 Link Here
989
        schema:
1037
        schema:
990
          $ref: ../swagger.yaml#/definitions/identity_provider_domain
1038
          $ref: ../swagger.yaml#/definitions/identity_provider_domain
991
      "400":
1039
      "400":
992
        description: Bad Request
1040
        description: Bad request
993
        schema:
1041
        schema:
994
          $ref: ../swagger.yaml#/definitions/error
1042
          $ref: ../swagger.yaml#/definitions/error
995
      "403":
1043
      "403":
Lines 1028-1033 Link Here
1028
    responses:
1076
    responses:
1029
      "204":
1077
      "204":
1030
        description: identity provider deleted
1078
        description: identity provider deleted
1079
      "400":
1080
        description: Bad request
1081
        schema:
1082
          $ref: "../swagger.yaml#/definitions/error"
1031
      "401":
1083
      "401":
1032
        description: Authentication required
1084
        description: Authentication required
1033
        schema:
1085
        schema:
(-)a/api/v1/swagger/paths/authorised_value_categories.yaml (-1 / +4 lines)
Lines 33-39 Link Here
33
            $ref: "../swagger.yaml#/definitions/authorised_value_category"
33
            $ref: "../swagger.yaml#/definitions/authorised_value_category"
34
          type: array
34
          type: array
35
      400:
35
      400:
36
        description: Bad request
36
        description: |
37
          Bad request. Possible `error_code` attribute values:
38
39
            * `invalid_query`
37
        schema:
40
        schema:
38
          $ref: "../swagger.yaml#/definitions/error"
41
          $ref: "../swagger.yaml#/definitions/error"
39
      403:
42
      403:
(-)a/api/v1/swagger/paths/authorised_values.yaml (-1 / +4 lines)
Lines 58-64 Link Here
58
            $ref: "../swagger.yaml#/definitions/authorised_value"
58
            $ref: "../swagger.yaml#/definitions/authorised_value"
59
          type: array
59
          type: array
60
      400:
60
      400:
61
        description: Bad request
61
        description: |
62
          Bad request. Possible `error_code` attribute values:
63
64
            * `invalid_query`
62
        schema:
65
        schema:
63
          $ref: "../swagger.yaml#/definitions/error"
66
          $ref: "../swagger.yaml#/definitions/error"
64
      403:
67
      403:
(-)a/api/v1/swagger/paths/authorities.yaml (-1 / +16 lines)
Lines 23-28 Link Here
23
    responses:
23
    responses:
24
      "200":
24
      "200":
25
        description: A list of authorities
25
        description: A list of authorities
26
      "400":
27
        description: |
28
          Bad request. Possible `error_code` attribute values:
29
30
            * `invalid_query`
31
        schema:
32
          $ref: "../swagger.yaml#/definitions/error"
26
      "401":
33
      "401":
27
        description: Authentication required
34
        description: Authentication required
28
        schema:
35
        schema:
Lines 91-97 Link Here
91
      "201":
98
      "201":
92
        description: An authority
99
        description: An authority
93
      "400":
100
      "400":
94
        description: Bad request.
101
        description: Bad request
95
        schema:
102
        schema:
96
          $ref: "../swagger.yaml#/definitions/error"
103
          $ref: "../swagger.yaml#/definitions/error"
97
      "401":
104
      "401":
Lines 148-153 Link Here
148
    responses:
155
    responses:
149
      "200":
156
      "200":
150
        description: An authority
157
        description: An authority
158
      "400":
159
        description: Bad request
160
        schema:
161
          $ref: "../swagger.yaml#/definitions/error"
151
      "401":
162
      "401":
152
        description: Authentication required
163
        description: Authentication required
153
        schema:
164
        schema:
Lines 196-201 Link Here
196
        description: Authority deleted
207
        description: Authority deleted
197
        schema:
208
        schema:
198
          type: string
209
          type: string
210
      "400":
211
        description: Bad request
212
        schema:
213
          $ref: "../swagger.yaml#/definitions/error"
199
      "401":
214
      "401":
200
        description: Authentication required
215
        description: Authentication required
201
        schema:
216
        schema:
(-)a/api/v1/swagger/paths/biblios.yaml (-1 / +55 lines)
Lines 83-88 Link Here
83
    responses:
83
    responses:
84
      "200":
84
      "200":
85
        description: A list of biblios
85
        description: A list of biblios
86
      "400":
87
        description: |
88
          Bad request. Possible `error_code` attribute values:
89
90
            * `invalid_query`
91
        schema:
92
          $ref: "../swagger.yaml#/definitions/error"
86
      "401":
93
      "401":
87
        description: Authentication required
94
        description: Authentication required
88
        schema:
95
        schema:
Lines 134-139 Link Here
134
    responses:
141
    responses:
135
      "200":
142
      "200":
136
        description: A biblio
143
        description: A biblio
144
      "400":
145
        description: Bad request
146
        schema:
147
          $ref: "../swagger.yaml#/definitions/error"
137
      "401":
148
      "401":
138
        description: Authentication required
149
        description: Authentication required
139
        schema:
150
        schema:
Lines 182-187 Link Here
182
        description: Biblio deleted
193
        description: Biblio deleted
183
        schema:
194
        schema:
184
          type: string
195
          type: string
196
      "400":
197
        description: Bad request
198
        schema:
199
          $ref: "../swagger.yaml#/definitions/error"
185
      "401":
200
      "401":
186
        description: Authentication required
201
        description: Authentication required
187
        schema:
202
        schema:
Lines 311-316 Link Here
311
          type: array
326
          type: array
312
          items:
327
          items:
313
            $ref: ../swagger.yaml#/definitions/booking
328
            $ref: ../swagger.yaml#/definitions/booking
329
      "400":
330
        description: |
331
          Bad request. Possible `error_code` attribute values:
332
333
            * `invalid_query`
334
        schema:
335
          $ref: "../swagger.yaml#/definitions/error"
314
      "401":
336
      "401":
315
        description: Authentication required
337
        description: Authentication required
316
        schema:
338
        schema:
Lines 382-387 Link Here
382
        description: A list of checkouts
404
        description: A list of checkouts
383
        schema:
405
        schema:
384
          $ref: "../swagger.yaml#/definitions/checkouts"
406
          $ref: "../swagger.yaml#/definitions/checkouts"
407
      "400":
408
        description: |
409
          Bad request. Possible `error_code` attribute values:
410
411
            * `invalid_query`
412
        schema:
413
          $ref: "../swagger.yaml#/definitions/error"
385
      "403":
414
      "403":
386
        description: Access forbidden
415
        description: Access forbidden
387
        schema:
416
        schema:
Lines 447-452 Link Here
447
          type: array
476
          type: array
448
          items:
477
          items:
449
            $ref: "../swagger.yaml#/definitions/item"
478
            $ref: "../swagger.yaml#/definitions/item"
479
      "400":
480
        description: |
481
          Bad request. Possible `error_code` attribute values:
482
483
            * `invalid_query`
484
        schema:
485
          $ref: "../swagger.yaml#/definitions/error"
450
      "401":
486
      "401":
451
        description: Authentication required
487
        description: Authentication required
452
        schema:
488
        schema:
Lines 624-630 Link Here
624
          items:
660
          items:
625
            $ref: "../swagger.yaml#/definitions/library"
661
            $ref: "../swagger.yaml#/definitions/library"
626
      "400":
662
      "400":
627
        description: Missing or wrong parameters
663
        description: |
664
          Bad request. Possible `error_code` attribute values:
665
666
            * `invalid_query`
628
        schema:
667
        schema:
629
          $ref: "../swagger.yaml#/definitions/error"
668
          $ref: "../swagger.yaml#/definitions/error"
630
      "401":
669
      "401":
Lines 670-675 Link Here
670
    responses:
709
    responses:
671
      "200":
710
      "200":
672
        description: A biblio
711
        description: A biblio
712
      "400":
713
        description: Bad request
714
        schema:
715
          $ref: "../swagger.yaml#/definitions/error"
673
      "401":
716
      "401":
674
        description: Authentication required
717
        description: Authentication required
675
        schema:
718
        schema:
Lines 736-741 Link Here
736
          type: array
779
          type: array
737
          items:
780
          items:
738
            $ref: "../swagger.yaml#/definitions/item"
781
            $ref: "../swagger.yaml#/definitions/item"
782
      "400":
783
        description: |
784
          Bad request. Possible `error_code` attribute values:
785
786
            * `invalid_query`
787
        schema:
788
          $ref: "../swagger.yaml#/definitions/error"
739
      "401":
789
      "401":
740
        description: Authentication required
790
        description: Authentication required
741
        schema:
791
        schema:
Lines 809-814 Link Here
809
              description: number of ratings
859
              description: number of ratings
810
              type: integer
860
              type: integer
811
          additionalProperties: false
861
          additionalProperties: false
862
      "400":
863
        description: Bad request
864
        schema:
865
          $ref: "../swagger.yaml#/definitions/error"
812
      "401":
866
      "401":
813
        description: Authentication required
867
        description: Authentication required
814
        schema:
868
        schema:
(-)a/api/v1/swagger/paths/biblios_item_groups.yaml (-2 / +17 lines)
Lines 37-42 Link Here
37
          type: array
37
          type: array
38
          items:
38
          items:
39
            "$ref": "../swagger.yaml#/definitions/item_group"
39
            "$ref": "../swagger.yaml#/definitions/item_group"
40
      '400':
41
        description: |
42
          Bad request. Possible `error_code` attribute values:
43
44
            * `invalid_query`
45
        schema:
46
          $ref: "../swagger.yaml#/definitions/error"
40
      '401':
47
      '401':
41
        description: Authentication required
48
        description: Authentication required
42
        schema:
49
        schema:
Lines 90-96 Link Here
90
        schema:
97
        schema:
91
          "$ref": "../swagger.yaml#/definitions/item_group"
98
          "$ref": "../swagger.yaml#/definitions/item_group"
92
      '400':
99
      '400':
93
        description: Bad parameter
100
        description: Bad request
94
        schema:
101
        schema:
95
          "$ref": "../swagger.yaml#/definitions/error"
102
          "$ref": "../swagger.yaml#/definitions/error"
96
      '401':
103
      '401':
Lines 156-162 Link Here
156
        schema:
163
        schema:
157
          "$ref": "../swagger.yaml#/definitions/item_group"
164
          "$ref": "../swagger.yaml#/definitions/item_group"
158
      '400':
165
      '400':
159
        description: Missing or wrong parameters
166
        description: Bad request
160
        schema:
167
        schema:
161
          "$ref": "../swagger.yaml#/definitions/error"
168
          "$ref": "../swagger.yaml#/definitions/error"
162
      '404':
169
      '404':
Lines 273-278 Link Here
273
        description: ItemGroup deleted
280
        description: ItemGroup deleted
274
        schema:
281
        schema:
275
          type: string
282
          type: string
283
      '400':
284
        description: Bad request
285
        schema:
286
          $ref: "../swagger.yaml#/definitions/error"
276
      '401':
287
      '401':
277
        description: Authentication required
288
        description: Authentication required
278
        schema:
289
        schema:
Lines 397-402 Link Here
397
        description: Item unlinked from item group
408
        description: Item unlinked from item group
398
        schema:
409
        schema:
399
          type: string
410
          type: string
411
      '400':
412
        description: Bad request
413
        schema:
414
          $ref: "../swagger.yaml#/definitions/error"
400
      '401':
415
      '401':
401
        description: Authentication required
416
        description: Authentication required
402
        schema:
417
        schema:
(-)a/api/v1/swagger/paths/biblios_merge.yaml (+4 lines)
Lines 24-29 Link Here
24
    responses:
24
    responses:
25
      '200':
25
      '200':
26
        description: The merge result as a biblio record
26
        description: The merge result as a biblio record
27
      '400':
28
        description: Bad request
29
        schema:
30
          $ref: "../swagger.yaml#/definitions/error"
27
      '404':
31
      '404':
28
        description: Biblio not found
32
        description: Biblio not found
29
        schema:
33
        schema:
(-)a/api/v1/swagger/paths/bookings.yaml (-2 / +17 lines)
Lines 56-61 Link Here
56
          items:
56
          items:
57
            $ref: ../swagger.yaml#/definitions/booking
57
            $ref: ../swagger.yaml#/definitions/booking
58
          type: array
58
          type: array
59
      400:
60
        description: |
61
          Bad request. Possible `error_code` attribute values:
62
63
            * `invalid_query`
64
        schema:
65
          $ref: "../swagger.yaml#/definitions/error"
59
      403:
66
      403:
60
        description: Access forbidden
67
        description: Access forbidden
61
        schema:
68
        schema:
Lines 91-97 Link Here
91
        schema:
98
        schema:
92
          $ref: ../swagger.yaml#/definitions/booking
99
          $ref: ../swagger.yaml#/definitions/booking
93
      400:
100
      400:
94
        description: Client error
101
        description: Bad request
95
        schema:
102
        schema:
96
          $ref: ../swagger.yaml#/definitions/error
103
          $ref: ../swagger.yaml#/definitions/error
97
      401:
104
      401:
Lines 131-136 Link Here
131
    responses:
138
    responses:
132
      204:
139
      204:
133
        description: Booking deleted
140
        description: Booking deleted
141
      400:
142
        description: Bad request
143
        schema:
144
          $ref: "../swagger.yaml#/definitions/error"
134
      401:
145
      401:
135
        description: Authentication required
146
        description: Authentication required
136
        schema:
147
        schema:
Lines 169-174 Link Here
169
        description: A booking
180
        description: A booking
170
        schema:
181
        schema:
171
          $ref: ../swagger.yaml#/definitions/booking
182
          $ref: ../swagger.yaml#/definitions/booking
183
      400:
184
        description: Bad request
185
        schema:
186
          $ref: "../swagger.yaml#/definitions/error"
172
      404:
187
      404:
173
        description: Booking not found
188
        description: Booking not found
174
        schema:
189
        schema:
Lines 206-212 Link Here
206
        schema:
221
        schema:
207
          $ref: ../swagger.yaml#/definitions/booking
222
          $ref: ../swagger.yaml#/definitions/booking
208
      400:
223
      400:
209
        description: Client error
224
        description: Bad request
210
        schema:
225
        schema:
211
          $ref: ../swagger.yaml#/definitions/error
226
          $ref: ../swagger.yaml#/definitions/error
212
      401:
227
      401:
(-)a/api/v1/swagger/paths/cash_registers.yaml (+11 lines)
Lines 34-39 Link Here
34
          type: array
34
          type: array
35
          items:
35
          items:
36
            $ref: "../swagger.yaml#/definitions/cashup"
36
            $ref: "../swagger.yaml#/definitions/cashup"
37
      "400":
38
        description: |
39
          Bad request. Possible `error_code` attribute values:
40
41
            * `invalid_query`
42
        schema:
43
          $ref: "../swagger.yaml#/definitions/error"
37
      "403":
44
      "403":
38
        description: Access forbidden
45
        description: Access forbidden
39
        schema:
46
        schema:
Lines 82-87 Link Here
82
        description: A cashup
89
        description: A cashup
83
        schema:
90
        schema:
84
          $ref: "../swagger.yaml#/definitions/cashup"
91
          $ref: "../swagger.yaml#/definitions/cashup"
92
      "400":
93
        description: Bad request
94
        schema:
95
          $ref: "../swagger.yaml#/definitions/error"
85
      "403":
96
      "403":
86
        description: Access forbidden
97
        description: Access forbidden
87
        schema:
98
        schema:
(-)a/api/v1/swagger/paths/checkouts.yaml (-1 / +36 lines)
Lines 38-43 Link Here
38
        description: A list of checkouts
38
        description: A list of checkouts
39
        schema:
39
        schema:
40
          $ref: "../swagger.yaml#/definitions/checkouts"
40
          $ref: "../swagger.yaml#/definitions/checkouts"
41
      "400":
42
        description: |
43
          Bad request. Possible `error_code` attribute values:
44
45
            * `invalid_query`
46
        schema:
47
          $ref: "../swagger.yaml#/definitions/error"
41
      "403":
48
      "403":
42
        description: Access forbidden
49
        description: Access forbidden
43
        schema:
50
        schema:
Lines 90-96 Link Here
90
        schema:
97
        schema:
91
          $ref: "../swagger.yaml#/definitions/checkout"
98
          $ref: "../swagger.yaml#/definitions/checkout"
92
      "400":
99
      "400":
93
        description: Missing or wrong parameters
100
        description: Bad request
94
        schema:
101
        schema:
95
          $ref: "../swagger.yaml#/definitions/error"
102
          $ref: "../swagger.yaml#/definitions/error"
96
      "401":
103
      "401":
Lines 150-155 Link Here
150
        description: Updated borrower's checkout
157
        description: Updated borrower's checkout
151
        schema:
158
        schema:
152
          $ref: "../swagger.yaml#/definitions/checkout"
159
          $ref: "../swagger.yaml#/definitions/checkout"
160
      "400":
161
        description: Bad request
162
        schema:
163
          $ref: "../swagger.yaml#/definitions/error"
153
      "403":
164
      "403":
154
        description: Access forbidden
165
        description: Access forbidden
155
        schema:
166
        schema:
Lines 189-194 Link Here
189
        description: Updated borrower's checkout
200
        description: Updated borrower's checkout
190
        schema:
201
        schema:
191
          $ref: "../swagger.yaml#/definitions/checkout"
202
          $ref: "../swagger.yaml#/definitions/checkout"
203
      "400":
204
        description: Bad request
205
        schema:
206
          $ref: "../swagger.yaml#/definitions/error"
192
      "403":
207
      "403":
193
        description: Cannot renew checkout
208
        description: Cannot renew checkout
194
        schema:
209
        schema:
Lines 228-233 Link Here
228
        description: Updated borrower's checkout
243
        description: Updated borrower's checkout
229
        schema:
244
        schema:
230
          $ref: "../swagger.yaml#/definitions/checkout"
245
          $ref: "../swagger.yaml#/definitions/checkout"
246
      "400":
247
        description: Bad request
248
        schema:
249
          $ref: "../swagger.yaml#/definitions/error"
231
      "403":
250
      "403":
232
        description: Cannot renew checkout
251
        description: Cannot renew checkout
233
        schema:
252
        schema:
Lines 275-280 Link Here
275
        description: List of checkouts renewals
294
        description: List of checkouts renewals
276
        schema:
295
        schema:
277
          $ref: "../swagger.yaml#/definitions/renewals"
296
          $ref: "../swagger.yaml#/definitions/renewals"
297
      "400":
298
        description: Bad request
299
        schema:
300
          $ref: "../swagger.yaml#/definitions/error"
278
      "403":
301
      "403":
279
        description: Access forbidden
302
        description: Access forbidden
280
        schema:
303
        schema:
Lines 313-318 Link Here
313
        description: Checkout renewability information
336
        description: Checkout renewability information
314
        schema:
337
        schema:
315
          $ref: "../swagger.yaml#/definitions/allows_renewal"
338
          $ref: "../swagger.yaml#/definitions/allows_renewal"
339
      "400":
340
        description: Bad request
341
        schema:
342
          $ref: "../swagger.yaml#/definitions/error"
316
      "403":
343
      "403":
317
        description: Forbidden
344
        description: Forbidden
318
        schema:
345
        schema:
Lines 352-357 Link Here
352
        description: Availability
379
        description: Availability
353
        schema:
380
        schema:
354
          $ref: "../swagger.yaml#/definitions/checkout_availability"
381
          $ref: "../swagger.yaml#/definitions/checkout_availability"
382
      "400":
383
        description: Bad request
384
        schema:
385
          $ref: "../swagger.yaml#/definitions/error"
355
      "403":
386
      "403":
356
        description: Access forbidden
387
        description: Access forbidden
357
        schema:
388
        schema:
Lines 397-402 Link Here
397
            confirmation_token:
428
            confirmation_token:
398
              type: string
429
              type: string
399
          additionalProperties: false
430
          additionalProperties: false
431
      "400":
432
        description: Bad request
433
        schema:
434
          $ref: "../swagger.yaml#/definitions/error"
400
      "403":
435
      "403":
401
        description: Access forbidden
436
        description: Access forbidden
402
        schema:
437
        schema:
(-)a/api/v1/swagger/paths/circulation-rules.yaml (+4 lines)
Lines 15-20 Link Here
15
          type: object
15
          type: object
16
          additionalProperties:
16
          additionalProperties:
17
            $ref: "../swagger.yaml#/definitions/circ-rule-kind"
17
            $ref: "../swagger.yaml#/definitions/circ-rule-kind"
18
      "400":
19
        description: Bad request
20
        schema:
21
          $ref: "../swagger.yaml#/definitions/error"
18
      "403":
22
      "403":
19
        description: Access forbidden
23
        description: Access forbidden
20
        schema:
24
        schema:
(-)a/api/v1/swagger/paths/cities.yaml (+23 lines)
Lines 43-48 Link Here
43
          type: array
43
          type: array
44
          items:
44
          items:
45
            $ref: "../swagger.yaml#/definitions/city"
45
            $ref: "../swagger.yaml#/definitions/city"
46
      "400":
47
        description: |
48
          Bad request. Possible `error_code` attribute values:
49
50
            * `invalid_query`
51
        schema:
52
          $ref: "../swagger.yaml#/definitions/error"
46
      "403":
53
      "403":
47
        description: Access forbidden
54
        description: Access forbidden
48
        schema:
55
        schema:
Lines 81-86 Link Here
81
        description: City added
88
        description: City added
82
        schema:
89
        schema:
83
          $ref: "../swagger.yaml#/definitions/city"
90
          $ref: "../swagger.yaml#/definitions/city"
91
      "400":
92
        description: Bad request
93
        schema:
94
          $ref: "../swagger.yaml#/definitions/error"
84
      "401":
95
      "401":
85
        description: Authentication required
96
        description: Authentication required
86
        schema:
97
        schema:
Lines 119-124 Link Here
119
        description: A city
130
        description: A city
120
        schema:
131
        schema:
121
          $ref: "../swagger.yaml#/definitions/city"
132
          $ref: "../swagger.yaml#/definitions/city"
133
      "400":
134
        description: Bad request
135
        schema:
136
          $ref: "../swagger.yaml#/definitions/error"
122
      "404":
137
      "404":
123
        description: City not found
138
        description: City not found
124
        schema:
139
        schema:
Lines 158-163 Link Here
158
        description: A city
173
        description: A city
159
        schema:
174
        schema:
160
          $ref: "../swagger.yaml#/definitions/city"
175
          $ref: "../swagger.yaml#/definitions/city"
176
      "400":
177
        description: Bad request
178
        schema:
179
          $ref: "../swagger.yaml#/definitions/error"
161
      "401":
180
      "401":
162
        description: Authentication required
181
        description: Authentication required
163
        schema:
182
        schema:
Lines 194-199 Link Here
194
    responses:
213
    responses:
195
      "204":
214
      "204":
196
        description: City deleted
215
        description: City deleted
216
      "400":
217
        description: Bad request
218
        schema:
219
          $ref: "../swagger.yaml#/definitions/error"
197
      "401":
220
      "401":
198
        description: Authentication required
221
        description: Authentication required
199
        schema:
222
        schema:
(-)a/api/v1/swagger/paths/clubs.yaml (-1 / +1 lines)
Lines 61-67 Link Here
61
        schema:
61
        schema:
62
          $ref: "../definitions/club_hold.yaml"
62
          $ref: "../definitions/club_hold.yaml"
63
      "400":
63
      "400":
64
        description: Missing or wrong parameters
64
        description: Bad request
65
        schema:
65
        schema:
66
          $ref: "../swagger.yaml#/definitions/error"
66
          $ref: "../swagger.yaml#/definitions/error"
67
      "401":
67
      "401":
(-)a/api/v1/swagger/paths/config_smtp_servers.yaml (+23 lines)
Lines 23-28 Link Here
23
          type: array
23
          type: array
24
          items:
24
          items:
25
            $ref: "../swagger.yaml#/definitions/smtp_server"
25
            $ref: "../swagger.yaml#/definitions/smtp_server"
26
      "400":
27
        description: |
28
          Bad request. Possible `error_code` attribute values:
29
30
            * `invalid_query`
31
        schema:
32
          $ref: "../swagger.yaml#/definitions/error"
26
      "403":
33
      "403":
27
        description: Access forbidden
34
        description: Access forbidden
28
        schema:
35
        schema:
Lines 61-66 Link Here
61
        description: An SMTP server object
68
        description: An SMTP server object
62
        schema:
69
        schema:
63
          $ref: "../swagger.yaml#/definitions/smtp_server"
70
          $ref: "../swagger.yaml#/definitions/smtp_server"
71
      "400":
72
        description: Bad request
73
        schema:
74
          $ref: "../swagger.yaml#/definitions/error"
64
      "401":
75
      "401":
65
        description: Authentication required
76
        description: Authentication required
66
        schema:
77
        schema:
Lines 103-108 Link Here
103
        description: An SMTP server object
114
        description: An SMTP server object
104
        schema:
115
        schema:
105
          $ref: "../swagger.yaml#/definitions/smtp_server"
116
          $ref: "../swagger.yaml#/definitions/smtp_server"
117
      "400":
118
        description: Bad request
119
        schema:
120
          $ref: "../swagger.yaml#/definitions/error"
106
      "404":
121
      "404":
107
        description: Object not found
122
        description: Object not found
108
        schema:
123
        schema:
Lines 146-151 Link Here
146
        description: An SMTP server object
161
        description: An SMTP server object
147
        schema:
162
        schema:
148
          $ref: "../swagger.yaml#/definitions/smtp_server"
163
          $ref: "../swagger.yaml#/definitions/smtp_server"
164
      "400":
165
        description: Bad request
166
        schema:
167
          $ref: "../swagger.yaml#/definitions/error"
149
      "401":
168
      "401":
150
        description: Authentication required
169
        description: Authentication required
151
        schema:
170
        schema:
Lines 185-190 Link Here
185
    responses:
204
    responses:
186
      "204":
205
      "204":
187
        description: SMTP server deleted
206
        description: SMTP server deleted
207
      "400":
208
        description: Bad request
209
        schema:
210
          $ref: "../swagger.yaml#/definitions/error"
188
      "401":
211
      "401":
189
        description: Authentication required
212
        description: Authentication required
190
        schema:
213
        schema:
(-)a/api/v1/swagger/paths/erm_agreements.yaml (-5 / +12 lines)
Lines 83-90 Link Here
83
          items:
83
          items:
84
            $ref: "../swagger.yaml#/definitions/erm_agreement"
84
            $ref: "../swagger.yaml#/definitions/erm_agreement"
85
          type: array
85
          type: array
86
      400:
86
      "400":
87
        description: Bad request
87
        description: |
88
          Bad request. Possible `error_code` attribute values:
89
90
            * `invalid_query`
88
        schema:
91
        schema:
89
          $ref: "../swagger.yaml#/definitions/error"
92
          $ref: "../swagger.yaml#/definitions/error"
90
      403:
93
      403:
Lines 128-134 Link Here
128
          items:
131
          items:
129
            $ref: "../swagger.yaml#/definitions/erm_agreement"
132
            $ref: "../swagger.yaml#/definitions/erm_agreement"
130
      400:
133
      400:
131
        description: Bad parameter
134
        description: Bad request
132
        schema:
135
        schema:
133
          $ref: "../swagger.yaml#/definitions/error"
136
          $ref: "../swagger.yaml#/definitions/error"
134
      401:
137
      401:
Lines 202-207 Link Here
202
        schema:
205
        schema:
203
          items:
206
          items:
204
            $ref: "../swagger.yaml#/definitions/erm_agreement"
207
            $ref: "../swagger.yaml#/definitions/erm_agreement"
208
      400:
209
        description: Bad request
210
        schema:
211
          $ref: "../swagger.yaml#/definitions/error"
205
      401:
212
      401:
206
        description: Authentication required
213
        description: Authentication required
207
        schema:
214
        schema:
Lines 266-272 Link Here
266
          items:
273
          items:
267
            $ref: "../swagger.yaml#/definitions/erm_agreement"
274
            $ref: "../swagger.yaml#/definitions/erm_agreement"
268
      400:
275
      400:
269
        description: Bad parameter
276
        description: Bad request
270
        schema:
277
        schema:
271
          $ref: "../swagger.yaml#/definitions/error"
278
          $ref: "../swagger.yaml#/definitions/error"
272
      403:
279
      403:
Lines 312-318 Link Here
312
      204:
319
      204:
313
        description: Agreement deleted
320
        description: Agreement deleted
314
      400:
321
      400:
315
        description: Agreement deletion failed
322
        description: Bad request
316
        schema:
323
        schema:
317
          $ref: "../swagger.yaml#/definitions/error"
324
          $ref: "../swagger.yaml#/definitions/error"
318
      401:
325
      401:
(-)a/api/v1/swagger/paths/erm_counter_files.yaml (-3 / +10 lines)
Lines 19-24 Link Here
19
        description: A counter file
19
        description: A counter file
20
        schema:
20
        schema:
21
          type: file
21
          type: file
22
      400:
23
        description: Bad request
24
        schema:
25
          $ref: "../swagger.yaml#/definitions/error"
22
      401:
26
      401:
23
        description: Authentication required
27
        description: Authentication required
24
        schema:
28
        schema:
Lines 108-114 Link Here
108
            $ref: "../swagger.yaml#/definitions/erm_counter_file"
112
            $ref: "../swagger.yaml#/definitions/erm_counter_file"
109
          type: array
113
          type: array
110
      400:
114
      400:
111
        description: Bad request
115
        description: |
116
          Bad request. Possible `error_code` attribute values:
117
118
            * `invalid_query`
112
        schema:
119
        schema:
113
          $ref: "../swagger.yaml#/definitions/error"
120
          $ref: "../swagger.yaml#/definitions/error"
114
      403:
121
      403:
Lines 143-149 Link Here
143
      204:
150
      204:
144
        description: counter_file deleted
151
        description: counter_file deleted
145
      400:
152
      400:
146
        description: counter_file deletion failed
153
        description: Bad request
147
        schema:
154
        schema:
148
          $ref: "../swagger.yaml#/definitions/error"
155
          $ref: "../swagger.yaml#/definitions/error"
149
      401:
156
      401:
Lines 174-177 Link Here
174
          $ref: "../swagger.yaml#/definitions/error"
181
          $ref: "../swagger.yaml#/definitions/error"
175
    x-koha-authorization:
182
    x-koha-authorization:
176
      permissions:
183
      permissions:
177
        erm: 1
184
        erm: 1
(-)a/api/v1/swagger/paths/erm_counter_logs.yaml (-2 / +5 lines)
Lines 27-33 Link Here
27
            $ref: "../swagger.yaml#/definitions/erm_counter_log"
27
            $ref: "../swagger.yaml#/definitions/erm_counter_log"
28
          type: array
28
          type: array
29
      400:
29
      400:
30
        description: Bad request
30
        description: |
31
          Bad request. Possible `error_code` attribute values:
32
33
            * `invalid_query`
31
        schema:
34
        schema:
32
          $ref: "../swagger.yaml#/definitions/error"
35
          $ref: "../swagger.yaml#/definitions/error"
33
      403:
36
      403:
Lines 46-49 Link Here
46
          $ref: "../swagger.yaml#/definitions/error"
49
          $ref: "../swagger.yaml#/definitions/error"
47
    x-koha-authorization:
50
    x-koha-authorization:
48
      permissions:
51
      permissions:
49
        erm: 1
52
        erm: 1
(-)a/api/v1/swagger/paths/erm_counter_registries.yaml (-2 / +5 lines)
Lines 23-29 Link Here
23
            $ref: "../swagger.yaml#/definitions/erm_counter_registry"
23
            $ref: "../swagger.yaml#/definitions/erm_counter_registry"
24
          type: array
24
          type: array
25
      400:
25
      400:
26
        description: Bad request
26
        description: |
27
          Bad request. Possible `error_code` attribute values:
28
29
            * `invalid_query`
27
        schema:
30
        schema:
28
          $ref: "../swagger.yaml#/definitions/error"
31
          $ref: "../swagger.yaml#/definitions/error"
29
      403:
32
      403:
Lines 42-45 Link Here
42
          $ref: "../swagger.yaml#/definitions/error"
45
          $ref: "../swagger.yaml#/definitions/error"
43
    x-koha-authorization:
46
    x-koha-authorization:
44
      permissions:
47
      permissions:
45
        erm: 1
48
        erm: 1
(-)a/api/v1/swagger/paths/erm_custom_reports.yaml (-1 / +29 lines)
Lines 32-37 Link Here
32
        schema:
32
        schema:
33
          items:
33
          items:
34
            $ref: "../swagger.yaml#/definitions/erm_custom_report"
34
            $ref: "../swagger.yaml#/definitions/erm_custom_report"
35
      "400":
36
        description: |
37
          Bad request. Possible `error_code` attribute values:
38
39
            * `invalid_query`
40
        schema:
41
          $ref: "../swagger.yaml#/definitions/error"
35
      401:
42
      401:
36
        description: authentication required
43
        description: authentication required
37
        schema:
44
        schema:
Lines 91-96 Link Here
91
        schema:
98
        schema:
92
          items:
99
          items:
93
            $ref: "../swagger.yaml#/definitions/erm_custom_report"
100
            $ref: "../swagger.yaml#/definitions/erm_custom_report"
101
      "400":
102
        description: |
103
          Bad request. Possible `error_code` attribute values:
104
105
            * `invalid_query`
106
        schema:
107
          $ref: "../swagger.yaml#/definitions/error"
94
      401:
108
      401:
95
        description: authentication required
109
        description: authentication required
96
        schema:
110
        schema:
Lines 150-155 Link Here
150
        schema:
164
        schema:
151
          items:
165
          items:
152
            $ref: "../swagger.yaml#/definitions/erm_custom_report"
166
            $ref: "../swagger.yaml#/definitions/erm_custom_report"
167
      "400":
168
        description: |
169
          Bad request. Possible `error_code` attribute values:
170
171
            * `invalid_query`
172
        schema:
173
          $ref: "../swagger.yaml#/definitions/error"
153
      401:
174
      401:
154
        description: authentication required
175
        description: authentication required
155
        schema:
176
        schema:
Lines 212-217 Link Here
212
        schema:
233
        schema:
213
          items:
234
          items:
214
            $ref: "../swagger.yaml#/definitions/erm_custom_report"
235
            $ref: "../swagger.yaml#/definitions/erm_custom_report"
236
      "400":
237
        description: |
238
          Bad request. Possible `error_code` attribute values:
239
240
            * `invalid_query`
241
        schema:
242
          $ref: "../swagger.yaml#/definitions/error"
215
      401:
243
      401:
216
        description: authentication required
244
        description: authentication required
217
        schema:
245
        schema:
Lines 236-239 Link Here
236
          $ref: "../swagger.yaml#/definitions/error"
264
          $ref: "../swagger.yaml#/definitions/error"
237
    x-koha-authorization:
265
    x-koha-authorization:
238
      permissions:
266
      permissions:
239
        erm: 1
267
        erm: 1
(-)a/api/v1/swagger/paths/erm_default_usage_reports.yaml (-6 / +9 lines)
Lines 37-44 Link Here
37
          items:
37
          items:
38
            $ref: "../swagger.yaml#/definitions/erm_default_usage_report"
38
            $ref: "../swagger.yaml#/definitions/erm_default_usage_report"
39
          type: array
39
          type: array
40
      400:
40
      "400":
41
        description: Bad request
41
        description: |
42
          Bad request. Possible `error_code` attribute values:
43
44
            * `invalid_query`
42
        schema:
45
        schema:
43
          $ref: "../swagger.yaml#/definitions/error"
46
          $ref: "../swagger.yaml#/definitions/error"
44
      403:
47
      403:
Lines 82-88 Link Here
82
          items:
85
          items:
83
            $ref: "../swagger.yaml#/definitions/erm_default_usage_report"
86
            $ref: "../swagger.yaml#/definitions/erm_default_usage_report"
84
      400:
87
      400:
85
        description: Bad parameter
88
        description: Bad request
86
        schema:
89
        schema:
87
          $ref: "../swagger.yaml#/definitions/error"
90
          $ref: "../swagger.yaml#/definitions/error"
88
      401:
91
      401:
Lines 132-139 Link Here
132
    responses:
135
    responses:
133
      204:
136
      204:
134
        description: default_usage_report deleted
137
        description: default_usage_report deleted
135
      400:
138
      "400":
136
        description: default_usage_report deletion failed
139
        description: Bad request
137
        schema:
140
        schema:
138
          $ref: "../swagger.yaml#/definitions/error"
141
          $ref: "../swagger.yaml#/definitions/error"
139
      401:
142
      401:
Lines 164-167 Link Here
164
          $ref: "../swagger.yaml#/definitions/error"
167
          $ref: "../swagger.yaml#/definitions/error"
165
    x-koha-authorization:
168
    x-koha-authorization:
166
      permissions:
169
      permissions:
167
        erm: 1
170
        erm: 1
(-)a/api/v1/swagger/paths/erm_documents.yaml (+4 lines)
Lines 19-24 Link Here
19
        description: Anagreement
19
        description: Anagreement
20
        schema:
20
        schema:
21
          type: file
21
          type: file
22
      "400":
23
        description: Bad request
24
        schema:
25
          $ref: "../swagger.yaml#/definitions/error"
22
      401:
26
      401:
23
        description: Authentication required
27
        description: Authentication required
24
        schema:
28
        schema:
(-)a/api/v1/swagger/paths/erm_eholdings_packages.yaml (-5 / +16 lines)
Lines 80-87 Link Here
80
          items:
80
          items:
81
            $ref: "../swagger.yaml#/definitions/erm_eholdings_package"
81
            $ref: "../swagger.yaml#/definitions/erm_eholdings_package"
82
          type: array
82
          type: array
83
      400:
83
      "400":
84
        description: Bad request
84
        description: |
85
          Bad request. Possible `error_code` attribute values:
86
87
            * `invalid_query`
85
        schema:
88
        schema:
86
          $ref: "../swagger.yaml#/definitions/error"
89
          $ref: "../swagger.yaml#/definitions/error"
87
      403:
90
      403:
Lines 130-136 Link Here
130
          items:
133
          items:
131
            $ref: "../swagger.yaml#/definitions/erm_eholdings_package"
134
            $ref: "../swagger.yaml#/definitions/erm_eholdings_package"
132
      400:
135
      400:
133
        description: Bad parameter
136
        description: Bad request
134
        schema:
137
        schema:
135
          $ref: "../swagger.yaml#/definitions/error"
138
          $ref: "../swagger.yaml#/definitions/error"
136
      401:
139
      401:
Lines 197-202 Link Here
197
        schema:
200
        schema:
198
          items:
201
          items:
199
            $ref: "../swagger.yaml#/definitions/erm_eholdings_package"
202
            $ref: "../swagger.yaml#/definitions/erm_eholdings_package"
203
      "400":
204
        description: Bad request
205
        schema:
206
          $ref: "../swagger.yaml#/definitions/error"
200
      401:
207
      401:
201
        description: Authentication required
208
        description: Authentication required
202
        schema:
209
        schema:
Lines 263-269 Link Here
263
          items:
270
          items:
264
            $ref: "../swagger.yaml#/definitions/erm_eholdings_package"
271
            $ref: "../swagger.yaml#/definitions/erm_eholdings_package"
265
      400:
272
      400:
266
        description: Bad parameter
273
        description: Bad request
267
        schema:
274
        schema:
268
          $ref: "../swagger.yaml#/definitions/error"
275
          $ref: "../swagger.yaml#/definitions/error"
269
      403:
276
      403:
Lines 310-316 Link Here
310
      204:
317
      204:
311
        description: package deleted
318
        description: package deleted
312
      400:
319
      400:
313
        description: package deletion failed
320
        description: Bad request
314
        schema:
321
        schema:
315
          $ref: "../swagger.yaml#/definitions/error"
322
          $ref: "../swagger.yaml#/definitions/error"
316
      401:
323
      401:
Lines 378-383 Link Here
378
              description: Add or remove this package from remote holdings
385
              description: Add or remove this package from remote holdings
379
              type: boolean
386
              type: boolean
380
          additionalProperties: false
387
          additionalProperties: false
388
      400:
389
        description: Bad request
390
        schema:
391
          $ref: "../swagger.yaml#/definitions/error"
381
      401:
392
      401:
382
        description: Authentication required
393
        description: Authentication required
383
        schema:
394
        schema:
(-)a/api/v1/swagger/paths/erm_eholdings_packages_resources.yaml (-2 / +5 lines)
Lines 58-65 Link Here
58
          items:
58
          items:
59
            $ref: "../swagger.yaml#/definitions/erm_eholdings_resource"
59
            $ref: "../swagger.yaml#/definitions/erm_eholdings_resource"
60
          type: array
60
          type: array
61
      400:
61
      "400":
62
        description: Bad request
62
        description: |
63
          Bad request. Possible `error_code` attribute values:
64
65
            * `invalid_query`
63
        schema:
66
        schema:
64
          $ref: "../swagger.yaml#/definitions/error"
67
          $ref: "../swagger.yaml#/definitions/error"
65
      403:
68
      403:
(-)a/api/v1/swagger/paths/erm_eholdings_resources.yaml (-2 / +13 lines)
Lines 57-64 Link Here
57
          items:
57
          items:
58
            $ref: "../swagger.yaml#/definitions/erm_eholdings_resource"
58
            $ref: "../swagger.yaml#/definitions/erm_eholdings_resource"
59
          type: array
59
          type: array
60
      400:
60
      "400":
61
        description: Bad request
61
        description: |
62
          Bad request. Possible `error_code` attribute values:
63
64
            * `invalid_query`
62
        schema:
65
        schema:
63
          $ref: "../swagger.yaml#/definitions/error"
66
          $ref: "../swagger.yaml#/definitions/error"
64
      403:
67
      403:
Lines 112-117 Link Here
112
        schema:
115
        schema:
113
          items:
116
          items:
114
            $ref: "../swagger.yaml#/definitions/erm_eholdings_resource"
117
            $ref: "../swagger.yaml#/definitions/erm_eholdings_resource"
118
      "400":
119
        description: Bad request
120
        schema:
121
          $ref: "../swagger.yaml#/definitions/error"
115
      401:
122
      401:
116
        description: Authentication required
123
        description: Authentication required
117
        schema:
124
        schema:
Lines 173-178 Link Here
173
              description: Add or remove this resource from remote holdings
180
              description: Add or remove this resource from remote holdings
174
              type: boolean
181
              type: boolean
175
          additionalProperties: false
182
          additionalProperties: false
183
      "400":
184
        description: Bad request
185
        schema:
186
          $ref: "../swagger.yaml#/definitions/error"
176
      401:
187
      401:
177
        description: Authentication required
188
        description: Authentication required
178
        schema:
189
        schema:
(-)a/api/v1/swagger/paths/erm_eholdings_titles.yaml (-6 / +13 lines)
Lines 167-174 Link Here
167
          items:
167
          items:
168
            $ref: "../swagger.yaml#/definitions/erm_eholdings_title"
168
            $ref: "../swagger.yaml#/definitions/erm_eholdings_title"
169
          type: array
169
          type: array
170
      400:
170
      "400":
171
        description: Bad request
171
        description: |
172
          Bad request. Possible `error_code` attribute values:
173
174
            * `invalid_query`
172
        schema:
175
        schema:
173
          $ref: "../swagger.yaml#/definitions/error"
176
          $ref: "../swagger.yaml#/definitions/error"
174
      403:
177
      403:
Lines 217-223 Link Here
217
          items:
220
          items:
218
            $ref: "../swagger.yaml#/definitions/erm_eholdings_title"
221
            $ref: "../swagger.yaml#/definitions/erm_eholdings_title"
219
      400:
222
      400:
220
        description: Bad parameter
223
        description: Bad request
221
        schema:
224
        schema:
222
          $ref: "../swagger.yaml#/definitions/error"
225
          $ref: "../swagger.yaml#/definitions/error"
223
      401:
226
      401:
Lines 282-287 Link Here
282
        schema:
285
        schema:
283
          items:
286
          items:
284
            $ref: "../swagger.yaml#/definitions/erm_eholdings_title"
287
            $ref: "../swagger.yaml#/definitions/erm_eholdings_title"
288
      "400":
289
        description: Bad request
290
        schema:
291
          $ref: "../swagger.yaml#/definitions/error"
285
      401:
292
      401:
286
        description: Authentication required
293
        description: Authentication required
287
        schema:
294
        schema:
Lines 348-354 Link Here
348
          items:
355
          items:
349
            $ref: "../swagger.yaml#/definitions/erm_eholdings_title"
356
            $ref: "../swagger.yaml#/definitions/erm_eholdings_title"
350
      400:
357
      400:
351
        description: Bad parameter
358
        description: Bad request
352
        schema:
359
        schema:
353
          $ref: "../swagger.yaml#/definitions/error"
360
          $ref: "../swagger.yaml#/definitions/error"
354
      403:
361
      403:
Lines 395-401 Link Here
395
      204:
402
      204:
396
        description: title deleted
403
        description: title deleted
397
      400:
404
      400:
398
        description: title deletion failed
405
        description: Bad request
399
        schema:
406
        schema:
400
          $ref: "../swagger.yaml#/definitions/error"
407
          $ref: "../swagger.yaml#/definitions/error"
401
      401:
408
      401:
Lines 461-467 Link Here
461
              type: string
468
              type: string
462
          additionalProperties: false
469
          additionalProperties: false
463
      400:
470
      400:
464
        description: Bad parameter
471
        description: Bad request
465
        schema:
472
        schema:
466
          $ref: "../swagger.yaml#/definitions/error"
473
          $ref: "../swagger.yaml#/definitions/error"
467
      401:
474
      401:
(-)a/api/v1/swagger/paths/erm_eholdings_titles_resources.yaml (-2 / +5 lines)
Lines 58-65 Link Here
58
          items:
58
          items:
59
            $ref: "../swagger.yaml#/definitions/erm_eholdings_resource"
59
            $ref: "../swagger.yaml#/definitions/erm_eholdings_resource"
60
          type: array
60
          type: array
61
      400:
61
      "400":
62
        description: Bad request
62
        description: |
63
          Bad request. Possible `error_code` attribute values:
64
65
            * `invalid_query`
63
        schema:
66
        schema:
64
          $ref: "../swagger.yaml#/definitions/error"
67
          $ref: "../swagger.yaml#/definitions/error"
65
      403:
68
      403:
(-)a/api/v1/swagger/paths/erm_licenses.yaml (-5 / +12 lines)
Lines 66-73 Link Here
66
          items:
66
          items:
67
            $ref: "../swagger.yaml#/definitions/erm_license"
67
            $ref: "../swagger.yaml#/definitions/erm_license"
68
          type: array
68
          type: array
69
      400:
69
      "400":
70
        description: Bad request
70
        description: |
71
          Bad request. Possible `error_code` attribute values:
72
73
            * `invalid_query`
71
        schema:
74
        schema:
72
          $ref: "../swagger.yaml#/definitions/error"
75
          $ref: "../swagger.yaml#/definitions/error"
73
      403:
76
      403:
Lines 111-117 Link Here
111
          items:
114
          items:
112
            $ref: "../swagger.yaml#/definitions/erm_license"
115
            $ref: "../swagger.yaml#/definitions/erm_license"
113
      400:
116
      400:
114
        description: Bad parameter
117
        description: Bad request
115
        schema:
118
        schema:
116
          $ref: "../swagger.yaml#/definitions/error"
119
          $ref: "../swagger.yaml#/definitions/error"
117
      401:
120
      401:
Lines 177-182 Link Here
177
        schema:
180
        schema:
178
          items:
181
          items:
179
            $ref: "../swagger.yaml#/definitions/erm_license"
182
            $ref: "../swagger.yaml#/definitions/erm_license"
183
      "400":
184
        description: Bad request
185
        schema:
186
          $ref: "../swagger.yaml#/definitions/error"
180
      401:
187
      401:
181
        description: authentication required
188
        description: authentication required
182
        schema:
189
        schema:
Lines 238-244 Link Here
238
          items:
245
          items:
239
            $ref: "../swagger.yaml#/definitions/erm_license"
246
            $ref: "../swagger.yaml#/definitions/erm_license"
240
      400:
247
      400:
241
        description: bad parameter
248
        description: Bad request
242
        schema:
249
        schema:
243
          $ref: "../swagger.yaml#/definitions/error"
250
          $ref: "../swagger.yaml#/definitions/error"
244
      403:
251
      403:
Lines 284-290 Link Here
284
      204:
291
      204:
285
        description: license deleted
292
        description: license deleted
286
      400:
293
      400:
287
        description: license deletion failed
294
        description: Bad request
288
        schema:
295
        schema:
289
          $ref: "../swagger.yaml#/definitions/error"
296
          $ref: "../swagger.yaml#/definitions/error"
290
      401:
297
      401:
(-)a/api/v1/swagger/paths/erm_sushi_services.yaml (-2 / +5 lines)
Lines 21-28 Link Here
21
        schema:
21
        schema:
22
          items:
22
          items:
23
            $ref: "../swagger.yaml#/definitions/erm_sushi_service"
23
            $ref: "../swagger.yaml#/definitions/erm_sushi_service"
24
      400:
24
      "400":
25
        description: Bad request
25
        description: |
26
          Bad request. Possible `error_code` attribute values:
27
28
            * `invalid_query`
26
        schema:
29
        schema:
27
          $ref: "../swagger.yaml#/definitions/error"
30
          $ref: "../swagger.yaml#/definitions/error"
28
      403:
31
      403:
(-)a/api/v1/swagger/paths/erm_usage_data_providers.yaml (-8 / +15 lines)
Lines 107-114 Link Here
107
          items:
107
          items:
108
            $ref: "../swagger.yaml#/definitions/erm_usage_data_provider"
108
            $ref: "../swagger.yaml#/definitions/erm_usage_data_provider"
109
          type: array
109
          type: array
110
      400:
110
      "400":
111
        description: Bad request
111
        description: |
112
          Bad request. Possible `error_code` attribute values:
113
114
            * `invalid_query`
112
        schema:
115
        schema:
113
          $ref: "../swagger.yaml#/definitions/error"
116
          $ref: "../swagger.yaml#/definitions/error"
114
      403:
117
      403:
Lines 152-158 Link Here
152
          items:
155
          items:
153
            $ref: "../swagger.yaml#/definitions/erm_usage_data_provider"
156
            $ref: "../swagger.yaml#/definitions/erm_usage_data_provider"
154
      400:
157
      400:
155
        description: Bad parameter
158
        description: Bad request
156
        schema:
159
        schema:
157
          $ref: "../swagger.yaml#/definitions/error"
160
          $ref: "../swagger.yaml#/definitions/error"
158
      401:
161
      401:
Lines 216-221 Link Here
216
        schema:
219
        schema:
217
          items:
220
          items:
218
            $ref: "../swagger.yaml#/definitions/erm_usage_data_provider"
221
            $ref: "../swagger.yaml#/definitions/erm_usage_data_provider"
222
      "400":
223
        description: Bad request
224
        schema:
225
          $ref: "../swagger.yaml#/definitions/error"
219
      401:
226
      401:
220
        description: authentication required
227
        description: authentication required
221
        schema:
228
        schema:
Lines 273-280 Link Here
273
        schema:
280
        schema:
274
          items:
281
          items:
275
            $ref: "../swagger.yaml#/definitions/erm_usage_data_provider"
282
            $ref: "../swagger.yaml#/definitions/erm_usage_data_provider"
276
      400:
283
      "400":
277
        description: bad parameter
284
        description: Bad request
278
        schema:
285
        schema:
279
          $ref: "../swagger.yaml#/definitions/error"
286
          $ref: "../swagger.yaml#/definitions/error"
280
      403:
287
      403:
Lines 319-326 Link Here
319
    responses:
326
    responses:
320
      204:
327
      204:
321
        description: usage_data_provider deleted
328
        description: usage_data_provider deleted
322
      400:
329
      "400":
323
        description: usage_data_provider deletion failed
330
        description: Bad request
324
        schema:
331
        schema:
325
          $ref: "../swagger.yaml#/definitions/error"
332
          $ref: "../swagger.yaml#/definitions/error"
326
      401:
333
      401:
Lines 491-494 Link Here
491
          $ref: "../swagger.yaml#/definitions/error"
498
          $ref: "../swagger.yaml#/definitions/error"
492
    x-koha-authorization:
499
    x-koha-authorization:
493
      permissions:
500
      permissions:
494
        erm: 1
501
        erm: 1
(-)a/api/v1/swagger/paths/erm_usage_databases.yaml (-3 / +6 lines)
Lines 64-71 Link Here
64
          items:
64
          items:
65
            $ref: "../swagger.yaml#/definitions/erm_usage_database"
65
            $ref: "../swagger.yaml#/definitions/erm_usage_database"
66
          type: array
66
          type: array
67
      400:
67
      "400":
68
        description: Bad request
68
        description: |
69
          Bad request. Possible `error_code` attribute values:
70
71
            * `invalid_query`
69
        schema:
72
        schema:
70
          $ref: "../swagger.yaml#/definitions/error"
73
          $ref: "../swagger.yaml#/definitions/error"
71
      403:
74
      403:
Lines 84-87 Link Here
84
          $ref: "../swagger.yaml#/definitions/error"
87
          $ref: "../swagger.yaml#/definitions/error"
85
    x-koha-authorization:
88
    x-koha-authorization:
86
      permissions:
89
      permissions:
87
        erm: 1
90
        erm: 1
(-)a/api/v1/swagger/paths/erm_usage_items.yaml (-3 / +6 lines)
Lines 59-66 Link Here
59
          items:
59
          items:
60
            $ref: "../swagger.yaml#/definitions/erm_usage_item"
60
            $ref: "../swagger.yaml#/definitions/erm_usage_item"
61
          type: array
61
          type: array
62
      400:
62
      "400":
63
        description: Bad request
63
        description: |
64
          Bad request. Possible `error_code` attribute values:
65
66
            * `invalid_query`
64
        schema:
67
        schema:
65
          $ref: "../swagger.yaml#/definitions/error"
68
          $ref: "../swagger.yaml#/definitions/error"
66
      403:
69
      403:
Lines 79-82 Link Here
79
          $ref: "../swagger.yaml#/definitions/error"
82
          $ref: "../swagger.yaml#/definitions/error"
80
    x-koha-authorization:
83
    x-koha-authorization:
81
      permissions:
84
      permissions:
82
        erm: 1
85
        erm: 1
(-)a/api/v1/swagger/paths/erm_usage_platforms.yaml (-3 / +6 lines)
Lines 49-56 Link Here
49
          items:
49
          items:
50
            $ref: "../swagger.yaml#/definitions/erm_usage_platform"
50
            $ref: "../swagger.yaml#/definitions/erm_usage_platform"
51
          type: array
51
          type: array
52
      400:
52
      "400":
53
        description: Bad request
53
        description: |
54
          Bad request. Possible `error_code` attribute values:
55
56
            * `invalid_query`
54
        schema:
57
        schema:
55
          $ref: "../swagger.yaml#/definitions/error"
58
          $ref: "../swagger.yaml#/definitions/error"
56
      403:
59
      403:
Lines 69-72 Link Here
69
          $ref: "../swagger.yaml#/definitions/error"
72
          $ref: "../swagger.yaml#/definitions/error"
70
    x-koha-authorization:
73
    x-koha-authorization:
71
      permissions:
74
      permissions:
72
        erm: 1
75
        erm: 1
(-)a/api/v1/swagger/paths/erm_usage_titles.yaml (-2 / +5 lines)
Lines 89-96 Link Here
89
          items:
89
          items:
90
            $ref: "../swagger.yaml#/definitions/erm_usage_title"
90
            $ref: "../swagger.yaml#/definitions/erm_usage_title"
91
          type: array
91
          type: array
92
      400:
92
      "400":
93
        description: Bad request
93
        description: |
94
          Bad request. Possible `error_code` attribute values:
95
96
            * `invalid_query`
94
        schema:
97
        schema:
95
          $ref: "../swagger.yaml#/definitions/error"
98
          $ref: "../swagger.yaml#/definitions/error"
96
      403:
99
      403:
(-)a/api/v1/swagger/paths/erm_users.yaml (-2 / +5 lines)
Lines 33-40 Link Here
33
          type: array
33
          type: array
34
          items:
34
          items:
35
            $ref: "../swagger.yaml#/definitions/patron"
35
            $ref: "../swagger.yaml#/definitions/patron"
36
      400:
36
      "400":
37
        description: Bad request
37
        description: |
38
          Bad request. Possible `error_code` attribute values:
39
40
            * `invalid_query`
38
        schema:
41
        schema:
39
          $ref: "../swagger.yaml#/definitions/error"
42
          $ref: "../swagger.yaml#/definitions/error"
40
      403:
43
      403:
(-)a/api/v1/swagger/paths/holds.yaml (-7 / +25 lines)
Lines 112-117 Link Here
112
        description: A list of holds
112
        description: A list of holds
113
        schema:
113
        schema:
114
          $ref: "../swagger.yaml#/definitions/holds"
114
          $ref: "../swagger.yaml#/definitions/holds"
115
      "400":
116
        description: |
117
          Bad request. Possible `error_code` attribute values:
118
119
            * `invalid_query`
120
        schema:
121
          $ref: "../swagger.yaml#/definitions/error"
115
      "401":
122
      "401":
116
        description: Authentication required
123
        description: Authentication required
117
        schema:
124
        schema:
Lines 224-230 Link Here
224
        schema:
231
        schema:
225
          $ref: "../swagger.yaml#/definitions/hold"
232
          $ref: "../swagger.yaml#/definitions/hold"
226
      "400":
233
      "400":
227
        description: Missing or wrong parameters
234
        description: Bad request
228
        schema:
235
        schema:
229
          $ref: "../swagger.yaml#/definitions/error"
236
          $ref: "../swagger.yaml#/definitions/error"
230
      "401":
237
      "401":
Lines 291-297 Link Here
291
        schema:
298
        schema:
292
          $ref: "../swagger.yaml#/definitions/hold"
299
          $ref: "../swagger.yaml#/definitions/hold"
293
      "400":
300
      "400":
294
        description: Missing or wrong parameters
301
        description: Bad request
295
        schema:
302
        schema:
296
          $ref: "../swagger.yaml#/definitions/error"
303
          $ref: "../swagger.yaml#/definitions/error"
297
      "401":
304
      "401":
Lines 359-365 Link Here
359
        schema:
366
        schema:
360
          $ref: "../swagger.yaml#/definitions/hold"
367
          $ref: "../swagger.yaml#/definitions/hold"
361
      "400":
368
      "400":
362
        description: Missing or wrong parameters
369
        description: Bad request
363
        schema:
370
        schema:
364
          $ref: "../swagger.yaml#/definitions/error"
371
          $ref: "../swagger.yaml#/definitions/error"
365
      "401":
372
      "401":
Lines 413-418 Link Here
413
        description: Hold request recorded
420
        description: Hold request recorded
414
      "204":
421
      "204":
415
        description: Hold deleted
422
        description: Hold deleted
423
      "400":
424
        description: Bad request
425
        schema:
426
          $ref: "../swagger.yaml#/definitions/error"
416
      "401":
427
      "401":
417
        description: Authentication required
428
        description: Authentication required
418
        schema:
429
        schema:
Lines 461-466 Link Here
461
        description: The new priority value for the hold
472
        description: The new priority value for the hold
462
        schema:
473
        schema:
463
          type: integer
474
          type: integer
475
      "400":
476
        description: Bad request
477
        schema:
478
          $ref: "../swagger.yaml#/definitions/error"
464
      "401":
479
      "401":
465
        description: Authentication required
480
        description: Authentication required
466
        schema:
481
        schema:
Lines 520-526 Link Here
520
      "201":
535
      "201":
521
        description: Hold suspended
536
        description: Hold suspended
522
      "400":
537
      "400":
523
        description: Missing or wrong parameters
538
        description: Bad request
524
        schema:
539
        schema:
525
          $ref: "../swagger.yaml#/definitions/error"
540
          $ref: "../swagger.yaml#/definitions/error"
526
      "401":
541
      "401":
Lines 565-571 Link Here
565
      "204":
580
      "204":
566
        description: Hold resumed
581
        description: Hold resumed
567
      "400":
582
      "400":
568
        description: Missing or wrong parameters
583
        description: Bad request
569
        schema:
584
        schema:
570
          $ref: "../swagger.yaml#/definitions/error"
585
          $ref: "../swagger.yaml#/definitions/error"
571
      "401":
586
      "401":
Lines 630-636 Link Here
630
          items:
645
          items:
631
            $ref: "../swagger.yaml#/definitions/library"
646
            $ref: "../swagger.yaml#/definitions/library"
632
      "400":
647
      "400":
633
        description: Missing or wrong parameters
648
        description: |
649
          Bad request. Possible `error_code` attribute values:
650
651
            * `invalid_query`
634
        schema:
652
        schema:
635
          $ref: "../swagger.yaml#/definitions/error"
653
          $ref: "../swagger.yaml#/definitions/error"
636
      "401":
654
      "401":
Lines 693-699 Link Here
693
              description: Internal identifier for the pickup library
711
              description: Internal identifier for the pickup library
694
          additionalProperties: false
712
          additionalProperties: false
695
      "400":
713
      "400":
696
        description: Missing or wrong parameters
714
        description: Bad request
697
        schema:
715
        schema:
698
          $ref: "../swagger.yaml#/definitions/error"
716
          $ref: "../swagger.yaml#/definitions/error"
699
      "401":
717
      "401":
(-)a/api/v1/swagger/paths/ill_backends.yaml (-1 / +9 lines)
Lines 14-19 Link Here
14
        description: A list of ILL backends
14
        description: A list of ILL backends
15
        schema:
15
        schema:
16
          $ref: "../swagger.yaml#/definitions/ill_backends"
16
          $ref: "../swagger.yaml#/definitions/ill_backends"
17
      "400":
18
        description: Bad request
19
        schema:
20
          $ref: "../swagger.yaml#/definitions/error"
17
      "401":
21
      "401":
18
        description: Authentication required
22
        description: Authentication required
19
        schema:
23
        schema:
Lines 70-75 Link Here
70
        description: An ILL backends
74
        description: An ILL backends
71
        schema:
75
        schema:
72
          $ref: "../swagger.yaml#/definitions/ill_backend"
76
          $ref: "../swagger.yaml#/definitions/ill_backend"
77
      "400":
78
        description: Bad request
79
        schema:
80
          $ref: "../swagger.yaml#/definitions/error"
73
      "401":
81
      "401":
74
        description: Authentication required
82
        description: Authentication required
75
        schema:
83
        schema:
Lines 95-98 Link Here
95
          $ref: "../swagger.yaml#/definitions/error"
103
          $ref: "../swagger.yaml#/definitions/error"
96
    x-koha-authorization:
104
    x-koha-authorization:
97
      permissions:
105
      permissions:
98
        ill: "1"
106
        ill: "1"
(-)a/api/v1/swagger/paths/ill_batches.yaml (+18 lines)
Lines 35-40 Link Here
35
        description: A list of ILL batches
35
        description: A list of ILL batches
36
        schema:
36
        schema:
37
          $ref: "../swagger.yaml#/definitions/ill_batches"
37
          $ref: "../swagger.yaml#/definitions/ill_batches"
38
      "400":
39
        description: |
40
          Bad request. Possible `error_code` attribute values:
41
42
            * `invalid_query`
43
        schema:
44
          $ref: "../swagger.yaml#/definitions/error"
38
      "401":
45
      "401":
39
        description: Authentication required
46
        description: Authentication required
40
        schema:
47
        schema:
Lines 170-175 Link Here
170
        description: An ILL batch
177
        description: An ILL batch
171
        schema:
178
        schema:
172
          $ref: "../swagger.yaml#/definitions/ill_batch"
179
          $ref: "../swagger.yaml#/definitions/ill_batch"
180
      "400":
181
        description: |
182
          Bad request. Possible `error_code` attribute values:
183
184
            * `invalid_query`
185
        schema:
186
          $ref: "../swagger.yaml#/definitions/error"
173
      "401":
187
      "401":
174
        description: Authentication required
188
        description: Authentication required
175
        schema:
189
        schema:
Lines 264-269 Link Here
264
        description: ILL batch deleted
278
        description: ILL batch deleted
265
        schema:
279
        schema:
266
          type: string
280
          type: string
281
      "400":
282
        description: Bad request
283
        schema:
284
          $ref: "../swagger.yaml#/definitions/error"
267
      "401":
285
      "401":
268
        description: Authentication required
286
        description: Authentication required
269
        schema:
287
        schema:
(-)a/api/v1/swagger/paths/ill_batchstatuses.yaml (+12 lines)
Lines 14-19 Link Here
14
        description: A list of ILL batch statuses
14
        description: A list of ILL batch statuses
15
        schema:
15
        schema:
16
          $ref: "../swagger.yaml#/definitions/ill_batchstatuses"
16
          $ref: "../swagger.yaml#/definitions/ill_batchstatuses"
17
      "400":
18
        description: Bad request
19
        schema:
20
          $ref: "../swagger.yaml#/definitions/error"
17
      "401":
21
      "401":
18
        description: Authentication required
22
        description: Authentication required
19
        schema:
23
        schema:
Lines 110-115 Link Here
110
        description: An ILL batch status
114
        description: An ILL batch status
111
        schema:
115
        schema:
112
          $ref: "../swagger.yaml#/definitions/ill_batchstatus"
116
          $ref: "../swagger.yaml#/definitions/ill_batchstatus"
117
      "400":
118
        description: Bad request
119
        schema:
120
          $ref: "../swagger.yaml#/definitions/error"
113
      "401":
121
      "401":
114
        description: Authentication required
122
        description: Authentication required
115
        schema:
123
        schema:
Lines 204-209 Link Here
204
        description: ILL batch status deleted
212
        description: ILL batch status deleted
205
        schema:
213
        schema:
206
          type: string
214
          type: string
215
      "400":
216
        description: Bad request
217
        schema:
218
          $ref: "../swagger.yaml#/definitions/error"
207
      "401":
219
      "401":
208
        description: Authentication required
220
        description: Authentication required
209
        schema:
221
        schema:
(-)a/api/v1/swagger/paths/ill_requests.yaml (+7 lines)
Lines 41-46 Link Here
41
          type: array
41
          type: array
42
          items:
42
          items:
43
            $ref: "../swagger.yaml#/definitions/ill_request"
43
            $ref: "../swagger.yaml#/definitions/ill_request"
44
      "400":
45
        description: |
46
          Bad request. Possible `error_code` attribute values:
47
48
            * `invalid_query`
49
        schema:
50
          $ref: "../swagger.yaml#/definitions/error"
44
      "403":
51
      "403":
45
        description: Access forbidden
52
        description: Access forbidden
46
        schema:
53
        schema:
(-)a/api/v1/swagger/paths/import_batch_profiles.yaml (-2 / +13 lines)
Lines 28-33 Link Here
28
        description: A list of import batch profiles
28
        description: A list of import batch profiles
29
        schema:
29
        schema:
30
          $ref: "../swagger.yaml#/definitions/import_batch_profiles"
30
          $ref: "../swagger.yaml#/definitions/import_batch_profiles"
31
      "400":
32
        description: |
33
          Bad request. Possible `error_code` attribute values:
34
35
            * `invalid_query`
36
        schema:
37
          $ref: "../swagger.yaml#/definitions/error"
31
      "401":
38
      "401":
32
        description: Authentication required
39
        description: Authentication required
33
        schema:
40
        schema:
Lines 128-134 Link Here
128
        schema:
135
        schema:
129
          $ref: "../swagger.yaml#/definitions/import_batch_profile"
136
          $ref: "../swagger.yaml#/definitions/import_batch_profile"
130
      "400":
137
      "400":
131
        description: Missing or wrong parameters
138
        description: Bad request
132
        schema:
139
        schema:
133
          $ref: "../swagger.yaml#/definitions/error"
140
          $ref: "../swagger.yaml#/definitions/error"
134
      "401":
141
      "401":
Lines 237-243 Link Here
237
        schema:
244
        schema:
238
          $ref: "../swagger.yaml#/definitions/import_batch_profile"
245
          $ref: "../swagger.yaml#/definitions/import_batch_profile"
239
      "400":
246
      "400":
240
        description: Missing or wrong parameters
247
        description: Bad request
241
        schema:
248
        schema:
242
          $ref: "../swagger.yaml#/definitions/error"
249
          $ref: "../swagger.yaml#/definitions/error"
243
      "401":
250
      "401":
Lines 279-284 Link Here
279
    responses:
286
    responses:
280
      "204":
287
      "204":
281
        description: Profile deleted
288
        description: Profile deleted
289
      "400":
290
        description: Bad request
291
        schema:
292
          $ref: "../swagger.yaml#/definitions/error"
282
      "401":
293
      "401":
283
        description: Authentication required
294
        description: Authentication required
284
        schema:
295
        schema:
(-)a/api/v1/swagger/paths/import_batches.yaml (-1 / +5 lines)
Lines 36-42 Link Here
36
      "200":
36
      "200":
37
        description: Match updated
37
        description: Match updated
38
      "400":
38
      "400":
39
        description: Missing or wrong parameters
39
        description: Bad request
40
        schema:
40
        schema:
41
          $ref: "../swagger.yaml#/definitions/error"
41
          $ref: "../swagger.yaml#/definitions/error"
42
      "401":
42
      "401":
Lines 87-92 Link Here
87
    responses:
87
    responses:
88
      "204":
88
      "204":
89
        description: Matches unchosen
89
        description: Matches unchosen
90
      "400":
91
        description: Bad request
92
        schema:
93
          $ref: "../swagger.yaml#/definitions/error"
90
      "401":
94
      "401":
91
        description: Authentication required
95
        description: Authentication required
92
        schema:
96
        schema:
(-)a/api/v1/swagger/paths/item_types.yaml (-2 / +5 lines)
Lines 32-39 Link Here
32
          items:
32
          items:
33
            $ref: "../swagger.yaml#/definitions/item_type"
33
            $ref: "../swagger.yaml#/definitions/item_type"
34
          type: array
34
          type: array
35
      400:
35
      "400":
36
        description: Bad request
36
        description: |
37
          Bad request. Possible `error_code` attribute values:
38
39
            * `invalid_query`
37
        schema:
40
        schema:
38
          $ref: "../swagger.yaml#/definitions/error"
41
          $ref: "../swagger.yaml#/definitions/error"
39
      403:
42
      403:
(-)a/api/v1/swagger/paths/items.yaml (-7 / +34 lines)
Lines 41-46 Link Here
41
          type: array
41
          type: array
42
          items:
42
          items:
43
            $ref: "../swagger.yaml#/definitions/item"
43
            $ref: "../swagger.yaml#/definitions/item"
44
      "400":
45
        description: |
46
          Bad request. Possible `error_code` attribute values:
47
48
            * `invalid_query`
49
        schema:
50
          $ref: "../swagger.yaml#/definitions/error"
44
      "401":
51
      "401":
45
        description: Authentication required
52
        description: Authentication required
46
        schema:
53
        schema:
Lines 92-98 Link Here
92
        schema:
99
        schema:
93
          $ref: "../swagger.yaml#/definitions/item"
100
          $ref: "../swagger.yaml#/definitions/item"
94
      "400":
101
      "400":
95
        description: Missing or wrong parameters
102
        description: Bad request
96
        schema:
103
        schema:
97
          $ref: "../swagger.yaml#/definitions/error"
104
          $ref: "../swagger.yaml#/definitions/error"
98
      "404":
105
      "404":
Lines 129-135 Link Here
129
      "204":
136
      "204":
130
        description: Deleted item
137
        description: Deleted item
131
      "400":
138
      "400":
132
        description: Missing or wrong parameters
139
        description: Bad request
133
        schema:
140
        schema:
134
          $ref: "../swagger.yaml#/definitions/error"
141
          $ref: "../swagger.yaml#/definitions/error"
135
      "403":
142
      "403":
Lines 191-197 Link Here
191
          items:
198
          items:
192
            $ref: "../swagger.yaml#/definitions/item"
199
            $ref: "../swagger.yaml#/definitions/item"
193
      "400":
200
      "400":
194
        description: Bad parameter
201
        description: Bad request
195
        schema:
202
        schema:
196
          $ref: "../swagger.yaml#/definitions/error"
203
          $ref: "../swagger.yaml#/definitions/error"
197
      "401":
204
      "401":
Lines 265-270 Link Here
265
          type: array
272
          type: array
266
          items:
273
          items:
267
            $ref: "../swagger.yaml#/definitions/item"
274
            $ref: "../swagger.yaml#/definitions/item"
275
      "400":
276
        description: |
277
          Bad request. Possible `error_code` attribute values:
278
279
            * `invalid_query`
280
        schema:
281
          $ref: "../swagger.yaml#/definitions/error"
268
      "401":
282
      "401":
269
        description: Authentication required
283
        description: Authentication required
270
        schema:
284
        schema:
Lines 306-312 Link Here
306
      "204":
320
      "204":
307
        description: Bundle link deleted
321
        description: Bundle link deleted
308
      "400":
322
      "400":
309
        description: Bad parameter
323
        description: Bad request
310
        schema:
324
        schema:
311
          $ref: "../swagger.yaml#/definitions/error"
325
          $ref: "../swagger.yaml#/definitions/error"
312
      "409":
326
      "409":
Lines 363-371 Link Here
363
          items:
377
          items:
364
            $ref: ../swagger.yaml#/definitions/booking
378
            $ref: ../swagger.yaml#/definitions/booking
365
      "400":
379
      "400":
366
        description: Missing or wrong parameters
380
        description: |
381
          Bad request. Possible `error_code` attribute values:
382
383
            * `invalid_query`
367
        schema:
384
        schema:
368
          $ref: ../swagger.yaml#/definitions/error
385
          $ref: "../swagger.yaml#/definitions/error"
369
      "401":
386
      "401":
370
        description: Authentication required
387
        description: Authentication required
371
        schema:
388
        schema:
Lines 422-428 Link Here
422
          items:
439
          items:
423
            $ref: "../swagger.yaml#/definitions/library"
440
            $ref: "../swagger.yaml#/definitions/library"
424
      "400":
441
      "400":
425
        description: Missing or wrong parameters
442
        description: |
443
          Bad request. Possible `error_code` attribute values:
444
445
            * `invalid_query`
426
        schema:
446
        schema:
427
          $ref: "../swagger.yaml#/definitions/error"
447
          $ref: "../swagger.yaml#/definitions/error"
428
      "401":
448
      "401":
Lines 493-498 Link Here
493
          type: array
513
          type: array
494
          items:
514
          items:
495
            $ref: "../swagger.yaml#/definitions/item"
515
            $ref: "../swagger.yaml#/definitions/item"
516
      "400":
517
        description: |
518
          Bad request. Possible `error_code` attribute values:
519
520
            * `invalid_query`
521
        schema:
522
          $ref: "../swagger.yaml#/definitions/error"
496
      "401":
523
      "401":
497
        description: Authentication required
524
        description: Authentication required
498
        schema:
525
        schema:
(-)a/api/v1/swagger/paths/jobs.yaml (+11 lines)
Lines 28-33 Link Here
28
          type: array
28
          type: array
29
          items:
29
          items:
30
            $ref: "../swagger.yaml#/definitions/job"
30
            $ref: "../swagger.yaml#/definitions/job"
31
      "400":
32
        description: |
33
          Bad request. Possible `error_code` attribute values:
34
35
            * `invalid_query`
36
        schema:
37
          $ref: "../swagger.yaml#/definitions/error"
31
      "403":
38
      "403":
32
        description: Access forbidden
39
        description: Access forbidden
33
        schema:
40
        schema:
Lines 62-67 Link Here
62
        description: A job
69
        description: A job
63
        schema:
70
        schema:
64
          $ref: "../swagger.yaml#/definitions/job"
71
          $ref: "../swagger.yaml#/definitions/job"
72
      "400":
73
        description: Bad request
74
        schema:
75
          $ref: "../swagger.yaml#/definitions/error"
65
      "403":
76
      "403":
66
        description: Access forbidden
77
        description: Access forbidden
67
        schema:
78
        schema:
(-)a/api/v1/swagger/paths/libraries.yaml (+40 lines)
Lines 115-120 Link Here
115
          type: array
115
          type: array
116
          items:
116
          items:
117
            $ref: "../swagger.yaml#/definitions/library"
117
            $ref: "../swagger.yaml#/definitions/library"
118
      "400":
119
        description: |
120
          Bad request. Possible `error_code` attribute values:
121
122
            * `invalid_query`
123
        schema:
124
          $ref: "../swagger.yaml#/definitions/error"
118
      "500":
125
      "500":
119
        description: |
126
        description: |
120
          Internal server error. Possible `error_code` attribute values:
127
          Internal server error. Possible `error_code` attribute values:
Lines 207-212 Link Here
207
        description: A library
214
        description: A library
208
        schema:
215
        schema:
209
          $ref: "../swagger.yaml#/definitions/library"
216
          $ref: "../swagger.yaml#/definitions/library"
217
      "400":
218
        description: Bad request
219
        schema:
220
          $ref: "../swagger.yaml#/definitions/error"
210
      "404":
221
      "404":
211
        description: Library not found
222
        description: Library not found
212
        schema:
223
        schema:
Lines 282-287 Link Here
282
        description: Library deleted
293
        description: Library deleted
283
        schema:
294
        schema:
284
          type: string
295
          type: string
296
      "400":
297
        description: Bad request
298
        schema:
299
          $ref: "../swagger.yaml#/definitions/error"
285
      "401":
300
      "401":
286
        description: Authentication required
301
        description: Authentication required
287
        schema:
302
        schema:
Lines 332-337 Link Here
332
          type: array
347
          type: array
333
          items:
348
          items:
334
            $ref: "../swagger.yaml#/definitions/desk"
349
            $ref: "../swagger.yaml#/definitions/desk"
350
      "400":
351
        description: |
352
          Bad request. Possible `error_code` attribute values:
353
354
            * `invalid_query`
355
        schema:
356
          $ref: "../swagger.yaml#/definitions/error"
335
      404:
357
      404:
336
        description: Resource not found
358
        description: Resource not found
337
        schema:
359
        schema:
Lines 374-379 Link Here
374
          type: array
396
          type: array
375
          items:
397
          items:
376
            $ref: "../swagger.yaml#/definitions/cash_register"
398
            $ref: "../swagger.yaml#/definitions/cash_register"
399
      "400":
400
        description: |
401
          Bad request. Possible `error_code` attribute values:
402
403
            * `invalid_query`
404
        schema:
405
          $ref: "../swagger.yaml#/definitions/error"
377
      404:
406
      404:
378
        description: Resource not found
407
        description: Resource not found
379
        schema:
408
        schema:
Lines 416-421 Link Here
416
          type: array
445
          type: array
417
          items:
446
          items:
418
            $ref: "../swagger.yaml#/definitions/library"
447
            $ref: "../swagger.yaml#/definitions/library"
448
      "400":
449
        description: |
450
          Bad request. Possible `error_code` attribute values:
451
452
            * `invalid_query`
453
        schema:
454
          $ref: "../swagger.yaml#/definitions/error"
419
      "500":
455
      "500":
420
        description: |
456
        description: |
421
          Internal server error. Possible `error_code` attribute values:
457
          Internal server error. Possible `error_code` attribute values:
Lines 441-446 Link Here
441
    responses:
477
    responses:
442
      "200":
478
      "200":
443
        description: A library
479
        description: A library
480
      "400":
481
        description: Bad request
482
        schema:
483
          $ref: "../swagger.yaml#/definitions/error"
444
      "401":
484
      "401":
445
        description: Authentication required
485
        description: Authentication required
446
        schema:
486
        schema:
(-)a/api/v1/swagger/paths/oauth.yaml (-2 / +2 lines)
Lines 36-42 Link Here
36
              type: integer
36
              type: integer
37
          additionalProperties: false
37
          additionalProperties: false
38
      "400":
38
      "400":
39
        description: Bad Request
39
        description: Bad request
40
        schema:
40
        schema:
41
          $ref: "../swagger.yaml#/definitions/error"
41
          $ref: "../swagger.yaml#/definitions/error"
42
      "403":
42
      "403":
Lines 108-114 Link Here
108
        schema:
108
        schema:
109
          type: string
109
          type: string
110
      "400":
110
      "400":
111
        description: Bad Request
111
        description: Bad request
112
        schema:
112
        schema:
113
          $ref: ../swagger.yaml#/definitions/error
113
          $ref: ../swagger.yaml#/definitions/error
114
      "403":
114
      "403":
(-)a/api/v1/swagger/paths/patron_categories.yaml (+7 lines)
Lines 23-28 Link Here
23
          type: array
23
          type: array
24
          items:
24
          items:
25
            $ref: "../swagger.yaml#/definitions/patron_category"
25
            $ref: "../swagger.yaml#/definitions/patron_category"
26
      "400":
27
        description: |
28
          Bad request. Possible `error_code` attribute values:
29
30
            * `invalid_query`
31
        schema:
32
          $ref: "../swagger.yaml#/definitions/error"
26
      "401":
33
      "401":
27
        description: Authentication required
34
        description: Authentication required
28
        schema:
35
        schema:
(-)a/api/v1/swagger/paths/patrons.yaml (-3 / +26 lines)
Lines 372-377 Link Here
372
          type: array
372
          type: array
373
          items:
373
          items:
374
            $ref: "../swagger.yaml#/definitions/patron"
374
            $ref: "../swagger.yaml#/definitions/patron"
375
      "400":
376
        description: |
377
          Bad request. Possible `error_code` attribute values:
378
379
            * `invalid_query`
380
        schema:
381
          $ref: "../swagger.yaml#/definitions/error"
375
      "401":
382
      "401":
376
        description: Authentication required
383
        description: Authentication required
377
        schema:
384
        schema:
Lines 434-440 Link Here
434
          items:
441
          items:
435
            $ref: "../swagger.yaml#/definitions/patron"
442
            $ref: "../swagger.yaml#/definitions/patron"
436
      "400":
443
      "400":
437
        description: Bad parameter
444
        description: |
445
          Bad request. Possible `error_code` attribute values:
446
447
            * `invalid_attribute_type`
448
            * `attribute_not_unique`
449
            * `non_repeatable_attribute`
450
            * `missing_mandatory_attribute`
438
        schema:
451
        schema:
439
          $ref: "../swagger.yaml#/definitions/error"
452
          $ref: "../swagger.yaml#/definitions/error"
440
      "401":
453
      "401":
Lines 494-499 Link Here
494
        description: A patron
507
        description: A patron
495
        schema:
508
        schema:
496
          $ref: "../swagger.yaml#/definitions/patron"
509
          $ref: "../swagger.yaml#/definitions/patron"
510
      "400":
511
        description: Bad request
512
        schema:
513
          $ref: "../swagger.yaml#/definitions/error"
497
      "401":
514
      "401":
498
        description: Authentication required
515
        description: Authentication required
499
        schema:
516
        schema:
Lines 546-552 Link Here
546
          items:
563
          items:
547
            $ref: "../swagger.yaml#/definitions/patron"
564
            $ref: "../swagger.yaml#/definitions/patron"
548
      "400":
565
      "400":
549
        description: Bad parameter
566
        description: |
567
          Bad request. Possible `error_code` attribute values:
568
569
            * `invalid_attribute_type`
570
            * `attribute_not_unique`
571
            * `non_repeatable_attribute`
572
            * `missing_mandatory_attribute`
550
        schema:
573
        schema:
551
          $ref: "../swagger.yaml#/definitions/error"
574
          $ref: "../swagger.yaml#/definitions/error"
552
      "403":
575
      "403":
Lines 589-595 Link Here
589
      "204":
612
      "204":
590
        description: Patron deleted
613
        description: Patron deleted
591
      "400":
614
      "400":
592
        description: Patron deletion failed
615
        description: Bad request
593
        schema:
616
        schema:
594
          $ref: "../swagger.yaml#/definitions/error"
617
          $ref: "../swagger.yaml#/definitions/error"
595
      "401":
618
      "401":
(-)a/api/v1/swagger/paths/patrons_account.yaml (-1 / +23 lines)
Lines 15-20 Link Here
15
        description: Patron's account balance
15
        description: Patron's account balance
16
        schema:
16
        schema:
17
          $ref: "../swagger.yaml#/definitions/patron_balance"
17
          $ref: "../swagger.yaml#/definitions/patron_balance"
18
      "400":
19
        description: Bad request
20
        schema:
21
          $ref: "../swagger.yaml#/definitions/error"
18
      "401":
22
      "401":
19
        description: Authentication required
23
        description: Authentication required
20
        schema:
24
        schema:
Lines 66-71 Link Here
66
          type: array
70
          type: array
67
          items:
71
          items:
68
            $ref: "../swagger.yaml#/definitions/credit"
72
            $ref: "../swagger.yaml#/definitions/credit"
73
      "400":
74
        description: |
75
          Bad request. Possible `error_code` attribute values:
76
77
            * `invalid_query`
78
        schema:
79
          $ref: "../swagger.yaml#/definitions/error"
69
      "403":
80
      "403":
70
        description: Access forbidden
81
        description: Access forbidden
71
        schema:
82
        schema:
Lines 103-108 Link Here
103
        description: Credit added
114
        description: Credit added
104
        schema:
115
        schema:
105
          $ref: "../swagger.yaml#/definitions/account_line"
116
          $ref: "../swagger.yaml#/definitions/account_line"
117
      "400":
118
        description: Bad request
119
        schema:
120
          $ref: "../swagger.yaml#/definitions/error"
106
      "401":
121
      "401":
107
        description: Authentication required
122
        description: Authentication required
108
        schema:
123
        schema:
Lines 153-158 Link Here
153
          type: array
168
          type: array
154
          items:
169
          items:
155
            $ref: "../swagger.yaml#/definitions/debit"
170
            $ref: "../swagger.yaml#/definitions/debit"
171
      "400":
172
        description: |
173
          Bad request. Possible `error_code` attribute values:
174
175
            * `invalid_query`
176
        schema:
177
          $ref: "../swagger.yaml#/definitions/error"
156
      "403":
178
      "403":
157
        description: Access forbidden
179
        description: Access forbidden
158
        schema:
180
        schema:
Lines 195-201 Link Here
195
        schema:
217
        schema:
196
          $ref: "../swagger.yaml#/definitions/debit"
218
          $ref: "../swagger.yaml#/definitions/debit"
197
      "400":
219
      "400":
198
        description: Bad parameter
220
        description: Bad request
199
        schema:
221
        schema:
200
          $ref: "../swagger.yaml#/definitions/error"
222
          $ref: "../swagger.yaml#/definitions/error"
201
      "401":
223
      "401":
(-)a/api/v1/swagger/paths/patrons_checkouts.yaml (+7 lines)
Lines 34-39 Link Here
34
          type: array
34
          type: array
35
          items:
35
          items:
36
            $ref: "../swagger.yaml#/definitions/checkout"
36
            $ref: "../swagger.yaml#/definitions/checkout"
37
      "400":
38
        description: |
39
          Bad request. Possible `error_code` attribute values:
40
41
            * `invalid_query`
42
        schema:
43
          $ref: "../swagger.yaml#/definitions/error"
37
      "401":
44
      "401":
38
        description: Authentication required
45
        description: Authentication required
39
        schema:
46
        schema:
(-)a/api/v1/swagger/paths/patrons_extended_attributes.yaml (-3 / +14 lines)
Lines 24-29 Link Here
24
          type: array
24
          type: array
25
          items:
25
          items:
26
            $ref: "../swagger.yaml#/definitions/patron_extended_attribute"
26
            $ref: "../swagger.yaml#/definitions/patron_extended_attribute"
27
      "400":
28
        description: |
29
          Bad request. Possible `error_code` attribute values:
30
31
            * `invalid_query`
32
        schema:
33
          $ref: "../swagger.yaml#/definitions/error"
27
      "401":
34
      "401":
28
        description: Authentication required
35
        description: Authentication required
29
        schema:
36
        schema:
Lines 72-78 Link Here
72
        schema:
79
        schema:
73
          $ref: "../swagger.yaml#/definitions/patron_extended_attribute"
80
          $ref: "../swagger.yaml#/definitions/patron_extended_attribute"
74
      "400":
81
      "400":
75
        description: Bad parameter
82
        description: Bad request
76
        schema:
83
        schema:
77
          $ref: "../swagger.yaml#/definitions/error"
84
          $ref: "../swagger.yaml#/definitions/error"
78
      "401":
85
      "401":
Lines 131-137 Link Here
131
          items:
138
          items:
132
            $ref: "../swagger.yaml#/definitions/patron_extended_attribute"
139
            $ref: "../swagger.yaml#/definitions/patron_extended_attribute"
133
      "400":
140
      "400":
134
        description: Bad parameters
141
        description: Bad request
135
        schema:
142
        schema:
136
          $ref: "../swagger.yaml#/definitions/error"
143
          $ref: "../swagger.yaml#/definitions/error"
137
      "401":
144
      "401":
Lines 198-204 Link Here
198
        schema:
205
        schema:
199
          $ref: "../swagger.yaml#/definitions/patron_extended_attribute"
206
          $ref: "../swagger.yaml#/definitions/patron_extended_attribute"
200
      "400":
207
      "400":
201
        description: Bad parameter
208
        description: Bad request
202
        schema:
209
        schema:
203
          $ref: "../swagger.yaml#/definitions/error"
210
          $ref: "../swagger.yaml#/definitions/error"
204
      "401":
211
      "401":
Lines 249-254 Link Here
249
    responses:
256
    responses:
250
      "204":
257
      "204":
251
        description: Extended patron attribute deleted
258
        description: Extended patron attribute deleted
259
      "400":
260
        description: Bad request
261
        schema:
262
          $ref: "../swagger.yaml#/definitions/error"
252
      "401":
263
      "401":
253
        description: Authentication required
264
        description: Authentication required
254
        schema:
265
        schema:
(-)a/api/v1/swagger/paths/patrons_holds.yaml (+7 lines)
Lines 43-48 Link Here
43
          type: array
43
          type: array
44
          items:
44
          items:
45
            $ref: "../swagger.yaml#/definitions/hold"
45
            $ref: "../swagger.yaml#/definitions/hold"
46
      "400":
47
        description: |
48
          Bad request. Possible `error_code` attribute values:
49
50
            * `invalid_query`
51
        schema:
52
          $ref: "../swagger.yaml#/definitions/error"
46
      "401":
53
      "401":
47
        description: Authentication required
54
        description: Authentication required
48
        schema:
55
        schema:
(-)a/api/v1/swagger/paths/patrons_recalls.yaml (+7 lines)
Lines 24-29 Link Here
24
          type: array
24
          type: array
25
          items:
25
          items:
26
            $ref: "../swagger.yaml#/definitions/recall"
26
            $ref: "../swagger.yaml#/definitions/recall"
27
      "400":
28
        description: |
29
          Bad request. Possible `error_code` attribute values:
30
31
            * `invalid_query`
32
        schema:
33
          $ref: "../swagger.yaml#/definitions/error"
27
      "401":
34
      "401":
28
        description: Authentication required
35
        description: Authentication required
29
        schema:
36
        schema:
(-)a/api/v1/swagger/paths/preservation_processings.yaml (-8 / +15 lines)
Lines 32-39 Link Here
32
          items:
32
          items:
33
            $ref: "../swagger.yaml#/definitions/preservation_processing"
33
            $ref: "../swagger.yaml#/definitions/preservation_processing"
34
          type: array
34
          type: array
35
      400:
35
      "400":
36
        description: Bad request
36
        description: |
37
          Bad request. Possible `error_code` attribute values:
38
39
            * `invalid_query`
37
        schema:
40
        schema:
38
          $ref: "../swagger.yaml#/definitions/error"
41
          $ref: "../swagger.yaml#/definitions/error"
39
      403:
42
      403:
Lines 76-83 Link Here
76
        schema:
79
        schema:
77
          items:
80
          items:
78
            $ref: "../swagger.yaml#/definitions/preservation_processing"
81
            $ref: "../swagger.yaml#/definitions/preservation_processing"
79
      400:
82
      "400":
80
        description: Bad parameter
83
        description: Bad request
81
        schema:
84
        schema:
82
          $ref: "../swagger.yaml#/definitions/error"
85
          $ref: "../swagger.yaml#/definitions/error"
83
      401:
86
      401:
Lines 140-145 Link Here
140
        schema:
143
        schema:
141
          items:
144
          items:
142
            $ref: "../swagger.yaml#/definitions/preservation_processing"
145
            $ref: "../swagger.yaml#/definitions/preservation_processing"
146
      "400":
147
        description: Bad request
148
        schema:
149
          $ref: "../swagger.yaml#/definitions/error"
143
      401:
150
      401:
144
        description: Authentication required
151
        description: Authentication required
145
        schema:
152
        schema:
Lines 190-197 Link Here
190
        schema:
197
        schema:
191
          items:
198
          items:
192
            $ref: "../swagger.yaml#/definitions/preservation_processing"
199
            $ref: "../swagger.yaml#/definitions/preservation_processing"
193
      400:
200
      "400":
194
        description: Bad parameter
201
        description: Bad request
195
        schema:
202
        schema:
196
          $ref: "../swagger.yaml#/definitions/error"
203
          $ref: "../swagger.yaml#/definitions/error"
197
      403:
204
      403:
Lines 236-243 Link Here
236
    responses:
243
    responses:
237
      204:
244
      204:
238
        description: processing deleted
245
        description: processing deleted
239
      400:
246
      "400":
240
        description: processing deletion failed
247
        description: Bad request
241
        schema:
248
        schema:
242
          $ref: "../swagger.yaml#/definitions/error"
249
          $ref: "../swagger.yaml#/definitions/error"
243
      401:
250
      401:
(-)a/api/v1/swagger/paths/preservation_trains.yaml (-17 / +28 lines)
Lines 62-69 Link Here
62
          items:
62
          items:
63
            $ref: "../swagger.yaml#/definitions/preservation_train"
63
            $ref: "../swagger.yaml#/definitions/preservation_train"
64
          type: array
64
          type: array
65
      400:
65
      "400":
66
        description: Bad request
66
        description: |
67
          Bad request. Possible `error_code` attribute values:
68
69
            * `invalid_query`
67
        schema:
70
        schema:
68
          $ref: "../swagger.yaml#/definitions/error"
71
          $ref: "../swagger.yaml#/definitions/error"
69
      403:
72
      403:
Lines 107-114 Link Here
107
        schema:
110
        schema:
108
          items:
111
          items:
109
            $ref: "../swagger.yaml#/definitions/preservation_train"
112
            $ref: "../swagger.yaml#/definitions/preservation_train"
110
      400:
113
      "400":
111
        description: Bad parameter
114
        description: Bad request
112
        schema:
115
        schema:
113
          $ref: "../swagger.yaml#/definitions/error"
116
          $ref: "../swagger.yaml#/definitions/error"
114
      401:
117
      401:
Lines 178-183 Link Here
178
        schema:
181
        schema:
179
          items:
182
          items:
180
            $ref: "../swagger.yaml#/definitions/preservation_train"
183
            $ref: "../swagger.yaml#/definitions/preservation_train"
184
      "400":
185
        description: Bad request
186
        schema:
187
          $ref: "../swagger.yaml#/definitions/error"
181
      401:
188
      401:
182
        description: Authentication required
189
        description: Authentication required
183
        schema:
190
        schema:
Lines 228-235 Link Here
228
        schema:
235
        schema:
229
          items:
236
          items:
230
            $ref: "../swagger.yaml#/definitions/preservation_train"
237
            $ref: "../swagger.yaml#/definitions/preservation_train"
231
      400:
238
      "400":
232
        description: Bad parameter
239
        description: Bad request
233
        schema:
240
        schema:
234
          $ref: "../swagger.yaml#/definitions/error"
241
          $ref: "../swagger.yaml#/definitions/error"
235
      403:
242
      403:
Lines 275-282 Link Here
275
    responses:
282
    responses:
276
      204:
283
      204:
277
        description: Train deleted
284
        description: Train deleted
278
      400:
285
      "400":
279
        description: Train deletion failed
286
        description: Bad request
280
        schema:
287
        schema:
281
          $ref: "../swagger.yaml#/definitions/error"
288
          $ref: "../swagger.yaml#/definitions/error"
282
      401:
289
      401:
Lines 333-340 Link Here
333
        description: A successfully added item
340
        description: A successfully added item
334
        schema:
341
        schema:
335
          $ref: "../swagger.yaml#/definitions/preservation_train_item"
342
          $ref: "../swagger.yaml#/definitions/preservation_train_item"
336
      400:
343
      "400":
337
        description: Bad parameter
344
        description: Bad request
338
        schema:
345
        schema:
339
          $ref: "../swagger.yaml#/definitions/error"
346
          $ref: "../swagger.yaml#/definitions/error"
340
      401:
347
      401:
Lines 399-406 Link Here
399
          type: array
406
          type: array
400
          items:
407
          items:
401
            type: object
408
            type: object
402
      400:
409
      "400":
403
        description: Bad parameter
410
        description: Bad request
404
        schema:
411
        schema:
405
          $ref: "../swagger.yaml#/definitions/error"
412
          $ref: "../swagger.yaml#/definitions/error"
406
      401:
413
      401:
Lines 472-479 Link Here
472
        description: A successfully updated item
479
        description: A successfully updated item
473
        schema:
480
        schema:
474
          $ref: "../swagger.yaml#/definitions/preservation_train_item"
481
          $ref: "../swagger.yaml#/definitions/preservation_train_item"
475
      400:
482
      "400":
476
        description: Bad parameter
483
        description: Bad request
477
        schema:
484
        schema:
478
          $ref: "../swagger.yaml#/definitions/error"
485
          $ref: "../swagger.yaml#/definitions/error"
479
      403:
486
      403:
Lines 521-527 Link Here
521
      "204":
528
      "204":
522
        description: Item removed
529
        description: Item removed
523
      "400":
530
      "400":
524
        description: Item removal failed
531
        description: Bad request
525
        schema:
532
        schema:
526
          $ref: "../swagger.yaml#/definitions/error"
533
          $ref: "../swagger.yaml#/definitions/error"
527
      "401":
534
      "401":
Lines 578-583 Link Here
578
        description: An item in train
585
        description: An item in train
579
        schema:
586
        schema:
580
          $ref: "../swagger.yaml#/definitions/preservation_train_item"
587
          $ref: "../swagger.yaml#/definitions/preservation_train_item"
588
      "400":
589
        description: Bad request
590
        schema:
591
          $ref: "../swagger.yaml#/definitions/error"
581
      401:
592
      401:
582
        description: Authentication required
593
        description: Authentication required
583
        schema:
594
        schema:
Lines 635-642 Link Here
635
        description: A successfully copied item
646
        description: A successfully copied item
636
        schema:
647
        schema:
637
          $ref: "../swagger.yaml#/definitions/preservation_train_item"
648
          $ref: "../swagger.yaml#/definitions/preservation_train_item"
638
      400:
649
      "400":
639
        description: Bad parameter
650
        description: Bad request
640
        schema:
651
        schema:
641
          $ref: "../swagger.yaml#/definitions/error"
652
          $ref: "../swagger.yaml#/definitions/error"
642
      401:
653
      401:
(-)a/api/v1/swagger/paths/preservation_waiting_list.yaml (-4 / +7 lines)
Lines 41-47 Link Here
41
          items:
41
          items:
42
            $ref: "../swagger.yaml#/definitions/item"
42
            $ref: "../swagger.yaml#/definitions/item"
43
      "400":
43
      "400":
44
        description: Bad parameter
44
        description: |
45
          Bad request. Possible `error_code` attribute values:
46
47
            * `invalid_query`
45
        schema:
48
        schema:
46
          $ref: "../swagger.yaml#/definitions/error"
49
          $ref: "../swagger.yaml#/definitions/error"
47
      "401":
50
      "401":
Lines 92-99 Link Here
92
          type: array
95
          type: array
93
          items:
96
          items:
94
            type: object
97
            type: object
95
      400:
98
      "400":
96
        description: Bad parameter
99
        description: Bad request
97
        schema:
100
        schema:
98
          $ref: "../swagger.yaml#/definitions/error"
101
          $ref: "../swagger.yaml#/definitions/error"
99
      401:
102
      401:
Lines 145-151 Link Here
145
      "204":
148
      "204":
146
        description: Item removed
149
        description: Item removed
147
      "400":
150
      "400":
148
        description: Item removal failed
151
        description: Bad request
149
        schema:
152
        schema:
150
          $ref: "../swagger.yaml#/definitions/error"
153
          $ref: "../swagger.yaml#/definitions/error"
151
      "401":
154
      "401":
(-)a/api/v1/swagger/paths/public_oauth.yaml (-2 / +5 lines)
Lines 63-71 Link Here
63
        schema:
63
        schema:
64
          type: string
64
          type: string
65
      "400":
65
      "400":
66
        description: Bad Request
66
        description: |
67
          Bad request. Possible `error_code` attribute values:
68
69
            * `invalid_query`
67
        schema:
70
        schema:
68
          $ref: ../swagger.yaml#/definitions/error
71
          $ref: "../swagger.yaml#/definitions/error"
69
      "403":
72
      "403":
70
        description: Access forbidden
73
        description: Access forbidden
71
        schema:
74
        schema:
(-)a/api/v1/swagger/paths/public_patrons.yaml (-1 / +1 lines)
Lines 91-97 Link Here
91
        schema:
91
        schema:
92
          $ref: "../swagger.yaml#/definitions/checkout"
92
          $ref: "../swagger.yaml#/definitions/checkout"
93
      "400":
93
      "400":
94
        description: Missing or wrong parameters
94
        description: Bad request
95
        schema:
95
        schema:
96
          $ref: "../swagger.yaml#/definitions/error"
96
          $ref: "../swagger.yaml#/definitions/error"
97
      "401":
97
      "401":
(-)a/api/v1/swagger/paths/quotes.yaml (+23 lines)
Lines 43-48 Link Here
43
          type: array
43
          type: array
44
          items:
44
          items:
45
            $ref: "../swagger.yaml#/definitions/quote"
45
            $ref: "../swagger.yaml#/definitions/quote"
46
      "400":
47
        description: |
48
          Bad request. Possible `error_code` attribute values:
49
50
            * `invalid_query`
51
        schema:
52
          $ref: "../swagger.yaml#/definitions/error"
46
      "403":
53
      "403":
47
        description: Access forbidden
54
        description: Access forbidden
48
        schema:
55
        schema:
Lines 81-86 Link Here
81
        description: Quote added
88
        description: Quote added
82
        schema:
89
        schema:
83
          $ref: "../swagger.yaml#/definitions/quote"
90
          $ref: "../swagger.yaml#/definitions/quote"
91
      "400":
92
        description: Bad request
93
        schema:
94
          $ref: "../swagger.yaml#/definitions/error"
84
      "401":
95
      "401":
85
        description: Authentication required
96
        description: Authentication required
86
        schema:
97
        schema:
Lines 119-124 Link Here
119
        description: A Quote
130
        description: A Quote
120
        schema:
131
        schema:
121
          $ref: "../swagger.yaml#/definitions/quote"
132
          $ref: "../swagger.yaml#/definitions/quote"
133
      "400":
134
        description: Bad request
135
        schema:
136
          $ref: "../swagger.yaml#/definitions/error"
122
      "404":
137
      "404":
123
        description: Quote not found
138
        description: Quote not found
124
        schema:
139
        schema:
Lines 158-163 Link Here
158
        description: A quote
173
        description: A quote
159
        schema:
174
        schema:
160
          $ref: "../swagger.yaml#/definitions/quote"
175
          $ref: "../swagger.yaml#/definitions/quote"
176
      "400":
177
        description: Bad request
178
        schema:
179
          $ref: "../swagger.yaml#/definitions/error"
161
      "401":
180
      "401":
162
        description: Authentication required
181
        description: Authentication required
163
        schema:
182
        schema:
Lines 197-202 Link Here
197
    responses:
216
    responses:
198
      "204":
217
      "204":
199
        description: Quote deleted
218
        description: Quote deleted
219
      "400":
220
        description: Bad request
221
        schema:
222
          $ref: "../swagger.yaml#/definitions/error"
200
      "401":
223
      "401":
201
        description: Authentication required
224
        description: Authentication required
202
        schema:
225
        schema:
(-)a/api/v1/swagger/paths/search_filters.yaml (+23 lines)
Lines 23-28 Link Here
23
          type: array
23
          type: array
24
          items:
24
          items:
25
            $ref: "../swagger.yaml#/definitions/search_filter"
25
            $ref: "../swagger.yaml#/definitions/search_filter"
26
      "400":
27
        description: |
28
          Bad request. Possible `error_code` attribute values:
29
30
            * `invalid_query`
31
        schema:
32
          $ref: "../swagger.yaml#/definitions/error"
26
      '403':
33
      '403':
27
        description: Access forbidden
34
        description: Access forbidden
28
        schema:
35
        schema:
Lines 58-63 Link Here
58
        description: Search filter added
65
        description: Search filter added
59
        schema:
66
        schema:
60
          $ref: "../swagger.yaml#/definitions/search_filter"
67
          $ref: "../swagger.yaml#/definitions/search_filter"
68
      "400":
69
        description: Bad request
70
        schema:
71
          $ref: "../swagger.yaml#/definitions/error"
61
      '401':
72
      '401':
62
        description: Authentication required
73
        description: Authentication required
63
        schema:
74
        schema:
Lines 97-102 Link Here
97
        description: A search filter
108
        description: A search filter
98
        schema:
109
        schema:
99
          $ref: "../swagger.yaml#/definitions/search_filter"
110
          $ref: "../swagger.yaml#/definitions/search_filter"
111
      "400":
112
        description: Bad request
113
        schema:
114
          $ref: "../swagger.yaml#/definitions/error"
100
      '403':
115
      '403':
101
        description: Access forbidden
116
        description: Access forbidden
102
        schema:
117
        schema:
Lines 137-142 Link Here
137
        description: An search_filter
152
        description: An search_filter
138
        schema:
153
        schema:
139
          $ref: "../swagger.yaml#/definitions/search_filter"
154
          $ref: "../swagger.yaml#/definitions/search_filter"
155
      "400":
156
        description: Bad request
157
        schema:
158
          $ref: "../swagger.yaml#/definitions/error"
140
      '401':
159
      '401':
141
        description: Authentication required
160
        description: Authentication required
142
        schema:
161
        schema:
Lines 175-180 Link Here
175
        description: Searc filter deleted
194
        description: Searc filter deleted
176
        schema:
195
        schema:
177
          type: string
196
          type: string
197
      "400":
198
        description: Bad request
199
        schema:
200
          $ref: "../swagger.yaml#/definitions/error"
178
      '401':
201
      '401':
179
        description: Authentication required
202
        description: Authentication required
180
        schema:
203
        schema:
(-)a/api/v1/swagger/paths/suggestions.yaml (+22 lines)
Lines 24-29 Link Here
24
          type: array
24
          type: array
25
          items:
25
          items:
26
            $ref: "../swagger.yaml#/definitions/suggestion"
26
            $ref: "../swagger.yaml#/definitions/suggestion"
27
      "400":
28
        description: |
29
          Bad request. Possible `error_code` attribute values:
30
31
            * `invalid_query`
32
        schema:
33
          $ref: "../swagger.yaml#/definitions/error"
27
      "403":
34
      "403":
28
        description: Access forbidden
35
        description: Access forbidden
29
        schema:
36
        schema:
Lines 118-123 Link Here
118
        description: A suggestion
125
        description: A suggestion
119
        schema:
126
        schema:
120
          $ref: "../swagger.yaml#/definitions/suggestion"
127
          $ref: "../swagger.yaml#/definitions/suggestion"
128
      "400":
129
        description: Bad request
130
        schema:
131
          $ref: "../swagger.yaml#/definitions/error"
121
      "403":
132
      "403":
122
        description: Access forbidden
133
        description: Access forbidden
123
        schema:
134
        schema:
Lines 204-209 Link Here
204
        description: Suggestion deleted
215
        description: Suggestion deleted
205
        schema:
216
        schema:
206
          type: string
217
          type: string
218
      "400":
219
        description: Bad request
220
        schema:
221
          $ref: "../swagger.yaml#/definitions/error"
207
      "401":
222
      "401":
208
        description: Authentication required
223
        description: Authentication required
209
        schema:
224
        schema:
Lines 264-269 Link Here
264
          type: array
279
          type: array
265
          items:
280
          items:
266
            $ref: "../swagger.yaml#/definitions/patron"
281
            $ref: "../swagger.yaml#/definitions/patron"
282
      "400":
283
        description: |
284
          Bad request. Possible `error_code` attribute values:
285
286
            * `invalid_query`
287
        schema:
288
          $ref: "../swagger.yaml#/definitions/error"
267
      "403":
289
      "403":
268
        description: Access forbidden
290
        description: Access forbidden
269
        schema:
291
        schema:
(-)a/api/v1/swagger/paths/tickets.yaml (+41 lines)
Lines 36-41 Link Here
36
          type: array
36
          type: array
37
          items:
37
          items:
38
            $ref: "../swagger.yaml#/definitions/ticket"
38
            $ref: "../swagger.yaml#/definitions/ticket"
39
      "400":
40
        description: |
41
          Bad request. Possible `error_code` attribute values:
42
43
            * `invalid_query`
44
        schema:
45
          $ref: "../swagger.yaml#/definitions/error"
39
      "403":
46
      "403":
40
        description: Access forbidden
47
        description: Access forbidden
41
        schema:
48
        schema:
Lines 74-79 Link Here
74
        description: Ticket added
81
        description: Ticket added
75
        schema:
82
        schema:
76
          $ref: "../swagger.yaml#/definitions/ticket"
83
          $ref: "../swagger.yaml#/definitions/ticket"
84
      "400":
85
        description: Bad request
86
        schema:
87
          $ref: "../swagger.yaml#/definitions/error"
77
      "401":
88
      "401":
78
        description: Authentication required
89
        description: Authentication required
79
        schema:
90
        schema:
Lines 112-117 Link Here
112
        description: A ticket
123
        description: A ticket
113
        schema:
124
        schema:
114
          $ref: "../swagger.yaml#/definitions/ticket"
125
          $ref: "../swagger.yaml#/definitions/ticket"
126
      "400":
127
        description: |
128
          Bad request. Possible `error_code` attribute values:
129
130
            * `invalid_query`
131
        schema:
132
          $ref: "../swagger.yaml#/definitions/error"
115
      "404":
133
      "404":
116
        description: Ticket not found
134
        description: Ticket not found
117
        schema:
135
        schema:
Lines 151-156 Link Here
151
        description: A ticket
169
        description: A ticket
152
        schema:
170
        schema:
153
          $ref: "../swagger.yaml#/definitions/ticket"
171
          $ref: "../swagger.yaml#/definitions/ticket"
172
      "400":
173
        description: Bad request
174
        schema:
175
          $ref: "../swagger.yaml#/definitions/error"
154
      "401":
176
      "401":
155
        description: Authentication required
177
        description: Authentication required
156
        schema:
178
        schema:
Lines 187-192 Link Here
187
    responses:
209
    responses:
188
      "204":
210
      "204":
189
        description: Ticket deleted
211
        description: Ticket deleted
212
      "400":
213
        description: Bad request
214
        schema:
215
          $ref: "../swagger.yaml#/definitions/error"
190
      "401":
216
      "401":
191
        description: Authentication required
217
        description: Authentication required
192
        schema:
218
        schema:
Lines 245-250 Link Here
245
          type: array
271
          type: array
246
          items:
272
          items:
247
            $ref: "../swagger.yaml#/definitions/ticket_update"
273
            $ref: "../swagger.yaml#/definitions/ticket_update"
274
      "400":
275
        description: |
276
          Bad request. Possible `error_code` attribute values:
277
278
            * `invalid_query`
279
        schema:
280
          $ref: "../swagger.yaml#/definitions/error"
248
      "403":
281
      "403":
249
        description: Access forbidden
282
        description: Access forbidden
250
        schema:
283
        schema:
Lines 288-293 Link Here
288
        description: Ticket added
321
        description: Ticket added
289
        schema:
322
        schema:
290
          $ref: "../swagger.yaml#/definitions/ticket_update"
323
          $ref: "../swagger.yaml#/definitions/ticket_update"
324
      "400":
325
        description: Bad request
326
        schema:
327
          $ref: "../swagger.yaml#/definitions/error"
291
      "401":
328
      "401":
292
        description: Authentication required
329
        description: Authentication required
293
        schema:
330
        schema:
Lines 332-337 Link Here
332
        description: Ticket added
369
        description: Ticket added
333
        schema:
370
        schema:
334
          $ref: "../swagger.yaml#/definitions/ticket"
371
          $ref: "../swagger.yaml#/definitions/ticket"
372
      "400":
373
        description: Bad request
374
        schema:
375
          $ref: "../swagger.yaml#/definitions/error"
335
      "401":
376
      "401":
336
        description: Authentication required
377
        description: Authentication required
337
        schema:
378
        schema:
(-)a/api/v1/swagger/paths/transfer_limits.yaml (-1 / +12 lines)
Lines 44-50 Link Here
44
          items:
44
          items:
45
            $ref: "../swagger.yaml#/definitions/transfer_limit"
45
            $ref: "../swagger.yaml#/definitions/transfer_limit"
46
      "400":
46
      "400":
47
        description: Bad request
47
        description: |
48
          Bad request. Possible `error_code` attribute values:
49
50
            * `invalid_query`
48
        schema:
51
        schema:
49
          $ref: "../swagger.yaml#/definitions/error"
52
          $ref: "../swagger.yaml#/definitions/error"
50
      "401":
53
      "401":
Lines 138-143 Link Here
138
        description: Transfer limit deleted
141
        description: Transfer limit deleted
139
        schema:
142
        schema:
140
          type: string
143
          type: string
144
      "400":
145
        description: Bad request
146
        schema:
147
          $ref: "../swagger.yaml#/definitions/error"
141
      "401":
148
      "401":
142
        description: Authentication required
149
        description: Authentication required
143
        schema:
150
        schema:
Lines 313-318 Link Here
313
    responses:
320
    responses:
314
      "204":
321
      "204":
315
        description: Transfer limits deleted
322
        description: Transfer limits deleted
323
      "400":
324
        description: Bad request
325
        schema:
326
          $ref: "../swagger.yaml#/definitions/error"
316
      "401":
327
      "401":
317
        description: Authentication required
328
        description: Authentication required
318
        schema:
329
        schema:
(-)a/t/db_dependent/api/v1/query.t (-1 / +1 lines)
Lines 171-177 subtest 'SQL injection in "query" handling' => sub { Link Here
171
        "[{\"-and\":[[{\"me.patron_id\":{\"like(IF(ASCII(SUBSTRING((SELECT version()),1,1))=ASCII('1'),SLEEP(1/100000),0))or\":\"\%a\%\"}}]]}]";
171
        "[{\"-and\":[[{\"me.patron_id\":{\"like(IF(ASCII(SUBSTRING((SELECT version()),1,1))=ASCII('1'),SLEEP(1/100000),0))or\":\"\%a\%\"}}]]}]";
172
172
173
    $t->get_ok("//$userid:$password@/api/v1/patrons?q=$q")
173
    $t->get_ok("//$userid:$password@/api/v1/patrons?q=$q")
174
        ->status_is( 500, 'Attempt to inject SQL through operators is rejected' );
174
        ->status_is( 400, 'Attempt to inject SQL through operators is rejected' );
175
175
176
    $schema->storage->txn_rollback;
176
    $schema->storage->txn_rollback;
177
};
177
};
(-)a/xt/api.t (-2 / +44 lines)
Lines 14-20 Link Here
14
14
15
use Modern::Perl;
15
use Modern::Perl;
16
16
17
use Test::More tests => 4;
17
use Test::More tests => 5;
18
18
19
use Test::Mojo;
19
use Test::Mojo;
20
use Data::Dumper;
20
use Data::Dumper;
Lines 128-130 subtest 'tags tests' => sub { Link Here
128
        print STDERR "$error\n";
128
        print STDERR "$error\n";
129
    }
129
    }
130
};
130
};
131
- 
131
132
subtest '400 response tests' => sub {
133
134
    plan tests => 1;
135
136
    my @errors;
137
138
    foreach my $route ( sort keys %{$paths} ) {
139
        foreach my $verb ( keys %{ $paths->{$route} } ) {
140
141
            my $response_400 = $paths->{$route}->{$verb}->{responses}->{400};
142
143
            if ( !$response_400 ) {
144
                push @errors, "$verb $route -> response 400 absent";
145
                next;
146
            }
147
148
            push @errors,
149
                "$verb $route -> 'description' does not start with 'Bad request': ($response_400->{description})"
150
                unless $response_400->{description} =~ /^Bad request/;
151
152
            my $ref = $response_400->{schema}->{'$ref'};
153
            push @errors, "$verb $route -> '\$ref' is not '#/definitions/error': ($ref)"
154
                unless $ref =~ m/^#\/definitions\/error/;
155
156
            # GET routes with q parameter must mention the `invalid_query` error code
157
            if (   ( any { $_->{in} eq 'body' && $_->{name} eq 'query' } @{ $paths->{$route}->{$verb}->{parameters} } )
158
                || ( any { $_->{in} eq 'query' && $_->{name} eq 'q' } @{ $paths->{$route}->{$verb}->{parameters} } ) )
159
            {
160
161
                push @errors,
162
                    "$verb $route -> 'description' does not include '* \`invalid_query\`': ($response_400->{description})"
163
                    unless $response_400->{description} =~ /\* \`invalid_query\`/;
164
            }
165
        }
166
    }
167
168
    is( scalar @errors, 0, 'No errors in 400 definitions in the spec' );
169
170
    foreach my $error (@errors) {
171
        print STDERR "$error\n";
172
    }
173
};

Return to bug 37018