Repository navigation
Expand file tree
/
Copy pathpaths.yaml
More file actions
66 lines (65 loc) · 1.92 KB
/
Copy pathpaths.yaml
File metadata and controls
66 lines (65 loc) · 1.92 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
paths:
/users/{id}:
get:
tags: [Users]
summary: Get user by ID
operationId: getUserById
security: []
parameters:
- name: id
in: path
required: true
schema:
type: integer
responses:
"200":
description: User found
content:
application/json:
schema:
allOf:
- $ref: ../common/schemas.yaml#/components/schemas/ApiResponse
- type: object
properties:
data:
type: object
properties:
user:
$ref: ../common/schemas.yaml#/components/schemas/User
"404":
$ref: ../common/responses.yaml#/components/responses/NotFound
patch:
tags: [Users]
summary: Update user profile
operationId: updateUser
parameters:
- name: id
in: path
required: true
schema:
type: integer
requestBody:
required: true
content:
application/json:
schema:
$ref: ../common/schemas.yaml#/components/schemas/UserUpdate
responses:
"200":
description: User updated
content:
application/json:
schema:
allOf:
- $ref: ../common/schemas.yaml#/components/schemas/ApiResponse
- type: object
properties:
data:
type: object
properties:
user:
$ref: ../common/schemas.yaml#/components/schemas/User
"403":
$ref: ../common/responses.yaml#/components/responses/Forbidden
"409":
$ref: ../common/responses.yaml#/components/responses/Conflict