@eigenpal/sdk 0.6.14 → 0.6.16

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.
@@ -12,20 +12,6 @@ export type PatchAgentBody = {
12
12
  };
13
13
  };
14
14
 
15
- export type RunAgentBody = {
16
- input?: {
17
- [key: string]: unknown;
18
- };
19
- _metadata?: {
20
- [key: string]: unknown;
21
- };
22
- /**
23
- * Git source ref to resolve for this run. Defaults to latest. Supports latest, main, exact versions/tags such as 1.2.3, semver ranges such as 1.2.x or 1.x, and exact commit SHAs.
24
- */
25
- sourceRef?: string;
26
- [key: string]: unknown;
27
- };
28
-
29
15
  export type CreateAgentBody = {
30
16
  name: string;
31
17
  slug: string;
@@ -35,6 +21,10 @@ export type CreateAgentBody = {
35
21
  };
36
22
  };
37
23
 
24
+ export type RunTargetInputBody = {
25
+ [key: string]: unknown;
26
+ };
27
+
38
28
  export type RunFeedbackRequest = {
39
29
  body?: string | null;
40
30
  feedback?: string | null;
@@ -97,29 +87,6 @@ export type SourceSecretsEncryptBody = {
97
87
  }>;
98
88
  };
99
89
 
100
- export type RunWorkflowBody = {
101
- /**
102
- * Workflow inputs keyed by input name
103
- */
104
- input?: {
105
- [key: string]: unknown;
106
- };
107
- /**
108
- * Per-step output overrides for replay
109
- */
110
- overrides?: {
111
- steps?: {
112
- [key: string]: {
113
- [key: string]: unknown;
114
- };
115
- };
116
- } | null;
117
- /**
118
- * Caller surface (defaults to "api")
119
- */
120
- trigger?: 'api' | 'cli';
121
- };
122
-
123
90
  export type ApiErrorEnvelope = {
124
91
  issues: Array<ApiErrorIssue>;
125
92
  /**
@@ -187,32 +154,6 @@ export type PatchAgentResponse = {
187
154
  agent: AgentSummary;
188
155
  };
189
156
 
190
- export type RunAgentResponse = {
191
- runId: string;
192
- status?: ExecutionStatus | 'timeout';
193
- output?: unknown;
194
- schemaValid?: boolean | null;
195
- error?: string | null;
196
- requestedSourceRef?: string | null;
197
- resolvedGitRef?: string | null;
198
- resolvedGitTag?: string | null;
199
- resolvedCommitSha?: string | null;
200
- cost?: {
201
- [key: string]: unknown;
202
- };
203
- };
204
-
205
- export type ExecutionStatus =
206
- | 'created'
207
- | 'pending'
208
- | 'running'
209
- | 'waiting'
210
- | 'finalizing'
211
- | 'completed'
212
- | 'failed'
213
- | 'cancelled'
214
- | 'rejected';
215
-
216
157
  export type ListAgentVersionsResponse = {
217
158
  agentId: string;
218
159
  slug: string;
@@ -263,6 +204,33 @@ export type AutomationSyncResponse = {
263
204
  warnings: Array<string>;
264
205
  };
265
206
 
207
+ export type RunStartResponse = {
208
+ runId: string;
209
+ type: 'workflow' | 'agent';
210
+ status?: ExecutionStatus | 'pending' | 'timeout';
211
+ output?: unknown;
212
+ error?: string | null;
213
+ schemaValid?: boolean | null;
214
+ requestedSourceRef?: string | null;
215
+ resolvedGitRef?: string | null;
216
+ resolvedGitTag?: string | null;
217
+ resolvedCommitSha?: string | null;
218
+ cost?: {
219
+ [key: string]: unknown;
220
+ };
221
+ };
222
+
223
+ export type ExecutionStatus =
224
+ | 'created'
225
+ | 'pending'
226
+ | 'running'
227
+ | 'waiting'
228
+ | 'finalizing'
229
+ | 'completed'
230
+ | 'failed'
231
+ | 'cancelled'
232
+ | 'rejected';
233
+
266
234
  export type RunFilesResponse = {
267
235
  inputs: Array<{
268
236
  [key: string]: unknown;
@@ -280,10 +248,6 @@ export type RunRerunResponse = {
280
248
  status?: string;
281
249
  };
282
250
 
283
- export type RunResumeResponse = {
284
- [key: string]: unknown;
285
- };
286
-
287
251
  export type RunEnvelope = {
288
252
  run:
289
253
  | RunSummary
@@ -414,25 +378,6 @@ export type WorkflowDetail = {
414
378
  yamlContent?: string | null;
415
379
  };
416
380
 
417
- export type RunWorkflowResponse = {
418
- /**
419
- * Newly created execution id (e.g. exec_xyz)
420
- */
421
- executionId: string;
422
- /**
423
- * Final execution status. Only set when the run completed within `wait_for_completion`.
424
- */
425
- status?: ExecutionStatus;
426
- /**
427
- * Workflow output (status=completed)
428
- */
429
- result?: unknown;
430
- /**
431
- * Error message (status=failed)
432
- */
433
- error?: string;
434
- };
435
-
436
381
  export type ListVersionsResponse = {
437
382
  data: Array<WorkflowVersion>;
438
383
  total: number;
@@ -761,69 +706,6 @@ export type AgentsUpdateResponses = {
761
706
 
762
707
  export type AgentsUpdateResponse = AgentsUpdateResponses[keyof AgentsUpdateResponses];
763
708
 
764
- export type AgentsRunData = {
765
- body: RunAgentBody;
766
- path: {
767
- /**
768
- * Agent id or slug
769
- */
770
- agentId: string;
771
- };
772
- query?: {
773
- /**
774
- * Seconds to hold the connection waiting for completion (max 600). Omit for async.
775
- */
776
- wait_for_completion?: number;
777
- /**
778
- * Git source ref to resolve for this run. Defaults to latest. Supports latest, main, exact versions/tags such as 1.2.3, semver ranges such as 1.2.x or 1.x, and exact commit SHAs.
779
- */
780
- sourceRef?: string;
781
- };
782
- url: '/api/v1/agents/{agentId}/run';
783
- };
784
-
785
- export type AgentsRunErrors = {
786
- /**
787
- * Validation error. Request shape did not match the spec.
788
- */
789
- 400: ApiErrorEnvelope;
790
- /**
791
- * Missing or invalid API key
792
- */
793
- 401: ApiErrorEnvelope;
794
- /**
795
- * API key lacks required scope
796
- */
797
- 403: ApiErrorEnvelope;
798
- /**
799
- * Resource not found
800
- */
801
- 404: ApiErrorEnvelope;
802
- /**
803
- * Rate limit exceeded
804
- */
805
- 429: ApiErrorEnvelope;
806
- /**
807
- * Internal server error
808
- */
809
- 500: ApiErrorEnvelope;
810
- };
811
-
812
- export type AgentsRunError = AgentsRunErrors[keyof AgentsRunErrors];
813
-
814
- export type AgentsRunResponses = {
815
- /**
816
- * Execution completed while waiting
817
- */
818
- 200: RunAgentResponse;
819
- /**
820
- * Execution accepted
821
- */
822
- 202: RunAgentResponse;
823
- };
824
-
825
- export type AgentsRunResponse = AgentsRunResponses[keyof AgentsRunResponses];
826
-
827
709
  export type AgentsTriggersEmailDeleteAliasData = {
828
710
  body?: never;
829
711
  path: {
@@ -1374,6 +1256,71 @@ export type AutomationsSyncResponses = {
1374
1256
 
1375
1257
  export type AutomationsSyncResponse = AutomationsSyncResponses[keyof AutomationsSyncResponses];
1376
1258
 
1259
+ export type RunStartWithTargetData = {
1260
+ body: RunTargetInputBody;
1261
+ path: {
1262
+ /**
1263
+ * Automation target without a version suffix.
1264
+ */
1265
+ target: string;
1266
+ };
1267
+ query?: {
1268
+ /**
1269
+ * Optional version or source ref. Defaults to latest.
1270
+ */
1271
+ version?: string;
1272
+ wait_for_completion?: number;
1273
+ };
1274
+ url: '/api/v1/run/{target}';
1275
+ };
1276
+
1277
+ export type RunStartWithTargetErrors = {
1278
+ /**
1279
+ * Validation error. Request shape did not match the spec.
1280
+ */
1281
+ 400: ApiErrorEnvelope;
1282
+ /**
1283
+ * Missing or invalid API key
1284
+ */
1285
+ 401: ApiErrorEnvelope;
1286
+ /**
1287
+ * API key lacks required scope
1288
+ */
1289
+ 403: ApiErrorEnvelope;
1290
+ /**
1291
+ * Resource not found
1292
+ */
1293
+ 404: ApiErrorEnvelope;
1294
+ /**
1295
+ * Rate limit exceeded
1296
+ */
1297
+ 429: ApiErrorEnvelope;
1298
+ /**
1299
+ * Internal server error
1300
+ */
1301
+ 500: ApiErrorEnvelope;
1302
+ };
1303
+
1304
+ export type RunStartWithTargetError = RunStartWithTargetErrors[keyof RunStartWithTargetErrors];
1305
+
1306
+ export type RunStartWithTargetResponses = {
1307
+ /**
1308
+ * Run completed while waiting
1309
+ */
1310
+ 200: RunStartResponse;
1311
+ /**
1312
+ * Workflow run accepted
1313
+ */
1314
+ 201: RunStartResponse;
1315
+ /**
1316
+ * Agent run accepted or wait timed out
1317
+ */
1318
+ 202: RunStartResponse;
1319
+ };
1320
+
1321
+ export type RunStartWithTargetResponse =
1322
+ RunStartWithTargetResponses[keyof RunStartWithTargetResponses];
1323
+
1377
1324
  export type RunsArtifactGetData = {
1378
1325
  body?: never;
1379
1326
  path: {
@@ -2165,7 +2112,9 @@ export type RunsRerunData = {
2165
2112
  path: {
2166
2113
  id: string;
2167
2114
  };
2168
- query?: never;
2115
+ query?: {
2116
+ wait_for_completion?: number;
2117
+ };
2169
2118
  url: '/api/v1/runs/{id}/rerun';
2170
2119
  };
2171
2120
 
@@ -2200,66 +2149,20 @@ export type RunsRerunError = RunsRerunErrors[keyof RunsRerunErrors];
2200
2149
 
2201
2150
  export type RunsRerunResponses = {
2202
2151
  /**
2203
- * Rerun started
2152
+ * Rerun completed while waiting
2204
2153
  */
2205
2154
  200: RunRerunResponse;
2206
2155
  /**
2207
- * Rerun started
2156
+ * Workflow rerun accepted
2208
2157
  */
2209
2158
  201: RunRerunResponse;
2210
- };
2211
-
2212
- export type RunsRerunResponse = RunsRerunResponses[keyof RunsRerunResponses];
2213
-
2214
- export type RunsResumeData = {
2215
- body?: never;
2216
- path: {
2217
- /**
2218
- * Run id
2219
- */
2220
- id: string;
2221
- };
2222
- query?: never;
2223
- url: '/api/v1/runs/{id}/resume';
2224
- };
2225
-
2226
- export type RunsResumeErrors = {
2227
- /**
2228
- * Validation error. Request shape did not match the spec.
2229
- */
2230
- 400: ApiErrorEnvelope;
2231
- /**
2232
- * Missing or invalid API key
2233
- */
2234
- 401: ApiErrorEnvelope;
2235
- /**
2236
- * API key lacks required scope
2237
- */
2238
- 403: ApiErrorEnvelope;
2239
- /**
2240
- * Resource not found
2241
- */
2242
- 404: ApiErrorEnvelope;
2243
2159
  /**
2244
- * Rate limit exceeded
2160
+ * Agent rerun accepted or wait timed out
2245
2161
  */
2246
- 429: ApiErrorEnvelope;
2247
- /**
2248
- * Internal server error
2249
- */
2250
- 500: ApiErrorEnvelope;
2162
+ 202: RunRerunResponse;
2251
2163
  };
2252
2164
 
2253
- export type RunsResumeError = RunsResumeErrors[keyof RunsResumeErrors];
2254
-
2255
- export type RunsResumeResponses = {
2256
- /**
2257
- * Run resumed
2258
- */
2259
- 200: RunResumeResponse;
2260
- };
2261
-
2262
- export type RunsResumeResponse = RunsResumeResponses[keyof RunsResumeResponses];
2165
+ export type RunsRerunResponse = RunsRerunResponses[keyof RunsRerunResponses];
2263
2166
 
2264
2167
  export type RunsGetData = {
2265
2168
  body?: never;
@@ -2764,65 +2667,6 @@ export type WorkflowsGetResponses = {
2764
2667
 
2765
2668
  export type WorkflowsGetResponse = WorkflowsGetResponses[keyof WorkflowsGetResponses];
2766
2669
 
2767
- export type WorkflowsRunData = {
2768
- body: RunWorkflowBody;
2769
- path: {
2770
- /**
2771
- * Workflow id (e.g. `wf_abc123`) or slug (e.g. `extract-invoice`, the workflow `name`).
2772
- */
2773
- id: string;
2774
- };
2775
- query?: {
2776
- /**
2777
- * Version id, or "latest" (default)
2778
- */
2779
- version?: string;
2780
- /**
2781
- * Seconds to hold the connection waiting for completion (max 60). Omit for async.
2782
- */
2783
- wait_for_completion?: number;
2784
- };
2785
- url: '/api/v1/workflows/{id}/run';
2786
- };
2787
-
2788
- export type WorkflowsRunErrors = {
2789
- /**
2790
- * Validation error. Request shape did not match the spec.
2791
- */
2792
- 400: ApiErrorEnvelope;
2793
- /**
2794
- * Missing or invalid API key
2795
- */
2796
- 401: ApiErrorEnvelope;
2797
- /**
2798
- * API key lacks required scope
2799
- */
2800
- 403: ApiErrorEnvelope;
2801
- /**
2802
- * Resource not found
2803
- */
2804
- 404: ApiErrorEnvelope;
2805
- /**
2806
- * Rate limit exceeded
2807
- */
2808
- 429: ApiErrorEnvelope;
2809
- /**
2810
- * Internal server error
2811
- */
2812
- 500: ApiErrorEnvelope;
2813
- };
2814
-
2815
- export type WorkflowsRunError = WorkflowsRunErrors[keyof WorkflowsRunErrors];
2816
-
2817
- export type WorkflowsRunResponses = {
2818
- /**
2819
- * Execution accepted. Body always includes `executionId`. When `wait_for_completion` is set and the execution completes within the window, `status`/`result`/`error` are also returned; otherwise poll `/api/v1/runs/{executionId}` for status.
2820
- */
2821
- 201: RunWorkflowResponse;
2822
- };
2823
-
2824
- export type WorkflowsRunResponse = WorkflowsRunResponses[keyof WorkflowsRunResponses];
2825
-
2826
2670
  export type WorkflowsVersionsListData = {
2827
2671
  body?: never;
2828
2672
  path: {
package/src/index.ts CHANGED
@@ -8,10 +8,13 @@
8
8
  * const client = new EigenpalClient({ apiKey: process.env.EIGENPAL_API_KEY! });
9
9
  *
10
10
  * // Async — enqueue and poll later.
11
- * const { executionId } = await client.workflows.run('wf_abc', { input: { ... } });
11
+ * const { runId } = await client.run('workflows.extract-invoice', {
12
+ * input: { ... },
13
+ * });
12
14
  *
13
15
  * // Sync (server holds the connection up to 60s).
14
- * const result = await client.workflows.run('wf_abc', { input: { ... } }, {
16
+ * const result = await client.run('workflows.extract-invoice', {
17
+ * input: { ... },
15
18
  * waitForCompletion: 60,
16
19
  * });
17
20
  *
@@ -19,7 +22,15 @@
19
22
  * const final = await client.workflows.executions.runAndWait('wf_abc', { input: { ... } });
20
23
  * ```
21
24
  */
22
- export { EigenpalClient, type EigenpalOptions } from './client';
25
+ export {
26
+ EigenpalClient,
27
+ type EigenpalOptions,
28
+ type RerunOptions,
29
+ type RunInput,
30
+ type RunOptions,
31
+ type RunStartResponse,
32
+ type RunTarget,
33
+ } from './client';
23
34
 
24
35
  export {
25
36
  EigenpalAuthError,
@@ -34,20 +45,19 @@ export {
34
45
 
35
46
  export { toFile } from './lib/files';
36
47
  export type { FileDescriptor, FileInput, NodeReadableStream } from './lib/files';
37
- export type { ListAgentsOptions, RunAgentOptions } from './resources/agents';
48
+ export type { ListAgentsOptions } from './resources/agents';
38
49
  export type { ListRunsOptions } from './resources/runs';
39
50
  export type { SourceRawOptions, SourceReleasesOptions } from './resources/source';
40
51
  export type {
41
52
  ListVersionsOptions,
42
53
  ListWorkflowsOptions,
43
- RunWorkflowOptions,
44
54
  WorkflowInput,
45
55
  } from './resources/workflows';
46
56
  // Note: FileReference (by fileId) is intentionally NOT exported. From the
47
57
  // SDK perspective you always upload a file; fileId is an internal wire id
48
58
  // the server creates after upload — not something users construct.
49
59
 
50
- export type { RunAndWaitOptions } from './resources/executions';
60
+ export type { RunAndWaitOptions, WorkflowRunAndWaitResponse } from './resources/executions';
51
61
 
52
62
  // Re-export the canonical generated types so users can type their own
53
63
  // callbacks and helpers without reaching into `./generated`.
@@ -71,10 +81,8 @@ export type {
71
81
  ListVersionsResponse,
72
82
  ListWorkflowsResponse,
73
83
  RawSourceResponse,
74
- RunAgentResponse,
75
84
  RunSummary,
76
- RunWorkflowBody,
77
- RunWorkflowResponse,
85
+ RunTargetInputBody,
78
86
  RunsCancelResponse,
79
87
  RunsExpectedCreateResponse,
80
88
  RunsExpectedFileDeleteResponse,
@@ -85,7 +93,6 @@ export type {
85
93
  RunsGetResponse,
86
94
  RunsListResponse,
87
95
  RunsRerunResponse,
88
- RunsResumeResponse,
89
96
  SourceLockfileResponse,
90
97
  SourceReleasesResponse,
91
98
  SourceRepositoryResponse,
package/src/lib/files.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * File-input helpers for `client.workflows.run()` (and agent runs).
2
+ * File-input helpers for `client.run()`.
3
3
  *
4
4
  * A workflow input value is treated as a file when it is one of:
5
5
  * - a Node readable stream — `fs.createReadStream('contract.pdf')`
@@ -69,7 +69,7 @@ export type FileInput = Blob | FileDescriptor | NodeReadableStream;
69
69
  * a file path or stream.
70
70
  *
71
71
  * ```ts
72
- * await client.workflows.run('extract-invoice', {
72
+ * await client.run('workflows.extract-invoice', {
73
73
  * contract_document: toFile(buffer, 'contract.pdf'),
74
74
  * });
75
75
  * ```
@@ -188,49 +188,39 @@ async function appendFiles(
188
188
  }
189
189
 
190
190
  /**
191
- * Build a `multipart/form-data` body matching what `processMultipartRunBody`
192
- * on the server expects:
191
+ * JSON-body counterpart of {@link buildRunMultipart}: per-step overrides ride
192
+ * in the reserved `_overrides` body key.
193
+ */
194
+ export function buildRunJsonBody(
195
+ input: Record<string, unknown> | undefined,
196
+ overrides?: { steps?: Record<string, Record<string, unknown>> }
197
+ ): Record<string, unknown> {
198
+ return overrides ? { ...(input ?? {}), _overrides: overrides } : (input ?? {});
199
+ }
200
+
201
+ /**
202
+ * Build multipart for the canonical `client.run(...)` endpoint
203
+ * (`POST /api/v1/run/{target}`):
193
204
  *
194
- * - Each file in `input` becomes a top-level form field (key = input name).
195
- * - Non-file inputs + overrides + trigger go in a `_json` text field.
205
+ * - Each top-level file in `input` becomes a form field (key = input name).
206
+ * - Non-file inputs go in the `_json` text field (the input object itself).
207
+ * - Per-step overrides go in the reserved `_overrides` text field.
196
208
  *
197
209
  * Async because stream inputs are drained to bytes here. Only top-level file
198
210
  * values are extracted — files nested inside arrays / objects keep their
199
211
  * position in the JSON sidecar (the server has no nested-upload path).
200
212
  */
201
- export async function buildMultipart(args: {
213
+ export async function buildRunMultipart(args: {
202
214
  input?: Record<string, unknown>;
203
215
  overrides?: { steps?: Record<string, Record<string, unknown>> };
204
- trigger?: 'api' | 'cli';
205
216
  }): Promise<MultipartParts> {
206
217
  const fd = new FormData();
207
218
  const { scalars, fileCount } = await appendFiles(fd, args.input);
208
-
209
- const sidecar: Record<string, unknown> = {};
210
- if (Object.keys(scalars).length > 0) sidecar.input = scalars;
211
- if (args.overrides) sidecar.overrides = args.overrides;
212
- if (args.trigger) sidecar.trigger = args.trigger;
213
- if (Object.keys(sidecar).length > 0) {
214
- fd.append('_json', JSON.stringify(sidecar));
215
- }
216
-
217
- return { formData: fd, fileCount };
218
- }
219
-
220
- /**
221
- * Build multipart for agent runs. Agent run endpoints consume `_json` as the
222
- * input object itself, unlike workflow runs where `_json` is a sidecar with
223
- * `{ input, overrides, trigger }`.
224
- */
225
- export async function buildAgentMultipart(
226
- input?: Record<string, unknown>
227
- ): Promise<MultipartParts> {
228
- const fd = new FormData();
229
- const { scalars, fileCount } = await appendFiles(fd, input);
230
-
231
219
  if (Object.keys(scalars).length > 0) {
232
220
  fd.append('_json', JSON.stringify(scalars));
233
221
  }
234
-
222
+ if (args.overrides) {
223
+ fd.append('_overrides', JSON.stringify(args.overrides));
224
+ }
235
225
  return { formData: fd, fileCount };
236
226
  }
@@ -7,7 +7,6 @@ import {
7
7
  agentsFilesUploadBatch,
8
8
  agentsGet,
9
9
  agentsList,
10
- agentsRun,
11
10
  agentsTriggersEmailCreateAlias,
12
11
  agentsTriggersEmailDeleteAlias,
13
12
  agentsTriggersEmailGet,
@@ -34,10 +33,7 @@ import type {
34
33
  ListAgentsResponse,
35
34
  PatchAgentBody,
36
35
  PatchAgentResponse,
37
- RunAgentResponse,
38
36
  } from '../generated/types.gen';
39
- import { buildAgentMultipart, hasFileInput } from '../lib/files';
40
- import type { WorkflowInput } from './workflows';
41
37
 
42
38
  type Dispatch = <T>(call: () => Promise<OperationResult<T>>) => Promise<T>;
43
39
 
@@ -48,12 +44,6 @@ export interface ListAgentsOptions {
48
44
  signal?: AbortSignal;
49
45
  }
50
46
 
51
- export interface RunAgentOptions {
52
- waitForCompletion?: number;
53
- sourceRef?: string;
54
- signal?: AbortSignal;
55
- }
56
-
57
47
  export class AgentEmailTriggersResource {
58
48
  constructor(
59
49
  private readonly client: Client,
@@ -228,46 +218,4 @@ export class AgentsResource {
228
218
  agentsUpdate({ client: this.client, path: { agentId }, body, signal: options.signal })
229
219
  );
230
220
  }
231
-
232
- async run(
233
- agentId: string,
234
- input?: WorkflowInput,
235
- options: RunAgentOptions = {}
236
- ): Promise<RunAgentResponse> {
237
- const query = {
238
- ...(options.waitForCompletion !== undefined
239
- ? { wait_for_completion: options.waitForCompletion }
240
- : {}),
241
- ...(options.sourceRef !== undefined ? { sourceRef: options.sourceRef } : {}),
242
- };
243
-
244
- if (hasFileInput(input)) {
245
- const { formData } = await buildAgentMultipart(input);
246
- return this.dispatch<RunAgentResponse>(
247
- () =>
248
- this.client.post({
249
- url: '/api/v1/agents/{agentId}/run',
250
- path: { agentId },
251
- query,
252
- body: formData,
253
- bodySerializer: null,
254
- headers: { 'Content-Type': null },
255
- signal: options.signal,
256
- }) as Promise<OperationResult<RunAgentResponse>>
257
- );
258
- }
259
-
260
- return this.dispatch(() =>
261
- agentsRun({
262
- client: this.client,
263
- path: { agentId },
264
- query,
265
- body: {
266
- ...(input !== undefined ? { input } : {}),
267
- ...(options.sourceRef !== undefined ? { sourceRef: options.sourceRef } : {}),
268
- },
269
- signal: options.signal,
270
- })
271
- );
272
- }
273
221
  }