/** * Region utilities shared across CLI, webapp, generator, and deploy-core. * * Single source of truth for AWS region metadata (ADR * decisions/2026-06-11-region-semantics-and-provisioning.md D8). The * generator and CLI re-export from here; the webapp imports directly. */ export interface RegionInfo { code: string; name: string; city: string; country: string; /** Requires per-account enablement (AWS regions launched after 2019-03-20). */ optIn: boolean; } export declare const DEFAULT_REGION = "us-east-2"; /** Cap on Organisation.secondaryRegions — API contract shared by every write surface. */ export declare const MAX_SECONDARY_REGIONS = 10; export declare const AWS_REGIONS_METADATA: readonly [{ readonly code: "us-east-2"; readonly name: "US East"; readonly city: "Ohio"; readonly country: "USA"; readonly optIn: false; }, { readonly code: "us-west-2"; readonly name: "US West"; readonly city: "Oregon"; readonly country: "USA"; readonly optIn: false; }, { readonly code: "us-east-1"; readonly name: "US East"; readonly city: "N. Virginia"; readonly country: "USA"; readonly optIn: false; }, { readonly code: "eu-west-1"; readonly name: "EU West"; readonly city: "Ireland"; readonly country: "Ireland"; readonly optIn: false; }, { readonly code: "eu-central-1"; readonly name: "EU Central"; readonly city: "Frankfurt"; readonly country: "Germany"; readonly optIn: false; }, { readonly code: "ap-southeast-1"; readonly name: "Asia Pacific"; readonly city: "Singapore"; readonly country: "Singapore"; readonly optIn: false; }, { readonly code: "ap-northeast-1"; readonly name: "Asia Pacific"; readonly city: "Tokyo"; readonly country: "Japan"; readonly optIn: false; }, { readonly code: "ap-southeast-2"; readonly name: "Asia Pacific"; readonly city: "Sydney"; readonly country: "Australia"; readonly optIn: false; }, { readonly code: "us-west-1"; readonly name: "US West"; readonly city: "N. California"; readonly country: "USA"; readonly optIn: false; }, { readonly code: "ca-central-1"; readonly name: "Canada"; readonly city: "Central"; readonly country: "Canada"; readonly optIn: false; }, { readonly code: "af-south-1"; readonly name: "Africa"; readonly city: "Cape Town"; readonly country: "South Africa"; readonly optIn: true; }, { readonly code: "ap-east-1"; readonly name: "Asia Pacific"; readonly city: "Hong Kong"; readonly country: "Hong Kong"; readonly optIn: true; }, { readonly code: "ap-northeast-2"; readonly name: "Asia Pacific"; readonly city: "Seoul"; readonly country: "South Korea"; readonly optIn: false; }, { readonly code: "ap-northeast-3"; readonly name: "Asia Pacific"; readonly city: "Osaka"; readonly country: "Japan"; readonly optIn: false; }, { readonly code: "ap-south-1"; readonly name: "Asia Pacific"; readonly city: "Mumbai"; readonly country: "India"; readonly optIn: false; }, { readonly code: "ap-south-2"; readonly name: "Asia Pacific"; readonly city: "Hyderabad"; readonly country: "India"; readonly optIn: true; }, { readonly code: "ap-southeast-3"; readonly name: "Asia Pacific"; readonly city: "Jakarta"; readonly country: "Indonesia"; readonly optIn: true; }, { readonly code: "ap-southeast-4"; readonly name: "Asia Pacific"; readonly city: "Melbourne"; readonly country: "Australia"; readonly optIn: true; }, { readonly code: "eu-central-2"; readonly name: "EU Central"; readonly city: "Zurich"; readonly country: "Switzerland"; readonly optIn: true; }, { readonly code: "eu-north-1"; readonly name: "EU North"; readonly city: "Stockholm"; readonly country: "Sweden"; readonly optIn: false; }, { readonly code: "eu-south-1"; readonly name: "EU South"; readonly city: "Milan"; readonly country: "Italy"; readonly optIn: true; }, { readonly code: "eu-south-2"; readonly name: "EU South"; readonly city: "Spain"; readonly country: "Spain"; readonly optIn: true; }, { readonly code: "eu-west-2"; readonly name: "EU West"; readonly city: "London"; readonly country: "UK"; readonly optIn: false; }, { readonly code: "eu-west-3"; readonly name: "EU West"; readonly city: "Paris"; readonly country: "France"; readonly optIn: false; }, { readonly code: "me-central-1"; readonly name: "Middle East"; readonly city: "UAE"; readonly country: "UAE"; readonly optIn: true; }, { readonly code: "me-south-1"; readonly name: "Middle East"; readonly city: "Bahrain"; readonly country: "Bahrain"; readonly optIn: true; }, { readonly code: "sa-east-1"; readonly name: "South America"; readonly city: "São Paulo"; readonly country: "Brazil"; readonly optIn: false; }, { readonly code: "ap-southeast-5"; readonly name: "Asia Pacific"; readonly city: "Kuala Lumpur"; readonly country: "Malaysia"; readonly optIn: true; }, { readonly code: "ap-southeast-6"; readonly name: "Asia Pacific"; readonly city: "Auckland"; readonly country: "New Zealand"; readonly optIn: true; }, { readonly code: "ap-southeast-7"; readonly name: "Asia Pacific"; readonly city: "Bangkok"; readonly country: "Thailand"; readonly optIn: true; }, { readonly code: "ap-east-2"; readonly name: "Asia Pacific"; readonly city: "Taipei"; readonly country: "Taiwan"; readonly optIn: true; }, { readonly code: "ca-west-1"; readonly name: "Canada West"; readonly city: "Calgary"; readonly country: "Canada"; readonly optIn: true; }, { readonly code: "il-central-1"; readonly name: "Israel"; readonly city: "Tel Aviv"; readonly country: "Israel"; readonly optIn: true; }, { readonly code: "mx-central-1"; readonly name: "Mexico"; readonly city: "Central"; readonly country: "Mexico"; readonly optIn: true; }]; /** Union of supported region codes, derived from the metadata (SSoT). */ export type RegionCode = (typeof AWS_REGIONS_METADATA)[number]["code"]; export declare const regions: readonly string[]; /** * Codes of regions that must be enabled per-account before use, derived from * the metadata (SSoT) — never re-list these. */ export declare const OPT_IN_REGION_CODES: ReadonlySet; /** * Warning copy shown when a user selects an opt-in region at a region picker. * Single source for the CLI and webapp so the wording cannot drift — the webapp * provision-region preview prefixes a "⚠ " marker, the CLI renders it in its * warning colour. */ export declare function optInRegionWarning(regionCode: string): string; export declare function getRegionInfo(code: string): RegionInfo | undefined; /** * Abbreviate an AWS region name to a compact form. * e.g. "us-east-1" → "use1", "eu-west-1" → "euw1", "ap-south-1" → "apso1" */ export declare function abbreviateRegion(region: string): string; /** * Region short codes Fjall used to emit and no longer does, mapped to the * region(s) each one named. Derived by diffing the legacy derivation against * the current one over the live metadata, so it extends itself. * * A code lands here for one of two reasons, and the guards treat them the same: * it was ambiguous (`aps1` named both ap-southeast-1 and ap-south-1), or it was * unambiguous but has moved (`apn1` named ap-northeast-1, now `apne1`). Either * way a name carrying it is refused rather than resolved — an operator who * typed it meant the region it used to mean, and quietly delivering a different * one is precisely the failure the rename exists to end. */ export declare const RETIRED_REGION_ABBREVIATIONS: ReadonlyMap; /** * Suggest the geographically nearest *deployable* AWS region for an IANA * timezone (e.g. from Intl.DateTimeFormat().resolvedOptions().timeZone). Never * returns an opt-in region: a geographically-closest opt-in match is swapped * for its nearest default-enabled neighbour so an accepted suggestion can be * deployed without per-account enablement. Returns undefined when no sensible * suggestion exists (UTC, Etc/*, unrecognised input) — callers fall back to * DEFAULT_REGION without "closest to you" justification copy. */ export declare function suggestRegionForTimezone(timeZone: string): RegionCode | undefined;