@trigger.dev/core 0.0.0-prerelease-20240718194312 → 0.0.0-prerelease-20240724110801
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/{catalog-h79CG5Wy.d.ts → catalog-1uqiDu4t.d.ts} +2 -2
- package/dist/{catalog-H7yFiZ60.d.mts → catalog-HfeyVfYa.d.mts} +2 -2
- package/dist/{manager-KvCabW1a.d.mts → manager-CkUnBH2E.d.mts} +1 -1
- package/dist/{manager-OBA35PzR.d.ts → manager-y-nT-ymn.d.ts} +1 -1
- package/dist/v3/dev/index.d.mts +2 -2
- package/dist/v3/dev/index.d.ts +2 -2
- package/dist/v3/errors.d.mts +1 -1
- package/dist/v3/errors.d.ts +1 -1
- package/dist/v3/index.d.mts +45 -33
- package/dist/v3/index.d.ts +45 -33
- package/dist/v3/index.js +29 -2
- package/dist/v3/index.js.map +1 -1
- package/dist/v3/index.mjs +28 -3
- package/dist/v3/index.mjs.map +1 -1
- package/dist/v3/otel/index.js +1 -1
- package/dist/v3/otel/index.js.map +1 -1
- package/dist/v3/otel/index.mjs +1 -1
- package/dist/v3/otel/index.mjs.map +1 -1
- package/dist/v3/prod/index.d.mts +3 -3
- package/dist/v3/prod/index.d.ts +3 -3
- package/dist/v3/schemas/index.d.mts +87 -21
- package/dist/v3/schemas/index.d.ts +87 -21
- package/dist/v3/schemas/index.js +16 -1
- package/dist/v3/schemas/index.js.map +1 -1
- package/dist/v3/schemas/index.mjs +15 -2
- package/dist/v3/schemas/index.mjs.map +1 -1
- package/dist/v3/utils/ioSerialization.js +27 -2
- package/dist/v3/utils/ioSerialization.js.map +1 -1
- package/dist/v3/utils/ioSerialization.mjs +27 -2
- package/dist/v3/utils/ioSerialization.mjs.map +1 -1
- package/dist/v3/utils/retries.d.mts +1 -1
- package/dist/v3/utils/retries.d.ts +1 -1
- package/dist/v3/workers/index.d.mts +6 -6
- package/dist/v3/workers/index.d.ts +6 -6
- package/dist/v3/workers/index.js +27 -2
- package/dist/v3/workers/index.js.map +1 -1
- package/dist/v3/workers/index.mjs +27 -2
- package/dist/v3/workers/index.mjs.map +1 -1
- package/dist/v3/zodfetch.d.mts +1 -1
- package/dist/v3/zodfetch.d.ts +1 -1
- package/package.json +3 -3
- package/dist/{common-CLW82lkt.d.mts → common-ufw5MzBe.d.mts} +66 -66
- package/dist/{common-CLW82lkt.d.ts → common-ufw5MzBe.d.ts} +66 -66
- package/dist/{messages-JvHJ83wv.d.mts → messages-7b5K4qKr.d.mts} +666 -666
- package/dist/{messages-JvHJ83wv.d.ts → messages-7b5K4qKr.d.ts} +666 -666
- package/dist/{schemas-C9ssfehv.d.mts → schemas-kjSfajbV.d.mts} +48 -48
- package/dist/{schemas-C9ssfehv.d.ts → schemas-kjSfajbV.d.ts} +48 -48
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { L as LogLevel } from './taskLogger-CzADe4je.js';
|
|
2
|
-
import { M as MachinePresetName, a as TaskRunContext } from './common-
|
|
3
|
-
import { R as RetryOptions, P as Prettify, T as TaskMetadata, a as TaskFileMetadata, b as TaskMetadataWithFilePath } from './schemas-
|
|
2
|
+
import { M as MachinePresetName, a as TaskRunContext } from './common-ufw5MzBe.js';
|
|
3
|
+
import { R as RetryOptions, P as Prettify, T as TaskMetadata, a as TaskFileMetadata, b as TaskMetadataWithFilePath } from './schemas-kjSfajbV.js';
|
|
4
4
|
import { InstrumentationOption } from '@opentelemetry/instrumentation';
|
|
5
5
|
|
|
6
6
|
interface ProjectConfig {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { L as LogLevel } from './taskLogger-r_AFTX45.mjs';
|
|
2
|
-
import { M as MachinePresetName, a as TaskRunContext } from './common-
|
|
3
|
-
import { R as RetryOptions, P as Prettify, T as TaskMetadata, a as TaskFileMetadata, b as TaskMetadataWithFilePath } from './schemas-
|
|
2
|
+
import { M as MachinePresetName, a as TaskRunContext } from './common-ufw5MzBe.mjs';
|
|
3
|
+
import { R as RetryOptions, P as Prettify, T as TaskMetadata, a as TaskFileMetadata, b as TaskMetadataWithFilePath } from './schemas-kjSfajbV.mjs';
|
|
4
4
|
import { InstrumentationOption } from '@opentelemetry/instrumentation';
|
|
5
5
|
|
|
6
6
|
interface ProjectConfig {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as TaskRunContext, T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult } from './common-
|
|
1
|
+
import { a as TaskRunContext, T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult } from './common-ufw5MzBe.mjs';
|
|
2
2
|
|
|
3
3
|
interface RuntimeManager {
|
|
4
4
|
disable(): void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as TaskRunContext, T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult } from './common-
|
|
1
|
+
import { a as TaskRunContext, T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult } from './common-ufw5MzBe.js';
|
|
2
2
|
|
|
3
3
|
interface RuntimeManager {
|
|
4
4
|
disable(): void;
|
package/dist/v3/dev/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, a as TaskRunContext } from '../../common-
|
|
2
|
-
import { R as RuntimeManager } from '../../manager-
|
|
1
|
+
import { T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, a as TaskRunContext } from '../../common-ufw5MzBe.mjs';
|
|
2
|
+
import { R as RuntimeManager } from '../../manager-CkUnBH2E.mjs';
|
|
3
3
|
import 'zod';
|
|
4
4
|
|
|
5
5
|
declare class DevRuntimeManager implements RuntimeManager {
|
package/dist/v3/dev/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, a as TaskRunContext } from '../../common-
|
|
2
|
-
import { R as RuntimeManager } from '../../manager-
|
|
1
|
+
import { T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, a as TaskRunContext } from '../../common-ufw5MzBe.js';
|
|
2
|
+
import { R as RuntimeManager } from '../../manager-y-nT-ymn.js';
|
|
3
3
|
import 'zod';
|
|
4
4
|
|
|
5
5
|
declare class DevRuntimeManager implements RuntimeManager {
|
package/dist/v3/errors.d.mts
CHANGED
package/dist/v3/errors.d.ts
CHANGED
package/dist/v3/index.d.mts
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import * as zod from 'zod';
|
|
2
1
|
import { CursorPageParams, ApiRequestOptions, ZodFetchOptions, ApiPromise, CursorPagePromise, OffsetLimitPagePromise } from './zodfetch.mjs';
|
|
3
2
|
export { APIHeaders, ApiConnectionError, ApiError, AuthenticationError, BadRequestError, ConflictError, CursorPage, CursorPageResponse, InternalServerError, NotFoundError, OffsetLimitPage, OffsetLimitPageParams, OffsetLimitPageResponse, Page, PageResponse, PermissionDeniedError, RateLimitError, UnprocessableEntityError, isRequestOptions } from './zodfetch.mjs';
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
import { RunStatus, TriggerTaskRequestBody, BatchTriggerTaskRequestBody, ListRunResponseItem, RescheduleRunRequestBody, AddTagsRequestBody, CreateScheduleOptions, ListScheduleOptions, UpdateScheduleOptions, CreateEnvironmentVariableRequestBody, UpdateEnvironmentVariableRequestBody, Accessory } from './schemas/index.mjs';
|
|
5
|
+
export { AttemptStatus, BackgroundWorkerMetadata, BatchTriggerTaskResponse, CanceledRunResponse, CancellationSpanEvent, CreateAuthorizationCodeResponse, CreateAuthorizationCodeResponseSchema, CreateBackgroundWorkerRequestBody, CreateBackgroundWorkerResponse, CreateUploadPayloadUrlResponseBody, DeletedScheduleObject, DeploymentErrorData, EnvironmentVariable, EnvironmentVariableResponseBody, EnvironmentVariableValue, EnvironmentVariables, EventFilter, ExceptionEventProperties, ExceptionSpanEvent, ExternalBuildData, FetchRetryBackoffStrategy, FetchRetryByStatusOptions, FetchRetryHeadersStrategy, FetchRetryOptions, FetchRetryStrategy, FetchTimeoutOptions, GetBatchResponseBody, GetDeploymentResponseBody, GetEnvironmentVariablesResponseBody, GetPersonalAccessTokenRequest, GetPersonalAccessTokenRequestSchema, GetPersonalAccessTokenResponse, GetPersonalAccessTokenResponseSchema, GetProjectEnvResponse, GetProjectResponseBody, GetProjectsResponseBody, ImageDetailsMetadata, ImportEnvironmentVariablesRequestBody, InitializeDeploymentRequestBody, InitializeDeploymentResponseBody, ListRunResponse, ListSchedulesResult, OtherSpanEvent, PRIMARY_VARIANT, ReplayRunResponse, RetrieveRunResponse, RunEnvironmentDetails, RunScheduleDetails, RunTags, ScheduleGenerator, ScheduleObject, ScheduleType, ScheduledTaskPayload, SpanEvent, SpanEvents, SpanMessagingEvent, StartDeploymentIndexingRequestBody, StartDeploymentIndexingResponseBody, TaskEventStyle, TaskResource, TimezonesResult, TriggerTaskResponse, Variant, WhoAmIResponse, WhoAmIResponseSchema, isCancellationSpanEvent, isExceptionSpanEvent, stringPatternMatchers } from './schemas/index.mjs';
|
|
6
|
+
import { T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, a as TaskRunContext } from '../common-ufw5MzBe.mjs';
|
|
7
|
+
export { f as MachineConfig, d as MachineCpu, e as MachineMemory, g as MachinePreset, M as MachinePresetName, m as TaskRun, h as TaskRunBuiltInError, i as TaskRunCustomErrorObject, b as TaskRunError, k as TaskRunErrorCodes, c as TaskRunExecution, o as TaskRunExecutionAttempt, t as TaskRunExecutionBatch, p as TaskRunExecutionEnvironment, q as TaskRunExecutionOrganization, r as TaskRunExecutionProject, s as TaskRunExecutionQueue, u as TaskRunExecutionRetry, n as TaskRunExecutionTask, v as TaskRunExecutionUsage, w as TaskRunFailedExecutionResult, l as TaskRunInternalError, j as TaskRunStringError, x as TaskRunSuccessfulExecutionResult } from '../common-ufw5MzBe.mjs';
|
|
8
|
+
import { C as Clock, a as ClockTime, b as TaskCatalog, T as TaskMetadataWithFunctions } from '../catalog-HfeyVfYa.mjs';
|
|
9
|
+
export { f as Context, F as FailureFnParams, k as HandleErrorArgs, h as HandleErrorFnParams, H as HandleErrorFunction, i as HandleErrorModificationOptions, j as HandleErrorResult, e as InitFnParams, I as InitOutput, M as MiddlewareFnParams, P as ProjectConfig, n as ResolveEnvironmentVariablesFunction, m as ResolveEnvironmentVariablesParams, l as ResolveEnvironmentVariablesResult, R as RunFnParams, S as StartFnParams, g as SuccessFnParams, u as usage } from '../catalog-HfeyVfYa.mjs';
|
|
10
10
|
export { AbortTaskRunError, SerializedError, correctErrorStackTrace, createErrorTaskError, createJsonErrorObject, groupTaskMetadataIssuesByTask, parseError, sanitizeError } from './errors.mjs';
|
|
11
11
|
import { Attributes } from '@opentelemetry/api';
|
|
12
12
|
export { logger } from './logger-api.mjs';
|
|
13
|
-
import { R as RuntimeManager } from '../manager-
|
|
14
|
-
import { B as BackgroundWorkerProperties } from '../messages-
|
|
15
|
-
export { c as BackgroundWorkerClientMessages, b as BackgroundWorkerServerMessages, i as ClientToSharedQueueMessages, m as CoordinatorSocketData, C as CoordinatorToPlatformMessages, k as CoordinatorToProdWorkerMessages, h as PlatformToCoordinatorMessages, g as PlatformToProviderMessages, a as ProdChildToWorkerMessages, l as ProdWorkerSocketData, P as ProdWorkerToChildMessages, j as ProdWorkerToCoordinatorMessages, f as ProviderToPlatformMessages, S as SharedQueueToClientMessages, T as TaskMetadataFailedToParseData, U as UncaughtExceptionMessage, e as childToWorkerMessages, d as clientWebsocketMessages, s as serverWebsocketMessages, w as workerToChildMessages } from '../messages-
|
|
16
|
-
import { a as TaskFileMetadata, b as TaskMetadataWithFilePath } from '../schemas-
|
|
17
|
-
export { C as Config, E as EnvironmentType, F as FixedWindowRateLimit, h as PostStartCauses, i as PreStopCauses, P as Prettify, d as ProdTaskRunExecution, e as ProdTaskRunExecutionPayload, Q as QueueOptions, f as RateLimitOptions, l as RequireKeys, j as ResolvedConfig, R as RetryOptions, g as ScheduleMetadata, S as SlidingWindowRateLimit, T as TaskMetadata, k as TaskRunExecutionLazyAttemptPayload, c as TaskRunExecutionPayload, W as WaitReason } from '../schemas-
|
|
13
|
+
import { R as RuntimeManager } from '../manager-CkUnBH2E.mjs';
|
|
14
|
+
import { B as BackgroundWorkerProperties } from '../messages-7b5K4qKr.mjs';
|
|
15
|
+
export { c as BackgroundWorkerClientMessages, b as BackgroundWorkerServerMessages, i as ClientToSharedQueueMessages, m as CoordinatorSocketData, C as CoordinatorToPlatformMessages, k as CoordinatorToProdWorkerMessages, h as PlatformToCoordinatorMessages, g as PlatformToProviderMessages, a as ProdChildToWorkerMessages, l as ProdWorkerSocketData, P as ProdWorkerToChildMessages, j as ProdWorkerToCoordinatorMessages, f as ProviderToPlatformMessages, S as SharedQueueToClientMessages, T as TaskMetadataFailedToParseData, U as UncaughtExceptionMessage, e as childToWorkerMessages, d as clientWebsocketMessages, s as serverWebsocketMessages, w as workerToChildMessages } from '../messages-7b5K4qKr.mjs';
|
|
16
|
+
import { a as TaskFileMetadata, b as TaskMetadataWithFilePath } from '../schemas-kjSfajbV.mjs';
|
|
17
|
+
export { C as Config, E as EnvironmentType, F as FixedWindowRateLimit, h as PostStartCauses, i as PreStopCauses, P as Prettify, d as ProdTaskRunExecution, e as ProdTaskRunExecutionPayload, Q as QueueOptions, f as RateLimitOptions, l as RequireKeys, j as ResolvedConfig, R as RetryOptions, g as ScheduleMetadata, S as SlidingWindowRateLimit, T as TaskMetadata, k as TaskRunExecutionLazyAttemptPayload, c as TaskRunExecutionPayload, W as WaitReason } from '../schemas-kjSfajbV.mjs';
|
|
18
18
|
export { SemanticInternalAttributes } from './semanticInternalAttributes.mjs';
|
|
19
19
|
export { formatDuration, formatDurationInDays, formatDurationMilliseconds, formatDurationNanoseconds, millisecondsToNanoseconds, nanosecondsToMilliseconds } from './utils/durations.mjs';
|
|
20
20
|
export { T as TriggerTracer } from '../tracer-N0p2Fuuv.mjs';
|
|
@@ -53,6 +53,7 @@ interface ListRunsQueryParams extends CursorPageParams {
|
|
|
53
53
|
to?: Date | number;
|
|
54
54
|
period?: string;
|
|
55
55
|
bulkAction?: string;
|
|
56
|
+
tag?: Array<string> | string;
|
|
56
57
|
schedule?: string;
|
|
57
58
|
isTest?: boolean;
|
|
58
59
|
}
|
|
@@ -91,8 +92,12 @@ declare class ApiClient {
|
|
|
91
92
|
retrieveRun(runId: string, requestOptions?: ZodFetchOptions): ApiPromise<{
|
|
92
93
|
status: "COMPLETED" | "CANCELED" | "QUEUED" | "EXECUTING" | "WAITING_FOR_DEPLOY" | "REATTEMPTING" | "FROZEN" | "FAILED" | "CRASHED" | "INTERRUPTED" | "SYSTEM_FAILURE" | "DELAYED" | "EXPIRED";
|
|
93
94
|
id: string;
|
|
95
|
+
tags: string[];
|
|
94
96
|
isTest: boolean;
|
|
95
97
|
createdAt: Date;
|
|
98
|
+
durationMs: number;
|
|
99
|
+
costInCents: number;
|
|
100
|
+
baseCostInCents: number;
|
|
96
101
|
attempts: ({
|
|
97
102
|
status: "PENDING" | "COMPLETED" | "CANCELED" | "EXECUTING" | "FAILED" | "PAUSED";
|
|
98
103
|
id: string;
|
|
@@ -147,8 +152,12 @@ declare class ApiClient {
|
|
|
147
152
|
rescheduleRun(runId: string, body: RescheduleRunRequestBody, requestOptions?: ZodFetchOptions): ApiPromise<{
|
|
148
153
|
status: "COMPLETED" | "CANCELED" | "QUEUED" | "EXECUTING" | "WAITING_FOR_DEPLOY" | "REATTEMPTING" | "FROZEN" | "FAILED" | "CRASHED" | "INTERRUPTED" | "SYSTEM_FAILURE" | "DELAYED" | "EXPIRED";
|
|
149
154
|
id: string;
|
|
155
|
+
tags: string[];
|
|
150
156
|
isTest: boolean;
|
|
151
157
|
createdAt: Date;
|
|
158
|
+
durationMs: number;
|
|
159
|
+
costInCents: number;
|
|
160
|
+
baseCostInCents: number;
|
|
152
161
|
attempts: ({
|
|
153
162
|
status: "PENDING" | "COMPLETED" | "CANCELED" | "EXECUTING" | "FAILED" | "PAUSED";
|
|
154
163
|
id: string;
|
|
@@ -192,6 +201,9 @@ declare class ApiClient {
|
|
|
192
201
|
ttl?: string | undefined;
|
|
193
202
|
expiredAt?: Date | undefined;
|
|
194
203
|
}>;
|
|
204
|
+
addTags(runId: string, body: AddTagsRequestBody, requestOptions?: ZodFetchOptions): ApiPromise<{
|
|
205
|
+
message: string;
|
|
206
|
+
}>;
|
|
195
207
|
createSchedule(options: CreateScheduleOptions, requestOptions?: ZodFetchOptions): ApiPromise<{
|
|
196
208
|
type: "DECLARATIVE" | "IMPERATIVE";
|
|
197
209
|
id: string;
|
|
@@ -212,18 +224,18 @@ declare class ApiClient {
|
|
|
212
224
|
externalId?: string | null | undefined;
|
|
213
225
|
nextRun?: Date | null | undefined;
|
|
214
226
|
}>;
|
|
215
|
-
listSchedules(options?: ListScheduleOptions, requestOptions?: ZodFetchOptions): OffsetLimitPagePromise<
|
|
216
|
-
id:
|
|
217
|
-
type:
|
|
218
|
-
task:
|
|
219
|
-
active:
|
|
220
|
-
deduplicationKey:
|
|
221
|
-
externalId:
|
|
222
|
-
generator:
|
|
223
|
-
type:
|
|
224
|
-
expression:
|
|
225
|
-
description:
|
|
226
|
-
}, "strip",
|
|
227
|
+
listSchedules(options?: ListScheduleOptions, requestOptions?: ZodFetchOptions): OffsetLimitPagePromise<z.ZodObject<{
|
|
228
|
+
id: z.ZodString;
|
|
229
|
+
type: z.ZodUnion<[z.ZodLiteral<"DECLARATIVE">, z.ZodLiteral<"IMPERATIVE">]>;
|
|
230
|
+
task: z.ZodString;
|
|
231
|
+
active: z.ZodBoolean;
|
|
232
|
+
deduplicationKey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
233
|
+
externalId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
234
|
+
generator: z.ZodObject<{
|
|
235
|
+
type: z.ZodLiteral<"CRON">;
|
|
236
|
+
expression: z.ZodString;
|
|
237
|
+
description: z.ZodString;
|
|
238
|
+
}, "strip", z.ZodTypeAny, {
|
|
227
239
|
type: "CRON";
|
|
228
240
|
description: string;
|
|
229
241
|
expression: string;
|
|
@@ -232,13 +244,13 @@ declare class ApiClient {
|
|
|
232
244
|
description: string;
|
|
233
245
|
expression: string;
|
|
234
246
|
}>;
|
|
235
|
-
timezone:
|
|
236
|
-
nextRun:
|
|
237
|
-
environments:
|
|
238
|
-
id:
|
|
239
|
-
type:
|
|
240
|
-
userName:
|
|
241
|
-
}, "strip",
|
|
247
|
+
timezone: z.ZodString;
|
|
248
|
+
nextRun: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
249
|
+
environments: z.ZodArray<z.ZodObject<{
|
|
250
|
+
id: z.ZodString;
|
|
251
|
+
type: z.ZodString;
|
|
252
|
+
userName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
253
|
+
}, "strip", z.ZodTypeAny, {
|
|
242
254
|
type: string;
|
|
243
255
|
id: string;
|
|
244
256
|
userName?: string | null | undefined;
|
|
@@ -247,7 +259,7 @@ declare class ApiClient {
|
|
|
247
259
|
id: string;
|
|
248
260
|
userName?: string | null | undefined;
|
|
249
261
|
}>, "many">;
|
|
250
|
-
}, "strip",
|
|
262
|
+
}, "strip", z.ZodTypeAny, {
|
|
251
263
|
type: "DECLARATIVE" | "IMPERATIVE";
|
|
252
264
|
id: string;
|
|
253
265
|
task: string;
|
|
@@ -505,4 +517,4 @@ declare function accessoryAttributes(accessory: Accessory): Attributes;
|
|
|
505
517
|
|
|
506
518
|
declare function detectDependencyVersion(dependency: string): string | undefined;
|
|
507
519
|
|
|
508
|
-
export { Accessory, ApiClient, type ApiClientConfiguration, ApiPromise, ApiRequestOptions, BackgroundWorkerProperties, BatchTaskRunExecutionResult, BatchTriggerTaskRequestBody, type CreateEnvironmentVariableParams, CreateEnvironmentVariableRequestBody, CreateScheduleOptions, CursorPageParams, CursorPagePromise, type ImportEnvironmentVariablesParams, type ListProjectRunsQueryParams, ListRunResponseItem, type ListRunsQueryParams, ListScheduleOptions, OFFLOAD_IO_PACKET_LENGTH_LIMIT, OTEL_ATTRIBUTE_PER_EVENT_COUNT_LIMIT, OTEL_ATTRIBUTE_PER_LINK_COUNT_LIMIT, OTEL_LINK_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT, OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_EVENT_COUNT_LIMIT, OffsetLimitPagePromise, RescheduleRunRequestBody, RunStatus, TaskFileMetadata, TaskMetadataWithFilePath, TaskMetadataWithFunctions, TaskRunContext, TaskRunExecutionResult, type TriggerOptions, TriggerTaskRequestBody, type UpdateEnvironmentVariableParams, UpdateEnvironmentVariableRequestBody, UpdateScheduleOptions, accessoryAttributes, apiClientManager, clock, detectDependencyVersion, imposeAttributeLimits, mergeRequestOptions, runtime, taskCatalog, taskContext };
|
|
520
|
+
export { Accessory, AddTagsRequestBody, ApiClient, type ApiClientConfiguration, ApiPromise, ApiRequestOptions, BackgroundWorkerProperties, BatchTaskRunExecutionResult, BatchTriggerTaskRequestBody, type CreateEnvironmentVariableParams, CreateEnvironmentVariableRequestBody, CreateScheduleOptions, CursorPageParams, CursorPagePromise, type ImportEnvironmentVariablesParams, type ListProjectRunsQueryParams, ListRunResponseItem, type ListRunsQueryParams, ListScheduleOptions, OFFLOAD_IO_PACKET_LENGTH_LIMIT, OTEL_ATTRIBUTE_PER_EVENT_COUNT_LIMIT, OTEL_ATTRIBUTE_PER_LINK_COUNT_LIMIT, OTEL_LINK_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT, OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_EVENT_COUNT_LIMIT, OffsetLimitPagePromise, RescheduleRunRequestBody, RunStatus, TaskFileMetadata, TaskMetadataWithFilePath, TaskMetadataWithFunctions, TaskRunContext, TaskRunExecutionResult, type TriggerOptions, TriggerTaskRequestBody, type UpdateEnvironmentVariableParams, UpdateEnvironmentVariableRequestBody, UpdateScheduleOptions, accessoryAttributes, apiClientManager, clock, detectDependencyVersion, imposeAttributeLimits, mergeRequestOptions, runtime, taskCatalog, taskContext };
|
package/dist/v3/index.d.ts
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import * as zod from 'zod';
|
|
2
1
|
import { CursorPageParams, ApiRequestOptions, ZodFetchOptions, ApiPromise, CursorPagePromise, OffsetLimitPagePromise } from './zodfetch.js';
|
|
3
2
|
export { APIHeaders, ApiConnectionError, ApiError, AuthenticationError, BadRequestError, ConflictError, CursorPage, CursorPageResponse, InternalServerError, NotFoundError, OffsetLimitPage, OffsetLimitPageParams, OffsetLimitPageResponse, Page, PageResponse, PermissionDeniedError, RateLimitError, UnprocessableEntityError, isRequestOptions } from './zodfetch.js';
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
import { RunStatus, TriggerTaskRequestBody, BatchTriggerTaskRequestBody, ListRunResponseItem, RescheduleRunRequestBody, AddTagsRequestBody, CreateScheduleOptions, ListScheduleOptions, UpdateScheduleOptions, CreateEnvironmentVariableRequestBody, UpdateEnvironmentVariableRequestBody, Accessory } from './schemas/index.js';
|
|
5
|
+
export { AttemptStatus, BackgroundWorkerMetadata, BatchTriggerTaskResponse, CanceledRunResponse, CancellationSpanEvent, CreateAuthorizationCodeResponse, CreateAuthorizationCodeResponseSchema, CreateBackgroundWorkerRequestBody, CreateBackgroundWorkerResponse, CreateUploadPayloadUrlResponseBody, DeletedScheduleObject, DeploymentErrorData, EnvironmentVariable, EnvironmentVariableResponseBody, EnvironmentVariableValue, EnvironmentVariables, EventFilter, ExceptionEventProperties, ExceptionSpanEvent, ExternalBuildData, FetchRetryBackoffStrategy, FetchRetryByStatusOptions, FetchRetryHeadersStrategy, FetchRetryOptions, FetchRetryStrategy, FetchTimeoutOptions, GetBatchResponseBody, GetDeploymentResponseBody, GetEnvironmentVariablesResponseBody, GetPersonalAccessTokenRequest, GetPersonalAccessTokenRequestSchema, GetPersonalAccessTokenResponse, GetPersonalAccessTokenResponseSchema, GetProjectEnvResponse, GetProjectResponseBody, GetProjectsResponseBody, ImageDetailsMetadata, ImportEnvironmentVariablesRequestBody, InitializeDeploymentRequestBody, InitializeDeploymentResponseBody, ListRunResponse, ListSchedulesResult, OtherSpanEvent, PRIMARY_VARIANT, ReplayRunResponse, RetrieveRunResponse, RunEnvironmentDetails, RunScheduleDetails, RunTags, ScheduleGenerator, ScheduleObject, ScheduleType, ScheduledTaskPayload, SpanEvent, SpanEvents, SpanMessagingEvent, StartDeploymentIndexingRequestBody, StartDeploymentIndexingResponseBody, TaskEventStyle, TaskResource, TimezonesResult, TriggerTaskResponse, Variant, WhoAmIResponse, WhoAmIResponseSchema, isCancellationSpanEvent, isExceptionSpanEvent, stringPatternMatchers } from './schemas/index.js';
|
|
6
|
+
import { T as TaskRunExecutionResult, B as BatchTaskRunExecutionResult, a as TaskRunContext } from '../common-ufw5MzBe.js';
|
|
7
|
+
export { f as MachineConfig, d as MachineCpu, e as MachineMemory, g as MachinePreset, M as MachinePresetName, m as TaskRun, h as TaskRunBuiltInError, i as TaskRunCustomErrorObject, b as TaskRunError, k as TaskRunErrorCodes, c as TaskRunExecution, o as TaskRunExecutionAttempt, t as TaskRunExecutionBatch, p as TaskRunExecutionEnvironment, q as TaskRunExecutionOrganization, r as TaskRunExecutionProject, s as TaskRunExecutionQueue, u as TaskRunExecutionRetry, n as TaskRunExecutionTask, v as TaskRunExecutionUsage, w as TaskRunFailedExecutionResult, l as TaskRunInternalError, j as TaskRunStringError, x as TaskRunSuccessfulExecutionResult } from '../common-ufw5MzBe.js';
|
|
8
|
+
import { C as Clock, a as ClockTime, b as TaskCatalog, T as TaskMetadataWithFunctions } from '../catalog-1uqiDu4t.js';
|
|
9
|
+
export { f as Context, F as FailureFnParams, k as HandleErrorArgs, h as HandleErrorFnParams, H as HandleErrorFunction, i as HandleErrorModificationOptions, j as HandleErrorResult, e as InitFnParams, I as InitOutput, M as MiddlewareFnParams, P as ProjectConfig, n as ResolveEnvironmentVariablesFunction, m as ResolveEnvironmentVariablesParams, l as ResolveEnvironmentVariablesResult, R as RunFnParams, S as StartFnParams, g as SuccessFnParams, u as usage } from '../catalog-1uqiDu4t.js';
|
|
10
10
|
export { AbortTaskRunError, SerializedError, correctErrorStackTrace, createErrorTaskError, createJsonErrorObject, groupTaskMetadataIssuesByTask, parseError, sanitizeError } from './errors.js';
|
|
11
11
|
import { Attributes } from '@opentelemetry/api';
|
|
12
12
|
export { logger } from './logger-api.js';
|
|
13
|
-
import { R as RuntimeManager } from '../manager-
|
|
14
|
-
import { B as BackgroundWorkerProperties } from '../messages-
|
|
15
|
-
export { c as BackgroundWorkerClientMessages, b as BackgroundWorkerServerMessages, i as ClientToSharedQueueMessages, m as CoordinatorSocketData, C as CoordinatorToPlatformMessages, k as CoordinatorToProdWorkerMessages, h as PlatformToCoordinatorMessages, g as PlatformToProviderMessages, a as ProdChildToWorkerMessages, l as ProdWorkerSocketData, P as ProdWorkerToChildMessages, j as ProdWorkerToCoordinatorMessages, f as ProviderToPlatformMessages, S as SharedQueueToClientMessages, T as TaskMetadataFailedToParseData, U as UncaughtExceptionMessage, e as childToWorkerMessages, d as clientWebsocketMessages, s as serverWebsocketMessages, w as workerToChildMessages } from '../messages-
|
|
16
|
-
import { a as TaskFileMetadata, b as TaskMetadataWithFilePath } from '../schemas-
|
|
17
|
-
export { C as Config, E as EnvironmentType, F as FixedWindowRateLimit, h as PostStartCauses, i as PreStopCauses, P as Prettify, d as ProdTaskRunExecution, e as ProdTaskRunExecutionPayload, Q as QueueOptions, f as RateLimitOptions, l as RequireKeys, j as ResolvedConfig, R as RetryOptions, g as ScheduleMetadata, S as SlidingWindowRateLimit, T as TaskMetadata, k as TaskRunExecutionLazyAttemptPayload, c as TaskRunExecutionPayload, W as WaitReason } from '../schemas-
|
|
13
|
+
import { R as RuntimeManager } from '../manager-y-nT-ymn.js';
|
|
14
|
+
import { B as BackgroundWorkerProperties } from '../messages-7b5K4qKr.js';
|
|
15
|
+
export { c as BackgroundWorkerClientMessages, b as BackgroundWorkerServerMessages, i as ClientToSharedQueueMessages, m as CoordinatorSocketData, C as CoordinatorToPlatformMessages, k as CoordinatorToProdWorkerMessages, h as PlatformToCoordinatorMessages, g as PlatformToProviderMessages, a as ProdChildToWorkerMessages, l as ProdWorkerSocketData, P as ProdWorkerToChildMessages, j as ProdWorkerToCoordinatorMessages, f as ProviderToPlatformMessages, S as SharedQueueToClientMessages, T as TaskMetadataFailedToParseData, U as UncaughtExceptionMessage, e as childToWorkerMessages, d as clientWebsocketMessages, s as serverWebsocketMessages, w as workerToChildMessages } from '../messages-7b5K4qKr.js';
|
|
16
|
+
import { a as TaskFileMetadata, b as TaskMetadataWithFilePath } from '../schemas-kjSfajbV.js';
|
|
17
|
+
export { C as Config, E as EnvironmentType, F as FixedWindowRateLimit, h as PostStartCauses, i as PreStopCauses, P as Prettify, d as ProdTaskRunExecution, e as ProdTaskRunExecutionPayload, Q as QueueOptions, f as RateLimitOptions, l as RequireKeys, j as ResolvedConfig, R as RetryOptions, g as ScheduleMetadata, S as SlidingWindowRateLimit, T as TaskMetadata, k as TaskRunExecutionLazyAttemptPayload, c as TaskRunExecutionPayload, W as WaitReason } from '../schemas-kjSfajbV.js';
|
|
18
18
|
export { SemanticInternalAttributes } from './semanticInternalAttributes.js';
|
|
19
19
|
export { formatDuration, formatDurationInDays, formatDurationMilliseconds, formatDurationNanoseconds, millisecondsToNanoseconds, nanosecondsToMilliseconds } from './utils/durations.js';
|
|
20
20
|
export { T as TriggerTracer } from '../tracer-N0p2Fuuv.js';
|
|
@@ -53,6 +53,7 @@ interface ListRunsQueryParams extends CursorPageParams {
|
|
|
53
53
|
to?: Date | number;
|
|
54
54
|
period?: string;
|
|
55
55
|
bulkAction?: string;
|
|
56
|
+
tag?: Array<string> | string;
|
|
56
57
|
schedule?: string;
|
|
57
58
|
isTest?: boolean;
|
|
58
59
|
}
|
|
@@ -91,8 +92,12 @@ declare class ApiClient {
|
|
|
91
92
|
retrieveRun(runId: string, requestOptions?: ZodFetchOptions): ApiPromise<{
|
|
92
93
|
status: "COMPLETED" | "CANCELED" | "QUEUED" | "EXECUTING" | "WAITING_FOR_DEPLOY" | "REATTEMPTING" | "FROZEN" | "FAILED" | "CRASHED" | "INTERRUPTED" | "SYSTEM_FAILURE" | "DELAYED" | "EXPIRED";
|
|
93
94
|
id: string;
|
|
95
|
+
tags: string[];
|
|
94
96
|
isTest: boolean;
|
|
95
97
|
createdAt: Date;
|
|
98
|
+
durationMs: number;
|
|
99
|
+
costInCents: number;
|
|
100
|
+
baseCostInCents: number;
|
|
96
101
|
attempts: ({
|
|
97
102
|
status: "PENDING" | "COMPLETED" | "CANCELED" | "EXECUTING" | "FAILED" | "PAUSED";
|
|
98
103
|
id: string;
|
|
@@ -147,8 +152,12 @@ declare class ApiClient {
|
|
|
147
152
|
rescheduleRun(runId: string, body: RescheduleRunRequestBody, requestOptions?: ZodFetchOptions): ApiPromise<{
|
|
148
153
|
status: "COMPLETED" | "CANCELED" | "QUEUED" | "EXECUTING" | "WAITING_FOR_DEPLOY" | "REATTEMPTING" | "FROZEN" | "FAILED" | "CRASHED" | "INTERRUPTED" | "SYSTEM_FAILURE" | "DELAYED" | "EXPIRED";
|
|
149
154
|
id: string;
|
|
155
|
+
tags: string[];
|
|
150
156
|
isTest: boolean;
|
|
151
157
|
createdAt: Date;
|
|
158
|
+
durationMs: number;
|
|
159
|
+
costInCents: number;
|
|
160
|
+
baseCostInCents: number;
|
|
152
161
|
attempts: ({
|
|
153
162
|
status: "PENDING" | "COMPLETED" | "CANCELED" | "EXECUTING" | "FAILED" | "PAUSED";
|
|
154
163
|
id: string;
|
|
@@ -192,6 +201,9 @@ declare class ApiClient {
|
|
|
192
201
|
ttl?: string | undefined;
|
|
193
202
|
expiredAt?: Date | undefined;
|
|
194
203
|
}>;
|
|
204
|
+
addTags(runId: string, body: AddTagsRequestBody, requestOptions?: ZodFetchOptions): ApiPromise<{
|
|
205
|
+
message: string;
|
|
206
|
+
}>;
|
|
195
207
|
createSchedule(options: CreateScheduleOptions, requestOptions?: ZodFetchOptions): ApiPromise<{
|
|
196
208
|
type: "DECLARATIVE" | "IMPERATIVE";
|
|
197
209
|
id: string;
|
|
@@ -212,18 +224,18 @@ declare class ApiClient {
|
|
|
212
224
|
externalId?: string | null | undefined;
|
|
213
225
|
nextRun?: Date | null | undefined;
|
|
214
226
|
}>;
|
|
215
|
-
listSchedules(options?: ListScheduleOptions, requestOptions?: ZodFetchOptions): OffsetLimitPagePromise<
|
|
216
|
-
id:
|
|
217
|
-
type:
|
|
218
|
-
task:
|
|
219
|
-
active:
|
|
220
|
-
deduplicationKey:
|
|
221
|
-
externalId:
|
|
222
|
-
generator:
|
|
223
|
-
type:
|
|
224
|
-
expression:
|
|
225
|
-
description:
|
|
226
|
-
}, "strip",
|
|
227
|
+
listSchedules(options?: ListScheduleOptions, requestOptions?: ZodFetchOptions): OffsetLimitPagePromise<z.ZodObject<{
|
|
228
|
+
id: z.ZodString;
|
|
229
|
+
type: z.ZodUnion<[z.ZodLiteral<"DECLARATIVE">, z.ZodLiteral<"IMPERATIVE">]>;
|
|
230
|
+
task: z.ZodString;
|
|
231
|
+
active: z.ZodBoolean;
|
|
232
|
+
deduplicationKey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
233
|
+
externalId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
234
|
+
generator: z.ZodObject<{
|
|
235
|
+
type: z.ZodLiteral<"CRON">;
|
|
236
|
+
expression: z.ZodString;
|
|
237
|
+
description: z.ZodString;
|
|
238
|
+
}, "strip", z.ZodTypeAny, {
|
|
227
239
|
type: "CRON";
|
|
228
240
|
description: string;
|
|
229
241
|
expression: string;
|
|
@@ -232,13 +244,13 @@ declare class ApiClient {
|
|
|
232
244
|
description: string;
|
|
233
245
|
expression: string;
|
|
234
246
|
}>;
|
|
235
|
-
timezone:
|
|
236
|
-
nextRun:
|
|
237
|
-
environments:
|
|
238
|
-
id:
|
|
239
|
-
type:
|
|
240
|
-
userName:
|
|
241
|
-
}, "strip",
|
|
247
|
+
timezone: z.ZodString;
|
|
248
|
+
nextRun: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
249
|
+
environments: z.ZodArray<z.ZodObject<{
|
|
250
|
+
id: z.ZodString;
|
|
251
|
+
type: z.ZodString;
|
|
252
|
+
userName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
253
|
+
}, "strip", z.ZodTypeAny, {
|
|
242
254
|
type: string;
|
|
243
255
|
id: string;
|
|
244
256
|
userName?: string | null | undefined;
|
|
@@ -247,7 +259,7 @@ declare class ApiClient {
|
|
|
247
259
|
id: string;
|
|
248
260
|
userName?: string | null | undefined;
|
|
249
261
|
}>, "many">;
|
|
250
|
-
}, "strip",
|
|
262
|
+
}, "strip", z.ZodTypeAny, {
|
|
251
263
|
type: "DECLARATIVE" | "IMPERATIVE";
|
|
252
264
|
id: string;
|
|
253
265
|
task: string;
|
|
@@ -505,4 +517,4 @@ declare function accessoryAttributes(accessory: Accessory): Attributes;
|
|
|
505
517
|
|
|
506
518
|
declare function detectDependencyVersion(dependency: string): string | undefined;
|
|
507
519
|
|
|
508
|
-
export { Accessory, ApiClient, type ApiClientConfiguration, ApiPromise, ApiRequestOptions, BackgroundWorkerProperties, BatchTaskRunExecutionResult, BatchTriggerTaskRequestBody, type CreateEnvironmentVariableParams, CreateEnvironmentVariableRequestBody, CreateScheduleOptions, CursorPageParams, CursorPagePromise, type ImportEnvironmentVariablesParams, type ListProjectRunsQueryParams, ListRunResponseItem, type ListRunsQueryParams, ListScheduleOptions, OFFLOAD_IO_PACKET_LENGTH_LIMIT, OTEL_ATTRIBUTE_PER_EVENT_COUNT_LIMIT, OTEL_ATTRIBUTE_PER_LINK_COUNT_LIMIT, OTEL_LINK_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT, OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_EVENT_COUNT_LIMIT, OffsetLimitPagePromise, RescheduleRunRequestBody, RunStatus, TaskFileMetadata, TaskMetadataWithFilePath, TaskMetadataWithFunctions, TaskRunContext, TaskRunExecutionResult, type TriggerOptions, TriggerTaskRequestBody, type UpdateEnvironmentVariableParams, UpdateEnvironmentVariableRequestBody, UpdateScheduleOptions, accessoryAttributes, apiClientManager, clock, detectDependencyVersion, imposeAttributeLimits, mergeRequestOptions, runtime, taskCatalog, taskContext };
|
|
520
|
+
export { Accessory, AddTagsRequestBody, ApiClient, type ApiClientConfiguration, ApiPromise, ApiRequestOptions, BackgroundWorkerProperties, BatchTaskRunExecutionResult, BatchTriggerTaskRequestBody, type CreateEnvironmentVariableParams, CreateEnvironmentVariableRequestBody, CreateScheduleOptions, CursorPageParams, CursorPagePromise, type ImportEnvironmentVariablesParams, type ListProjectRunsQueryParams, ListRunResponseItem, type ListRunsQueryParams, ListScheduleOptions, OFFLOAD_IO_PACKET_LENGTH_LIMIT, OTEL_ATTRIBUTE_PER_EVENT_COUNT_LIMIT, OTEL_ATTRIBUTE_PER_LINK_COUNT_LIMIT, OTEL_LINK_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_COUNT_LIMIT, OTEL_LOG_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT, OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT, OTEL_SPAN_EVENT_COUNT_LIMIT, OffsetLimitPagePromise, RescheduleRunRequestBody, RunStatus, TaskFileMetadata, TaskMetadataWithFilePath, TaskMetadataWithFunctions, TaskRunContext, TaskRunExecutionResult, type TriggerOptions, TriggerTaskRequestBody, type UpdateEnvironmentVariableParams, UpdateEnvironmentVariableRequestBody, UpdateScheduleOptions, accessoryAttributes, apiClientManager, clock, detectDependencyVersion, imposeAttributeLimits, mergeRequestOptions, runtime, taskCatalog, taskContext };
|
package/dist/v3/index.js
CHANGED
|
@@ -33,7 +33,7 @@ var __privateMethod = (obj, member, method) => {
|
|
|
33
33
|
};
|
|
34
34
|
|
|
35
35
|
// package.json
|
|
36
|
-
var version = "0.0.0-prerelease-
|
|
36
|
+
var version = "0.0.0-prerelease-20240724110801";
|
|
37
37
|
var dependencies = {
|
|
38
38
|
"@google-cloud/precise-date": "^4.0.0",
|
|
39
39
|
"@opentelemetry/api": "^1.8.0",
|
|
@@ -717,6 +717,11 @@ var CreateBackgroundWorkerResponse = zod.z.object({
|
|
|
717
717
|
version: zod.z.string(),
|
|
718
718
|
contentHash: zod.z.string()
|
|
719
719
|
});
|
|
720
|
+
var RunTag = zod.z.string().max(64, "Tags must be less than 64 characters");
|
|
721
|
+
var RunTags = zod.z.union([
|
|
722
|
+
RunTag,
|
|
723
|
+
RunTag.array().max(3, "You can only set a maximum of 3 tags on a run.")
|
|
724
|
+
]);
|
|
720
725
|
var TriggerTaskRequestBody = zod.z.object({
|
|
721
726
|
payload: zod.z.any(),
|
|
722
727
|
context: zod.z.any(),
|
|
@@ -731,6 +736,7 @@ var TriggerTaskRequestBody = zod.z.object({
|
|
|
731
736
|
payloadType: zod.z.string().optional(),
|
|
732
737
|
delay: zod.z.string().or(zod.z.coerce.date()).optional(),
|
|
733
738
|
ttl: zod.z.string().or(zod.z.number().nonnegative().int()).optional(),
|
|
739
|
+
tags: RunTags.optional(),
|
|
734
740
|
maxAttempts: zod.z.number().int().optional()
|
|
735
741
|
}).optional()
|
|
736
742
|
});
|
|
@@ -758,6 +764,9 @@ var GetBatchResponseBody = zod.z.object({
|
|
|
758
764
|
])
|
|
759
765
|
}))
|
|
760
766
|
});
|
|
767
|
+
var AddTagsRequestBody = zod.z.object({
|
|
768
|
+
tags: RunTags
|
|
769
|
+
});
|
|
761
770
|
var RescheduleRunRequestBody = zod.z.object({
|
|
762
771
|
delay: zod.z.string().or(zod.z.coerce.date())
|
|
763
772
|
});
|
|
@@ -1020,7 +1029,11 @@ var CommonRunFields = {
|
|
|
1020
1029
|
finishedAt: zod.z.coerce.date().optional(),
|
|
1021
1030
|
delayedUntil: zod.z.coerce.date().optional(),
|
|
1022
1031
|
ttl: zod.z.string().optional(),
|
|
1023
|
-
expiredAt: zod.z.coerce.date().optional()
|
|
1032
|
+
expiredAt: zod.z.coerce.date().optional(),
|
|
1033
|
+
tags: zod.z.string().array(),
|
|
1034
|
+
costInCents: zod.z.number(),
|
|
1035
|
+
baseCostInCents: zod.z.number(),
|
|
1036
|
+
durationMs: zod.z.number()
|
|
1024
1037
|
};
|
|
1025
1038
|
var RetrieveRunResponse = zod.z.object({
|
|
1026
1039
|
...CommonRunFields,
|
|
@@ -3296,6 +3309,15 @@ var _ApiClient = class _ApiClient {
|
|
|
3296
3309
|
body: JSON.stringify(body)
|
|
3297
3310
|
}, mergeRequestOptions(this.defaultRequestOptions, requestOptions));
|
|
3298
3311
|
}
|
|
3312
|
+
addTags(runId, body, requestOptions) {
|
|
3313
|
+
return zodfetch(zod.z.object({
|
|
3314
|
+
message: zod.z.string()
|
|
3315
|
+
}), `${this.baseUrl}/api/v1/runs/${runId}/tags`, {
|
|
3316
|
+
method: "POST",
|
|
3317
|
+
headers: __privateMethod(this, _getHeaders, getHeaders_fn).call(this, false),
|
|
3318
|
+
body: JSON.stringify(body)
|
|
3319
|
+
}, mergeRequestOptions(this.defaultRequestOptions, requestOptions));
|
|
3320
|
+
}
|
|
3299
3321
|
createSchedule(options, requestOptions) {
|
|
3300
3322
|
return zodfetch(ScheduleObject, `${this.baseUrl}/api/v1/schedules`, {
|
|
3301
3323
|
method: "POST",
|
|
@@ -3423,6 +3445,9 @@ function createSearchQueryForListRuns(query) {
|
|
|
3423
3445
|
if (query.bulkAction) {
|
|
3424
3446
|
searchParams.append("filter[bulkAction]", query.bulkAction);
|
|
3425
3447
|
}
|
|
3448
|
+
if (query.tag) {
|
|
3449
|
+
searchParams.append("filter[tag]", Array.isArray(query.tag) ? query.tag.join(",") : query.tag);
|
|
3450
|
+
}
|
|
3426
3451
|
if (query.schedule) {
|
|
3427
3452
|
searchParams.append("filter[schedule]", query.schedule);
|
|
3428
3453
|
}
|
|
@@ -4489,6 +4514,7 @@ function safeJsonParse2(value) {
|
|
|
4489
4514
|
__name(safeJsonParse2, "safeJsonParse");
|
|
4490
4515
|
|
|
4491
4516
|
exports.AbortTaskRunError = AbortTaskRunError;
|
|
4517
|
+
exports.AddTagsRequestBody = AddTagsRequestBody;
|
|
4492
4518
|
exports.ApiClient = ApiClient;
|
|
4493
4519
|
exports.ApiConnectionError = ApiConnectionError;
|
|
4494
4520
|
exports.ApiError = ApiError;
|
|
@@ -4593,6 +4619,7 @@ exports.RetryOptions = RetryOptions;
|
|
|
4593
4619
|
exports.RunEnvironmentDetails = RunEnvironmentDetails;
|
|
4594
4620
|
exports.RunScheduleDetails = RunScheduleDetails;
|
|
4595
4621
|
exports.RunStatus = RunStatus;
|
|
4622
|
+
exports.RunTags = RunTags;
|
|
4596
4623
|
exports.ScheduleGenerator = ScheduleGenerator;
|
|
4597
4624
|
exports.ScheduleMetadata = ScheduleMetadata;
|
|
4598
4625
|
exports.ScheduleObject = ScheduleObject;
|