-
Notifications
You must be signed in to change notification settings - Fork 0
/
openapi.yaml
322 lines (306 loc) · 8.57 KB
/
openapi.yaml
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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
openapi: 3.0.2
info:
version: 1.0.0
title: Catalog View API
contact:
name: Digitaliseringsdirektoratet
url: 'https://fellesdatakatalog.digdir.no'
email: [email protected]
license:
name: License of API
url: 'http://data.norge.no/nlod/no/2.0'
servers:
- url: 'https://catalog-view.api.fellesdatakatalog.digdir.no'
description: Production
- url: 'https://catalog-view.api.demo.fellesdatakatalog.digdir.no'
description: Demo
- url: 'https://catalog-view.api.staging.fellesdatakatalog.digdir.no'
description: Test
paths:
/catalogs/{catalogId}/concepts:
get:
description: Returns all concepts in the collection
operationId: getConcepts
parameters:
- name: catalogId
in: path
description: Catalog id, usually id of publishing organization
required: true
schema:
type: string
- name: changedAfter
in: query
description: Response will only include concepts that has been changed after this date, format "yyyy-MM-dd'T'HH:mm:ss.SSSXXX". Note that it needs to be url-encoded, ie `+` -> `%2b`
required: false
schema:
type: string
format: date
- name: domainCodes
in: query
description: Response will only include concepts that has at least one of the domain codes
required: false
schema:
type: string
responses:
'200':
description: OK
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Concept'
/catalogs/{catalogId}/concepts/{id}:
get:
description: Returns single concept
operationId: getConceptById
parameters:
- name: catalogId
in: path
description: Catalog id, usually id of publishing organization
required: true
schema:
type: string
- name: id
in: path
description: Concept id
required: true
schema:
type: string
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: "#/components/schemas/Concept"
components:
schemas:
Concept:
type: object
properties:
id:
type: string
description: Concept id (GUID)
idOfOriginalVersion:
type: string
description: The id of the original version of the concept, equals id when original
version:
$ref: "#/components/schemas/SemVer"
isPublished:
type: boolean
description: The concept is published to felles datakatalog
publisher:
type: string
description: Organization id of publisher
status:
type: string
description: Status of concept, full uri if part of EU published concept statuses
preferredTerm:
$ref: "#/components/schemas/LocalizedStrings"
admittedTerm:
$ref: "#/components/schemas/ListOfLocalizedStrings"
deprecatedTerm:
$ref: "#/components/schemas/ListOfLocalizedStrings"
definition:
$ref: "#/components/schemas/Definition"
publicDefinition:
$ref: "#/components/schemas/Definition"
specialistDefinition:
$ref: "#/components/schemas/Definition"
note:
$ref: "#/components/schemas/LocalizedStrings"
attachedTag:
type: array
items:
type: string
valueRange:
$ref: "#/components/schemas/URIText"
contactPoint:
$ref: "#/components/schemas/ContactPoint"
abbreviatedLabel:
type: string
seeAlso:
type: array
items:
type: string
internalSeeAlso:
type: array
items:
type: string
conceptRelations:
type: array
items:
$ref: "#/components/schemas/ConceptRelation"
internalConceptRelations:
type: array
items:
$ref: "#/components/schemas/ConceptRelation"
replacedBy:
type: array
items:
type: string
internalReplacedBy:
type: array
items:
type: string
example:
$ref: "#/components/schemas/LocalizedStrings"
domain:
$ref: "#/components/schemas/ListOfLocalizedStrings"
domainCodes:
type: array
items:
$ref: "#/components/schemas/Code"
startDate:
type: string
format: date
description: date (inclusive) from which the concept is valid
endDate:
type: string
format: date
description: date (inclusively) through which the concept is valid
created:
type: string
format: date-time
description: Date and time this version was created, pattern yyyy-MM-dd'T'HH:mm:ss.SSSXXX
createdBy:
type: string
description: Name of user who created the concept
lastChanged:
type: string
format: date-time
description: Date and time this version was last changed, pattern yyyy-MM-dd'T'HH:mm:ss.SSSXXX
lastChangedBy:
type: string
description: Name of user who last changed the concept
assignedUser:
$ref: "#/components/schemas/User"
internalFields:
type: array
items:
$ref: "#/components/schemas/InternalField"
Definition:
type: object
properties:
text:
$ref: "#/components/schemas/LocalizedStrings"
sourceDescription:
$ref: "#/components/schemas/SourceDescription"
SemVer:
type: object
required:
- major
- minor
- patch
properties:
major:
type: integer
minimum: 0
minor:
type: integer
minimum: 0
patch:
type: integer
minimum: 0
LocalizedStrings:
type: object
properties:
nb:
type: string
description: Norsk bokmål
nn:
type: string
description: Nynorsk
en:
type: string
description: English
ListOfLocalizedStrings:
type: object
properties:
nb:
type: array
description: Norsk bokmål
items:
type: string
nn:
type: array
description: Nynorsk
items:
type: string
en:
type: array
description: English
items:
type: string
SourceDescription:
type: object
properties:
relationshipWithSource:
type: string
description: Relationship between the definition and the source, as complete uri from a controlled vocabulary
source:
$ref: "#/components/schemas/URIText"
URIText:
type: object
properties:
uri:
type: string
text:
type: string
ContactPoint:
type: object
properties:
email:
type: string
telephone:
type: string
User:
type: object
properties:
name:
type: string
email:
type: string
Code:
type: object
properties:
codeId:
type: string
codeListId:
type: string
codeLabel:
$ref: "#/components/schemas/LocalizedStrings"
InternalField:
type: object
properties:
id:
type: string
label:
$ref: "#/components/schemas/LocalizedStrings"
type:
type: string
enum: [text_short, text_long, bool, user, code]
value:
oneOf:
- $ref: "#/components/schemas/ShortTextField"
- $ref: "#/components/schemas/LongTextField"
- $ref: "#/components/schemas/BooleanValue"
- $ref: "#/components/schemas/User"
- $ref: "#/components/schemas/Code"
ShortTextField:
type: string
LongTextField:
type: string
BooleanValue:
type: boolean
ConceptRelation:
type: object
properties:
relationType:
type: string
enum: [ASSOCIATIVE, HAS_PARTITIVE, HAS_COMPREHENSIVE, HAS_SPECIFIC, HAS_GENERIC]
description:
$ref: "#/components/schemas/LocalizedStrings"
relatedConcept:
type: string