-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathinterface.raml
More file actions
93 lines (86 loc) · 3.48 KB
/
Copy pathinterface.raml
File metadata and controls
93 lines (86 loc) · 3.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
#%RAML 1.0
title: "Organizations"
baseUri: https://github.com/folio-org/mod-organizations-storage
version: v2.0
documentation:
- title: Interfaces
content: <b>CRUD APIs used to manage interfaces.</b>
types:
interface: !include acq-models/mod-orgs/schemas/interface.json
interface_collection: !include acq-models/mod-orgs/schemas/interface_collection.json
interface_credential: !include acq-models/mod-orgs/schemas/interface_credential.json
errors: !include raml-util/schemas/errors.schema
UUID:
type: string
pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$
traits:
orderable: !include raml-util/traits/orderable.raml
pageable: !include raml-util/traits/pageable.raml
searchable: !include raml-util/traits/searchable.raml
validate: !include raml-util/traits/validation.raml
resourceTypes:
collection: !include raml-util/rtypes/collection.raml
collection-item: !include raml-util/rtypes/item-collection.raml
/organizations-storage/interfaces:
type:
collection:
exampleCollection: !include acq-models/mod-orgs/examples/interface_collection.sample
exampleItem: !include acq-models/mod-orgs/examples/interface_post.sample
schemaCollection: interface_collection
schemaItem: interface
is: [validate]
get:
description: Get list of interfaces
is: [
searchable: {description: "with valid searchable fields: for example code", example: "[\"code\", \"MEDGRANT\", \"=\"]"},
pageable
]
/{id}:
uriParameters:
id:
description: The UUID of a Interface
type: UUID
type:
collection-item:
exampleItem: !include acq-models/mod-orgs/examples/interface_get.sample
schema: interface
is: [validate]
/credentials:
displayName: Interface Credential
description: Manage interface credential
type:
collection-item:
exampleItem: !include acq-models/mod-orgs/examples/interface_credential_get.sample
schema: interface_credential
post:
description: Create a new interface credential
body:
application/json:
type: interface_credential
example:
strict: false
value: !include acq-models/mod-orgs/examples/interface_credential_get.sample
responses:
201:
description: "Returns a newly created interface credential, with server-controlled fields like 'id' populated"
headers:
Location:
description: URI to the created interface credential
body:
application/json:
example: !include acq-models/mod-orgs/examples/interface_credential_get.sample
400:
description: "Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response."
body:
text/plain:
example: "unable to add interface credential -- malformed JSON at 13:3"
401:
description: "Not authorized to perform requested action"
body:
text/plain:
example: "unable to create interface credential -- unauthorized"
500:
description: "Internal server error, e.g. due to misconfiguration"
body:
text/plain:
example: "Internal server error, contact administrator"