import { DeploymentType } from './deployment_type'; /** * These are some utility types to make the BackendIdentifier a bit more self-documenting */ export type AppId = string; export type ProjectName = string; export type BranchName = string; export type SandboxName = string; /** * This tuple defines the constituent parts that are used to construct backend stack names * The stack name becomes what identifies a deployed backend. * * To translate to/from a stack name, use the utility methods in @aws-amplify/platform-core */ export type BackendIdentifier = { /** * The Amplify AppId for the backend */ namespace: Readonly; /** * The Amplify branch name for the backend */ name: Readonly; /** * Const that determines this BackendIdentifier is for a branch backend */ type: Readonly>; /** * Optional hash for consistent stack naming in cases where namespace or name contain characters that can't be serialized into a stack name */ hash?: Readonly; } | { /** * The project name for the sandbox. * * While this type does not enforce any specific behavior, at the time of writing, this value defaults to package.json#name when running sandbox commands * Consult upstream code for exact usage. */ namespace: Readonly; /** * The name of this sandbox. * * While this type does not enforce any specific behavior, at the time of writing, this value defaults to the current local username and can be overridden with the --name argument to sandbox. * Consult upstream code for exact usage. */ name: Readonly; /** * Const that determines this BackendIdentifier is for a sandbox backend */ type: Readonly>; /** * Optional hash for consistent stack naming in cases where namespace or name contain characters that can't be serialized into a stack name */ hash?: Readonly; } | { /** * The deployment identifier for the standalone deployment. */ namespace: Readonly; /** * The deployment name for the standalone deployment. */ name: Readonly; /** * Const that determines this BackendIdentifier is for a standalone backend (without Amplify Hosting) */ type: Readonly>; /** * Optional hash for consistent stack naming in cases where namespace or name contain characters that can't be serialized into a stack name */ hash?: Readonly; }; //# sourceMappingURL=backend_identifier.d.ts.map