Skip to content

Commit a647b3d

Browse files
committed
5564: Update exported api spec
1 parent 060d7e4 commit a647b3d

3 files changed

Lines changed: 9 additions & 98 deletions

File tree

.github/workflows/apispec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ jobs:
4040
run: |
4141
echo '## 🛑 Exported API specification file not up to date' > var/comment.md
4242
echo '' >> var/comment.md
43-
echo 'Please run `task api:spec:export` to export the API specification. Then commit and push the changes.' >> var/comment.md
43+
echo 'Please run `composer update-api-spec` to export the API specification. Then commit and push the changes.' >> var/comment.md
4444
gh pr comment ${{ github.event.pull_request.number }} --body-file var/comment.md --create-if-none --edit-last
4545
4646
- name: Fail job, api spec is not up to date

public/api-spec-v1.json

Lines changed: 5 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -21,56 +21,14 @@
2121
"responses": {
2222
"202": {
2323
"description": "DetectionResult resource created",
24-
"content": {
25-
"application/json": {
26-
"schema": {}
27-
},
28-
"application/ld+json": {
29-
"schema": {}
30-
}
31-
},
3224
"links": {}
3325
},
3426
"400": {
3527
"description": "Invalid input",
36-
"content": {
37-
"application/ld+json": {
38-
"schema": {
39-
"$ref": "#/components/schemas/Error.jsonld"
40-
}
41-
},
42-
"application/problem+json": {
43-
"schema": {
44-
"$ref": "#/components/schemas/Error"
45-
}
46-
},
47-
"application/json": {
48-
"schema": {
49-
"$ref": "#/components/schemas/Error"
50-
}
51-
}
52-
},
5328
"links": {}
5429
},
5530
"422": {
5631
"description": "An error occurred",
57-
"content": {
58-
"application/ld+json": {
59-
"schema": {
60-
"$ref": "#/components/schemas/ConstraintViolation.jsonld-jsonld"
61-
}
62-
},
63-
"application/problem+json": {
64-
"schema": {
65-
"$ref": "#/components/schemas/ConstraintViolation-json"
66-
}
67-
},
68-
"application/json": {
69-
"schema": {
70-
"$ref": "#/components/schemas/ConstraintViolation-json"
71-
}
72-
}
73-
},
7432
"links": {}
7533
}
7634
},
@@ -92,21 +50,18 @@
9250
}
9351
},
9452
"required": true
95-
},
96-
"deprecated": false
53+
}
9754
}
9855
}
9956
},
10057
"components": {
10158
"schemas": {
102-
"ConstraintViolation-json": {
59+
"ConstraintViolation": {
10360
"type": "object",
10461
"description": "Unprocessable entity",
105-
"deprecated": false,
10662
"properties": {
10763
"status": {
10864
"default": 422,
109-
"example": 422,
11065
"type": "integer"
11166
},
11267
"violations": {
@@ -149,14 +104,12 @@
149104
}
150105
}
151106
},
152-
"ConstraintViolation.jsonld-jsonld": {
107+
"ConstraintViolation.jsonld": {
153108
"type": "object",
154109
"description": "Unprocessable entity",
155-
"deprecated": false,
156110
"properties": {
157111
"status": {
158112
"default": 422,
159-
"example": 422,
160113
"type": "integer"
161114
},
162115
"violations": {
@@ -205,30 +158,24 @@
205158
},
206159
"DetectionResult-write": {
207160
"type": "object",
208-
"description": "",
209-
"deprecated": false,
210161
"properties": {
211162
"type": {
212163
"default": "",
213-
"example": "",
214164
"type": "string"
215165
},
216166
"rootDir": {
217167
"default": "",
218-
"example": "",
219168
"type": "string"
220169
},
221170
"data": {
222171
"default": "",
223-
"example": "",
224172
"type": "string"
225173
}
226174
}
227175
},
228176
"Error": {
229177
"type": "object",
230178
"description": "A representation of common errors.",
231-
"deprecated": false,
232179
"properties": {
233180
"title": {
234181
"readOnly": true,
@@ -271,7 +218,6 @@
271218
"Error.jsonld": {
272219
"type": "object",
273220
"description": "A representation of common errors.",
274-
"deprecated": false,
275221
"properties": {
276222
"title": {
277223
"readOnly": true,
@@ -340,7 +286,8 @@
340286
],
341287
"tags": [
342288
{
343-
"name": "DetectionResult"
289+
"name": "DetectionResult",
290+
"description": "Resource 'DetectionResult' operations."
344291
}
345292
],
346293
"webhooks": {}

public/api-spec-v1.yaml

Lines changed: 3 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -16,37 +16,12 @@ paths:
1616
responses:
1717
'202':
1818
description: 'DetectionResult resource created'
19-
content:
20-
application/json:
21-
schema: { }
22-
application/ld+json:
23-
schema: { }
2419
links: { }
2520
'400':
2621
description: 'Invalid input'
27-
content:
28-
application/ld+json:
29-
schema:
30-
$ref: '#/components/schemas/Error.jsonld'
31-
application/problem+json:
32-
schema:
33-
$ref: '#/components/schemas/Error'
34-
application/json:
35-
schema:
36-
$ref: '#/components/schemas/Error'
3722
links: { }
3823
'422':
3924
description: 'An error occurred'
40-
content:
41-
application/ld+json:
42-
schema:
43-
$ref: '#/components/schemas/ConstraintViolation.jsonld-jsonld'
44-
application/problem+json:
45-
schema:
46-
$ref: '#/components/schemas/ConstraintViolation-json'
47-
application/json:
48-
schema:
49-
$ref: '#/components/schemas/ConstraintViolation-json'
5025
links: { }
5126
summary: 'Creates a DetectionResult resource.'
5227
description: 'Creates a DetectionResult resource.'
@@ -61,17 +36,14 @@ paths:
6136
schema:
6237
$ref: '#/components/schemas/DetectionResult-write'
6338
required: true
64-
deprecated: false
6539
components:
6640
schemas:
67-
ConstraintViolation-json:
41+
ConstraintViolation:
6842
type: object
6943
description: 'Unprocessable entity'
70-
deprecated: false
7144
properties:
7245
status:
7346
default: 422
74-
example: 422
7547
type: integer
7648
violations:
7749
type: array
@@ -100,14 +72,12 @@ components:
10072
type:
10173
- string
10274
- 'null'
103-
ConstraintViolation.jsonld-jsonld:
75+
ConstraintViolation.jsonld:
10476
type: object
10577
description: 'Unprocessable entity'
106-
deprecated: false
10778
properties:
10879
status:
10980
default: 422
110-
example: 422
11181
type: integer
11282
violations:
11383
type: array
@@ -141,25 +111,19 @@ components:
141111
- 'null'
142112
DetectionResult-write:
143113
type: object
144-
description: ''
145-
deprecated: false
146114
properties:
147115
type:
148116
default: ''
149-
example: ''
150117
type: string
151118
rootDir:
152119
default: ''
153-
example: ''
154120
type: string
155121
data:
156122
default: ''
157-
example: ''
158123
type: string
159124
Error:
160125
type: object
161126
description: 'A representation of common errors.'
162-
deprecated: false
163127
properties:
164128
title:
165129
readOnly: true
@@ -191,7 +155,6 @@ components:
191155
Error.jsonld:
192156
type: object
193157
description: 'A representation of common errors.'
194-
deprecated: false
195158
properties:
196159
title:
197160
readOnly: true
@@ -242,4 +205,5 @@ security:
242205
tags:
243206
-
244207
name: DetectionResult
208+
description: "Resource 'DetectionResult' operations."
245209
webhooks: { }

0 commit comments

Comments
 (0)