import * as z from "zod/v4"; import { ClosedEnum } from "../types/enums.js"; import { Result as SafeParseResult } from "../types/fp.js"; import { DeploymentCredentialRotationEvent } from "./deploymentcredentialrotationevent.js"; import { SDKValidationError } from "./errors/sdkvalidationerror.js"; export type EventDataDeploymentDeletionRequested = { /** * ID of the deployment */ deploymentId: string; type: "DeploymentDeletionRequested"; }; /** * Type of authenticated principal that requested an event. */ export declare const EventKind4: { readonly User: "user"; readonly ServiceAccount: "serviceAccount"; }; /** * Type of authenticated principal that requested an event. */ export type EventKind4 = ClosedEnum; /** * Authenticated principal that requested a deployment intent event. */ export type EventActor4 = { /** * User email when the principal is a user. */ email?: string | null | undefined; /** * Stable user or service-account identifier. */ id: string; /** * Type of authenticated principal that requested an event. */ kind: EventKind4; }; export type EventActorUnion4 = EventActor4 | any; export type EventDataDeploymentEnvironmentUpdated = { actor?: EventActor4 | any | null | undefined; /** * Names of the environment variables that changed (added, removed, or modified) */ changedKeys: Array; /** * ID of the deployment */ deploymentId: string; type: "DeploymentEnvironmentUpdated"; }; export type EventDataDeploymentReleaseUnpinned = { /** * ID of the deployment */ deploymentId: string; /** * ID of the release that was previously pinned */ previousPinnedReleaseId: string; type: "DeploymentReleaseUnpinned"; }; export type EventDataDeploymentReleasePinned = { /** * ID of the deployment */ deploymentId: string; /** * ID of the release that is now pinned */ pinnedReleaseId: string; /** * ID of the previously pinned release, if any */ previousPinnedReleaseId?: string | null | undefined; type: "DeploymentReleasePinned"; }; export type EventDataDeploymentRedeployRequested = { /** * ID of the deployment */ deploymentId: string; /** * ID of the release being redeployed */ releaseId: string; type: "DeploymentRedeployRequested"; }; /** * Type of authenticated principal that requested an event. */ export declare const EventKind3: { readonly User: "user"; readonly ServiceAccount: "serviceAccount"; }; /** * Type of authenticated principal that requested an event. */ export type EventKind3 = ClosedEnum; /** * Authenticated principal that requested a deployment intent event. */ export type EventActor3 = { /** * User email when the principal is a user. */ email?: string | null | undefined; /** * Stable user or service-account identifier. */ id: string; /** * Type of authenticated principal that requested an event. */ kind: EventKind3; }; export type EventActorUnion3 = EventActor3 | any; /** * Canonical error container that provides a structured way to represent errors * * @remarks * with rich metadata including error codes, human-readable messages, context, * and chaining capabilities for error propagation. * * This struct is designed to be both machine-readable and user-friendly, * supporting serialization for API responses and detailed error reporting * in distributed systems. */ export type EventPreviousError = { /** * A unique identifier for the type of error. * * @remarks * * This should be a short, machine-readable string that can be used * by clients to programmatically handle different error types. * Examples: "NOT_FOUND", "VALIDATION_ERROR", "TIMEOUT" */ code: string; /** * Additional diagnostic information about the error context. * * @remarks * * This optional field can contain structured data providing more details * about the error, such as validation errors, request parameters that * caused the issue, or other relevant context information. */ context?: any | null | undefined; /** * Optional human-facing remediation hint. */ hint?: string | null | undefined; /** * HTTP status code for this error. * * @remarks * * Used when converting the error to an HTTP response. If None, falls back to * the error type's default status code or 500. */ httpStatusCode?: number | null | undefined; /** * Indicates if this is an internal error that should not be exposed to users. * * @remarks * * When `true`, this error contains sensitive information or implementation * details that should not be shown to end-users. Such errors should be * logged for debugging but replaced with generic error messages in responses. */ internal: boolean; /** * Human-readable error message. * * @remarks * * This message should be clear and actionable for developers or end-users, * providing context about what went wrong and potentially how to fix it. */ message: string; /** * Indicates whether the operation that caused the error should be retried. * * @remarks * * When `true`, the error is transient and the operation might succeed * if attempted again. When `false`, retrying the same operation is * unlikely to succeed without changes. */ retryable: boolean; /** * The underlying error that caused this error, creating an error chain. * * @remarks * * This allows for proper error propagation and debugging by maintaining * the full context of how an error occurred through multiple layers * of an application. */ source?: any | null | undefined; }; export type EventPreviousErrorUnion = EventPreviousError | any; export type EventDataDeploymentRetryRequested = { actor?: EventActor3 | any | null | undefined; /** * ID of the release that the failed attempt was targeting, if known */ attemptedReleaseId?: string | null | undefined; /** * ID of the deployment */ deploymentId: string; previousError?: EventPreviousError | any | null | undefined; type: "DeploymentRetryRequested"; }; /** * Type of authenticated principal that requested an event. */ export declare const EventKind2: { readonly User: "user"; readonly ServiceAccount: "serviceAccount"; }; /** * Type of authenticated principal that requested an event. */ export type EventKind2 = ClosedEnum; /** * Authenticated principal that requested a deployment intent event. */ export type EventActor2 = { /** * User email when the principal is a user. */ email?: string | null | undefined; /** * Stable user or service-account identifier. */ id: string; /** * Type of authenticated principal that requested an event. */ kind: EventKind2; }; export type EventActorUnion2 = EventActor2 | any; export type EventDataDeploymentReleaseChannelChanged = { actor?: EventActor2 | any | null | undefined; /** * Newly followed channel */ channel: string; /** * ID of the deployment */ deploymentId: string; /** * Previously followed channel */ previousChannel: string; type: "DeploymentReleaseChannelChanged"; }; /** * Type of authenticated principal that requested an event. */ export declare const EventKind1: { readonly User: "user"; readonly ServiceAccount: "serviceAccount"; }; /** * Type of authenticated principal that requested an event. */ export type EventKind1 = ClosedEnum; /** * Authenticated principal that requested a deployment intent event. */ export type EventActor1 = { /** * User email when the principal is a user. */ email?: string | null | undefined; /** * Stable user or service-account identifier. */ id: string; /** * Type of authenticated principal that requested an event. */ kind: EventKind1; }; export type EventActorUnion1 = EventActor1 | any; export type EventDataReleaseChannelUpdated = { actor?: EventActor1 | any | null | undefined; /** * Name of the channel that moved */ channel: string; /** * ID of the release that was previously current, if any */ previousReleaseId?: string | null | undefined; /** * ID of the release that is now current */ releaseId: string; type: "ReleaseChannelUpdated"; }; export type EventDataDeploymentDeleted = { /** * ID of the deployment that was deleted */ deploymentId: string; type: "DeploymentDeleted"; }; export type EventDataDeploymentRecovered = { /** * ID of the deployment */ deploymentId: string; /** * ID of the release that is now live */ releaseId: string; type: "DeploymentRecovered"; }; /** * Canonical error container that provides a structured way to represent errors * * @remarks * with rich metadata including error codes, human-readable messages, context, * and chaining capabilities for error propagation. * * This struct is designed to be both machine-readable and user-friendly, * supporting serialization for API responses and detailed error reporting * in distributed systems. */ export type EventDataError2 = { /** * A unique identifier for the type of error. * * @remarks * * This should be a short, machine-readable string that can be used * by clients to programmatically handle different error types. * Examples: "NOT_FOUND", "VALIDATION_ERROR", "TIMEOUT" */ code: string; /** * Additional diagnostic information about the error context. * * @remarks * * This optional field can contain structured data providing more details * about the error, such as validation errors, request parameters that * caused the issue, or other relevant context information. */ context?: any | null | undefined; /** * Optional human-facing remediation hint. */ hint?: string | null | undefined; /** * HTTP status code for this error. * * @remarks * * Used when converting the error to an HTTP response. If None, falls back to * the error type's default status code or 500. */ httpStatusCode?: number | null | undefined; /** * Indicates if this is an internal error that should not be exposed to users. * * @remarks * * When `true`, this error contains sensitive information or implementation * details that should not be shown to end-users. Such errors should be * logged for debugging but replaced with generic error messages in responses. */ internal: boolean; /** * Human-readable error message. * * @remarks * * This message should be clear and actionable for developers or end-users, * providing context about what went wrong and potentially how to fix it. */ message: string; /** * Indicates whether the operation that caused the error should be retried. * * @remarks * * When `true`, the error is transient and the operation might succeed * if attempted again. When `false`, retrying the same operation is * unlikely to succeed without changes. */ retryable: boolean; /** * The underlying error that caused this error, creating an error chain. * * @remarks * * This allows for proper error propagation and debugging by maintaining * the full context of how an error occurred through multiple layers * of an application. */ source?: any | null | undefined; }; export type EventDataDeploymentDegraded = { /** * ID of the deployment */ deploymentId: string; /** * Canonical error container that provides a structured way to represent errors * * @remarks * with rich metadata including error codes, human-readable messages, context, * and chaining capabilities for error propagation. * * This struct is designed to be both machine-readable and user-friendly, * supporting serialization for API responses and detailed error reporting * in distributed systems. */ error: EventDataError2; type: "DeploymentDegraded"; }; /** * Canonical error container that provides a structured way to represent errors * * @remarks * with rich metadata including error codes, human-readable messages, context, * and chaining capabilities for error propagation. * * This struct is designed to be both machine-readable and user-friendly, * supporting serialization for API responses and detailed error reporting * in distributed systems. */ export type EventDataError1 = { /** * A unique identifier for the type of error. * * @remarks * * This should be a short, machine-readable string that can be used * by clients to programmatically handle different error types. * Examples: "NOT_FOUND", "VALIDATION_ERROR", "TIMEOUT" */ code: string; /** * Additional diagnostic information about the error context. * * @remarks * * This optional field can contain structured data providing more details * about the error, such as validation errors, request parameters that * caused the issue, or other relevant context information. */ context?: any | null | undefined; /** * Optional human-facing remediation hint. */ hint?: string | null | undefined; /** * HTTP status code for this error. * * @remarks * * Used when converting the error to an HTTP response. If None, falls back to * the error type's default status code or 500. */ httpStatusCode?: number | null | undefined; /** * Indicates if this is an internal error that should not be exposed to users. * * @remarks * * When `true`, this error contains sensitive information or implementation * details that should not be shown to end-users. Such errors should be * logged for debugging but replaced with generic error messages in responses. */ internal: boolean; /** * Human-readable error message. * * @remarks * * This message should be clear and actionable for developers or end-users, * providing context about what went wrong and potentially how to fix it. */ message: string; /** * Indicates whether the operation that caused the error should be retried. * * @remarks * * When `true`, the error is transient and the operation might succeed * if attempted again. When `false`, retrying the same operation is * unlikely to succeed without changes. */ retryable: boolean; /** * The underlying error that caused this error, creating an error chain. * * @remarks * * This allows for proper error propagation and debugging by maintaining * the full context of how an error occurred through multiple layers * of an application. */ source?: any | null | undefined; }; /** * Phase of a deployment at which a failure occurred. * * @remarks * * Derived from the source deployment status: `preflights-failed` → * `Preflights`, `provisioning-failed` → `Provisioning`, `update-failed` → * `Updating`, `delete-failed` → `Deleting`. * `refresh-failed` is modelled separately via `DeploymentDegraded`. */ export declare const EventPhase: { readonly Preflights: "preflights"; readonly Provisioning: "provisioning"; readonly Updating: "updating"; readonly Deleting: "deleting"; }; /** * Phase of a deployment at which a failure occurred. * * @remarks * * Derived from the source deployment status: `preflights-failed` → * `Preflights`, `provisioning-failed` → `Provisioning`, `update-failed` → * `Updating`, `delete-failed` → `Deleting`. * `refresh-failed` is modelled separately via `DeploymentDegraded`. */ export type EventPhase = ClosedEnum; export type EventDataDeploymentFailed = { /** * ID of the release the platform was trying to deploy, if known */ attemptedReleaseId?: string | null | undefined; /** * ID of the deployment */ deploymentId: string; /** * Canonical error container that provides a structured way to represent errors * * @remarks * with rich metadata including error codes, human-readable messages, context, * and chaining capabilities for error propagation. * * This struct is designed to be both machine-readable and user-friendly, * supporting serialization for API responses and detailed error reporting * in distributed systems. */ error: EventDataError1; /** * Phase of a deployment at which a failure occurred. * * @remarks * * Derived from the source deployment status: `preflights-failed` → * `Preflights`, `provisioning-failed` → `Provisioning`, `update-failed` → * `Updating`, `delete-failed` → `Deleting`. * `refresh-failed` is modelled separately via `DeploymentDegraded`. */ phase: EventPhase; type: "DeploymentFailed"; }; export type EventDataDeploymentReleased = { /** * ID of the deployment */ deploymentId: string; /** * ID of the release that was previously live, if any */ previousReleaseId?: string | null | undefined; /** * ID of the release that is now live */ releaseId: string; type: "DeploymentReleased"; }; export type EventDataDeploymentCreated = { /** * ID of the deployment group this slot belongs to */ deploymentGroupId: string; /** * ID of the deployment that was created */ deploymentId: string; /** * Initial release the slot was created with, if any */ releaseId?: string | null | undefined; type: "DeploymentCreated"; }; export type EventDataEmptyingBuckets = { /** * Names of the S3 buckets being emptied */ bucketNames: Array; type: "EmptyingBuckets"; }; export type EventDataDeletingCloudFormationStack = { /** * Name of the CloudFormation stack */ cfnStackName: string; /** * Current stack status */ currentStatus: string; type: "DeletingCloudFormationStack"; }; export type EventDataImportingStackStateFromCloudFormation = { /** * Name of the CloudFormation stack */ cfnStackName: string; type: "ImportingStackStateFromCloudFormation"; }; export type EventDataAssumingRole = { /** * ARN of the role to assume */ roleArn: string; type: "AssumingRole"; }; export type EventDataDeployingCloudFormationStack = { /** * Name of the CloudFormation stack */ cfnStackName: string; /** * Current stack status */ currentStatus: string; type: "DeployingCloudFormationStack"; }; export type EventDataEnsuringDockerRepository = { /** * Name of the docker repository */ repositoryName: string; type: "EnsuringDockerRepository"; }; export type EventDataSettingUpPlatformContext = { /** * Name of the platform (e.g., "AWS", "GCP") */ platformName: string; type: "SettingUpPlatformContext"; }; export type EventDataCleaningUpEnvironment = { /** * Name of the stack being cleaned up */ stackName: string; /** * Name of the deployment strategy being used for cleanup */ strategyName: string; type: "CleaningUpEnvironment"; }; export type EventDataCleaningUpStack = { /** * Name of the stack being cleaned up */ stackName: string; /** * Name of the deployment strategy being used for cleanup */ strategyName: string; type: "CleaningUpStack"; }; export type EventDataRunningTestWorker = { /** * Name of the stack being tested */ stackName: string; type: "RunningTestWorker"; }; export type EventDataDeployingStack = { /** * Name of the stack being deployed */ stackName: string; type: "DeployingStack"; }; export type EventDataPreparingEnvironment = { /** * Name of the deployment strategy being used */ strategyName: string; type: "PreparingEnvironment"; }; export type EventDataDebuggingAgent = { /** * ID of the agent being debugged */ agentId: string; /** * ID of the debug session */ debugSessionId: string; type: "DebuggingAgent"; }; export type EventDataDeletingAgent = { /** * ID of the agent being deleted */ agentId: string; /** * ID of the release that was running on the agent */ releaseId: string; type: "DeletingAgent"; }; export type EventDataUpdatingAgent = { /** * ID of the agent being updated */ agentId: string; /** * ID of the new release being deployed to the agent */ releaseId: string; type: "UpdatingAgent"; }; export type EventDataProvisioningAgent = { /** * ID of the agent being provisioned */ agentId: string; /** * ID of the release being deployed to the agent */ releaseId: string; type: "ProvisioningAgent"; }; export type EventDataGeneratingTemplate = { /** * Platform for which the template is being generated */ platform: string; type: "GeneratingTemplate"; }; export type EventDataGeneratingCloudFormationTemplate = { type: "GeneratingCloudFormationTemplate"; }; /** * Represents the target cloud platform. */ export declare const EventPlatform: { readonly Aws: "aws"; readonly Gcp: "gcp"; readonly Azure: "azure"; readonly Kubernetes: "kubernetes"; readonly Machines: "machines"; readonly Local: "local"; readonly Test: "test"; }; /** * Represents the target cloud platform. */ export type EventPlatform = ClosedEnum; /** * Resource that can hold any resource type in the Alien system. All resources share common 'type' and 'id' fields with additional type-specific properties. */ export type EventConfig = { /** * The unique identifier for this specific resource instance. Must contain only alphanumeric characters, hyphens, and underscores ([A-Za-z0-9-_]). Maximum 64 characters. */ id: string; /** * Resource type identifier that determines the specific kind of resource. This field is used for polymorphic deserialization and resource-specific behavior. */ type: string; additionalProperties?: { [k: string]: any | null; } | undefined; }; /** * Represents the target cloud platform. */ export declare const EventControllerPlatformEnum: { readonly Aws: "aws"; readonly Gcp: "gcp"; readonly Azure: "azure"; readonly Kubernetes: "kubernetes"; readonly Machines: "machines"; readonly Local: "local"; readonly Test: "test"; }; /** * Represents the target cloud platform. */ export type EventControllerPlatformEnum = ClosedEnum; export type EventControllerPlatformUnion = EventControllerPlatformEnum | any; /** * Reference to a resource by its stable id and resource type. */ export type EventDependency = { id: string; /** * Resource type identifier that determines the specific kind of resource. This field is used for polymorphic deserialization and resource-specific behavior. */ type: string; }; /** * Canonical error container that provides a structured way to represent errors * * @remarks * with rich metadata including error codes, human-readable messages, context, * and chaining capabilities for error propagation. * * This struct is designed to be both machine-readable and user-friendly, * supporting serialization for API responses and detailed error reporting * in distributed systems. */ export type EventErrorNextState = { /** * A unique identifier for the type of error. * * @remarks * * This should be a short, machine-readable string that can be used * by clients to programmatically handle different error types. * Examples: "NOT_FOUND", "VALIDATION_ERROR", "TIMEOUT" */ code: string; /** * Additional diagnostic information about the error context. * * @remarks * * This optional field can contain structured data providing more details * about the error, such as validation errors, request parameters that * caused the issue, or other relevant context information. */ context?: any | null | undefined; /** * Optional human-facing remediation hint. */ hint?: string | null | undefined; /** * HTTP status code for this error. * * @remarks * * Used when converting the error to an HTTP response. If None, falls back to * the error type's default status code or 500. */ httpStatusCode?: number | null | undefined; /** * Indicates if this is an internal error that should not be exposed to users. * * @remarks * * When `true`, this error contains sensitive information or implementation * details that should not be shown to end-users. Such errors should be * logged for debugging but replaced with generic error messages in responses. */ internal: boolean; /** * Human-readable error message. * * @remarks * * This message should be clear and actionable for developers or end-users, * providing context about what went wrong and potentially how to fix it. */ message: string; /** * Indicates whether the operation that caused the error should be retried. * * @remarks * * When `true`, the error is transient and the operation might succeed * if attempted again. When `false`, retrying the same operation is * unlikely to succeed without changes. */ retryable: boolean; /** * The underlying error that caused this error, creating an error chain. * * @remarks * * This allows for proper error propagation and debugging by maintaining * the full context of how an error occurred through multiple layers * of an application. */ source?: any | null | undefined; }; export type EventNextStateErrorUnion = EventErrorNextState | any; /** * Describes the lifecycle of a resource within a stack, determining how it's managed and deployed. */ export declare const EventLifecycleEnum: { readonly Frozen: "frozen"; readonly Live: "live"; }; /** * Describes the lifecycle of a resource within a stack, determining how it's managed and deployed. */ export type EventLifecycleEnum = ClosedEnum; export type EventLifecycleUnion = EventLifecycleEnum | any; /** * Resource outputs that can hold output data for any resource type in the Alien system. All resource outputs share a common 'type' field with additional type-specific output properties. */ export type EventOutputs = { /** * Resource type identifier that determines the specific kind of resource. This field is used for polymorphic deserialization and resource-specific behavior. */ type: string; additionalProperties?: { [k: string]: any | null; } | undefined; }; export type EventOutputsUnion = EventOutputs | any; /** * Resource that can hold any resource type in the Alien system. All resources share common 'type' and 'id' fields with additional type-specific properties. */ export type EventPreviousConfig = { /** * The unique identifier for this specific resource instance. Must contain only alphanumeric characters, hyphens, and underscores ([A-Za-z0-9-_]). Maximum 64 characters. */ id: string; /** * Resource type identifier that determines the specific kind of resource. This field is used for polymorphic deserialization and resource-specific behavior. */ type: string; additionalProperties?: { [k: string]: any | null; } | undefined; }; export type EventPreviousConfigUnion = EventPreviousConfig | any; /** * Represents the high-level status of a resource during its lifecycle. */ export declare const EventStatus: { readonly Pending: "pending"; readonly Provisioning: "provisioning"; readonly ProvisionFailed: "provision-failed"; readonly Running: "running"; readonly Updating: "updating"; readonly UpdateFailed: "update-failed"; readonly Deleting: "deleting"; readonly DeleteFailed: "delete-failed"; readonly TeardownRequired: "teardown-required"; readonly Deleted: "deleted"; readonly RefreshFailed: "refresh-failed"; }; /** * Represents the high-level status of a resource during its lifecycle. */ export type EventStatus = ClosedEnum; /** * Represents the state of a single resource within the stack for a specific platform. */ export type EventResources = { /** * The platform-specific resource controller that manages this resource's lifecycle. * * @remarks * This is None when the resource status is Pending. * Stored as JSON to make the struct serializable and movable to alien-core. */ internal?: any | null | undefined; /** * Resource that can hold any resource type in the Alien system. All resources share common 'type' and 'id' fields with additional type-specific properties. */ config: EventConfig; controllerPlatform?: EventControllerPlatformEnum | any | null | undefined; /** * Complete list of dependencies for this resource, including infrastructure dependencies. * * @remarks * This preserves the full dependency information from the stack definition. */ dependencies?: Array | undefined; error?: EventErrorNextState | any | null | undefined; /** * Stores the controller state that failed, used for manual retry operations. * * @remarks * This allows resuming from the exact point where the failure occurred. * Stored as JSON to make the struct serializable and movable to alien-core. */ lastFailedState?: any | null | undefined; lifecycle?: EventLifecycleEnum | any | null | undefined; outputs?: EventOutputs | any | null | undefined; previousConfig?: EventPreviousConfig | any | null | undefined; /** * Binding parameters for remote access. * * @remarks * Only populated when the resource has `remote_access: true` in its ResourceEntry. * This is the JSON serialization of the binding configuration (e.g., StorageBinding, VaultBinding). * Populated by controllers during provisioning using get_binding_params(). */ remoteBindingParams?: any | null | undefined; /** * Tracks consecutive retry attempts for the current state transition. */ retryAttempt?: number | undefined; /** * Represents the high-level status of a resource during its lifecycle. */ status: EventStatus; /** * The high-level type of the resource (e.g., Worker::RESOURCE_TYPE, Storage::RESOURCE_TYPE). */ type: string; }; /** * Represents the collective state of all resources in a stack, including platform and pending actions. */ export type EventNextState = { /** * Represents the target cloud platform. */ platform: EventPlatform; /** * A prefix used for resource naming to ensure uniqueness across deployments. */ resourcePrefix: string; /** * The state of individual resources, keyed by resource ID. */ resources: { [k: string]: EventResources; }; }; export type EventDataStackStep = { /** * Represents the collective state of all resources in a stack, including platform and pending actions. */ nextState: EventNextState; /** * An suggested duration to wait before executing the next step. */ suggestedDelayMs?: number | null | undefined; type: "StackStep"; }; export type EventDataCompilingCode = { /** * Language being compiled (rust, typescript, etc.) */ language: string; /** * Current progress/status line from the build output */ progress?: string | null | undefined; type: "CompilingCode"; }; export type EventDataCreatingRelease = { /** * Project name */ project: string; type: "CreatingRelease"; }; export type EventDataPushingResource = { /** * Name of the resource being pushed */ resourceName: string; /** * Type of the resource: "worker", "container" */ resourceType: string; type: "PushingResource"; }; export type EventDataPushingStack = { /** * Human-readable destination for pushed images */ destination?: string | null | undefined; /** * Target platform */ platform: string; /** * Name of the stack being pushed */ stack: string; type: "PushingStack"; }; /** * Progress information for image push operations */ export type EventProgress = { /** * Bytes uploaded so far */ bytesUploaded: number; /** * Number of layers uploaded so far */ layersUploaded: number; /** * Current operation being performed */ operation: string; /** * Total bytes to upload */ totalBytes: number; /** * Total number of layers to upload */ totalLayers: number; }; export type EventProgressUnion = EventProgress | any; export type EventDataPushingImage = { /** * Name of the image being pushed */ image: string; progress?: EventProgress | any | null | undefined; type: "PushingImage"; }; export type EventDataBuildingImage = { /** * Name of the image being built */ image: string; type: "BuildingImage"; }; export type EventDataBuildingResource = { /** * All resource names sharing this build (for deduped container groups) */ relatedResources?: Array | undefined; /** * Name of the resource being built */ resourceName: string; /** * Type of the resource: "worker", "container" */ resourceType: string; type: "BuildingResource"; }; export type EventDataDownloadingAlienRuntime = { /** * Target triple for the runtime */ targetTriple: string; type: "DownloadingAlienRuntime"; /** * URL being downloaded from */ url: string; }; export type EventDataRunningPreflights = { /** * Platform being targeted */ platform: string; /** * Name of the stack being checked */ stack: string; type: "RunningPreflights"; }; export type EventDataBuildingStack = { /** * Name of the stack being built */ stack: string; type: "BuildingStack"; }; export type EventDataFinished = { type: "Finished"; }; export type EventDataLoadingConfiguration = { type: "LoadingConfiguration"; }; export type EventDataUnion = EventDataLoadingConfiguration | EventDataFinished | EventDataBuildingStack | EventDataRunningPreflights | EventDataDownloadingAlienRuntime | EventDataBuildingResource | EventDataBuildingImage | EventDataPushingImage | EventDataPushingStack | EventDataPushingResource | EventDataCreatingRelease | EventDataCompilingCode | EventDataStackStep | EventDataGeneratingCloudFormationTemplate | EventDataGeneratingTemplate | EventDataProvisioningAgent | EventDataUpdatingAgent | EventDataDeletingAgent | EventDataDebuggingAgent | EventDataPreparingEnvironment | EventDataDeployingStack | EventDataRunningTestWorker | EventDataCleaningUpStack | EventDataCleaningUpEnvironment | EventDataSettingUpPlatformContext | EventDataEnsuringDockerRepository | EventDataDeployingCloudFormationStack | EventDataAssumingRole | EventDataImportingStackStateFromCloudFormation | EventDataDeletingCloudFormationStack | EventDataEmptyingBuckets | EventDataDeploymentCreated | EventDataDeploymentReleased | EventDataDeploymentFailed | EventDataDeploymentDegraded | EventDataDeploymentRecovered | EventDataDeploymentDeleted | EventDataReleaseChannelUpdated | EventDataDeploymentReleaseChannelChanged | EventDataDeploymentRetryRequested | EventDataDeploymentRedeployRequested | EventDataDeploymentReleasePinned | EventDataDeploymentReleaseUnpinned | EventDataDeploymentEnvironmentUpdated | EventDataDeploymentDeletionRequested | DeploymentCredentialRotationEvent; export declare const EventStateSuccess: { readonly Success: "success"; }; export type EventStateSuccess = ClosedEnum; export declare const EventStateStarted: { readonly Started: "started"; }; export type EventStateStarted = ClosedEnum; export declare const EventStateNone: { readonly None: "none"; }; export type EventStateNone = ClosedEnum; /** * Canonical error container that provides a structured way to represent errors * * @remarks * with rich metadata including error codes, human-readable messages, context, * and chaining capabilities for error propagation. * * This struct is designed to be both machine-readable and user-friendly, * supporting serialization for API responses and detailed error reporting * in distributed systems. */ export type EventStateError = { /** * A unique identifier for the type of error. * * @remarks * * This should be a short, machine-readable string that can be used * by clients to programmatically handle different error types. * Examples: "NOT_FOUND", "VALIDATION_ERROR", "TIMEOUT" */ code: string; /** * Additional diagnostic information about the error context. * * @remarks * * This optional field can contain structured data providing more details * about the error, such as validation errors, request parameters that * caused the issue, or other relevant context information. */ context?: any | null | undefined; /** * Optional human-facing remediation hint. */ hint?: string | null | undefined; /** * HTTP status code for this error. * * @remarks * * Used when converting the error to an HTTP response. If None, falls back to * the error type's default status code or 500. */ httpStatusCode?: number | null | undefined; /** * Indicates if this is an internal error that should not be exposed to users. * * @remarks * * When `true`, this error contains sensitive information or implementation * details that should not be shown to end-users. Such errors should be * logged for debugging but replaced with generic error messages in responses. */ internal: boolean; /** * Human-readable error message. * * @remarks * * This message should be clear and actionable for developers or end-users, * providing context about what went wrong and potentially how to fix it. */ message: string; /** * Indicates whether the operation that caused the error should be retried. * * @remarks * * When `true`, the error is transient and the operation might succeed * if attempted again. When `false`, retrying the same operation is * unlikely to succeed without changes. */ retryable: boolean; /** * The underlying error that caused this error, creating an error chain. * * @remarks * * This allows for proper error propagation and debugging by maintaining * the full context of how an error occurred through multiple layers * of an application. */ source?: any | null | undefined; }; export type EventStateErrorUnion = EventStateError | any; /** * Event failed with an error */ export type EventFailed = { error?: EventStateError | any | null | undefined; }; export type EventState = { /** * Event failed with an error */ failed: EventFailed; }; /** * Represents the state of an event */ export type EventStateUnion = EventState | EventStateNone | EventStateStarted | EventStateSuccess; export type Event = { /** * Unique identifier for the event. */ id: string; /** * Unique identifier for the deployment. */ deploymentId?: string | null | undefined; /** * Unique identifier for the release. */ releaseId?: string | null | undefined; /** * Unique identifier for the debug session. */ debugSessionId?: string | null | undefined; data: EventDataLoadingConfiguration | EventDataFinished | EventDataBuildingStack | EventDataRunningPreflights | EventDataDownloadingAlienRuntime | EventDataBuildingResource | EventDataBuildingImage | EventDataPushingImage | EventDataPushingStack | EventDataPushingResource | EventDataCreatingRelease | EventDataCompilingCode | EventDataStackStep | EventDataGeneratingCloudFormationTemplate | EventDataGeneratingTemplate | EventDataProvisioningAgent | EventDataUpdatingAgent | EventDataDeletingAgent | EventDataDebuggingAgent | EventDataPreparingEnvironment | EventDataDeployingStack | EventDataRunningTestWorker | EventDataCleaningUpStack | EventDataCleaningUpEnvironment | EventDataSettingUpPlatformContext | EventDataEnsuringDockerRepository | EventDataDeployingCloudFormationStack | EventDataAssumingRole | EventDataImportingStackStateFromCloudFormation | EventDataDeletingCloudFormationStack | EventDataEmptyingBuckets | EventDataDeploymentCreated | EventDataDeploymentReleased | EventDataDeploymentFailed | EventDataDeploymentDegraded | EventDataDeploymentRecovered | EventDataDeploymentDeleted | EventDataReleaseChannelUpdated | EventDataDeploymentReleaseChannelChanged | EventDataDeploymentRetryRequested | EventDataDeploymentRedeployRequested | EventDataDeploymentReleasePinned | EventDataDeploymentReleaseUnpinned | EventDataDeploymentEnvironmentUpdated | EventDataDeploymentDeletionRequested | DeploymentCredentialRotationEvent; /** * Represents the state of an event */ state: EventState | EventStateNone | EventStateStarted | EventStateSuccess; /** * Unique identifier for the project. */ projectId: string; createdAt: Date; /** * Unique identifier for the workspace. */ workspaceId: string; }; /** @internal */ export declare const EventDataDeploymentDeletionRequested$inboundSchema: z.ZodType; export declare function eventDataDeploymentDeletionRequestedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventKind4$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventActor4$inboundSchema: z.ZodType; export declare function eventActor4FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventActorUnion4$inboundSchema: z.ZodType; export declare function eventActorUnion4FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentEnvironmentUpdated$inboundSchema: z.ZodType; export declare function eventDataDeploymentEnvironmentUpdatedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentReleaseUnpinned$inboundSchema: z.ZodType; export declare function eventDataDeploymentReleaseUnpinnedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentReleasePinned$inboundSchema: z.ZodType; export declare function eventDataDeploymentReleasePinnedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentRedeployRequested$inboundSchema: z.ZodType; export declare function eventDataDeploymentRedeployRequestedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventKind3$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventActor3$inboundSchema: z.ZodType; export declare function eventActor3FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventActorUnion3$inboundSchema: z.ZodType; export declare function eventActorUnion3FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventPreviousError$inboundSchema: z.ZodType; export declare function eventPreviousErrorFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventPreviousErrorUnion$inboundSchema: z.ZodType; export declare function eventPreviousErrorUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentRetryRequested$inboundSchema: z.ZodType; export declare function eventDataDeploymentRetryRequestedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventKind2$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventActor2$inboundSchema: z.ZodType; export declare function eventActor2FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventActorUnion2$inboundSchema: z.ZodType; export declare function eventActorUnion2FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentReleaseChannelChanged$inboundSchema: z.ZodType; export declare function eventDataDeploymentReleaseChannelChangedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventKind1$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventActor1$inboundSchema: z.ZodType; export declare function eventActor1FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventActorUnion1$inboundSchema: z.ZodType; export declare function eventActorUnion1FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataReleaseChannelUpdated$inboundSchema: z.ZodType; export declare function eventDataReleaseChannelUpdatedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentDeleted$inboundSchema: z.ZodType; export declare function eventDataDeploymentDeletedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentRecovered$inboundSchema: z.ZodType; export declare function eventDataDeploymentRecoveredFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataError2$inboundSchema: z.ZodType; export declare function eventDataError2FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentDegraded$inboundSchema: z.ZodType; export declare function eventDataDeploymentDegradedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataError1$inboundSchema: z.ZodType; export declare function eventDataError1FromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventPhase$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventDataDeploymentFailed$inboundSchema: z.ZodType; export declare function eventDataDeploymentFailedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentReleased$inboundSchema: z.ZodType; export declare function eventDataDeploymentReleasedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeploymentCreated$inboundSchema: z.ZodType; export declare function eventDataDeploymentCreatedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataEmptyingBuckets$inboundSchema: z.ZodType; export declare function eventDataEmptyingBucketsFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeletingCloudFormationStack$inboundSchema: z.ZodType; export declare function eventDataDeletingCloudFormationStackFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataImportingStackStateFromCloudFormation$inboundSchema: z.ZodType; export declare function eventDataImportingStackStateFromCloudFormationFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataAssumingRole$inboundSchema: z.ZodType; export declare function eventDataAssumingRoleFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeployingCloudFormationStack$inboundSchema: z.ZodType; export declare function eventDataDeployingCloudFormationStackFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataEnsuringDockerRepository$inboundSchema: z.ZodType; export declare function eventDataEnsuringDockerRepositoryFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataSettingUpPlatformContext$inboundSchema: z.ZodType; export declare function eventDataSettingUpPlatformContextFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataCleaningUpEnvironment$inboundSchema: z.ZodType; export declare function eventDataCleaningUpEnvironmentFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataCleaningUpStack$inboundSchema: z.ZodType; export declare function eventDataCleaningUpStackFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataRunningTestWorker$inboundSchema: z.ZodType; export declare function eventDataRunningTestWorkerFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeployingStack$inboundSchema: z.ZodType; export declare function eventDataDeployingStackFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataPreparingEnvironment$inboundSchema: z.ZodType; export declare function eventDataPreparingEnvironmentFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDebuggingAgent$inboundSchema: z.ZodType; export declare function eventDataDebuggingAgentFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDeletingAgent$inboundSchema: z.ZodType; export declare function eventDataDeletingAgentFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataUpdatingAgent$inboundSchema: z.ZodType; export declare function eventDataUpdatingAgentFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataProvisioningAgent$inboundSchema: z.ZodType; export declare function eventDataProvisioningAgentFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataGeneratingTemplate$inboundSchema: z.ZodType; export declare function eventDataGeneratingTemplateFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataGeneratingCloudFormationTemplate$inboundSchema: z.ZodType; export declare function eventDataGeneratingCloudFormationTemplateFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventPlatform$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventConfig$inboundSchema: z.ZodType; export declare function eventConfigFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventControllerPlatformEnum$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventControllerPlatformUnion$inboundSchema: z.ZodType; export declare function eventControllerPlatformUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDependency$inboundSchema: z.ZodType; export declare function eventDependencyFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventErrorNextState$inboundSchema: z.ZodType; export declare function eventErrorNextStateFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventNextStateErrorUnion$inboundSchema: z.ZodType; export declare function eventNextStateErrorUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventLifecycleEnum$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventLifecycleUnion$inboundSchema: z.ZodType; export declare function eventLifecycleUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventOutputs$inboundSchema: z.ZodType; export declare function eventOutputsFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventOutputsUnion$inboundSchema: z.ZodType; export declare function eventOutputsUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventPreviousConfig$inboundSchema: z.ZodType; export declare function eventPreviousConfigFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventPreviousConfigUnion$inboundSchema: z.ZodType; export declare function eventPreviousConfigUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventStatus$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventResources$inboundSchema: z.ZodType; export declare function eventResourcesFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventNextState$inboundSchema: z.ZodType; export declare function eventNextStateFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataStackStep$inboundSchema: z.ZodType; export declare function eventDataStackStepFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataCompilingCode$inboundSchema: z.ZodType; export declare function eventDataCompilingCodeFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataCreatingRelease$inboundSchema: z.ZodType; export declare function eventDataCreatingReleaseFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataPushingResource$inboundSchema: z.ZodType; export declare function eventDataPushingResourceFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataPushingStack$inboundSchema: z.ZodType; export declare function eventDataPushingStackFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventProgress$inboundSchema: z.ZodType; export declare function eventProgressFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventProgressUnion$inboundSchema: z.ZodType; export declare function eventProgressUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataPushingImage$inboundSchema: z.ZodType; export declare function eventDataPushingImageFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataBuildingImage$inboundSchema: z.ZodType; export declare function eventDataBuildingImageFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataBuildingResource$inboundSchema: z.ZodType; export declare function eventDataBuildingResourceFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataDownloadingAlienRuntime$inboundSchema: z.ZodType; export declare function eventDataDownloadingAlienRuntimeFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataRunningPreflights$inboundSchema: z.ZodType; export declare function eventDataRunningPreflightsFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataBuildingStack$inboundSchema: z.ZodType; export declare function eventDataBuildingStackFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataFinished$inboundSchema: z.ZodType; export declare function eventDataFinishedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataLoadingConfiguration$inboundSchema: z.ZodType; export declare function eventDataLoadingConfigurationFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventDataUnion$inboundSchema: z.ZodType; export declare function eventDataUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventStateSuccess$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventStateStarted$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventStateNone$inboundSchema: z.ZodEnum; /** @internal */ export declare const EventStateError$inboundSchema: z.ZodType; export declare function eventStateErrorFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventStateErrorUnion$inboundSchema: z.ZodType; export declare function eventStateErrorUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventFailed$inboundSchema: z.ZodType; export declare function eventFailedFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventState$inboundSchema: z.ZodType; export declare function eventStateFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const EventStateUnion$inboundSchema: z.ZodType; export declare function eventStateUnionFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const Event$inboundSchema: z.ZodType; export declare function eventFromJSON(jsonString: string): SafeParseResult; //# sourceMappingURL=event.d.ts.map