@claudexor/schema 4.0.0 → 4.1.0
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.
- package/dist/account-resources.d.ts +64 -27
- package/dist/account-resources.d.ts.map +1 -1
- package/dist/account-target.d.ts +3 -0
- package/dist/account-target.d.ts.map +1 -1
- package/dist/account-target.js +2 -0
- package/dist/account-target.js.map +1 -1
- package/dist/attachment.js +1 -1
- package/dist/attachment.js.map +1 -1
- package/dist/budget.d.ts +3 -0
- package/dist/budget.d.ts.map +1 -1
- package/dist/budget.js +2 -0
- package/dist/budget.js.map +1 -1
- package/dist/credential-profile-snapshot.d.ts +64 -28
- package/dist/credential-profile-snapshot.d.ts.map +1 -1
- package/dist/harness-quota.d.ts +8 -3
- package/dist/harness-quota.d.ts.map +1 -1
- package/dist/harness.d.ts +17 -5
- package/dist/harness.d.ts.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/model-image.d.ts +416 -0
- package/dist/model-image.d.ts.map +1 -0
- package/dist/model-image.js +77 -0
- package/dist/model-image.js.map +1 -0
- package/dist/model-operation.d.ts +143 -0
- package/dist/model-operation.d.ts.map +1 -1
- package/dist/model-operation.js +22 -0
- package/dist/model-operation.js.map +1 -1
- package/dist/quota-availability.d.ts +33 -0
- package/dist/quota-availability.d.ts.map +1 -0
- package/dist/quota-availability.js +130 -0
- package/dist/quota-availability.js.map +1 -0
- package/dist/quota-read.d.ts +38 -9
- package/dist/quota-read.d.ts.map +1 -1
- package/dist/quota-read.js +5 -3
- package/dist/quota-read.js.map +1 -1
- package/dist/quota-request-kind.d.ts +9 -0
- package/dist/quota-request-kind.d.ts.map +1 -0
- package/dist/quota-request-kind.js +8 -0
- package/dist/quota-request-kind.js.map +1 -0
- package/dist/quota.d.ts +60 -49
- package/dist/quota.d.ts.map +1 -1
- package/dist/quota.js +17 -126
- package/dist/quota.js.map +1 -1
- package/dist/rate-limit.d.ts +3 -0
- package/dist/rate-limit.d.ts.map +1 -1
- package/dist/rate-limit.js +2 -0
- package/dist/rate-limit.js.map +1 -1
- package/generated/BudgetObservation.schema.json +11 -0
- package/generated/ControlAccountResetResponse.schema.json +14 -1
- package/generated/ControlAccountResourcesResponse.schema.json +14 -1
- package/generated/ControlCredentialProfilesQueryResponse.schema.json +14 -1
- package/generated/ControlCredentialProfilesResourcesResponse.schema.json +14 -1
- package/generated/ControlCredentialProfilesSnapshotResponse.schema.json +14 -1
- package/generated/ControlModelSourcesAccountsResponse.schema.json +62 -0
- package/generated/ControlModelSourcesQueryResponse.schema.json +62 -0
- package/generated/ControlQuotaFreshnessResponse.schema.json +14 -1
- package/generated/ControlQuotaQueryResponse.schema.json +17 -1
- package/generated/ControlQuotaReadRequest.schema.json +15 -1
- package/generated/ControlQuotaRefreshRequest.schema.json +8 -0
- package/generated/ControlQuotaResponse.schema.json +14 -1
- package/generated/ControlUploadCreateRequest.schema.json +1 -1
- package/generated/HarnessEvent.schema.json +21 -1
- package/generated/ImageCallRequest.schema.json +145 -0
- package/generated/ImageCallResult.schema.json +415 -0
- package/package.json +2 -2
|
@@ -0,0 +1,415 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$ref": "#/definitions/ImageCallResult",
|
|
3
|
+
"definitions": {
|
|
4
|
+
"ImageCallResult": {
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"outcome": {
|
|
8
|
+
"type": "string",
|
|
9
|
+
"enum": [
|
|
10
|
+
"completed",
|
|
11
|
+
"failed",
|
|
12
|
+
"unknown"
|
|
13
|
+
]
|
|
14
|
+
},
|
|
15
|
+
"operation": {
|
|
16
|
+
"type": "string",
|
|
17
|
+
"enum": [
|
|
18
|
+
"generate",
|
|
19
|
+
"edit"
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
"requestedModel": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"minLength": 1,
|
|
25
|
+
"pattern": "\\S",
|
|
26
|
+
"description": "The model the caller asked for. route.model contains only a provider-observed model, or null."
|
|
27
|
+
},
|
|
28
|
+
"images": {
|
|
29
|
+
"type": "array",
|
|
30
|
+
"items": {
|
|
31
|
+
"type": "object",
|
|
32
|
+
"properties": {
|
|
33
|
+
"mime": {
|
|
34
|
+
"type": "string",
|
|
35
|
+
"enum": [
|
|
36
|
+
"image/png",
|
|
37
|
+
"image/jpeg",
|
|
38
|
+
"image/webp"
|
|
39
|
+
],
|
|
40
|
+
"description": "Sniffed from the decoded bytes."
|
|
41
|
+
},
|
|
42
|
+
"sha256": {
|
|
43
|
+
"type": "string",
|
|
44
|
+
"pattern": "^sha256:[a-f0-9]{64}$",
|
|
45
|
+
"description": "Digest of the decoded bytes."
|
|
46
|
+
},
|
|
47
|
+
"sizeBytes": {
|
|
48
|
+
"type": "integer",
|
|
49
|
+
"minimum": 0
|
|
50
|
+
},
|
|
51
|
+
"dataBase64": {
|
|
52
|
+
"type": "string",
|
|
53
|
+
"minLength": 1,
|
|
54
|
+
"description": "The provider's b64_json, exact."
|
|
55
|
+
},
|
|
56
|
+
"generationId": {
|
|
57
|
+
"type": [
|
|
58
|
+
"string",
|
|
59
|
+
"null"
|
|
60
|
+
]
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
"required": [
|
|
64
|
+
"mime",
|
|
65
|
+
"sha256",
|
|
66
|
+
"sizeBytes",
|
|
67
|
+
"dataBase64",
|
|
68
|
+
"generationId"
|
|
69
|
+
],
|
|
70
|
+
"additionalProperties": false
|
|
71
|
+
},
|
|
72
|
+
"description": "Every usable returned item, in provider order; rejected items are diagnosed in problem."
|
|
73
|
+
},
|
|
74
|
+
"route": {
|
|
75
|
+
"type": "object",
|
|
76
|
+
"properties": {
|
|
77
|
+
"source": {
|
|
78
|
+
"type": "string",
|
|
79
|
+
"minLength": 1,
|
|
80
|
+
"description": "Non-empty identifier string."
|
|
81
|
+
},
|
|
82
|
+
"credentialProfileId": {
|
|
83
|
+
"$ref": "#/definitions/ImageCallResult/properties/route/properties/source"
|
|
84
|
+
},
|
|
85
|
+
"accountFingerprint": {
|
|
86
|
+
"type": [
|
|
87
|
+
"string",
|
|
88
|
+
"null"
|
|
89
|
+
]
|
|
90
|
+
},
|
|
91
|
+
"model": {
|
|
92
|
+
"type": [
|
|
93
|
+
"string",
|
|
94
|
+
"null"
|
|
95
|
+
]
|
|
96
|
+
}
|
|
97
|
+
},
|
|
98
|
+
"required": [
|
|
99
|
+
"source",
|
|
100
|
+
"credentialProfileId",
|
|
101
|
+
"accountFingerprint",
|
|
102
|
+
"model"
|
|
103
|
+
],
|
|
104
|
+
"additionalProperties": false,
|
|
105
|
+
"description": "Selected route at dispatch; a result records the actually observed model, or null."
|
|
106
|
+
},
|
|
107
|
+
"appliedOptions": {
|
|
108
|
+
"type": "object",
|
|
109
|
+
"properties": {
|
|
110
|
+
"size": {
|
|
111
|
+
"type": "string",
|
|
112
|
+
"minLength": 1,
|
|
113
|
+
"pattern": "\\S",
|
|
114
|
+
"description": "Vendor size token, e.g. \"auto\" or \"1024x1024\"."
|
|
115
|
+
},
|
|
116
|
+
"quality": {
|
|
117
|
+
"type": "string",
|
|
118
|
+
"enum": [
|
|
119
|
+
"low",
|
|
120
|
+
"medium",
|
|
121
|
+
"high",
|
|
122
|
+
"auto"
|
|
123
|
+
]
|
|
124
|
+
},
|
|
125
|
+
"background": {
|
|
126
|
+
"type": "string",
|
|
127
|
+
"enum": [
|
|
128
|
+
"transparent",
|
|
129
|
+
"opaque",
|
|
130
|
+
"auto"
|
|
131
|
+
]
|
|
132
|
+
},
|
|
133
|
+
"n": {
|
|
134
|
+
"type": "integer",
|
|
135
|
+
"exclusiveMinimum": 0,
|
|
136
|
+
"maximum": 10,
|
|
137
|
+
"description": "Requested image count in ONE provider request. Omitted sends no n; the provider may return several items either way."
|
|
138
|
+
}
|
|
139
|
+
},
|
|
140
|
+
"additionalProperties": false,
|
|
141
|
+
"description": "As reported by the provider response."
|
|
142
|
+
},
|
|
143
|
+
"usage": {
|
|
144
|
+
"type": "object",
|
|
145
|
+
"properties": {
|
|
146
|
+
"input_tokens": {
|
|
147
|
+
"anyOf": [
|
|
148
|
+
{
|
|
149
|
+
"type": "integer",
|
|
150
|
+
"minimum": 0
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
"type": "null"
|
|
154
|
+
}
|
|
155
|
+
],
|
|
156
|
+
"default": null
|
|
157
|
+
},
|
|
158
|
+
"output_tokens": {
|
|
159
|
+
"anyOf": [
|
|
160
|
+
{
|
|
161
|
+
"type": "integer",
|
|
162
|
+
"minimum": 0
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
"type": "null"
|
|
166
|
+
}
|
|
167
|
+
],
|
|
168
|
+
"default": null
|
|
169
|
+
},
|
|
170
|
+
"cached_input_tokens": {
|
|
171
|
+
"anyOf": [
|
|
172
|
+
{
|
|
173
|
+
"type": "integer",
|
|
174
|
+
"minimum": 0
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
"type": "null"
|
|
178
|
+
}
|
|
179
|
+
],
|
|
180
|
+
"default": null
|
|
181
|
+
},
|
|
182
|
+
"cache_write_tokens": {
|
|
183
|
+
"anyOf": [
|
|
184
|
+
{
|
|
185
|
+
"type": "integer",
|
|
186
|
+
"minimum": 0
|
|
187
|
+
},
|
|
188
|
+
{
|
|
189
|
+
"type": "null"
|
|
190
|
+
}
|
|
191
|
+
],
|
|
192
|
+
"default": null
|
|
193
|
+
},
|
|
194
|
+
"reasoning_tokens": {
|
|
195
|
+
"anyOf": [
|
|
196
|
+
{
|
|
197
|
+
"type": "integer",
|
|
198
|
+
"minimum": 0
|
|
199
|
+
},
|
|
200
|
+
{
|
|
201
|
+
"type": "null"
|
|
202
|
+
}
|
|
203
|
+
],
|
|
204
|
+
"default": null
|
|
205
|
+
}
|
|
206
|
+
},
|
|
207
|
+
"additionalProperties": false,
|
|
208
|
+
"description": "Provider-reported counters for one generation; missing counters remain null."
|
|
209
|
+
},
|
|
210
|
+
"cost": {
|
|
211
|
+
"type": "object",
|
|
212
|
+
"properties": {
|
|
213
|
+
"processing": {
|
|
214
|
+
"type": "object",
|
|
215
|
+
"properties": {
|
|
216
|
+
"nativeMode": {
|
|
217
|
+
"anyOf": [
|
|
218
|
+
{
|
|
219
|
+
"$ref": "#/definitions/ImageCallResult/properties/appliedOptions/properties/size"
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
"type": "null"
|
|
223
|
+
}
|
|
224
|
+
],
|
|
225
|
+
"description": "User-supplied string that must contain visible content, not just whitespace."
|
|
226
|
+
},
|
|
227
|
+
"kind": {
|
|
228
|
+
"type": "string",
|
|
229
|
+
"enum": [
|
|
230
|
+
"included",
|
|
231
|
+
"paid_credits",
|
|
232
|
+
"cash",
|
|
233
|
+
"valuation",
|
|
234
|
+
"unknown"
|
|
235
|
+
]
|
|
236
|
+
},
|
|
237
|
+
"source": {
|
|
238
|
+
"$ref": "#/definitions/ImageCallResult/properties/appliedOptions/properties/size"
|
|
239
|
+
}
|
|
240
|
+
},
|
|
241
|
+
"required": [
|
|
242
|
+
"nativeMode",
|
|
243
|
+
"kind",
|
|
244
|
+
"source"
|
|
245
|
+
],
|
|
246
|
+
"additionalProperties": false,
|
|
247
|
+
"description": "Mode-qualified billing evidence for an existing cost record. Authentication alone does not establish included premium service; credits, cash, and token valuation stay distinct."
|
|
248
|
+
},
|
|
249
|
+
"knowledge": {
|
|
250
|
+
"type": "string",
|
|
251
|
+
"enum": [
|
|
252
|
+
"exact",
|
|
253
|
+
"estimated",
|
|
254
|
+
"unknown"
|
|
255
|
+
],
|
|
256
|
+
"description": "Quality of incremental-cash cost evidence for an operation."
|
|
257
|
+
},
|
|
258
|
+
"billing": {
|
|
259
|
+
"type": "string",
|
|
260
|
+
"enum": [
|
|
261
|
+
"proven_zero",
|
|
262
|
+
"subscription_entitlement",
|
|
263
|
+
"metered",
|
|
264
|
+
"unknown"
|
|
265
|
+
],
|
|
266
|
+
"description": "What is actually known about incremental billing; a native credential route alone never proves entitlement or zero cost."
|
|
267
|
+
},
|
|
268
|
+
"source": {
|
|
269
|
+
"type": "string",
|
|
270
|
+
"minLength": 1
|
|
271
|
+
},
|
|
272
|
+
"provenance": {
|
|
273
|
+
"type": "array",
|
|
274
|
+
"items": {
|
|
275
|
+
"type": "string",
|
|
276
|
+
"minLength": 1
|
|
277
|
+
},
|
|
278
|
+
"minItems": 1
|
|
279
|
+
},
|
|
280
|
+
"estimatedUsd": {
|
|
281
|
+
"anyOf": [
|
|
282
|
+
{
|
|
283
|
+
"type": "number",
|
|
284
|
+
"minimum": 0
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
"type": "null"
|
|
288
|
+
}
|
|
289
|
+
],
|
|
290
|
+
"default": null
|
|
291
|
+
},
|
|
292
|
+
"cashUsd": {
|
|
293
|
+
"anyOf": [
|
|
294
|
+
{
|
|
295
|
+
"type": "number",
|
|
296
|
+
"minimum": 0
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
"type": "null"
|
|
300
|
+
}
|
|
301
|
+
],
|
|
302
|
+
"default": null
|
|
303
|
+
},
|
|
304
|
+
"valuationUsd": {
|
|
305
|
+
"anyOf": [
|
|
306
|
+
{
|
|
307
|
+
"type": "number",
|
|
308
|
+
"minimum": 0
|
|
309
|
+
},
|
|
310
|
+
{
|
|
311
|
+
"type": "null"
|
|
312
|
+
}
|
|
313
|
+
],
|
|
314
|
+
"default": null
|
|
315
|
+
},
|
|
316
|
+
"valuationKnowledge": {
|
|
317
|
+
"$ref": "#/definitions/ImageCallResult/properties/cost/properties/knowledge",
|
|
318
|
+
"default": "unknown",
|
|
319
|
+
"description": "Quality of incremental-cash cost evidence for an operation."
|
|
320
|
+
}
|
|
321
|
+
},
|
|
322
|
+
"required": [
|
|
323
|
+
"knowledge",
|
|
324
|
+
"billing",
|
|
325
|
+
"source",
|
|
326
|
+
"provenance"
|
|
327
|
+
],
|
|
328
|
+
"additionalProperties": false,
|
|
329
|
+
"description": "Incremental cash and token valuation are independent; subscription credentials alone never invent a cash receipt."
|
|
330
|
+
},
|
|
331
|
+
"providerRequestId": {
|
|
332
|
+
"type": [
|
|
333
|
+
"string",
|
|
334
|
+
"null"
|
|
335
|
+
]
|
|
336
|
+
},
|
|
337
|
+
"problem": {
|
|
338
|
+
"anyOf": [
|
|
339
|
+
{
|
|
340
|
+
"type": "object",
|
|
341
|
+
"properties": {
|
|
342
|
+
"code": {
|
|
343
|
+
"type": "string",
|
|
344
|
+
"minLength": 1
|
|
345
|
+
},
|
|
346
|
+
"message": {
|
|
347
|
+
"type": "string"
|
|
348
|
+
},
|
|
349
|
+
"retryable": {
|
|
350
|
+
"type": "boolean"
|
|
351
|
+
},
|
|
352
|
+
"fieldErrors": {
|
|
353
|
+
"type": "object",
|
|
354
|
+
"additionalProperties": {
|
|
355
|
+
"type": "array",
|
|
356
|
+
"items": {
|
|
357
|
+
"type": "string"
|
|
358
|
+
}
|
|
359
|
+
},
|
|
360
|
+
"default": {}
|
|
361
|
+
},
|
|
362
|
+
"requiredActions": {
|
|
363
|
+
"type": "array",
|
|
364
|
+
"items": {
|
|
365
|
+
"type": "string",
|
|
366
|
+
"minLength": 1
|
|
367
|
+
},
|
|
368
|
+
"default": []
|
|
369
|
+
},
|
|
370
|
+
"evidenceRefs": {
|
|
371
|
+
"type": "array",
|
|
372
|
+
"items": {
|
|
373
|
+
"type": "string",
|
|
374
|
+
"minLength": 1
|
|
375
|
+
},
|
|
376
|
+
"default": []
|
|
377
|
+
},
|
|
378
|
+
"context": {
|
|
379
|
+
"type": "object",
|
|
380
|
+
"additionalProperties": {},
|
|
381
|
+
"default": {},
|
|
382
|
+
"description": "Typed route-specific recovery context; never a duplicate error message."
|
|
383
|
+
}
|
|
384
|
+
},
|
|
385
|
+
"required": [
|
|
386
|
+
"code",
|
|
387
|
+
"message",
|
|
388
|
+
"retryable"
|
|
389
|
+
],
|
|
390
|
+
"additionalProperties": false
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
"type": "null"
|
|
394
|
+
}
|
|
395
|
+
]
|
|
396
|
+
}
|
|
397
|
+
},
|
|
398
|
+
"required": [
|
|
399
|
+
"outcome",
|
|
400
|
+
"operation",
|
|
401
|
+
"requestedModel",
|
|
402
|
+
"images",
|
|
403
|
+
"route",
|
|
404
|
+
"appliedOptions",
|
|
405
|
+
"usage",
|
|
406
|
+
"cost",
|
|
407
|
+
"providerRequestId",
|
|
408
|
+
"problem"
|
|
409
|
+
],
|
|
410
|
+
"additionalProperties": false,
|
|
411
|
+
"description": "One provider image outcome; base64 lives only in this private result resource, never in model text."
|
|
412
|
+
}
|
|
413
|
+
},
|
|
414
|
+
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
415
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@claudexor/schema",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.1.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Single source of truth for all Claudexor data shapes (Zod + generated JSON Schema).",
|
|
6
6
|
"type": "module",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"zod": "^4.6.5",
|
|
22
22
|
"zod-to-json-schema": "^3.24.1",
|
|
23
|
-
"@claudexor/util": "4.
|
|
23
|
+
"@claudexor/util": "4.1.0"
|
|
24
24
|
},
|
|
25
25
|
"repository": {
|
|
26
26
|
"type": "git",
|