agentic-platform-sdk 0.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. agentic_platform_sdk/__init__.py +9 -0
  2. agentic_platform_sdk/_a2a.py +133 -0
  3. agentic_platform_sdk/_client.py +152 -0
  4. agentic_platform_sdk/_contract.py +72 -0
  5. agentic_platform_sdk/_generated/__init__.py +0 -0
  6. agentic_platform_sdk/_generated/_base.py +20 -0
  7. agentic_platform_sdk/_generated/models.py +698 -0
  8. agentic_platform_sdk/_paging.py +117 -0
  9. agentic_platform_sdk/_spec/call_areas.json +13 -0
  10. agentic_platform_sdk/_spec/chat-events.schema.json +371 -0
  11. agentic_platform_sdk/_spec/errors.json +2365 -0
  12. agentic_platform_sdk/_spec/operations.json +230 -0
  13. agentic_platform_sdk/_transport.py +630 -0
  14. agentic_platform_sdk/_util.py +133 -0
  15. agentic_platform_sdk/agents.py +793 -0
  16. agentic_platform_sdk/approvals.py +66 -0
  17. agentic_platform_sdk/auth.py +336 -0
  18. agentic_platform_sdk/chat.py +599 -0
  19. agentic_platform_sdk/datasets.py +69 -0
  20. agentic_platform_sdk/errors.py +204 -0
  21. agentic_platform_sdk/kb.py +288 -0
  22. agentic_platform_sdk/llm.py +40 -0
  23. agentic_platform_sdk/me.py +28 -0
  24. agentic_platform_sdk/models.py +91 -0
  25. agentic_platform_sdk/ontology.py +209 -0
  26. agentic_platform_sdk/py.typed +0 -0
  27. agentic_platform_sdk/testing/__init__.py +19 -0
  28. agentic_platform_sdk/testing/conformance.py +803 -0
  29. agentic_platform_sdk/testing/fake.py +902 -0
  30. agentic_platform_sdk/testing/standin.py +165 -0
  31. agentic_platform_sdk/toolchains.py +137 -0
  32. agentic_platform_sdk/tools/__init__.py +70 -0
  33. agentic_platform_sdk/tools/_jcs.py +218 -0
  34. agentic_platform_sdk/tools/asgi.py +228 -0
  35. agentic_platform_sdk/tools/mcp.py +751 -0
  36. agentic_platform_sdk/tools/verify.py +379 -0
  37. agentic_platform_sdk/vision.py +300 -0
  38. agentic_platform_sdk-0.1.0.dist-info/METADATA +226 -0
  39. agentic_platform_sdk-0.1.0.dist-info/RECORD +41 -0
  40. agentic_platform_sdk-0.1.0.dist-info/WHEEL +4 -0
  41. agentic_platform_sdk-0.1.0.dist-info/licenses/LICENSE +202 -0
@@ -0,0 +1,2365 @@
1
+ {
2
+ "version": 1,
3
+ "codes": [
4
+ {
5
+ "code": "*.rejected",
6
+ "http_status": [
7
+ 400
8
+ ],
9
+ "retryable": false,
10
+ "refused_before_run": false,
11
+ "meaning": "Made by the SDK when the API answers 4xx with no stable error code (400 stands for any such status; a list-shaped 422 is request.invalid instead); * is the catalogue area of the SDK client's area (e.g. kb -> knowledge_base).",
12
+ "sdk_synthesised": true,
13
+ "pattern": true
14
+ },
15
+ {
16
+ "code": "*.unavailable",
17
+ "http_status": [
18
+ 503
19
+ ],
20
+ "retryable": true,
21
+ "refused_before_run": false,
22
+ "meaning": "Made by the SDK when it cannot reach the API (a transport failure) or when the API answers 5xx with no stable error code (503 stands for 'no usable answer'); * is the catalogue area of the SDK client's area (e.g. kb -> knowledge_base).",
23
+ "sdk_synthesised": true,
24
+ "pattern": true
25
+ },
26
+ {
27
+ "code": "a2a.after_seq_invalid",
28
+ "http_status": [
29
+ 200
30
+ ],
31
+ "retryable": false,
32
+ "refused_before_run": false,
33
+ "meaning": "The chat-events resume position agentic.after_seq is not an integer of at least 0. (a JSON-RPC error; the HTTP status is 200)",
34
+ "carried_in": "body"
35
+ },
36
+ {
37
+ "code": "a2a.agent_not_found",
38
+ "http_status": [
39
+ 200,
40
+ 404
41
+ ],
42
+ "retryable": false,
43
+ "refused_before_run": false,
44
+ "meaning": "The agent does not exist, or is not runnable by the caller (404 on the REST routes, a JSON-RPC error with HTTP 200 otherwise).",
45
+ "carried_in": "both"
46
+ },
47
+ {
48
+ "code": "a2a.app_context_invalid",
49
+ "http_status": [
50
+ 200
51
+ ],
52
+ "retryable": false,
53
+ "refused_before_run": false,
54
+ "meaning": "The chat-events message metadata agentic.app_context is not a JSON object. (a JSON-RPC error; the HTTP status is 200)",
55
+ "carried_in": "body"
56
+ },
57
+ {
58
+ "code": "a2a.app_context_too_large",
59
+ "http_status": [
60
+ 200
61
+ ],
62
+ "retryable": false,
63
+ "refused_before_run": false,
64
+ "meaning": "The chat-events message metadata agentic.app_context is over 4096 bytes of compact JSON. (a JSON-RPC error; the HTTP status is 200)",
65
+ "carried_in": "body"
66
+ },
67
+ {
68
+ "code": "a2a.awaiting_approval",
69
+ "http_status": [
70
+ 200
71
+ ],
72
+ "retryable": false,
73
+ "refused_before_run": false,
74
+ "meaning": "The task waits for a human approval. (a JSON-RPC error; the HTTP status is 200)",
75
+ "carried_in": "body"
76
+ },
77
+ {
78
+ "code": "a2a.batch_unsupported",
79
+ "http_status": [
80
+ 200
81
+ ],
82
+ "retryable": false,
83
+ "refused_before_run": false,
84
+ "meaning": "A JSON-RPC batch was sent; batches are not supported. (a JSON-RPC error; the HTTP status is 200)",
85
+ "carried_in": "body"
86
+ },
87
+ {
88
+ "code": "a2a.client_disconnected",
89
+ "http_status": [
90
+ 400
91
+ ],
92
+ "retryable": false,
93
+ "refused_before_run": false,
94
+ "meaning": "The client hung up before the task body arrived."
95
+ },
96
+ {
97
+ "code": "a2a.content_type_not_supported",
98
+ "http_status": [
99
+ 200
100
+ ],
101
+ "retryable": false,
102
+ "refused_before_run": false,
103
+ "meaning": "The message carries a content type the agent does not take. (a JSON-RPC error; the HTTP status is 200)",
104
+ "carried_in": "body"
105
+ },
106
+ {
107
+ "code": "a2a.context_not_found",
108
+ "http_status": [
109
+ 200
110
+ ],
111
+ "retryable": false,
112
+ "refused_before_run": false,
113
+ "meaning": "The contextId names no known context. (a JSON-RPC error; the HTTP status is 200)",
114
+ "carried_in": "body"
115
+ },
116
+ {
117
+ "code": "a2a.events_unavailable",
118
+ "http_status": [
119
+ 200
120
+ ],
121
+ "retryable": false,
122
+ "refused_before_run": false,
123
+ "meaning": "The chat-events log of the task cannot be read or has a gap; resubscribe or call GetTask. (a JSON-RPC error; the HTTP status is 200)",
124
+ "carried_in": "body"
125
+ },
126
+ {
127
+ "code": "a2a.extension_required",
128
+ "http_status": [
129
+ 200
130
+ ],
131
+ "retryable": false,
132
+ "refused_before_run": false,
133
+ "meaning": "The request needs an A2A extension the call did not declare. (a JSON-RPC error; the HTTP status is 200)",
134
+ "carried_in": "body"
135
+ },
136
+ {
137
+ "code": "a2a.include_artifacts_unsupported",
138
+ "http_status": [
139
+ 200
140
+ ],
141
+ "retryable": false,
142
+ "refused_before_run": false,
143
+ "meaning": "includeArtifacts is not supported. (a JSON-RPC error; the HTTP status is 200)",
144
+ "carried_in": "body"
145
+ },
146
+ {
147
+ "code": "a2a.internal_error",
148
+ "http_status": [
149
+ 200
150
+ ],
151
+ "retryable": false,
152
+ "refused_before_run": false,
153
+ "meaning": "The door failed internally. (a JSON-RPC error; the HTTP status is 200)",
154
+ "carried_in": "body"
155
+ },
156
+ {
157
+ "code": "a2a.invalid_params",
158
+ "http_status": [
159
+ 200
160
+ ],
161
+ "retryable": false,
162
+ "refused_before_run": false,
163
+ "meaning": "A JSON-RPC parameter is missing or invalid. (a JSON-RPC error; the HTTP status is 200)",
164
+ "carried_in": "body"
165
+ },
166
+ {
167
+ "code": "a2a.invalid_request",
168
+ "http_status": [
169
+ 200
170
+ ],
171
+ "retryable": false,
172
+ "refused_before_run": false,
173
+ "meaning": "The JSON-RPC envelope is not valid. (a JSON-RPC error; the HTTP status is 200)",
174
+ "carried_in": "body"
175
+ },
176
+ {
177
+ "code": "a2a.invalid_task",
178
+ "http_status": [
179
+ 422
180
+ ],
181
+ "retryable": false,
182
+ "refused_before_run": false,
183
+ "meaning": "The task body is not valid."
184
+ },
185
+ {
186
+ "code": "a2a.method_not_found",
187
+ "http_status": [
188
+ 200
189
+ ],
190
+ "retryable": false,
191
+ "refused_before_run": false,
192
+ "meaning": "No such JSON-RPC method. (a JSON-RPC error; the HTTP status is 200)",
193
+ "carried_in": "body"
194
+ },
195
+ {
196
+ "code": "a2a.notification_unsupported",
197
+ "http_status": [
198
+ 200
199
+ ],
200
+ "retryable": false,
201
+ "refused_before_run": false,
202
+ "meaning": "A JSON-RPC notification (no id) was sent; every call needs an id. (a JSON-RPC error; the HTTP status is 200)",
203
+ "carried_in": "body"
204
+ },
205
+ {
206
+ "code": "a2a.parse_error",
207
+ "http_status": [
208
+ 200
209
+ ],
210
+ "retryable": false,
211
+ "refused_before_run": false,
212
+ "meaning": "The body is not JSON. (a JSON-RPC error; the HTTP status is 200)",
213
+ "carried_in": "body"
214
+ },
215
+ {
216
+ "code": "a2a.push_address_not_allowed",
217
+ "http_status": [
218
+ 200
219
+ ],
220
+ "retryable": false,
221
+ "refused_before_run": false,
222
+ "meaning": "The push URL resolves to a non-public address. (a JSON-RPC error; the HTTP status is 200)",
223
+ "carried_in": "body"
224
+ },
225
+ {
226
+ "code": "a2a.push_auth_invalid",
227
+ "http_status": [
228
+ 200
229
+ ],
230
+ "retryable": false,
231
+ "refused_before_run": false,
232
+ "meaning": "The stored push credentials cannot be used. (a JSON-RPC error; the HTTP status is 200)",
233
+ "carried_in": "body"
234
+ },
235
+ {
236
+ "code": "a2a.push_auth_scheme_unsupported",
237
+ "http_status": [
238
+ 200
239
+ ],
240
+ "retryable": false,
241
+ "refused_before_run": false,
242
+ "meaning": "The push authentication scheme is not supported. (a JSON-RPC error; the HTTP status is 200)",
243
+ "carried_in": "body"
244
+ },
245
+ {
246
+ "code": "a2a.push_client_required",
247
+ "http_status": [
248
+ 200
249
+ ],
250
+ "retryable": false,
251
+ "refused_before_run": false,
252
+ "meaning": "Push notifications need a registered API client. (a JSON-RPC error; the HTTP status is 200)",
253
+ "carried_in": "body"
254
+ },
255
+ {
256
+ "code": "a2a.push_config_deleted",
257
+ "http_status": [
258
+ 200
259
+ ],
260
+ "retryable": false,
261
+ "refused_before_run": false,
262
+ "meaning": "Push delivery outcome: the config was deleted. (a JSON-RPC error; the HTTP status is 200)",
263
+ "carried_in": "body"
264
+ },
265
+ {
266
+ "code": "a2a.push_config_mismatch",
267
+ "http_status": [
268
+ 200
269
+ ],
270
+ "retryable": false,
271
+ "refused_before_run": false,
272
+ "meaning": "Push delivery outcome: the config is not its task's client's; nothing was sent. (a JSON-RPC error; the HTTP status is 200)",
273
+ "carried_in": "body"
274
+ },
275
+ {
276
+ "code": "a2a.push_config_not_found",
277
+ "http_status": [
278
+ 200
279
+ ],
280
+ "retryable": false,
281
+ "refused_before_run": false,
282
+ "meaning": "No such push notification config. (a JSON-RPC error; the HTTP status is 200)",
283
+ "carried_in": "body"
284
+ },
285
+ {
286
+ "code": "a2a.push_host_not_allowed",
287
+ "http_status": [
288
+ 200
289
+ ],
290
+ "retryable": false,
291
+ "refused_before_run": false,
292
+ "meaning": "The push host is not on the allowlist. (a JSON-RPC error; the HTTP status is 200)",
293
+ "carried_in": "body"
294
+ },
295
+ {
296
+ "code": "a2a.push_http_status",
297
+ "http_status": [
298
+ 200
299
+ ],
300
+ "retryable": false,
301
+ "refused_before_run": false,
302
+ "meaning": "Push delivery outcome: the receiver answered non-2xx. (a JSON-RPC error; the HTTP status is 200)",
303
+ "carried_in": "body"
304
+ },
305
+ {
306
+ "code": "a2a.push_not_supported",
307
+ "http_status": [
308
+ 200
309
+ ],
310
+ "retryable": false,
311
+ "refused_before_run": false,
312
+ "meaning": "The agent does not support push notifications. (a JSON-RPC error; the HTTP status is 200)",
313
+ "carried_in": "body"
314
+ },
315
+ {
316
+ "code": "a2a.push_proxy_unsupported",
317
+ "http_status": [
318
+ 200
319
+ ],
320
+ "retryable": false,
321
+ "refused_before_run": false,
322
+ "meaning": "Push delivery outcome: delivery through the egress proxy is not supported. (a JSON-RPC error; the HTTP status is 200)",
323
+ "carried_in": "body"
324
+ },
325
+ {
326
+ "code": "a2a.push_request_failed",
327
+ "http_status": [
328
+ 200
329
+ ],
330
+ "retryable": false,
331
+ "refused_before_run": false,
332
+ "meaning": "Push delivery outcome: transport, TLS or timeout failure. (a JSON-RPC error; the HTTP status is 200)",
333
+ "carried_in": "body"
334
+ },
335
+ {
336
+ "code": "a2a.push_secret_missing",
337
+ "http_status": [
338
+ 200
339
+ ],
340
+ "retryable": false,
341
+ "refused_before_run": false,
342
+ "meaning": "No live callback secret signs the push. (a JSON-RPC error; the HTTP status is 200)",
343
+ "carried_in": "body"
344
+ },
345
+ {
346
+ "code": "a2a.push_task_retired",
347
+ "http_status": [
348
+ 200
349
+ ],
350
+ "retryable": false,
351
+ "refused_before_run": false,
352
+ "meaning": "Push delivery outcome: the task was retired. (a JSON-RPC error; the HTTP status is 200)",
353
+ "carried_in": "body"
354
+ },
355
+ {
356
+ "code": "a2a.push_task_terminal",
357
+ "http_status": [
358
+ 200
359
+ ],
360
+ "retryable": false,
361
+ "refused_before_run": false,
362
+ "meaning": "The task is already finished; no push can be registered. (a JSON-RPC error; the HTTP status is 200)",
363
+ "carried_in": "body"
364
+ },
365
+ {
366
+ "code": "a2a.push_too_many_configs",
367
+ "http_status": [
368
+ 200
369
+ ],
370
+ "retryable": false,
371
+ "refused_before_run": false,
372
+ "meaning": "The task has the maximum number of push configs. (a JSON-RPC error; the HTTP status is 200)",
373
+ "carried_in": "body"
374
+ },
375
+ {
376
+ "code": "a2a.push_url_invalid",
377
+ "http_status": [
378
+ 200
379
+ ],
380
+ "retryable": false,
381
+ "refused_before_run": false,
382
+ "meaning": "The push URL is malformed or not https. (a JSON-RPC error; the HTTP status is 200)",
383
+ "carried_in": "body"
384
+ },
385
+ {
386
+ "code": "a2a.task_body_timeout",
387
+ "http_status": [
388
+ 408
389
+ ],
390
+ "retryable": false,
391
+ "refused_before_run": false,
392
+ "meaning": "The task body did not arrive in time."
393
+ },
394
+ {
395
+ "code": "a2a.task_canceled",
396
+ "http_status": [
397
+ 200
398
+ ],
399
+ "retryable": false,
400
+ "refused_before_run": false,
401
+ "meaning": "The task was canceled. (a JSON-RPC error; the HTTP status is 200)",
402
+ "carried_in": "body"
403
+ },
404
+ {
405
+ "code": "a2a.task_continuation_unsupported",
406
+ "http_status": [
407
+ 200
408
+ ],
409
+ "retryable": false,
410
+ "refused_before_run": false,
411
+ "meaning": "Continuing a finished task is not supported. (a JSON-RPC error; the HTTP status is 200)",
412
+ "carried_in": "body"
413
+ },
414
+ {
415
+ "code": "a2a.task_not_cancelable",
416
+ "http_status": [
417
+ 200
418
+ ],
419
+ "retryable": false,
420
+ "refused_before_run": false,
421
+ "meaning": "The task cannot be canceled in its state. (a JSON-RPC error; the HTTP status is 200)",
422
+ "carried_in": "body"
423
+ },
424
+ {
425
+ "code": "a2a.task_not_found",
426
+ "http_status": [
427
+ 200
428
+ ],
429
+ "retryable": false,
430
+ "refused_before_run": false,
431
+ "meaning": "The task does not exist, or is not visible to the caller. (a JSON-RPC error; the HTTP status is 200)",
432
+ "carried_in": "body"
433
+ },
434
+ {
435
+ "code": "a2a.task_route_moved",
436
+ "http_status": [
437
+ 410
438
+ ],
439
+ "retryable": false,
440
+ "refused_before_run": false,
441
+ "meaning": "The flat /tasks route is retired; the body names the JSON-RPC replacement."
442
+ },
443
+ {
444
+ "code": "a2a.task_timeout",
445
+ "http_status": [
446
+ 200,
447
+ 504
448
+ ],
449
+ "retryable": false,
450
+ "refused_before_run": false,
451
+ "meaning": "The task ran past the time limit (504 on the REST route).",
452
+ "carried_in": "both"
453
+ },
454
+ {
455
+ "code": "a2a.task_too_large",
456
+ "http_status": [
457
+ 413
458
+ ],
459
+ "retryable": false,
460
+ "refused_before_run": false,
461
+ "meaning": "The task body is larger than the limit."
462
+ },
463
+ {
464
+ "code": "a2a.tenant_unsupported",
465
+ "http_status": [
466
+ 200
467
+ ],
468
+ "retryable": false,
469
+ "refused_before_run": false,
470
+ "meaning": "A tenant path or field was sent; tenants are not supported. (a JSON-RPC error; the HTTP status is 200)",
471
+ "carried_in": "body"
472
+ },
473
+ {
474
+ "code": "a2a.version_not_supported",
475
+ "http_status": [
476
+ 200,
477
+ 400
478
+ ],
479
+ "retryable": false,
480
+ "refused_before_run": false,
481
+ "meaning": "The A2A-Version is not served; the body lists the supported ones (400 on the agent card, HTTP 200 as a JSON-RPC error).",
482
+ "carried_in": "both"
483
+ },
484
+ {
485
+ "code": "a2a.worker_lost",
486
+ "http_status": [
487
+ 200
488
+ ],
489
+ "retryable": false,
490
+ "refused_before_run": false,
491
+ "meaning": "The worker running the task was lost. (a JSON-RPC error; the HTTP status is 200)",
492
+ "carried_in": "body"
493
+ },
494
+ {
495
+ "code": "agent.adapter_not_usable",
496
+ "http_status": [
497
+ 422
498
+ ],
499
+ "retryable": false,
500
+ "refused_before_run": false,
501
+ "meaning": "The agent's scenario adapter is not usable by the acting user in the acting workspace. (a model-door refusal; the open chat door answers it as 422 with this code)"
502
+ },
503
+ {
504
+ "code": "agent.execution_failed",
505
+ "http_status": [
506
+ 200
507
+ ],
508
+ "retryable": false,
509
+ "refused_before_run": false,
510
+ "meaning": "The fallback failure code of an A2A task whose agent failed with no stable code.",
511
+ "carried_in": "body"
512
+ },
513
+ {
514
+ "code": "agent.model_not_set",
515
+ "http_status": [
516
+ 422
517
+ ],
518
+ "retryable": false,
519
+ "refused_before_run": false,
520
+ "meaning": "No model is named by the request or the conversation, and the agent stores none. (a model-door refusal; the open chat door answers it as 422 with this code)"
521
+ },
522
+ {
523
+ "code": "agent.model_not_usable",
524
+ "http_status": [
525
+ 422
526
+ ],
527
+ "retryable": false,
528
+ "refused_before_run": false,
529
+ "meaning": "The agent's own registered model is not usable by the acting user in the acting workspace. (a model-door refusal; the open chat door answers it as 422 with this code)"
530
+ },
531
+ {
532
+ "code": "api_client.admin_required",
533
+ "http_status": [
534
+ 403
535
+ ],
536
+ "retryable": false,
537
+ "refused_before_run": false,
538
+ "meaning": "Managing API clients needs a workspace admin. (admin API)"
539
+ },
540
+ {
541
+ "code": "api_client.callback_secret_not_found",
542
+ "http_status": [
543
+ 404
544
+ ],
545
+ "retryable": false,
546
+ "refused_before_run": false,
547
+ "meaning": "The callback secret does not exist on this client. (admin API)"
548
+ },
549
+ {
550
+ "code": "api_client.cursor_incomplete",
551
+ "http_status": [
552
+ 422
553
+ ],
554
+ "retryable": false,
555
+ "refused_before_run": false,
556
+ "meaning": "A call-log cursor must carry both its timestamp and its id. (admin API)"
557
+ },
558
+ {
559
+ "code": "api_client.dpop_jwk_invalid",
560
+ "http_status": [
561
+ 422
562
+ ],
563
+ "retryable": false,
564
+ "refused_before_run": false,
565
+ "meaning": "The DPoP public key is not an EC P-256 JWK of exactly kty, crv, x and y. (admin API)"
566
+ },
567
+ {
568
+ "code": "api_client.dpop_jwk_required",
569
+ "http_status": [
570
+ 422
571
+ ],
572
+ "retryable": false,
573
+ "refused_before_run": false,
574
+ "meaning": "A client that requires DPoP cannot be issued a key without a public key. (admin API)"
575
+ },
576
+ {
577
+ "code": "api_client.dpop_off",
578
+ "http_status": [
579
+ 409
580
+ ],
581
+ "retryable": false,
582
+ "refused_before_run": false,
583
+ "meaning": "A DPoP binding was asked for while open-API DPoP mode is off. (admin API)"
584
+ },
585
+ {
586
+ "code": "api_client.expired",
587
+ "http_status": [
588
+ 409
589
+ ],
590
+ "retryable": false,
591
+ "refused_before_run": false,
592
+ "meaning": "The API client has expired, so no key can be issued for it. (admin API)"
593
+ },
594
+ {
595
+ "code": "api_client.expiry_in_past",
596
+ "http_status": [
597
+ 422
598
+ ],
599
+ "retryable": false,
600
+ "refused_before_run": false,
601
+ "meaning": "The requested expiry is in the past. (admin API)"
602
+ },
603
+ {
604
+ "code": "api_client.key_not_found",
605
+ "http_status": [
606
+ 404
607
+ ],
608
+ "retryable": false,
609
+ "refused_before_run": false,
610
+ "meaning": "The API key does not exist on this client. (admin API)"
611
+ },
612
+ {
613
+ "code": "api_client.limit_out_of_range",
614
+ "http_status": [
615
+ 422
616
+ ],
617
+ "retryable": false,
618
+ "refused_before_run": false,
619
+ "meaning": "A requested rate limit is outside the allowed range. (admin API)"
620
+ },
621
+ {
622
+ "code": "api_client.not_found",
623
+ "http_status": [
624
+ 404
625
+ ],
626
+ "retryable": false,
627
+ "refused_before_run": false,
628
+ "meaning": "The API client does not exist in this workspace. (admin API)"
629
+ },
630
+ {
631
+ "code": "api_client.revoked",
632
+ "http_status": [
633
+ 409
634
+ ],
635
+ "retryable": false,
636
+ "refused_before_run": false,
637
+ "meaning": "The API client was revoked, so it can no longer be changed. (admin API)"
638
+ },
639
+ {
640
+ "code": "api_client.route_limit_scope_not_granted",
641
+ "http_status": [
642
+ 422
643
+ ],
644
+ "retryable": false,
645
+ "refused_before_run": false,
646
+ "meaning": "A per-route limit names a scope the client does not hold. (admin API)"
647
+ },
648
+ {
649
+ "code": "api_client.too_many_callback_secrets",
650
+ "http_status": [
651
+ 409
652
+ ],
653
+ "retryable": false,
654
+ "refused_before_run": false,
655
+ "meaning": "The client already has the maximum number of live callback secrets. (admin API)"
656
+ },
657
+ {
658
+ "code": "api_client.too_many_keys",
659
+ "http_status": [
660
+ 409
661
+ ],
662
+ "retryable": false,
663
+ "refused_before_run": false,
664
+ "meaning": "The client already has the maximum number of live keys. (admin API)"
665
+ },
666
+ {
667
+ "code": "api_client.unknown_scope",
668
+ "http_status": [
669
+ 422
670
+ ],
671
+ "retryable": false,
672
+ "refused_before_run": false,
673
+ "meaning": "A requested scope does not exist. (admin API)"
674
+ },
675
+ {
676
+ "code": "approval.already_decided",
677
+ "http_status": [
678
+ 409
679
+ ],
680
+ "retryable": false,
681
+ "refused_before_run": false,
682
+ "meaning": "This approver has already decided this approval."
683
+ },
684
+ {
685
+ "code": "approval.not_found",
686
+ "http_status": [
687
+ 404
688
+ ],
689
+ "retryable": false,
690
+ "refused_before_run": false,
691
+ "meaning": "The approval does not exist, is not of a kind an app may decide, or the caller is not allowed to decide it (the same 404 for each, so a reader learns nothing more)."
692
+ },
693
+ {
694
+ "code": "approval.request_not_pending",
695
+ "http_status": [
696
+ 409
697
+ ],
698
+ "retryable": false,
699
+ "refused_before_run": false,
700
+ "meaning": "The approval is already decided, cancelled or expired."
701
+ },
702
+ {
703
+ "code": "approval.step_not_open",
704
+ "http_status": [
705
+ 409
706
+ ],
707
+ "retryable": false,
708
+ "refused_before_run": false,
709
+ "meaning": "The approval's stage moved on while the decision was being made."
710
+ },
711
+ {
712
+ "code": "auth.app_disabled",
713
+ "http_status": [
714
+ 401
715
+ ],
716
+ "retryable": false,
717
+ "refused_before_run": false,
718
+ "meaning": "The app the token was issued for is disabled."
719
+ },
720
+ {
721
+ "code": "auth.app_not_registered",
722
+ "http_status": [
723
+ 401
724
+ ],
725
+ "retryable": false,
726
+ "refused_before_run": false,
727
+ "meaning": "The token's app is not registered on the platform."
728
+ },
729
+ {
730
+ "code": "auth.dpop_proof_late",
731
+ "http_status": [
732
+ 401
733
+ ],
734
+ "retryable": false,
735
+ "refused_before_run": false,
736
+ "meaning": "The request reached the DPoP check too long after it arrived (a slow body)."
737
+ },
738
+ {
739
+ "code": "auth.dpop_replay_unavailable",
740
+ "http_status": [
741
+ 503
742
+ ],
743
+ "retryable": true,
744
+ "refused_before_run": false,
745
+ "meaning": "The shared DPoP replay store cannot answer; see Retry-After."
746
+ },
747
+ {
748
+ "code": "auth.email_required",
749
+ "http_status": [
750
+ 403
751
+ ],
752
+ "retryable": false,
753
+ "refused_before_run": false,
754
+ "meaning": "The identity provider token carries no usable email address."
755
+ },
756
+ {
757
+ "code": "auth.idp_unavailable",
758
+ "http_status": [
759
+ 503
760
+ ],
761
+ "retryable": true,
762
+ "refused_before_run": false,
763
+ "meaning": "The identity provider cannot be reached; see Retry-After."
764
+ },
765
+ {
766
+ "code": "auth.login_unavailable",
767
+ "http_status": [
768
+ 503
769
+ ],
770
+ "retryable": true,
771
+ "refused_before_run": false,
772
+ "meaning": "The sign-in flow cannot reach its state store or the identity provider."
773
+ },
774
+ {
775
+ "code": "auth.mfa_idp_unattested",
776
+ "http_status": [
777
+ 401
778
+ ],
779
+ "retryable": false,
780
+ "refused_before_run": false,
781
+ "meaning": "The person must use a second factor and the identity provider did not vouch for one on this token."
782
+ },
783
+ {
784
+ "code": "auth.oidc_state_invalid",
785
+ "http_status": [
786
+ 400
787
+ ],
788
+ "retryable": false,
789
+ "refused_before_run": false,
790
+ "meaning": "The sign-in state is missing, expired or already used."
791
+ },
792
+ {
793
+ "code": "auth.token_invalid",
794
+ "http_status": [
795
+ 401
796
+ ],
797
+ "retryable": false,
798
+ "refused_before_run": false,
799
+ "meaning": "The app token is invalid, expired or replayed."
800
+ },
801
+ {
802
+ "code": "auth.user_inactive",
803
+ "http_status": [
804
+ 403
805
+ ],
806
+ "retryable": false,
807
+ "refused_before_run": false,
808
+ "meaning": "The person the token acts as is deactivated."
809
+ },
810
+ {
811
+ "code": "crypto.key_unavailable",
812
+ "http_status": [
813
+ 422
814
+ ],
815
+ "retryable": false,
816
+ "refused_before_run": false,
817
+ "meaning": "The model's stored API key is under a data key this process does not hold yet; final on this route. (a model-door refusal; the open chat door answers it as 422 with this code)"
818
+ },
819
+ {
820
+ "code": "crypto.signing_snapshot_stale",
821
+ "http_status": [
822
+ 503
823
+ ],
824
+ "retryable": false,
825
+ "refused_before_run": false,
826
+ "meaning": "This process has not reloaded the signing-key state for too long, so it refuses to sign or verify (the DPoP nonce MAC); another instance may answer. Final in v1: the name is not in the *_unavailable family."
827
+ },
828
+ {
829
+ "code": "dataset.not_found",
830
+ "http_status": [
831
+ 404
832
+ ],
833
+ "retryable": false,
834
+ "refused_before_run": false,
835
+ "meaning": "The dataset does not exist, or is not visible to the caller."
836
+ },
837
+ {
838
+ "code": "gateway.client_expired",
839
+ "http_status": [
840
+ 401
841
+ ],
842
+ "retryable": false,
843
+ "refused_before_run": false,
844
+ "meaning": "The API client the key belongs to has expired."
845
+ },
846
+ {
847
+ "code": "gateway.client_revoked",
848
+ "http_status": [
849
+ 401
850
+ ],
851
+ "retryable": false,
852
+ "refused_before_run": false,
853
+ "meaning": "The API client the key belongs to was revoked."
854
+ },
855
+ {
856
+ "code": "gateway.dpop_binding_required",
857
+ "http_status": [
858
+ 401
859
+ ],
860
+ "retryable": false,
861
+ "refused_before_run": false,
862
+ "meaning": "The client or app requires a DPoP-bound credential and this one is unbound."
863
+ },
864
+ {
865
+ "code": "gateway.dpop_nonce_required",
866
+ "http_status": [
867
+ 401
868
+ ],
869
+ "retryable": false,
870
+ "refused_before_run": false,
871
+ "meaning": "The DPoP nonce is missing or stale; retry once with the nonce from the DPoP-Nonce header."
872
+ },
873
+ {
874
+ "code": "gateway.dpop_proof_invalid",
875
+ "http_status": [
876
+ 401
877
+ ],
878
+ "retryable": false,
879
+ "refused_before_run": false,
880
+ "meaning": "The DPoP proof was refused (malformed, wrong key, replayed, wrong method or URL), or a DPoP proof was sent for an unbound credential."
881
+ },
882
+ {
883
+ "code": "gateway.dpop_proof_required",
884
+ "http_status": [
885
+ 401
886
+ ],
887
+ "retryable": false,
888
+ "refused_before_run": false,
889
+ "meaning": "A bound credential was sent without a DPoP proof, or with the Bearer scheme."
890
+ },
891
+ {
892
+ "code": "gateway.invalid_key",
893
+ "http_status": [
894
+ 401
895
+ ],
896
+ "retryable": false,
897
+ "refused_before_run": false,
898
+ "meaning": "The API key is not known."
899
+ },
900
+ {
901
+ "code": "gateway.kb_embedding_not_open",
902
+ "http_status": [
903
+ 409
904
+ ],
905
+ "retryable": false,
906
+ "refused_before_run": false,
907
+ "meaning": "The knowledge base embeds with a hosted model on the platform key, which the open API never spends."
908
+ },
909
+ {
910
+ "code": "gateway.key_expired",
911
+ "http_status": [
912
+ 401
913
+ ],
914
+ "retryable": false,
915
+ "refused_before_run": false,
916
+ "meaning": "The API key has expired."
917
+ },
918
+ {
919
+ "code": "gateway.key_required",
920
+ "http_status": [
921
+ 401
922
+ ],
923
+ "retryable": false,
924
+ "refused_before_run": false,
925
+ "meaning": "No credentials were sent, or not as a Bearer (or DPoP) credential."
926
+ },
927
+ {
928
+ "code": "gateway.key_revoked",
929
+ "http_status": [
930
+ 401
931
+ ],
932
+ "retryable": false,
933
+ "refused_before_run": false,
934
+ "meaning": "The API key was revoked."
935
+ },
936
+ {
937
+ "code": "gateway.limiter_unavailable",
938
+ "http_status": [
939
+ 503
940
+ ],
941
+ "retryable": true,
942
+ "refused_before_run": true,
943
+ "meaning": "The rate limiter cannot be asked; see Retry-After."
944
+ },
945
+ {
946
+ "code": "gateway.owner_not_member",
947
+ "http_status": [
948
+ 403
949
+ ],
950
+ "retryable": false,
951
+ "refused_before_run": false,
952
+ "meaning": "The client's owner is no longer an active member of the client's workspace."
953
+ },
954
+ {
955
+ "code": "gateway.rate_limited",
956
+ "http_status": [
957
+ 429
958
+ ],
959
+ "retryable": true,
960
+ "refused_before_run": true,
961
+ "meaning": "Per-client or per-route rate window full; see Retry-After."
962
+ },
963
+ {
964
+ "code": "gateway.route_not_published",
965
+ "http_status": [
966
+ 403
967
+ ],
968
+ "retryable": false,
969
+ "refused_before_run": false,
970
+ "meaning": "The route is not published on the open API."
971
+ },
972
+ {
973
+ "code": "gateway.route_sunset",
974
+ "http_status": [
975
+ 410
976
+ ],
977
+ "retryable": false,
978
+ "refused_before_run": false,
979
+ "meaning": "The route has passed its sunset date."
980
+ },
981
+ {
982
+ "code": "gateway.scope_missing",
983
+ "http_status": [
984
+ 403
985
+ ],
986
+ "retryable": false,
987
+ "refused_before_run": false,
988
+ "meaning": "The client or app token does not hold the scope the route needs."
989
+ },
990
+ {
991
+ "code": "gateway.too_many_files",
992
+ "http_status": [
993
+ 422
994
+ ],
995
+ "retryable": false,
996
+ "refused_before_run": false,
997
+ "meaning": "The multipart upload carries more than one file part."
998
+ },
999
+ {
1000
+ "code": "gateway.too_many_in_flight",
1001
+ "http_status": [
1002
+ 429
1003
+ ],
1004
+ "retryable": true,
1005
+ "refused_before_run": true,
1006
+ "meaning": "A concurrency cap (client, workspace or global) is full; see Retry-After and X-Gateway-Limit-Scope."
1007
+ },
1008
+ {
1009
+ "code": "gateway.upload_idle_timeout",
1010
+ "http_status": [
1011
+ 408
1012
+ ],
1013
+ "retryable": false,
1014
+ "refused_before_run": false,
1015
+ "meaning": "The upload body stopped arriving, or arrived below the minimum pace."
1016
+ },
1017
+ {
1018
+ "code": "idempotency.invalid_key",
1019
+ "http_status": [
1020
+ 422
1021
+ ],
1022
+ "retryable": false,
1023
+ "refused_before_run": false,
1024
+ "meaning": "The Idempotency-Key header is not an acceptable key."
1025
+ },
1026
+ {
1027
+ "code": "idempotency.key_reused",
1028
+ "http_status": [
1029
+ 200,
1030
+ 409
1031
+ ],
1032
+ "retryable": false,
1033
+ "refused_before_run": false,
1034
+ "meaning": "The Idempotency-Key was already used with a different request body (200 inside a JSON-RPC error).",
1035
+ "carried_in": "both"
1036
+ },
1037
+ {
1038
+ "code": "kb.embedding_dimension_mismatch",
1039
+ "http_status": [
1040
+ 409
1041
+ ],
1042
+ "retryable": false,
1043
+ "refused_before_run": false,
1044
+ "meaning": "The query vector's width does not match the knowledge base's index."
1045
+ },
1046
+ {
1047
+ "code": "kb.embedding_unavailable",
1048
+ "http_status": [
1049
+ 503
1050
+ ],
1051
+ "retryable": true,
1052
+ "refused_before_run": false,
1053
+ "meaning": "The knowledge base's embedding model cannot be used right now."
1054
+ },
1055
+ {
1056
+ "code": "kb.reranker_unavailable",
1057
+ "http_status": [
1058
+ 503
1059
+ ],
1060
+ "retryable": true,
1061
+ "refused_before_run": false,
1062
+ "meaning": "The reranker model cannot be used right now."
1063
+ },
1064
+ {
1065
+ "code": "knowledge_base.already_exists",
1066
+ "http_status": [
1067
+ 409
1068
+ ],
1069
+ "retryable": false,
1070
+ "refused_before_run": false,
1071
+ "meaning": "A knowledge base of this app with this name already exists in the workspace."
1072
+ },
1073
+ {
1074
+ "code": "knowledge_base.app_token_required",
1075
+ "http_status": [
1076
+ 403
1077
+ ],
1078
+ "retryable": false,
1079
+ "refused_before_run": false,
1080
+ "meaning": "The knowledge base is owned by an app and only that app's token may change it."
1081
+ },
1082
+ {
1083
+ "code": "knowledge_base.content_type_mismatch",
1084
+ "http_status": [
1085
+ 422
1086
+ ],
1087
+ "retryable": false,
1088
+ "refused_before_run": false,
1089
+ "meaning": "The uploaded bytes do not match the file name's type."
1090
+ },
1091
+ {
1092
+ "code": "knowledge_base.document_delete_forbidden",
1093
+ "http_status": [
1094
+ 403
1095
+ ],
1096
+ "retryable": false,
1097
+ "refused_before_run": false,
1098
+ "meaning": "The caller may not delete this document."
1099
+ },
1100
+ {
1101
+ "code": "knowledge_base.document_not_found",
1102
+ "http_status": [
1103
+ 404
1104
+ ],
1105
+ "retryable": false,
1106
+ "refused_before_run": false,
1107
+ "meaning": "The document does not exist in this knowledge base."
1108
+ },
1109
+ {
1110
+ "code": "knowledge_base.duplicate_document",
1111
+ "http_status": [
1112
+ 409
1113
+ ],
1114
+ "retryable": false,
1115
+ "refused_before_run": false,
1116
+ "meaning": "A document with the same content already exists in the knowledge base."
1117
+ },
1118
+ {
1119
+ "code": "knowledge_base.empty_file",
1120
+ "http_status": [
1121
+ 400
1122
+ ],
1123
+ "retryable": false,
1124
+ "refused_before_run": false,
1125
+ "meaning": "The uploaded file is empty."
1126
+ },
1127
+ {
1128
+ "code": "knowledge_base.external_read_only",
1129
+ "http_status": [
1130
+ 409
1131
+ ],
1132
+ "retryable": false,
1133
+ "refused_before_run": false,
1134
+ "meaning": "An external knowledge base is read-only here."
1135
+ },
1136
+ {
1137
+ "code": "knowledge_base.file_required",
1138
+ "http_status": [
1139
+ 422
1140
+ ],
1141
+ "retryable": false,
1142
+ "refused_before_run": false,
1143
+ "meaning": "The upload carries no file part."
1144
+ },
1145
+ {
1146
+ "code": "knowledge_base.file_too_large",
1147
+ "http_status": [
1148
+ 413
1149
+ ],
1150
+ "retryable": false,
1151
+ "refused_before_run": false,
1152
+ "meaning": "The file is larger than the upload limit."
1153
+ },
1154
+ {
1155
+ "code": "knowledge_base.index_failed",
1156
+ "http_status": [
1157
+ 200
1158
+ ],
1159
+ "retryable": false,
1160
+ "refused_before_run": false,
1161
+ "meaning": "A failed document's code when the worker stored none; appears as the document's code field, never as an HTTP error.",
1162
+ "carried_in": "body"
1163
+ },
1164
+ {
1165
+ "code": "knowledge_base.index_unavailable",
1166
+ "http_status": [
1167
+ 503
1168
+ ],
1169
+ "retryable": true,
1170
+ "refused_before_run": false,
1171
+ "meaning": "The indexing queue is unavailable; the document was discarded. Retryable, but an upload is repeated only when the request is safe to repeat (spec 4.2): without that the SDK raises and the caller may send the upload again."
1172
+ },
1173
+ {
1174
+ "code": "knowledge_base.invalid_file_name",
1175
+ "http_status": [
1176
+ 400
1177
+ ],
1178
+ "retryable": false,
1179
+ "refused_before_run": false,
1180
+ "meaning": "The upload's file name is empty, too long, or holds a control character or path separator."
1181
+ },
1182
+ {
1183
+ "code": "knowledge_base.invalid_name",
1184
+ "http_status": [
1185
+ 400
1186
+ ],
1187
+ "retryable": false,
1188
+ "refused_before_run": false,
1189
+ "meaning": "The knowledge base name is empty or not acceptable."
1190
+ },
1191
+ {
1192
+ "code": "knowledge_base.no_collection",
1193
+ "http_status": [
1194
+ 409
1195
+ ],
1196
+ "retryable": false,
1197
+ "refused_before_run": false,
1198
+ "meaning": "The knowledge base has no vector collection to read."
1199
+ },
1200
+ {
1201
+ "code": "knowledge_base.no_content",
1202
+ "http_status": [
1203
+ 200
1204
+ ],
1205
+ "retryable": false,
1206
+ "refused_before_run": false,
1207
+ "meaning": "A failed document from which no text could be extracted; appears as the document's code field, never as an HTTP error.",
1208
+ "carried_in": "body"
1209
+ },
1210
+ {
1211
+ "code": "knowledge_base.not_found",
1212
+ "http_status": [
1213
+ 404
1214
+ ],
1215
+ "retryable": false,
1216
+ "refused_before_run": false,
1217
+ "meaning": "The knowledge base does not exist, or is not visible to the caller."
1218
+ },
1219
+ {
1220
+ "code": "knowledge_base.owned_by_other_app",
1221
+ "http_status": [
1222
+ 403
1223
+ ],
1224
+ "retryable": false,
1225
+ "refused_before_run": false,
1226
+ "meaning": "The knowledge base belongs to another app."
1227
+ },
1228
+ {
1229
+ "code": "knowledge_base.unsupported_file_type",
1230
+ "http_status": [
1231
+ 400
1232
+ ],
1233
+ "retryable": false,
1234
+ "refused_before_run": false,
1235
+ "meaning": "The file type is not supported for indexing."
1236
+ },
1237
+ {
1238
+ "code": "knowledge_base.upload_incomplete",
1239
+ "http_status": [
1240
+ 400
1241
+ ],
1242
+ "retryable": false,
1243
+ "refused_before_run": false,
1244
+ "meaning": "The upload ended before the whole body arrived."
1245
+ },
1246
+ {
1247
+ "code": "knowledge_base.write_forbidden",
1248
+ "http_status": [
1249
+ 403
1250
+ ],
1251
+ "retryable": false,
1252
+ "refused_before_run": false,
1253
+ "meaning": "The knowledge base is visible to the caller but not writable by it."
1254
+ },
1255
+ {
1256
+ "code": "llm.image_invalid",
1257
+ "http_status": [
1258
+ 422
1259
+ ],
1260
+ "retryable": false,
1261
+ "refused_before_run": false,
1262
+ "meaning": "An image in the request is not a valid image."
1263
+ },
1264
+ {
1265
+ "code": "llm.image_too_large",
1266
+ "http_status": [
1267
+ 422
1268
+ ],
1269
+ "retryable": false,
1270
+ "refused_before_run": false,
1271
+ "meaning": "An image in the request is larger than the limit."
1272
+ },
1273
+ {
1274
+ "code": "llm.image_too_many",
1275
+ "http_status": [
1276
+ 422
1277
+ ],
1278
+ "retryable": false,
1279
+ "refused_before_run": false,
1280
+ "meaning": "The request carries more images than allowed."
1281
+ },
1282
+ {
1283
+ "code": "llm.stream_unsupported",
1284
+ "http_status": [
1285
+ 422
1286
+ ],
1287
+ "retryable": false,
1288
+ "refused_before_run": false,
1289
+ "meaning": "Streaming is not supported on this route."
1290
+ },
1291
+ {
1292
+ "code": "llm.upstream_error",
1293
+ "http_status": [
1294
+ 502,
1295
+ 504
1296
+ ],
1297
+ "retryable": false,
1298
+ "refused_before_run": false,
1299
+ "meaning": "The model provider failed (502, reason provider_error) or timed out (504, reason timeout). The detail is an object with code and reason."
1300
+ },
1301
+ {
1302
+ "code": "model.adapter_not_served",
1303
+ "http_status": [
1304
+ 422
1305
+ ],
1306
+ "retryable": false,
1307
+ "refused_before_run": false,
1308
+ "meaning": "An adapter model was asked for on an endpoint that does not serve it live. (a model-door refusal; the open chat door answers it as 422 with this code)"
1309
+ },
1310
+ {
1311
+ "code": "model.alias_unresolved",
1312
+ "http_status": [
1313
+ 422
1314
+ ],
1315
+ "retryable": false,
1316
+ "refused_before_run": false,
1317
+ "meaning": "The model alias does not resolve to a usable model in this workspace."
1318
+ },
1319
+ {
1320
+ "code": "model.endpoint_unreachable",
1321
+ "http_status": [
1322
+ 422
1323
+ ],
1324
+ "retryable": false,
1325
+ "refused_before_run": false,
1326
+ "meaning": "The model this call would run on is recorded as dead. (a model-door refusal; the open chat door answers it as 422 with this code)"
1327
+ },
1328
+ {
1329
+ "code": "model.no_healthy_model",
1330
+ "http_status": [
1331
+ 422
1332
+ ],
1333
+ "retryable": false,
1334
+ "refused_before_run": false,
1335
+ "meaning": "Every model the caller may use is recorded as dead. (a model-door refusal; the open chat door answers it as 422 with this code)"
1336
+ },
1337
+ {
1338
+ "code": "model.not_deployed",
1339
+ "http_status": [
1340
+ 422
1341
+ ],
1342
+ "retryable": false,
1343
+ "refused_before_run": false,
1344
+ "meaning": "A platform-trained model has no running deployment. (a model-door refusal; the open chat door answers it as 422 with this code)"
1345
+ },
1346
+ {
1347
+ "code": "model.not_embedding",
1348
+ "http_status": [
1349
+ 422
1350
+ ],
1351
+ "retryable": false,
1352
+ "refused_before_run": false,
1353
+ "meaning": "The model is not an embedding model."
1354
+ },
1355
+ {
1356
+ "code": "model.not_found",
1357
+ "http_status": [
1358
+ 404
1359
+ ],
1360
+ "retryable": false,
1361
+ "refused_before_run": false,
1362
+ "meaning": "The model does not exist, or is not visible to the caller."
1363
+ },
1364
+ {
1365
+ "code": "model.not_servable",
1366
+ "http_status": [
1367
+ 422
1368
+ ],
1369
+ "retryable": false,
1370
+ "refused_before_run": false,
1371
+ "meaning": "The model cannot be called or scored (no deployment and no scoreable adapter, or no base model). (a model-door refusal; the open chat door answers it as 422 with this code)"
1372
+ },
1373
+ {
1374
+ "code": "model.not_usable",
1375
+ "http_status": [
1376
+ 422
1377
+ ],
1378
+ "retryable": false,
1379
+ "refused_before_run": false,
1380
+ "meaning": "The model exists but cannot be used (no running deployment, no endpoint, unsupported provider)."
1381
+ },
1382
+ {
1383
+ "code": "model.platform_key_not_allowed",
1384
+ "http_status": [
1385
+ 422
1386
+ ],
1387
+ "retryable": false,
1388
+ "refused_before_run": false,
1389
+ "meaning": "The model has no key of its own and would spend the platform's provider key."
1390
+ },
1391
+ {
1392
+ "code": "model.platform_key_shadowed",
1393
+ "http_status": [
1394
+ 422
1395
+ ],
1396
+ "retryable": false,
1397
+ "refused_before_run": false,
1398
+ "meaning": "The model's provider key is shadowed by the platform's, which may not be spent."
1399
+ },
1400
+ {
1401
+ "code": "model.provider_not_configured",
1402
+ "http_status": [
1403
+ 422
1404
+ ],
1405
+ "retryable": false,
1406
+ "refused_before_run": false,
1407
+ "meaning": "A platform-owned keyless model of a billed provider, and no environment key is set for it. (a model-door refusal; the open chat door answers it as 422 with this code)"
1408
+ },
1409
+ {
1410
+ "code": "model.provider_removed",
1411
+ "http_status": [
1412
+ 422
1413
+ ],
1414
+ "retryable": false,
1415
+ "refused_before_run": false,
1416
+ "meaning": "The model's provider is no longer supported."
1417
+ },
1418
+ {
1419
+ "code": "model.provider_unsupported",
1420
+ "http_status": [
1421
+ 422
1422
+ ],
1423
+ "retryable": false,
1424
+ "refused_before_run": false,
1425
+ "meaning": "The model's provider is not supported."
1426
+ },
1427
+ {
1428
+ "code": "model.refused",
1429
+ "http_status": [
1430
+ 422
1431
+ ],
1432
+ "retryable": false,
1433
+ "refused_before_run": false,
1434
+ "meaning": "The generic code of the door-refusal family. (a model-door refusal; the open chat door answers it as 422 with this code)"
1435
+ },
1436
+ {
1437
+ "code": "model.vision_unsupported",
1438
+ "http_status": [
1439
+ 422
1440
+ ],
1441
+ "retryable": false,
1442
+ "refused_before_run": false,
1443
+ "meaning": "The request carries images but the model does not see images."
1444
+ },
1445
+ {
1446
+ "code": "model_endpoint.address_reserved",
1447
+ "http_status": [
1448
+ 422
1449
+ ],
1450
+ "retryable": false,
1451
+ "refused_before_run": false,
1452
+ "meaning": "The user-registered endpoint's host resolves to an address no allowlist reaches. (a model-door refusal; the open chat door answers it as 422 with this code)"
1453
+ },
1454
+ {
1455
+ "code": "model_endpoint.host_not_allowed",
1456
+ "http_status": [
1457
+ 422
1458
+ ],
1459
+ "retryable": false,
1460
+ "refused_before_run": false,
1461
+ "meaning": "The user-registered endpoint's stored URL no longer passes the host rule. (a model-door refusal; the open chat door answers it as 422 with this code)"
1462
+ },
1463
+ {
1464
+ "code": "model_endpoint.host_unresolvable",
1465
+ "http_status": [
1466
+ 422
1467
+ ],
1468
+ "retryable": false,
1469
+ "refused_before_run": false,
1470
+ "meaning": "The user-registered endpoint's host name gives no address. (a model-door refusal; the open chat door answers it as 422 with this code)"
1471
+ },
1472
+ {
1473
+ "code": "model_endpoint.key_unreadable",
1474
+ "http_status": [
1475
+ 422
1476
+ ],
1477
+ "retryable": false,
1478
+ "refused_before_run": false,
1479
+ "meaning": "The stored key of the user-registered endpoint cannot be decrypted; the owner re-enters it. (a model-door refusal; the open chat door answers it as 422 with this code)"
1480
+ },
1481
+ {
1482
+ "code": "model_endpoint.not_available",
1483
+ "http_status": [
1484
+ 422
1485
+ ],
1486
+ "retryable": false,
1487
+ "refused_before_run": false,
1488
+ "meaning": "The user-registered endpoint has no running external endpoint. (a model-door refusal; the open chat door answers it as 422 with this code)"
1489
+ },
1490
+ {
1491
+ "code": "model_endpoint.refused",
1492
+ "http_status": [
1493
+ 422
1494
+ ],
1495
+ "retryable": false,
1496
+ "refused_before_run": false,
1497
+ "meaning": "The generic code of the user-registered endpoint refusals. (a model-door refusal; the open chat door answers it as 422 with this code)"
1498
+ },
1499
+ {
1500
+ "code": "model_endpoint.task_unsupported",
1501
+ "http_status": [
1502
+ 422
1503
+ ],
1504
+ "retryable": false,
1505
+ "refused_before_run": false,
1506
+ "meaning": "The user-registered endpoint does not serve the task asked for. (a model-door refusal; the open chat door answers it as 422 with this code)"
1507
+ },
1508
+ {
1509
+ "code": "ontology.app_managed",
1510
+ "http_status": [
1511
+ 409
1512
+ ],
1513
+ "retryable": false,
1514
+ "refused_before_run": false,
1515
+ "meaning": "The ontology is managed by an app; write it through the open API."
1516
+ },
1517
+ {
1518
+ "code": "ontology.app_token_required",
1519
+ "http_status": [
1520
+ 403
1521
+ ],
1522
+ "retryable": false,
1523
+ "refused_before_run": false,
1524
+ "meaning": "The ontology is owned by an app and only that app's token may change it."
1525
+ },
1526
+ {
1527
+ "code": "ontology.document_too_large",
1528
+ "http_status": [
1529
+ 413
1530
+ ],
1531
+ "retryable": false,
1532
+ "refused_before_run": false,
1533
+ "meaning": "The ontology document exceeds a size or count limit."
1534
+ },
1535
+ {
1536
+ "code": "ontology.invalid_document",
1537
+ "http_status": [
1538
+ 422
1539
+ ],
1540
+ "retryable": false,
1541
+ "refused_before_run": false,
1542
+ "meaning": "The ontology document is invalid; the detail names the path and reason."
1543
+ },
1544
+ {
1545
+ "code": "ontology.name_exists",
1546
+ "http_status": [
1547
+ 409
1548
+ ],
1549
+ "retryable": false,
1550
+ "refused_before_run": false,
1551
+ "meaning": "An ontology of this app with this name exists; the detail carries existing_id."
1552
+ },
1553
+ {
1554
+ "code": "ontology.not_found",
1555
+ "http_status": [
1556
+ 404
1557
+ ],
1558
+ "retryable": false,
1559
+ "refused_before_run": false,
1560
+ "meaning": "The ontology does not exist, or is not visible to the caller."
1561
+ },
1562
+ {
1563
+ "code": "ontology.owned_by_other_app",
1564
+ "http_status": [
1565
+ 403
1566
+ ],
1567
+ "retryable": false,
1568
+ "refused_before_run": false,
1569
+ "meaning": "The ontology belongs to another app."
1570
+ },
1571
+ {
1572
+ "code": "ontology.version_conflict",
1573
+ "http_status": [
1574
+ 409
1575
+ ],
1576
+ "retryable": false,
1577
+ "refused_before_run": false,
1578
+ "meaning": "The save was based on an older version; the detail carries current_version."
1579
+ },
1580
+ {
1581
+ "code": "ontology.version_not_found",
1582
+ "http_status": [
1583
+ 404
1584
+ ],
1585
+ "retryable": false,
1586
+ "refused_before_run": false,
1587
+ "meaning": "The ontology has no such version."
1588
+ },
1589
+ {
1590
+ "code": "ontology.write_forbidden",
1591
+ "http_status": [
1592
+ 403
1593
+ ],
1594
+ "retryable": false,
1595
+ "refused_before_run": false,
1596
+ "meaning": "The ontology is visible to the caller but not writable by it."
1597
+ },
1598
+ {
1599
+ "code": "request.invalid",
1600
+ "http_status": [
1601
+ 422
1602
+ ],
1603
+ "retryable": false,
1604
+ "refused_before_run": false,
1605
+ "meaning": "The request failed validation (the open API's list-shaped 422 body); the SDKs name it so.",
1606
+ "sdk_synthesised": true
1607
+ },
1608
+ {
1609
+ "code": "request.nul_byte",
1610
+ "http_status": [
1611
+ 422
1612
+ ],
1613
+ "retryable": false,
1614
+ "refused_before_run": false,
1615
+ "meaning": "The request carries a NUL character (raw in the body, or \\u0000 the database refuses)."
1616
+ },
1617
+ {
1618
+ "code": "run.already_retried",
1619
+ "http_status": [
1620
+ 409
1621
+ ],
1622
+ "retryable": false,
1623
+ "refused_before_run": false,
1624
+ "meaning": "The run was already retried."
1625
+ },
1626
+ {
1627
+ "code": "run.busy",
1628
+ "http_status": [
1629
+ 409
1630
+ ],
1631
+ "retryable": false,
1632
+ "refused_before_run": false,
1633
+ "meaning": "The run is busy; its cancel could not take the lock in time."
1634
+ },
1635
+ {
1636
+ "code": "run.dispatch_failed",
1637
+ "http_status": [
1638
+ 503
1639
+ ],
1640
+ "retryable": false,
1641
+ "refused_before_run": false,
1642
+ "meaning": "The run was filed but could not be queued; it is marked failed."
1643
+ },
1644
+ {
1645
+ "code": "run.not_terminal",
1646
+ "http_status": [
1647
+ 409
1648
+ ],
1649
+ "retryable": false,
1650
+ "refused_before_run": false,
1651
+ "meaning": "Only a finished run can be retried."
1652
+ },
1653
+ {
1654
+ "code": "run.nothing_to_retry",
1655
+ "http_status": [
1656
+ 409
1657
+ ],
1658
+ "retryable": false,
1659
+ "refused_before_run": false,
1660
+ "meaning": "The run has nothing to retry."
1661
+ },
1662
+ {
1663
+ "code": "run.retry_unsupported",
1664
+ "http_status": [
1665
+ 409
1666
+ ],
1667
+ "retryable": false,
1668
+ "refused_before_run": false,
1669
+ "meaning": "This kind of run cannot be retried."
1670
+ },
1671
+ {
1672
+ "code": "server.internal_error",
1673
+ "http_status": [
1674
+ 500
1675
+ ],
1676
+ "retryable": false,
1677
+ "refused_before_run": false,
1678
+ "meaning": "An unexpected failure with no code of its own (the API's catch-all handler)."
1679
+ },
1680
+ {
1681
+ "code": "toolchain_task.all_rows_invalid",
1682
+ "http_status": [
1683
+ 200
1684
+ ],
1685
+ "retryable": false,
1686
+ "refused_before_run": false,
1687
+ "meaning": "Failure code: every output row was dropped by the purpose validator.",
1688
+ "carried_in": "body"
1689
+ },
1690
+ {
1691
+ "code": "toolchain_task.callback_address_not_allowed",
1692
+ "http_status": [
1693
+ 200
1694
+ ],
1695
+ "retryable": false,
1696
+ "refused_before_run": false,
1697
+ "meaning": "Callback delivery outcome: the host resolved to a non-public address.",
1698
+ "carried_in": "body"
1699
+ },
1700
+ {
1701
+ "code": "toolchain_task.callback_host_not_allowed",
1702
+ "http_status": [
1703
+ 200,
1704
+ 422
1705
+ ],
1706
+ "retryable": false,
1707
+ "refused_before_run": false,
1708
+ "meaning": "The callback host is not on the allowlist (422 at filing, or a delivery outcome).",
1709
+ "carried_in": "both"
1710
+ },
1711
+ {
1712
+ "code": "toolchain_task.callback_http_error",
1713
+ "http_status": [
1714
+ 200
1715
+ ],
1716
+ "retryable": false,
1717
+ "refused_before_run": false,
1718
+ "meaning": "Callback delivery outcome: the receiver answered non-2xx.",
1719
+ "carried_in": "body"
1720
+ },
1721
+ {
1722
+ "code": "toolchain_task.callback_not_inherited",
1723
+ "http_status": [
1724
+ 200
1725
+ ],
1726
+ "retryable": false,
1727
+ "refused_before_run": false,
1728
+ "meaning": "Retry note: another caller's retry does not inherit the parent's callback.",
1729
+ "carried_in": "body"
1730
+ },
1731
+ {
1732
+ "code": "toolchain_task.callback_not_supported",
1733
+ "http_status": [
1734
+ 422
1735
+ ],
1736
+ "retryable": false,
1737
+ "refused_before_run": false,
1738
+ "meaning": "Only an open-API client may set a callback."
1739
+ },
1740
+ {
1741
+ "code": "toolchain_task.callback_proxy_unsupported",
1742
+ "http_status": [
1743
+ 200
1744
+ ],
1745
+ "retryable": false,
1746
+ "refused_before_run": false,
1747
+ "meaning": "Callback delivery outcome: delivery through the egress proxy is not supported.",
1748
+ "carried_in": "body"
1749
+ },
1750
+ {
1751
+ "code": "toolchain_task.callback_request_failed",
1752
+ "http_status": [
1753
+ 200
1754
+ ],
1755
+ "retryable": false,
1756
+ "refused_before_run": false,
1757
+ "meaning": "Callback delivery outcome: transport, TLS or timeout failure.",
1758
+ "carried_in": "body"
1759
+ },
1760
+ {
1761
+ "code": "toolchain_task.callback_secret_missing",
1762
+ "http_status": [
1763
+ 200,
1764
+ 422
1765
+ ],
1766
+ "retryable": false,
1767
+ "refused_before_run": false,
1768
+ "meaning": "No live callback secret exists to sign the callback (422 at filing, or a delivery outcome).",
1769
+ "carried_in": "both"
1770
+ },
1771
+ {
1772
+ "code": "toolchain_task.callback_url_invalid",
1773
+ "http_status": [
1774
+ 422
1775
+ ],
1776
+ "retryable": false,
1777
+ "refused_before_run": false,
1778
+ "meaning": "The callback URL is malformed, too long, or not https."
1779
+ },
1780
+ {
1781
+ "code": "toolchain_task.cancelled",
1782
+ "http_status": [
1783
+ 200
1784
+ ],
1785
+ "retryable": false,
1786
+ "refused_before_run": false,
1787
+ "meaning": "Failure code: the task was cancelled.",
1788
+ "carried_in": "body"
1789
+ },
1790
+ {
1791
+ "code": "toolchain_task.empty_output",
1792
+ "http_status": [
1793
+ 200
1794
+ ],
1795
+ "retryable": false,
1796
+ "refused_before_run": false,
1797
+ "meaning": "Failure code: the task ran and produced no rows and no report.",
1798
+ "carried_in": "body"
1799
+ },
1800
+ {
1801
+ "code": "toolchain_task.export_not_ready",
1802
+ "http_status": [
1803
+ 409
1804
+ ],
1805
+ "retryable": false,
1806
+ "refused_before_run": false,
1807
+ "meaning": "The task has no output version to export yet."
1808
+ },
1809
+ {
1810
+ "code": "toolchain_task.failed",
1811
+ "http_status": [
1812
+ 200
1813
+ ],
1814
+ "retryable": false,
1815
+ "refused_before_run": false,
1816
+ "meaning": "Failure code: the fixed fallback for any other failure.",
1817
+ "carried_in": "body"
1818
+ },
1819
+ {
1820
+ "code": "toolchain_task.input_layout_unsupported",
1821
+ "http_status": [
1822
+ 200
1823
+ ],
1824
+ "retryable": false,
1825
+ "refused_before_run": false,
1826
+ "meaning": "Failure code: the input version is a corpus stored as parts, which a task cannot read (create refuses it with version.layout_unsupported; this code marks one that arrived late).",
1827
+ "carried_in": "body"
1828
+ },
1829
+ {
1830
+ "code": "toolchain_task.input_not_found",
1831
+ "http_status": [
1832
+ 404
1833
+ ],
1834
+ "retryable": false,
1835
+ "refused_before_run": false,
1836
+ "meaning": "The input dataset version is missing or not readable."
1837
+ },
1838
+ {
1839
+ "code": "toolchain_task.input_too_large",
1840
+ "http_status": [
1841
+ 200
1842
+ ],
1843
+ "retryable": false,
1844
+ "refused_before_run": false,
1845
+ "meaning": "Failure code: the input has more rows than a task may read.",
1846
+ "carried_in": "body"
1847
+ },
1848
+ {
1849
+ "code": "toolchain_task.input_unavailable",
1850
+ "http_status": [
1851
+ 200
1852
+ ],
1853
+ "retryable": false,
1854
+ "refused_before_run": false,
1855
+ "meaning": "Failure code: the input could not be read when the task ran.",
1856
+ "carried_in": "body"
1857
+ },
1858
+ {
1859
+ "code": "toolchain_task.invalid_params",
1860
+ "http_status": [
1861
+ 422
1862
+ ],
1863
+ "retryable": false,
1864
+ "refused_before_run": false,
1865
+ "meaning": "The task's parameters are invalid for the toolchain."
1866
+ },
1867
+ {
1868
+ "code": "toolchain_task.not_cancellable",
1869
+ "http_status": [
1870
+ 409
1871
+ ],
1872
+ "retryable": false,
1873
+ "refused_before_run": false,
1874
+ "meaning": "The task is already finished."
1875
+ },
1876
+ {
1877
+ "code": "toolchain_task.not_found",
1878
+ "http_status": [
1879
+ 404
1880
+ ],
1881
+ "retryable": false,
1882
+ "refused_before_run": false,
1883
+ "meaning": "The task does not exist, or is not visible to the caller."
1884
+ },
1885
+ {
1886
+ "code": "toolchain_task.not_permitted",
1887
+ "http_status": [
1888
+ 200,
1889
+ 403
1890
+ ],
1891
+ "retryable": false,
1892
+ "refused_before_run": false,
1893
+ "meaning": "The task's user lost access between filing and running.",
1894
+ "carried_in": "both"
1895
+ },
1896
+ {
1897
+ "code": "toolchain_task.not_retryable",
1898
+ "http_status": [
1899
+ 409
1900
+ ],
1901
+ "retryable": false,
1902
+ "refused_before_run": false,
1903
+ "meaning": "The task cannot be retried in its state."
1904
+ },
1905
+ {
1906
+ "code": "toolchain_task.output_not_flat",
1907
+ "http_status": [
1908
+ 200,
1909
+ 422
1910
+ ],
1911
+ "retryable": false,
1912
+ "refused_before_run": false,
1913
+ "meaning": "The destination dataset is not a flat dataset.",
1914
+ "carried_in": "both"
1915
+ },
1916
+ {
1917
+ "code": "toolchain_task.output_not_found",
1918
+ "http_status": [
1919
+ 200,
1920
+ 404
1921
+ ],
1922
+ "retryable": false,
1923
+ "refused_before_run": false,
1924
+ "meaning": "The destination dataset is missing or not visible.",
1925
+ "carried_in": "both"
1926
+ },
1927
+ {
1928
+ "code": "toolchain_task.output_too_large",
1929
+ "http_status": [
1930
+ 200
1931
+ ],
1932
+ "retryable": false,
1933
+ "refused_before_run": false,
1934
+ "meaning": "Failure code: the output is larger than a task may write.",
1935
+ "carried_in": "body"
1936
+ },
1937
+ {
1938
+ "code": "toolchain_task.output_write_forbidden",
1939
+ "http_status": [
1940
+ 200,
1941
+ 403
1942
+ ],
1943
+ "retryable": false,
1944
+ "refused_before_run": false,
1945
+ "meaning": "The destination dataset is readable but not writable by the caller.",
1946
+ "carried_in": "both"
1947
+ },
1948
+ {
1949
+ "code": "toolchain_task.result_not_ready",
1950
+ "http_status": [
1951
+ 409
1952
+ ],
1953
+ "retryable": false,
1954
+ "refused_before_run": false,
1955
+ "meaning": "The task has not succeeded, so it has no result."
1956
+ },
1957
+ {
1958
+ "code": "toolchain_task.rows_not_usable",
1959
+ "http_status": [
1960
+ 200
1961
+ ],
1962
+ "retryable": false,
1963
+ "refused_before_run": false,
1964
+ "meaning": "Failure code: a row names a stored file or non-inline image.",
1965
+ "carried_in": "body"
1966
+ },
1967
+ {
1968
+ "code": "toolchain_task.shard_failed",
1969
+ "http_status": [
1970
+ 200
1971
+ ],
1972
+ "retryable": false,
1973
+ "refused_before_run": false,
1974
+ "meaning": "Failure code: the toolchain raised or declined on one or more shards.",
1975
+ "carried_in": "body"
1976
+ },
1977
+ {
1978
+ "code": "toolchain_task.shard_unavailable",
1979
+ "http_status": [
1980
+ 200
1981
+ ],
1982
+ "retryable": false,
1983
+ "refused_before_run": false,
1984
+ "meaning": "Failure code: transient failures used up every attempt of a shard.",
1985
+ "carried_in": "body"
1986
+ },
1987
+ {
1988
+ "code": "toolchain_task.time_limit",
1989
+ "http_status": [
1990
+ 200
1991
+ ],
1992
+ "retryable": false,
1993
+ "refused_before_run": false,
1994
+ "meaning": "Failure code: the task used up its time budget; nothing was published.",
1995
+ "carried_in": "body"
1996
+ },
1997
+ {
1998
+ "code": "toolchain_task.too_many_active",
1999
+ "http_status": [
2000
+ 429
2001
+ ],
2002
+ "retryable": false,
2003
+ "refused_before_run": false,
2004
+ "meaning": "The workspace has the maximum number of live tasks."
2005
+ },
2006
+ {
2007
+ "code": "toolchain_task.toolchain_not_found",
2008
+ "http_status": [
2009
+ 404
2010
+ ],
2011
+ "retryable": false,
2012
+ "refused_before_run": false,
2013
+ "meaning": "The toolchain does not exist."
2014
+ },
2015
+ {
2016
+ "code": "toolchain_task.toolchain_not_runnable",
2017
+ "http_status": [
2018
+ 200,
2019
+ 409
2020
+ ],
2021
+ "retryable": false,
2022
+ "refused_before_run": false,
2023
+ "meaning": "The toolchain is withdrawn, not runnable, or its pinned version is not in code.",
2024
+ "carried_in": "both"
2025
+ },
2026
+ {
2027
+ "code": "toolchain_task.worker_lost",
2028
+ "http_status": [
2029
+ 200
2030
+ ],
2031
+ "retryable": false,
2032
+ "refused_before_run": false,
2033
+ "meaning": "Failure code: the worker running the task was lost.",
2034
+ "carried_in": "body"
2035
+ },
2036
+ {
2037
+ "code": "training.artifact_unavailable",
2038
+ "http_status": [
2039
+ 503
2040
+ ],
2041
+ "retryable": true,
2042
+ "refused_before_run": false,
2043
+ "meaning": "The trained model's artifact cannot be read right now."
2044
+ },
2045
+ {
2046
+ "code": "training.base_model_unavailable",
2047
+ "http_status": [
2048
+ 200
2049
+ ],
2050
+ "retryable": false,
2051
+ "refused_before_run": false,
2052
+ "meaning": "Job failure code: the base model could not be loaded.",
2053
+ "carried_in": "body"
2054
+ },
2055
+ {
2056
+ "code": "training.cancelled",
2057
+ "http_status": [
2058
+ 200
2059
+ ],
2060
+ "retryable": false,
2061
+ "refused_before_run": false,
2062
+ "meaning": "Job failure code: the job was cancelled.",
2063
+ "carried_in": "body"
2064
+ },
2065
+ {
2066
+ "code": "training.checksum_mismatch",
2067
+ "http_status": [
2068
+ 200
2069
+ ],
2070
+ "retryable": false,
2071
+ "refused_before_run": false,
2072
+ "meaning": "Made by the SDK when a model download's bytes do not hash to the X-Model-Sha256 header the platform sent (the answer was a 200; the SDK raises after streaming it).",
2073
+ "carried_in": "body",
2074
+ "sdk_synthesised": true
2075
+ },
2076
+ {
2077
+ "code": "training.checksum_missing",
2078
+ "http_status": [
2079
+ 200
2080
+ ],
2081
+ "retryable": false,
2082
+ "refused_before_run": false,
2083
+ "meaning": "Made by the SDK when a model download answers without a usable X-Model-Sha256 header (missing, empty or not 64 hex digits): refused before anything is written (the answer was a 200). The caller opts out with require_checksum=False, for old or foreign servers only.",
2084
+ "carried_in": "body",
2085
+ "sdk_synthesised": true
2086
+ },
2087
+ {
2088
+ "code": "training.class_too_small",
2089
+ "http_status": [
2090
+ 422
2091
+ ],
2092
+ "retryable": false,
2093
+ "refused_before_run": false,
2094
+ "meaning": "A class has fewer images than the minimum."
2095
+ },
2096
+ {
2097
+ "code": "training.dataset_invalid",
2098
+ "http_status": [
2099
+ 200
2100
+ ],
2101
+ "retryable": false,
2102
+ "refused_before_run": false,
2103
+ "meaning": "Job failure code: the trainer found the dataset unusable.",
2104
+ "carried_in": "body"
2105
+ },
2106
+ {
2107
+ "code": "training.dataset_not_found",
2108
+ "http_status": [
2109
+ 404
2110
+ ],
2111
+ "retryable": false,
2112
+ "refused_before_run": false,
2113
+ "meaning": "The dataset does not exist, or is not visible to the caller."
2114
+ },
2115
+ {
2116
+ "code": "training.dataset_too_large",
2117
+ "http_status": [
2118
+ 413
2119
+ ],
2120
+ "retryable": false,
2121
+ "refused_before_run": false,
2122
+ "meaning": "The dataset is larger than the limit."
2123
+ },
2124
+ {
2125
+ "code": "training.executor_unavailable",
2126
+ "http_status": [
2127
+ 503
2128
+ ],
2129
+ "retryable": true,
2130
+ "refused_before_run": false,
2131
+ "meaning": "No trainer could take the job, or it could not be stopped right now."
2132
+ },
2133
+ {
2134
+ "code": "training.export_failed",
2135
+ "http_status": [
2136
+ 200
2137
+ ],
2138
+ "retryable": false,
2139
+ "refused_before_run": false,
2140
+ "meaning": "Job failure code: the trained model could not be exported.",
2141
+ "carried_in": "body"
2142
+ },
2143
+ {
2144
+ "code": "training.image_too_large",
2145
+ "http_status": [
2146
+ 413
2147
+ ],
2148
+ "retryable": false,
2149
+ "refused_before_run": false,
2150
+ "meaning": "An image is larger than the limit."
2151
+ },
2152
+ {
2153
+ "code": "training.inference_unavailable",
2154
+ "http_status": [
2155
+ 503
2156
+ ],
2157
+ "retryable": true,
2158
+ "refused_before_run": false,
2159
+ "meaning": "The inference service cannot answer right now."
2160
+ },
2161
+ {
2162
+ "code": "training.interrupted",
2163
+ "http_status": [
2164
+ 200
2165
+ ],
2166
+ "retryable": false,
2167
+ "refused_before_run": false,
2168
+ "meaning": "Job failure code: the run was interrupted (lost heartbeat, launch or upload failure); start a new job.",
2169
+ "carried_in": "body"
2170
+ },
2171
+ {
2172
+ "code": "training.invalid_manifest",
2173
+ "http_status": [
2174
+ 422
2175
+ ],
2176
+ "retryable": false,
2177
+ "refused_before_run": false,
2178
+ "meaning": "The dataset manifest is malformed."
2179
+ },
2180
+ {
2181
+ "code": "training.invalid_model",
2182
+ "http_status": [
2183
+ 422
2184
+ ],
2185
+ "retryable": false,
2186
+ "refused_before_run": false,
2187
+ "meaning": "The trained model cannot serve this request."
2188
+ },
2189
+ {
2190
+ "code": "training.invalid_params",
2191
+ "http_status": [
2192
+ 422
2193
+ ],
2194
+ "retryable": false,
2195
+ "refused_before_run": false,
2196
+ "meaning": "The job's parameters are out of range or unknown."
2197
+ },
2198
+ {
2199
+ "code": "training.invalid_request",
2200
+ "http_status": [
2201
+ 422
2202
+ ],
2203
+ "retryable": false,
2204
+ "refused_before_run": false,
2205
+ "meaning": "The request body is malformed."
2206
+ },
2207
+ {
2208
+ "code": "training.job_not_found",
2209
+ "http_status": [
2210
+ 404
2211
+ ],
2212
+ "retryable": false,
2213
+ "refused_before_run": false,
2214
+ "meaning": "The training job does not exist, or is not visible to the caller."
2215
+ },
2216
+ {
2217
+ "code": "training.manifest_unstorable",
2218
+ "http_status": [
2219
+ 422
2220
+ ],
2221
+ "retryable": false,
2222
+ "refused_before_run": false,
2223
+ "meaning": "A manifest name holds a NUL character or a lone surrogate; it is refused, never edited."
2224
+ },
2225
+ {
2226
+ "code": "training.model_not_found",
2227
+ "http_status": [
2228
+ 404
2229
+ ],
2230
+ "retryable": false,
2231
+ "refused_before_run": false,
2232
+ "meaning": "The trained model does not exist, or is not visible to the caller."
2233
+ },
2234
+ {
2235
+ "code": "training.not_cancellable",
2236
+ "http_status": [
2237
+ 409
2238
+ ],
2239
+ "retryable": false,
2240
+ "refused_before_run": false,
2241
+ "meaning": "The job is already finished."
2242
+ },
2243
+ {
2244
+ "code": "training.out_of_memory",
2245
+ "http_status": [
2246
+ 200
2247
+ ],
2248
+ "retryable": false,
2249
+ "refused_before_run": false,
2250
+ "meaning": "Job failure code: the trainer ran out of memory.",
2251
+ "carried_in": "body"
2252
+ },
2253
+ {
2254
+ "code": "training.registration_failed",
2255
+ "http_status": [
2256
+ 200
2257
+ ],
2258
+ "retryable": false,
2259
+ "refused_before_run": false,
2260
+ "meaning": "Job failure code: the trained model could not be registered.",
2261
+ "carried_in": "body"
2262
+ },
2263
+ {
2264
+ "code": "training.timeout",
2265
+ "http_status": [
2266
+ 200
2267
+ ],
2268
+ "retryable": false,
2269
+ "refused_before_run": false,
2270
+ "meaning": "Job failure code: the job ran past the time limit and was stopped.",
2271
+ "carried_in": "body"
2272
+ },
2273
+ {
2274
+ "code": "training.too_few_classes",
2275
+ "http_status": [
2276
+ 422
2277
+ ],
2278
+ "retryable": false,
2279
+ "refused_before_run": false,
2280
+ "meaning": "The dataset has fewer classes than the minimum."
2281
+ },
2282
+ {
2283
+ "code": "training.too_many_classes",
2284
+ "http_status": [
2285
+ 422
2286
+ ],
2287
+ "retryable": false,
2288
+ "refused_before_run": false,
2289
+ "meaning": "The dataset has more classes than the maximum."
2290
+ },
2291
+ {
2292
+ "code": "training.too_many_images",
2293
+ "http_status": [
2294
+ 422
2295
+ ],
2296
+ "retryable": false,
2297
+ "refused_before_run": false,
2298
+ "meaning": "The dataset has more images than the maximum."
2299
+ },
2300
+ {
2301
+ "code": "training.trainer_failed",
2302
+ "http_status": [
2303
+ 200
2304
+ ],
2305
+ "retryable": false,
2306
+ "refused_before_run": false,
2307
+ "meaning": "Job failure code: the trainer failed for a reason with no code of its own.",
2308
+ "carried_in": "body"
2309
+ },
2310
+ {
2311
+ "code": "training.unknown_base_model",
2312
+ "http_status": [
2313
+ 422
2314
+ ],
2315
+ "retryable": false,
2316
+ "refused_before_run": false,
2317
+ "meaning": "The base model is not one the platform offers."
2318
+ },
2319
+ {
2320
+ "code": "training.unknown_label",
2321
+ "http_status": [
2322
+ 422
2323
+ ],
2324
+ "retryable": false,
2325
+ "refused_before_run": false,
2326
+ "meaning": "An image names a label that is not in the dataset's classes."
2327
+ },
2328
+ {
2329
+ "code": "training.unsupported_image",
2330
+ "http_status": [
2331
+ 422
2332
+ ],
2333
+ "retryable": false,
2334
+ "refused_before_run": false,
2335
+ "meaning": "An image is not a supported image type."
2336
+ },
2337
+ {
2338
+ "code": "training.unsupported_task",
2339
+ "http_status": [
2340
+ 422
2341
+ ],
2342
+ "retryable": false,
2343
+ "refused_before_run": false,
2344
+ "meaning": "The task type is not supported; only image_classification is."
2345
+ },
2346
+ {
2347
+ "code": "training.write_forbidden",
2348
+ "http_status": [
2349
+ 403
2350
+ ],
2351
+ "retryable": false,
2352
+ "refused_before_run": false,
2353
+ "meaning": "A viewer may read training data but not create it."
2354
+ },
2355
+ {
2356
+ "code": "workflow.model_required",
2357
+ "http_status": [
2358
+ 422
2359
+ ],
2360
+ "retryable": false,
2361
+ "refused_before_run": false,
2362
+ "meaning": "The request names no registry model, and environment keys are not a default. (a model-door refusal; the open chat door answers it as 422 with this code)"
2363
+ }
2364
+ ]
2365
+ }