@instruments/materialgraph 0.24.0 → 0.26.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.
Files changed (124) hide show
  1. package/association-types.d.ts +20 -20
  2. package/associations-client.d.ts +4 -4
  3. package/associations-client.js +3 -10
  4. package/attribution-types.d.ts +3 -3
  5. package/brand-most-sampled-types.d.ts +4 -4
  6. package/brand-types.d.ts +6 -6
  7. package/brands-client.d.ts +4 -4
  8. package/brands-client.js +9 -13
  9. package/browse-types.d.ts +8 -8
  10. package/by-colour-types.d.ts +18 -18
  11. package/by-spec-types.d.ts +14 -14
  12. package/catalog-discovery-types.d.ts +14 -14
  13. package/catalogue-client.d.ts +4 -4
  14. package/catalogue-client.js +38 -37
  15. package/catalogue-types.d.ts +4 -4
  16. package/citation-types.d.ts +4 -4
  17. package/client-browse.d.ts +4 -4
  18. package/client-browse.js +24 -25
  19. package/client-config.d.ts +2 -2
  20. package/client-exploration.d.ts +3 -3
  21. package/client-exploration.js +4 -6
  22. package/client-source-material-comments.d.ts +4 -4
  23. package/client-source-material-comments.js +4 -38
  24. package/client-vocabulary.d.ts +8 -8
  25. package/client-vocabulary.js +20 -30
  26. package/client.d.ts +11 -45
  27. package/client.js +143 -188
  28. package/codes-client.d.ts +2 -2
  29. package/codes-client.js +8 -8
  30. package/codes-types.d.ts +34 -34
  31. package/colour-aggregate-types.d.ts +24 -24
  32. package/colours-client.d.ts +2 -2
  33. package/colours-client.js +15 -15
  34. package/compare-types.d.ts +10 -10
  35. package/composition-client.d.ts +3 -3
  36. package/composition-client.js +8 -7
  37. package/composition-types.d.ts +12 -12
  38. package/coordinate-client.d.ts +2 -2
  39. package/coordinate-client.js +1 -13
  40. package/corpus-scope-types.d.ts +3 -3
  41. package/corpus-scope-types.js +1 -25
  42. package/correction-types.d.ts +10 -10
  43. package/demand-batch-types.d.ts +18 -18
  44. package/demand-types.d.ts +24 -24
  45. package/errors.d.ts +12 -12
  46. package/errors.js +53 -52
  47. package/exploration-types.d.ts +29 -22
  48. package/fan-deck-types.d.ts +6 -6
  49. package/http-transport.d.ts +13 -21
  50. package/http-transport.js +31 -28
  51. package/identify-types.d.ts +10 -10
  52. package/index.d.ts +0 -6
  53. package/index.js +0 -2
  54. package/match-rejection-types.d.ts +6 -6
  55. package/match-stream-types.d.ts +32 -32
  56. package/match-stream.d.ts +2 -2
  57. package/match-stream.js +55 -41
  58. package/match-types.d.ts +8 -8
  59. package/material-asset-types.d.ts +26 -26
  60. package/material-block-types.d.ts +6 -6
  61. package/material-query-plan-types.d.ts +26 -26
  62. package/material-resources-client.d.ts +5 -5
  63. package/material-resources-client.js +10 -20
  64. package/material-types.d.ts +12 -12
  65. package/ndjson.js +16 -8
  66. package/operations.d.ts +6 -6
  67. package/operations.js +9 -39
  68. package/package.json +2 -2
  69. package/palette-completion-types.d.ts +22 -22
  70. package/palette-search-types.d.ts +28 -28
  71. package/query-understanding-types.d.ts +43 -36
  72. package/render-assets-types.d.ts +8 -8
  73. package/resolve-client.d.ts +2 -2
  74. package/resolve-client.js +4 -6
  75. package/resolve-colour-types.d.ts +22 -6
  76. package/resolve-types.d.ts +10 -10
  77. package/run-types.d.ts +70 -70
  78. package/runs.d.ts +13 -26
  79. package/runs.js +77 -89
  80. package/samplize-catalogue-types.d.ts +18 -18
  81. package/samplize-colorvec.d.ts +20 -20
  82. package/samplize-colorvec.js +66 -42
  83. package/schema-resource-types.d.ts +38 -38
  84. package/schema-resource-types.js +5 -5
  85. package/search-card-types.d.ts +14 -5
  86. package/search-collapse-types.d.ts +4 -4
  87. package/search-mood-types.d.ts +2 -2
  88. package/search-refinement-types.d.ts +8 -8
  89. package/search-request-types.d.ts +6 -6
  90. package/search-response-receipt-types.d.ts +135 -34
  91. package/search-response-types.d.ts +2 -2
  92. package/search-result-validation.d.ts +3 -3
  93. package/search-result-validation.js +53 -36
  94. package/search-window-types.d.ts +2 -2
  95. package/slot-pool-types.d.ts +20 -20
  96. package/source-material-validation.d.ts +3 -3
  97. package/source-material-validation.js +35 -39
  98. package/spec-facet-types.d.ts +10 -10
  99. package/spec-types.d.ts +6 -6
  100. package/specifications.d.ts +9 -25
  101. package/specifications.js +15 -21
  102. package/sse.d.ts +2 -2
  103. package/sse.js +32 -16
  104. package/substitute-types.d.ts +22 -22
  105. package/suggest-types.d.ts +7 -7
  106. package/suggest-types.js +3 -3
  107. package/taxonomy-coverage-types.d.ts +8 -8
  108. package/types.d.ts +119 -119
  109. package/validation.d.ts +26 -26
  110. package/validation.js +97 -92
  111. package/webmcp.d.ts +2 -2
  112. package/webmcp.generated.js +94 -87
  113. package/project-types.d.ts +0 -79
  114. package/project-types.js +0 -9
  115. package/projects.d.ts +0 -13
  116. package/projects.js +0 -46
  117. package/run-events.d.ts +0 -106
  118. package/run-events.js +0 -32
  119. package/schedule-reference-types.d.ts +0 -46
  120. package/schedule-reference-types.js +0 -1
  121. package/schedule-references-client.d.ts +0 -14
  122. package/schedule-references-client.js +0 -26
  123. package/schedule-types.d.ts +0 -261
  124. package/schedule-types.js +0 -1
package/run-types.d.ts CHANGED
@@ -32,27 +32,27 @@ export type FileInput = Blob | {
32
32
  * classifies each file and assigns its receipt {@link SourceMaterialReceiptFile.role};
33
33
  * the caller no longer pre-sorts a brief from its references.
34
34
  */
35
- export interface UploadSourceMaterialFilesInput {
35
+ export type UploadSourceMaterialFilesInput = {
36
36
  files: FileInput[];
37
- }
37
+ };
38
38
  /**
39
39
  * The legacy pre-classified shape — a single PDF `brief` plus optional image
40
40
  * `references` (multipart fields `brief` + `references`). Still accepted by the
41
41
  * server, folded into the pile. Prefer {@link UploadSourceMaterialFilesInput}.
42
42
  */
43
- export interface UploadSourceMaterialLegacyInput {
43
+ export type UploadSourceMaterialLegacyInput = {
44
44
  /** The single PDF brief for the batch (multipart field `brief`). */
45
45
  brief: FileInput;
46
46
  /** Up to 12 reference images (multipart field `references`, repeatable). */
47
47
  references?: FileInput[];
48
- }
48
+ };
49
49
  /**
50
50
  * Input for {@link MaterialGraphClient.uploadSourceMaterial} — either the
51
51
  * pile-of-files shape or the legacy brief+references shape.
52
52
  */
53
53
  export type UploadSourceMaterialInput = UploadSourceMaterialFilesInput | UploadSourceMaterialLegacyInput;
54
54
  /** One stored file in an upload receipt. */
55
- export interface SourceMaterialReceiptFile {
55
+ export type SourceMaterialReceiptFile = {
56
56
  /** The stored file id (`smf_…`). Opaque — the prefix is a reading aid, not a contract. */
57
57
  sourceId: SourceFileId;
58
58
  /**
@@ -68,13 +68,13 @@ export interface SourceMaterialReceiptFile {
68
68
  bytes: number;
69
69
  /** PDF page count; null for images. */
70
70
  pages: number | null;
71
- }
71
+ };
72
72
  /** The `201` receipt from `POST /api/v1/source-material`. */
73
- export interface SourceMaterialBatchReceipt {
73
+ export type SourceMaterialBatchReceipt = {
74
74
  /** The stored batch id (`smb_…`). Opaque — hand it straight to a compose Run. */
75
75
  batchId: BatchId;
76
76
  sources: SourceMaterialReceiptFile[];
77
- }
77
+ };
78
78
  /**
79
79
  * One analysis computed over an uploaded image's bytes.
80
80
  *
@@ -84,7 +84,7 @@ export interface SourceMaterialBatchReceipt {
84
84
  * sharing is by design and discloses nothing — you only ever see analyses of
85
85
  * images you hold yourself.
86
86
  */
87
- export interface SourceImageAnalysis {
87
+ export type SourceImageAnalysis = {
88
88
  /** The kind of read. {@link OpenEnum} keeps a newer server value type-checking. */
89
89
  kind: OpenEnum<"scene_match">;
90
90
  /** The model version that produced {@link SourceImageAnalysis.result}. */
@@ -104,9 +104,9 @@ export interface SourceImageAnalysis {
104
104
  result: Record<string, JsonValue>;
105
105
  /** ISO-8601 timestamp of the most recent analysis. */
106
106
  analysedAt: string;
107
- }
107
+ };
108
108
  /** Who a comment is from, as you SUBMIT it. Not the API principal posting it. */
109
- export interface SourceMaterialCommentAuthorInput {
109
+ export type SourceMaterialCommentAuthorInput = {
110
110
  /** Trimmed, 1–160 characters. Longer or blank is refused by the server. */
111
111
  name: string;
112
112
  /**
@@ -114,7 +114,7 @@ export interface SourceMaterialCommentAuthorInput {
114
114
  * Trimmed, 1–160 characters when present. Nullable, not optional.
115
115
  */
116
116
  organisation: string | null;
117
- }
117
+ };
118
118
  /**
119
119
  * Who a comment is from, as you READ IT BACK.
120
120
  *
@@ -122,28 +122,28 @@ export interface SourceMaterialCommentAuthorInput {
122
122
  * "recorded as from X", never as a statement X signed — the identity that IS
123
123
  * verified is {@link SourceMaterialCommentReply.recordedBy}.
124
124
  */
125
- export interface SourceMaterialCommentAuthor extends SourceMaterialCommentAuthorInput {
125
+ export type SourceMaterialCommentAuthor = {
126
126
  /**
127
127
  * How the name got here. `reported` means a caller typed it. {@link OpenEnum}
128
128
  * keeps a newer server value type-checking; treat anything unfamiliar as
129
129
  * unverified.
130
130
  */
131
131
  attribution: OpenEnum<"reported">;
132
- }
132
+ } & SourceMaterialCommentAuthorInput;
133
133
  /** The authenticated principal that recorded a comment. */
134
- export interface SourceMaterialCommentRecorder {
134
+ export type SourceMaterialCommentRecorder = {
135
135
  /**
136
136
  * The principal that wrote the row. Comments can only be posted against a
137
137
  * batch the poster owns, so on every comment you can read this is your own.
138
138
  */
139
139
  principalId: string;
140
- }
140
+ };
141
141
  /**
142
142
  * One reply on a source-material file. A reply carries no replies of its own:
143
143
  * threads are one level deep because the database makes a reply-to-reply
144
144
  * unstorable, and this type says so rather than implying a tree.
145
145
  */
146
- export interface SourceMaterialCommentReply {
146
+ export type SourceMaterialCommentReply = {
147
147
  /** The stored comment id (`smc_…`). Opaque. */
148
148
  commentId: string;
149
149
  author: SourceMaterialCommentAuthor;
@@ -152,14 +152,14 @@ export interface SourceMaterialCommentReply {
152
152
  body: string;
153
153
  /** ISO-8601 timestamp of the posting. */
154
154
  createdAt: string;
155
- }
155
+ };
156
156
  /** One root remark with the replies that answer it. */
157
- export interface SourceMaterialComment extends SourceMaterialCommentReply {
157
+ export type SourceMaterialComment = {
158
158
  /** ALWAYS an array. `[]` means nobody answered — never a missing field. */
159
159
  replies: SourceMaterialCommentReply[];
160
- }
160
+ } & SourceMaterialCommentReply;
161
161
  /** The `200` body of `GET …/sources/{sourceId}/comments`. */
162
- export interface SourceMaterialCommentThread {
162
+ export type SourceMaterialCommentThread = {
163
163
  /** The file the thread hangs off (`smf_…`). Opaque. */
164
164
  sourceId: string;
165
165
  /**
@@ -172,9 +172,9 @@ export interface SourceMaterialCommentThread {
172
172
  * so `comments` is the oldest of them rather than all of them.
173
173
  */
174
174
  truncated: boolean;
175
- }
175
+ };
176
176
  /** The body of `POST …/sources/{sourceId}/comments`. */
177
- export interface PostSourceMaterialCommentInput {
177
+ export type PostSourceMaterialCommentInput = {
178
178
  author: SourceMaterialCommentAuthorInput;
179
179
  /** Trimmed, 1–4000 characters. */
180
180
  body: string;
@@ -189,17 +189,17 @@ export interface PostSourceMaterialCommentInput {
189
189
  * rather than a permanent duplicate. Scoped to the file.
190
190
  */
191
191
  idempotencyKey?: string | null;
192
- }
192
+ };
193
193
  /** A comment the server just stored, as a root. */
194
- export interface StoredSourceMaterialRootComment extends SourceMaterialComment {
194
+ export type StoredSourceMaterialRootComment = {
195
195
  kind: "root";
196
- }
196
+ } & SourceMaterialComment;
197
197
  /** A comment the server just stored, as a reply to a root. */
198
- export interface StoredSourceMaterialReplyComment extends SourceMaterialCommentReply {
198
+ export type StoredSourceMaterialReplyComment = {
199
199
  kind: "reply";
200
200
  /** The root this answers. Present because a reply always has one. */
201
201
  parentCommentId: string;
202
- }
202
+ } & SourceMaterialCommentReply;
203
203
  /**
204
204
  * What a POST returns, discriminated on `kind`. Switch on it: a `root` carries
205
205
  * an empty `replies`, a `reply` carries `parentCommentId` and no `replies` at
@@ -207,13 +207,13 @@ export interface StoredSourceMaterialReplyComment extends SourceMaterialCommentR
207
207
  */
208
208
  export type StoredSourceMaterialComment = StoredSourceMaterialRootComment | StoredSourceMaterialReplyComment;
209
209
  /** The `201` body of `POST …/sources/{sourceId}/comments`. */
210
- export interface PostSourceMaterialCommentResult {
210
+ export type PostSourceMaterialCommentResult = {
211
211
  /** The file the comment hangs off (`smf_…`). Opaque. */
212
212
  sourceId: string;
213
213
  comment: StoredSourceMaterialComment;
214
- }
214
+ };
215
215
  /** One file as `GET /api/v1/source-material/{batchId}` returns it. */
216
- export interface SourceMaterialBatchFile extends SourceMaterialReceiptFile {
216
+ export type SourceMaterialBatchFile = {
217
217
  /** Fetchable URL for the stored bytes. */
218
218
  url: string;
219
219
  /**
@@ -234,38 +234,38 @@ export interface SourceMaterialBatchFile extends SourceMaterialReceiptFile {
234
234
  * you have, including one nobody has commented on.
235
235
  */
236
236
  commentsTruncated: boolean;
237
- }
237
+ } & SourceMaterialReceiptFile;
238
238
  /**
239
239
  * The `200` body of `GET /api/v1/source-material/{batchId}` — the batch, every
240
240
  * file it holds, and the analyses computed over each file's bytes.
241
241
  */
242
- export interface SourceMaterialBatchDetail {
242
+ export type SourceMaterialBatchDetail = {
243
243
  /** The stored batch id (`smb_…`). Opaque. */
244
244
  batchId: BatchId;
245
245
  /** ISO-8601 timestamp of the upload. */
246
246
  createdAt: string;
247
247
  sources: SourceMaterialBatchFile[];
248
- }
248
+ };
249
249
  export type CapabilityKind = OpenEnum<"agent" | "tool" | "workflow">;
250
250
  export type CapabilityExposure = OpenEnum<"public" | "partner" | "internal">;
251
251
  export type CapabilityScope = OpenEnum<"mg:read" | "mg:write" | "mg:ingest" | "mg:admin">;
252
252
  export type CapabilitySideEffectClass = OpenEnum<"read_only" | "browser_local" | "external_read" | "writes_proposed" | "writes_persisted" | "planned_only">;
253
- export interface CapabilityRetryPolicy {
253
+ export type CapabilityRetryPolicy = {
254
254
  maxAttempts: number;
255
255
  backoff: OpenEnum<"none" | "fixed" | "exponential">;
256
- }
257
- export interface CapabilityInvokeLink {
256
+ };
257
+ export type CapabilityInvokeLink = {
258
258
  href: string;
259
259
  method: OpenEnum<"GET" | "POST">;
260
- }
260
+ };
261
261
  /** One human-input checkpoint exposed by a workflow capability. */
262
- export interface PublicCapabilitySuspension {
262
+ export type PublicCapabilitySuspension = {
263
263
  stepId: string;
264
264
  suspend: Record<string, unknown>;
265
265
  resume: Record<string, unknown>;
266
- }
266
+ };
267
267
  /** One invocable capability from the governed public manifest. */
268
- export interface PublicCapabilityMetadata {
268
+ export type PublicCapabilityMetadata = {
269
269
  publicId: string;
270
270
  runtimeId: string;
271
271
  kind: CapabilityKind;
@@ -285,28 +285,28 @@ export interface PublicCapabilityMetadata {
285
285
  links: {
286
286
  invoke: CapabilityInvokeLink;
287
287
  };
288
- }
288
+ };
289
289
  /** The `GET /api/v1/capabilities` response envelope. */
290
- export interface CapabilityManifestResponse {
290
+ export type CapabilityManifestResponse = {
291
291
  capabilities: PublicCapabilityMetadata[];
292
- }
292
+ };
293
293
  export type PublicRunStatus = OpenEnum<"queued" | "claimed" | "running" | "suspended" | "succeeded" | "failed" | "canceled">;
294
- export interface PublicRunFailure {
294
+ export type PublicRunFailure = {
295
295
  code: string;
296
296
  message: string;
297
297
  retryable: boolean;
298
298
  detail?: Record<string, unknown>;
299
- }
300
- export interface PublicRunArtifactRef {
299
+ };
300
+ export type PublicRunArtifactRef = {
301
301
  kind: string;
302
302
  ref: string;
303
- }
303
+ };
304
304
  /**
305
305
  * The caller-owned, redacted Run ledger record. Prompts, raw model messages,
306
306
  * reasoning, credentials, provider payloads, and source-document contents are
307
307
  * never returned — inputs and outputs are the `redacted*Json` projections.
308
308
  */
309
- export interface PublicRun {
309
+ export type PublicRun = {
310
310
  /** Opaque — round-trip verbatim into every other Run call. */
311
311
  id: RunId;
312
312
  capabilityKind: CapabilityKind;
@@ -338,9 +338,9 @@ export interface PublicRun {
338
338
  completedAt: string | null;
339
339
  createdAt: string;
340
340
  updatedAt: string;
341
- }
341
+ };
342
342
  /** Body for `POST /api/v1/runs` ({@link MaterialGraphClient.createRun}). */
343
- export interface CreatePublicRunRequest {
343
+ export type CreatePublicRunRequest = {
344
344
  capabilityKind: CapabilityKind;
345
345
  capabilityId: string;
346
346
  /** The capability input, validated server-side against its live input schema. */
@@ -353,20 +353,20 @@ export interface CreatePublicRunRequest {
353
353
  idempotencyKey?: string;
354
354
  /** Free-form caller correlation reference, echoed back on the Run. */
355
355
  clientReference?: string;
356
- }
356
+ };
357
357
  /** The `POST /api/v1/runs` response (`200` replay or `202` accepted). */
358
- export interface CreatePublicRunResponse {
358
+ export type CreatePublicRunResponse = {
359
359
  accepted: boolean;
360
360
  replayed: boolean;
361
361
  workflowRunId: string;
362
362
  run: PublicRun;
363
- }
363
+ };
364
364
  /** The `GET /api/v1/runs/{runId}` and resume/cancel response envelope. */
365
- export interface PublicRunResponse {
365
+ export type PublicRunResponse = {
366
366
  run: PublicRun;
367
- }
367
+ };
368
368
  /** Query for `GET /api/v1/runs` ({@link MaterialGraphClient.listRuns}). */
369
- export interface ListRunsOptions {
369
+ export type ListRunsOptions = {
370
370
  /**
371
371
  * Return only Runs in this status. `"suspended"` is the recovery question:
372
372
  * which of my Runs is still waiting on an answer?
@@ -380,49 +380,49 @@ export interface ListRunsOptions {
380
380
  */
381
381
  cursor?: string;
382
382
  signal?: AbortSignal;
383
- }
383
+ };
384
384
  /** The `GET /api/v1/runs` response envelope — one page, newest first. */
385
- export interface PublicRunListResponse {
385
+ export type PublicRunListResponse = {
386
386
  runs: PublicRun[];
387
387
  /**
388
388
  * Pass as {@link ListRunsOptions.cursor} for the next page. ABSENT — not
389
389
  * empty-string, not null — once the last page has been served.
390
390
  */
391
391
  nextCursor?: string;
392
- }
392
+ };
393
393
  /** Body for `POST /api/v1/runs/{runId}/resume`. */
394
- export interface ResumePublicRunRequest {
394
+ export type ResumePublicRunRequest = {
395
395
  /** The resume payload, validated against the suspended step's resume schema. */
396
396
  resumeData: unknown;
397
- }
397
+ };
398
398
  /**
399
399
  * One redacted Run event, decoded from an SSE `data:` frame. The stream yields
400
400
  * these in ascending {@link RunEvent.sequence} order. `payloadJson` is read
401
401
  * structurally; use {@link parseRunEvent} to narrow the composition family.
402
402
  */
403
- export interface RunEvent {
403
+ export type RunEvent = {
404
404
  sequence: number;
405
405
  type: string;
406
406
  payloadJson: unknown;
407
- }
407
+ };
408
408
  /** Run event types that close the stream — a terminal event ends a drain. */
409
409
  export declare const TERMINAL_RUN_EVENT_TYPES: ReadonlySet<string>;
410
410
  /** Options for {@link MaterialGraphClient.streamRunEvents}. */
411
- export interface StreamRunEventsOptions {
411
+ export type StreamRunEventsOptions = {
412
412
  /** Resume the stream after this sequence (exclusive). Omitted starts at 0. */
413
413
  after?: number;
414
414
  /** Abort the stream; iteration stops cleanly. */
415
415
  signal?: AbortSignal;
416
- }
416
+ };
417
417
  /** Options for {@link MaterialGraphClient.drainRunEvents}. */
418
- export interface DrainRunEventsOptions {
418
+ export type DrainRunEventsOptions = {
419
419
  /** Resume after this sequence (exclusive). */
420
420
  after?: number;
421
421
  /** Stop collecting after this many milliseconds even without a terminal event. */
422
422
  deadlineMs: number;
423
- }
423
+ };
424
424
  /** Options for {@link MaterialGraphClient.resumeRun}. */
425
- export interface ResumeRunOptions {
425
+ export type ResumeRunOptions = {
426
426
  /**
427
427
  * The step the caller believes is suspended. When it mismatches the run
428
428
  * doc's live `suspensionStepId` the API answers RFC-7807 409 (MG-608) —
@@ -432,4 +432,4 @@ export interface ResumeRunOptions {
432
432
  stepId?: string;
433
433
  /** Abort the request. */
434
434
  signal?: AbortSignal;
435
- }
435
+ };
package/runs.d.ts CHANGED
@@ -1,13 +1,12 @@
1
- import { HttpTransport } from "./http-transport.js";
2
- import { type CapabilityManifestResponse, type CreatePublicRunRequest, type CreatePublicRunResponse, type DrainRunEventsOptions, type ListRunsOptions, type PostSourceMaterialCommentInput, type PostSourceMaterialCommentResult, type PublicRunListResponse, type PublicRunResponse, type ResumeRunOptions, type RunEvent, type SourceMaterialBatchDetail, type SourceMaterialBatchReceipt, type SourceMaterialCommentThread, type StreamRunEventsOptions, type UploadSourceMaterialInput } from "./run-types.js";
3
- import type { FinishScheduleResponse, GetRunScheduleOptions } from "./schedule-types.js";
1
+ import type { HttpTransport } from "./http-transport.js";
2
+ import type { CapabilityManifestResponse, CreatePublicRunRequest, CreatePublicRunResponse, DrainRunEventsOptions, ListRunsOptions, PostSourceMaterialCommentInput, PostSourceMaterialCommentResult, PublicRunListResponse, PublicRunResponse, ResumeRunOptions, RunEvent, SourceMaterialBatchDetail, SourceMaterialBatchReceipt, SourceMaterialCommentThread, StreamRunEventsOptions, UploadSourceMaterialInput } from "./run-types.js";
4
3
  /**
5
4
  * Upload one atomic source-material batch (`POST /api/v1/source-material`).
6
5
  * Accepts the pile-of-files shape (`{ files }` → repeatable `files` field) or
7
6
  * the legacy `{ brief, references }` shape (→ `brief` + repeatable `references`
8
7
  * fields). Both wire to multipart the server accepts.
9
8
  */
10
- export declare function uploadSourceMaterial(transport: HttpTransport, input: UploadSourceMaterialInput, signal?: AbortSignal): Promise<SourceMaterialBatchReceipt>;
9
+ export declare const uploadSourceMaterial: (transport: HttpTransport, input: UploadSourceMaterialInput, signal?: AbortSignal) => Promise<SourceMaterialBatchReceipt>;
11
10
  /**
12
11
  * Read back one uploaded batch (`GET /api/v1/source-material/{batchId}`): every
13
12
  * file with a fetchable `url`, and every analysis computed over its bytes
@@ -20,7 +19,7 @@ export declare function uploadSourceMaterial(transport: HttpTransport, input: Up
20
19
  * the server's Zod contract so a malformed response fails here with a path into
21
20
  * the payload rather than as an undefined three frames away in caller code.
22
21
  */
23
- export declare function getSourceMaterialBatch(transport: HttpTransport, batchId: string, signal?: AbortSignal): Promise<SourceMaterialBatchDetail>;
22
+ export declare const getSourceMaterialBatch: (transport: HttpTransport, batchId: string, signal?: AbortSignal) => Promise<SourceMaterialBatchDetail>;
24
23
  /**
25
24
  * Read one file's comment thread
26
25
  * (`GET /api/v1/source-material/{batchId}/sources/{sourceId}/comments`).
@@ -38,7 +37,7 @@ export declare function getSourceMaterialBatch(transport: HttpTransport, batchId
38
37
  * A file that is not in that batch, or a batch you do not own, raises the same
39
38
  * 404 as a file that never existed.
40
39
  */
41
- export declare function listSourceMaterialComments(transport: HttpTransport, batchId: string, sourceId: string, signal?: AbortSignal): Promise<SourceMaterialCommentThread>;
40
+ export declare const listSourceMaterialComments: (transport: HttpTransport, batchId: string, sourceId: string, signal?: AbortSignal) => Promise<SourceMaterialCommentThread>;
42
41
  /**
43
42
  * Add one remark to a file's thread
44
43
  * (`POST /api/v1/source-material/{batchId}/sources/{sourceId}/comments`).
@@ -54,11 +53,11 @@ export declare function listSourceMaterialComments(transport: HttpTransport, bat
54
53
  * The result is discriminated on `kind`: switch on it rather than reaching for
55
54
  * `replies`, which a `reply` does not have.
56
55
  */
57
- export declare function postSourceMaterialComment(transport: HttpTransport, batchId: string, sourceId: string, input: PostSourceMaterialCommentInput, signal?: AbortSignal): Promise<PostSourceMaterialCommentResult>;
56
+ export declare const postSourceMaterialComment: (transport: HttpTransport, batchId: string, sourceId: string, input: PostSourceMaterialCommentInput, signal?: AbortSignal) => Promise<PostSourceMaterialCommentResult>;
58
57
  /** List invocable agents, workflows, and tools (`GET /api/v1/capabilities`). */
59
- export declare function capabilities(transport: HttpTransport, signal?: AbortSignal): Promise<CapabilityManifestResponse>;
58
+ export declare const capabilities: (transport: HttpTransport, signal?: AbortSignal) => Promise<CapabilityManifestResponse>;
60
59
  /** Start an asynchronous capability Run (`POST /api/v1/runs`). */
61
- export declare function createRun(transport: HttpTransport, body: CreatePublicRunRequest, signal?: AbortSignal): Promise<CreatePublicRunResponse>;
60
+ export declare const createRun: (transport: HttpTransport, body: CreatePublicRunRequest, signal?: AbortSignal) => Promise<CreatePublicRunResponse>;
62
61
  /**
63
62
  * List your own Runs, newest first (`GET /api/v1/runs`).
64
63
  *
@@ -72,21 +71,9 @@ export declare function createRun(transport: HttpTransport, body: CreatePublicRu
72
71
  * Page by following `nextCursor` until it is ABSENT — a full page is not the
73
72
  * signal to stop, and an absent cursor is the only one.
74
73
  */
75
- export declare function listRuns(transport: HttpTransport, options?: ListRunsOptions): Promise<PublicRunListResponse>;
74
+ export declare const listRuns: (transport: HttpTransport, options?: ListRunsOptions) => Promise<PublicRunListResponse>;
76
75
  /** Get a Run's current state (`GET /api/v1/runs/{runId}`). */
77
- export declare function getRun(transport: HttpTransport, runId: string, signal?: AbortSignal): Promise<PublicRunResponse>;
78
- /**
79
- * Export a completed compose Run's scheme as a finish schedule — one row per
80
- * slot, every attribute value carrying its source and verification state
81
- * (`GET /api/v1/runs/{runId}/schedule`).
82
- *
83
- * The `.xlsx` form of the same export is deliberately NOT an SDK method: this
84
- * transport parses every response as text/JSON and has no binary read path, so
85
- * a bytes-returning method would mean a second transport surface for one file.
86
- * Fetch `GET /api/v1/runs/{runId}/schedule.xlsx` directly with the same bearer
87
- * key when you want the workbook.
88
- */
89
- export declare function getRunSchedule(transport: HttpTransport, runId: string, options?: GetRunScheduleOptions): Promise<FinishScheduleResponse>;
76
+ export declare const getRun: (transport: HttpTransport, runId: string, signal?: AbortSignal) => Promise<PublicRunResponse>;
90
77
  /**
91
78
  * Resume a suspended Run (`POST /api/v1/runs/{runId}/resume`).
92
79
  *
@@ -104,9 +91,9 @@ export declare function getRunSchedule(transport: HttpTransport, runId: string,
104
91
  * `JSON.stringify` drops both — so the distinction here is construction
105
92
  * intent, kept so the serialised body is provably unchanged for old callers.
106
93
  */
107
- export declare function resumeRun(transport: HttpTransport, runId: string, resumeData: unknown, signalOrOptions?: AbortSignal | ResumeRunOptions): Promise<PublicRunResponse>;
94
+ export declare const resumeRun: (transport: HttpTransport, runId: string, resumeData: unknown, signalOrOptions?: AbortSignal | ResumeRunOptions) => Promise<PublicRunResponse>;
108
95
  /** Request durable Run cancellation (`POST /api/v1/runs/{runId}/cancel`). */
109
- export declare function cancelRun(transport: HttpTransport, runId: string, signal?: AbortSignal): Promise<PublicRunResponse>;
96
+ export declare const cancelRun: (transport: HttpTransport, runId: string, signal?: AbortSignal) => Promise<PublicRunResponse>;
110
97
  /**
111
98
  * Stream ordered Run events as an async iterator (`GET
112
99
  * /api/v1/runs/{runId}/events`, SSE). Iterates until the stream ends or
@@ -129,4 +116,4 @@ export declare function streamRunEvents(transport: HttpTransport, runId: string,
129
116
  * failure (a real 4xx/5xx or transport error) still propagates, keeping the
130
117
  * fail-fast surface for genuine upstream problems.
131
118
  */
132
- export declare function drainRunEvents(transport: HttpTransport, runId: string, options: DrainRunEventsOptions): Promise<RunEvent[]>;
119
+ export declare const drainRunEvents: (transport: HttpTransport, runId: string, options: DrainRunEventsOptions) => Promise<RunEvent[]>;