cli/resources/fine_tuning/subresources/checkpoints/index.md +0 −314 deleted
File Deleted View Diff
1# Checkpoints
2
3# Permissions
4
5## List checkpoint permissions
6
7`$ openai fine-tuning:checkpoints:permissions retrieve`
8
9**get** `/fine_tuning/checkpoints/{fine_tuned_model_checkpoint}/permissions`
10
11**NOTE:** This endpoint requires an [admin API key](../admin-api-keys).
12
13Organization owners can use this endpoint to view all permissions for a fine-tuned model checkpoint.
14
15### Parameters
16
17- `--fine-tuned-model-checkpoint: string`
18
19 The ID of the fine-tuned model checkpoint to get permissions for.
20
21- `--after: optional string`
22
23 Identifier for the last permission ID from the previous pagination request.
24
25- `--limit: optional number`
26
27 Number of permissions to retrieve.
28
29- `--order: optional "ascending" or "descending"`
30
31 The order in which to retrieve permissions.
32
33- `--project-id: optional string`
34
35 The ID of the project to get permissions for.
36
37### Returns
38
39- `FineTuningCheckpointPermissionGetResponse: object { data, has_more, object, 2 more }`
40
41 - `data: array of object { id, created_at, object, project_id }`
42
43 - `id: string`
44
45 The permission identifier, which can be referenced in the API endpoints.
46
47 - `created_at: number`
48
49 The Unix timestamp (in seconds) for when the permission was created.
50
51 - `object: "checkpoint.permission"`
52
53 The object type, which is always "checkpoint.permission".
54
55 - `project_id: string`
56
57 The project identifier that the permission is for.
58
59 - `has_more: boolean`
60
61 - `object: "list"`
62
63 - `first_id: optional string`
64
65 - `last_id: optional string`
66
67### Example
68
69```cli
70openai fine-tuning:checkpoints:permissions retrieve \
71 --api-key 'My API Key' \
72 --fine-tuned-model-checkpoint ft-AF1WoRqd3aJAHsqc9NY7iL8F
73```
74
75#### Response
76
77```json
78{
79 "data": [
80 {
81 "id": "id",
82 "created_at": 0,
83 "object": "checkpoint.permission",
84 "project_id": "project_id"
85 }
86 ],
87 "has_more": true,
88 "object": "list",
89 "first_id": "first_id",
90 "last_id": "last_id"
91}
92```
93
94## List checkpoint permissions
95
96`$ openai fine-tuning:checkpoints:permissions list`
97
98**get** `/fine_tuning/checkpoints/{fine_tuned_model_checkpoint}/permissions`
99
100**NOTE:** This endpoint requires an [admin API key](../admin-api-keys).
101
102Organization owners can use this endpoint to view all permissions for a fine-tuned model checkpoint.
103
104### Parameters
105
106- `--fine-tuned-model-checkpoint: string`
107
108 The ID of the fine-tuned model checkpoint to get permissions for.
109
110- `--after: optional string`
111
112 Identifier for the last permission ID from the previous pagination request.
113
114- `--limit: optional number`
115
116 Number of permissions to retrieve.
117
118- `--order: optional "ascending" or "descending"`
119
120 The order in which to retrieve permissions.
121
122- `--project-id: optional string`
123
124 The ID of the project to get permissions for.
125
126### Returns
127
128- `ListFineTuningCheckpointPermissionResponse: object { data, has_more, object, 2 more }`
129
130 - `data: array of object { id, created_at, object, project_id }`
131
132 - `id: string`
133
134 The permission identifier, which can be referenced in the API endpoints.
135
136 - `created_at: number`
137
138 The Unix timestamp (in seconds) for when the permission was created.
139
140 - `object: "checkpoint.permission"`
141
142 The object type, which is always "checkpoint.permission".
143
144 - `project_id: string`
145
146 The project identifier that the permission is for.
147
148 - `has_more: boolean`
149
150 - `object: "list"`
151
152 - `first_id: optional string`
153
154 - `last_id: optional string`
155
156### Example
157
158```cli
159openai fine-tuning:checkpoints:permissions list \
160 --api-key 'My API Key' \
161 --fine-tuned-model-checkpoint ft-AF1WoRqd3aJAHsqc9NY7iL8F
162```
163
164#### Response
165
166```json
167{
168 "data": [
169 {
170 "id": "id",
171 "created_at": 0,
172 "object": "checkpoint.permission",
173 "project_id": "project_id"
174 }
175 ],
176 "has_more": true,
177 "object": "list",
178 "first_id": "first_id",
179 "last_id": "last_id"
180}
181```
182
183## Create checkpoint permissions
184
185`$ openai fine-tuning:checkpoints:permissions create`
186
187**post** `/fine_tuning/checkpoints/{fine_tuned_model_checkpoint}/permissions`
188
189**NOTE:** Calling this endpoint requires an [admin API key](../admin-api-keys).
190
191This enables organization owners to share fine-tuned models with other projects in their organization.
192
193### Parameters
194
195- `--fine-tuned-model-checkpoint: string`
196
197 The ID of the fine-tuned model checkpoint to create a permission for.
198
199- `--project-id: array of string`
200
201 The project identifiers to grant access to.
202
203### Returns
204
205- `ListFineTuningCheckpointPermissionResponse: object { data, has_more, object, 2 more }`
206
207 - `data: array of object { id, created_at, object, project_id }`
208
209 - `id: string`
210
211 The permission identifier, which can be referenced in the API endpoints.
212
213 - `created_at: number`
214
215 The Unix timestamp (in seconds) for when the permission was created.
216
217 - `object: "checkpoint.permission"`
218
219 The object type, which is always "checkpoint.permission".
220
221 - `project_id: string`
222
223 The project identifier that the permission is for.
224
225 - `has_more: boolean`
226
227 - `object: "list"`
228
229 - `first_id: optional string`
230
231 - `last_id: optional string`
232
233### Example
234
235```cli
236openai fine-tuning:checkpoints:permissions create \
237 --api-key 'My API Key' \
238 --fine-tuned-model-checkpoint ft:gpt-4o-mini-2024-07-18:org:weather:B7R9VjQd \
239 --project-id string
240```
241
242#### Response
243
244```json
245{
246 "data": [
247 {
248 "id": "id",
249 "created_at": 0,
250 "object": "checkpoint.permission",
251 "project_id": "project_id"
252 }
253 ],
254 "has_more": true,
255 "object": "list",
256 "first_id": "first_id",
257 "last_id": "last_id"
258}
259```
260
261## Delete checkpoint permission
262
263`$ openai fine-tuning:checkpoints:permissions delete`
264
265**delete** `/fine_tuning/checkpoints/{fine_tuned_model_checkpoint}/permissions/{permission_id}`
266
267**NOTE:** This endpoint requires an [admin API key](../admin-api-keys).
268
269Organization owners can use this endpoint to delete a permission for a fine-tuned model checkpoint.
270
271### Parameters
272
273- `--fine-tuned-model-checkpoint: string`
274
275 The ID of the fine-tuned model checkpoint to delete a permission for.
276
277- `--permission-id: string`
278
279 The ID of the fine-tuned model checkpoint permission to delete.
280
281### Returns
282
283- `FineTuningCheckpointPermissionDeleteResponse: object { id, deleted, object }`
284
285 - `id: string`
286
287 The ID of the fine-tuned model checkpoint permission that was deleted.
288
289 - `deleted: boolean`
290
291 Whether the fine-tuned model checkpoint permission was successfully deleted.
292
293 - `object: "checkpoint.permission"`
294
295 The object type, which is always "checkpoint.permission".
296
297### Example
298
299```cli
300openai fine-tuning:checkpoints:permissions delete \
301 --api-key 'My API Key' \
302 --fine-tuned-model-checkpoint ft:gpt-4o-mini-2024-07-18:org:weather:B7R9VjQd \
303 --permission-id cp_zc4Q7MP6XxulcVzj4MZdwsAB
304```
305
306#### Response
307
308```json
309{
310 "id": "id",
311 "deleted": true,
312 "object": "checkpoint.permission"
313}
314```