Welcome to LaunchVerseQuickstartDashboard OverviewImporting Projects
Deployment GuideEnvironment VariablesLaunchverse ForgePreview EnvironmentsEnvironment Variable VersioningRollback & PromoteHow Builds Work (Forge)
Helix CopilotEphemeral SandboxesAI Log Explainer
The LaunchVerse EdgeCustom Domains & TLSDomain PurchasingTwo-Factor Authentication (TOTP)IP Allowlists
Managed DatabasesScale to ZeroLog DrainsDatabase Backups & Point-in-Time RecoveryObservabilityWeb Analytics & Traffic Tracking
Project GroupsRole-Based Access Control (RBAC)
Student ProgramDeveloper Streaks
API Reference
Changelog
SDKsHelix Gateway SDK
Web Shell
API Reference (Redoc)

Environment Variables

Environment variables are encrypted at rest and injected into your containers at runtime or build time. Launchverse supports multiple environments per project and full version history for every variable.

Add or update a variable in the UI

  1. Open Project Settings → Environment Variables.
  2. Choose the target environment (Production, Preview, or Development).
  3. Enter the key and value.
  4. Mark Build-time only if the value is needed during npm run build but not at runtime.
  5. Save. The change is recorded in the version history and, for production, mirrored to the engine.

Scopes

  • Production — injected into the main production deployment.
  • Preview — injected into PR preview deployments.
  • Development — pulled locally or via the API for development.
  • All — the legacy default; applies to production and preview unless scoped.

API

List variables

GET /api/projects/{projectId}/env

Response:

{
  "environment": { "id": "uuid", "name": "Production", "is_default": true },
  "variables": [
    { "id": "uuid", "key": "DATABASE_URL", "value": "••••••••", "is_build_time": false, "scope": "Production" }
  ]
}

Create or update a variable

POST /api/projects/{projectId}/env
{
  "key": "API_KEY",
  "value": "secret",
  "is_build_time": false,
  "scope": "Production",
  "environment_id": "uuid"
}

If environment_id is omitted, the project's default environment is used.

Response:

{
  "success": true,
  "variable": {
    "id": "uuid",
    "key": "API_KEY",
    "value": "••••••••",
    "is_build_time": false,
    "scope": "Production"
  }
}

Bulk import

Paste a .env file:

POST /api/projects/{projectId}/env/bulk
{
  "scope": "Production",
  "variables": [
    { "key": "A", "value": "1", "is_build_time": false },
    { "key": "B", "value": "2", "is_build_time": true }
  ]
}

Delete a variable

DELETE /api/projects/{projectId}/env/{varId}

Version history

Every write is recorded. See Environment Variable Versioning for how to list and restore previous values.

[!CAUTION] Saving a variable triggers a debounced redeploy on the default environment. Wait for the deployment to finish before testing.

Edit this page on GitHub↗