|
1
|
get: |
|
2
|
operationId: GetApiKeysId |
|
3
|
summary: Get API Key |
|
4
|
description: >- |
|
5
|
Retrieve an API key by its ID. You can expand the API key's relations or |
|
6
|
select the fields that should be returned using the query parameters. |
|
7
|
x-authenticated: true |
|
8
|
parameters: |
|
9
|
- name: id |
|
10
|
in: path |
|
11
|
description: The API key's ID. |
|
12
|
required: true |
|
13
|
schema: |
|
14
|
type: string |
|
15
|
- name: fields |
|
16
|
in: query |
|
17
|
description: >- |
|
18
|
Comma-separated fields that should be included in the returned data. if |
|
19
|
a field is prefixed with `+` it will be added to the default fields, |
|
20
|
using `-` will remove it from the default fields. without prefix it will |
|
21
|
replace the entire default fields. |
|
22
|
required: false |
|
23
|
schema: |
|
24
|
type: string |
|
25
|
title: fields |
|
26
|
description: >- |
|
27
|
Comma-separated fields that should be included in the returned data. |
|
28
|
if a field is prefixed with `+` it will be added to the default |
|
29
|
fields, using `-` will remove it from the default fields. without |
|
30
|
prefix it will replace the entire default fields. |
|
31
|
externalDocs: |
|
32
|
url: '#select-fields-and-relations' |
|
33
|
security: |
|
34
|
- api_token: [] |
|
35
|
- cookie_auth: [] |
|
36
|
- jwt_token: [] |
|
37
|
x-codeSamples: |
|
38
|
- lang: JavaScript |
|
39
|
label: JS SDK |
|
40
|
source: |
|
41
|
$ref: ../code_samples/JavaScript/admin_api-keys_{id}/get.js |
|
42
|
- lang: Shell |
|
43
|
label: cURL |
|
44
|
source: |
|
45
|
$ref: ../code_samples/Shell/admin_api-keys_{id}/get.sh |
|
46
|
tags: |
|
47
|
- Api Keys |
|
48
|
responses: |
|
49
|
'200': |
|
50
|
description: OK |
|
51
|
content: |
|
52
|
application/json: |
|
53
|
schema: |
|
54
|
$ref: ../components/schemas/AdminApiKeyResponse.yaml |
|
55
|
'400': |
|
56
|
$ref: ../components/responses/400_error.yaml |
|
57
|
'401': |
|
58
|
$ref: ../components/responses/unauthorized.yaml |
|
59
|
'404': |
|
60
|
$ref: ../components/responses/not_found_error.yaml |
|
61
|
'409': |
|
62
|
$ref: ../components/responses/invalid_state_error.yaml |
|
63
|
'422': |
|
64
|
$ref: ../components/responses/invalid_request_error.yaml |
|
65
|
'500': |
|
66
|
$ref: ../components/responses/500_error.yaml |
|
67
|
post: |
|
68
|
operationId: PostApiKeysId |
|
69
|
summary: Update an API Key |
|
70
|
description: Update an API key's details. |
|
71
|
x-authenticated: true |
|
72
|
parameters: |
|
73
|
- name: id |
|
74
|
in: path |
|
75
|
description: The API key's ID. |
|
76
|
required: true |
|
77
|
schema: |
|
78
|
type: string |
|
79
|
- name: fields |
|
80
|
in: query |
|
81
|
description: >- |
|
82
|
Comma-separated fields that should be included in the returned data. if |
|
83
|
a field is prefixed with `+` it will be added to the default fields, |
|
84
|
using `-` will remove it from the default fields. without prefix it will |
|
85
|
replace the entire default fields. |
|
86
|
required: false |
|
87
|
schema: |
|
88
|
type: string |
|
89
|
title: fields |
|
90
|
description: >- |
|
91
|
Comma-separated fields that should be included in the returned data. |
|
92
|
if a field is prefixed with `+` it will be added to the default |
|
93
|
fields, using `-` will remove it from the default fields. without |
|
94
|
prefix it will replace the entire default fields. |
|
95
|
externalDocs: |
|
96
|
url: '#select-fields-and-relations' |
|
97
|
security: |
|
98
|
- api_token: [] |
|
99
|
- cookie_auth: [] |
|
100
|
- jwt_token: [] |
|
101
|
requestBody: |
|
102
|
content: |
|
103
|
application/json: |
|
104
|
schema: |
|
105
|
$ref: ../components/schemas/AdminUpdateApiKey.yaml |
|
106
|
x-codeSamples: |
|
107
|
- lang: JavaScript |
|
108
|
label: JS SDK |
|
109
|
source: |
|
110
|
$ref: ../code_samples/JavaScript/admin_api-keys_{id}/post.js |
|
111
|
- lang: Shell |
|
112
|
label: cURL |
|
113
|
source: |
|
114
|
$ref: ../code_samples/Shell/admin_api-keys_{id}/post.sh |
|
115
|
tags: |
|
116
|
- Api Keys |
|
117
|
responses: |
|
118
|
'200': |
|
119
|
description: OK |
|
120
|
content: |
|
121
|
application/json: |
|
122
|
schema: |
|
123
|
$ref: ../components/schemas/AdminApiKeyResponse.yaml |
|
124
|
'400': |
|
125
|
$ref: ../components/responses/400_error.yaml |
|
126
|
'401': |
|
127
|
$ref: ../components/responses/unauthorized.yaml |
|
128
|
'404': |
|
129
|
$ref: ../components/responses/not_found_error.yaml |
|
130
|
'409': |
|
131
|
$ref: ../components/responses/invalid_state_error.yaml |
|
132
|
'422': |
|
133
|
$ref: ../components/responses/invalid_request_error.yaml |
|
134
|
'500': |
|
135
|
$ref: ../components/responses/500_error.yaml |
|
136
|
x-workflow: updateApiKeysWorkflow |
|
137
|
x-events: [] |
|
138
|
delete: |
|
139
|
operationId: DeleteApiKeysId |
|
140
|
summary: Delete an Api Key |
|
141
|
description: | |
|
142
|
Delete a publishable or secret API key. |
|
143
|
x-authenticated: true |
|
144
|
parameters: |
|
145
|
- name: id |
|
146
|
in: path |
|
147
|
description: The API key's ID. |
|
148
|
required: true |
|
149
|
schema: |
|
150
|
type: string |
|
151
|
security: |
|
152
|
- api_token: [] |
|
153
|
- cookie_auth: [] |
|
154
|
- jwt_token: [] |
|
155
|
x-codeSamples: |
|
156
|
- lang: JavaScript |
|
157
|
label: JS SDK |
|
158
|
source: |
|
159
|
$ref: ../code_samples/JavaScript/admin_api-keys_{id}/delete.js |
|
160
|
- lang: Shell |
|
161
|
label: cURL |
|
162
|
source: |
|
163
|
$ref: ../code_samples/Shell/admin_api-keys_{id}/delete.sh |
|
164
|
tags: |
|
165
|
- Api Keys |
|
166
|
responses: |
|
167
|
'200': |
|
168
|
description: OK |
|
169
|
content: |
|
170
|
application/json: |
|
171
|
schema: |
|
172
|
type: object |
|
173
|
description: The deletion's details. |
|
174
|
required: |
|
175
|
- id |
|
176
|
- object |
|
177
|
- deleted |
|
178
|
properties: |
|
179
|
id: |
|
180
|
type: string |
|
181
|
title: id |
|
182
|
description: The API key's ID. |
|
183
|
object: |
|
184
|
type: string |
|
185
|
title: object |
|
186
|
description: The name of the object that was deleted. |
|
187
|
default: api_key |
|
188
|
deleted: |
|
189
|
type: boolean |
|
190
|
title: deleted |
|
191
|
description: Whether the API key was deleted. |
|
192
|
'400': |
|
193
|
$ref: ../components/responses/400_error.yaml |
|
194
|
'401': |
|
195
|
$ref: ../components/responses/unauthorized.yaml |
|
196
|
'404': |
|
197
|
$ref: ../components/responses/not_found_error.yaml |
|
198
|
'409': |
|
199
|
$ref: ../components/responses/invalid_state_error.yaml |
|
200
|
'422': |
|
201
|
$ref: ../components/responses/invalid_request_error.yaml |
|
202
|
'500': |
|
203
|
$ref: ../components/responses/500_error.yaml |
|
204
|
x-workflow: deleteApiKeysWorkflow |
|
205
|
x-events: [] |