Variable

variable.applied

Creates, updates and deletes were written to an environment in one request.

When it fires

After ApplyVariablesService succeeds. The apply path is used by the dashboard editor, by v1 API POST /projects/{slug}/environments/{environmentSlug}/variables/apply, and by envless push from @goenvless/cli.

One apply is one event. The individual creates, updates and deletes inside it do not emit variable.created, variable.updated or variable.deleted. If envless push writes to several environments, each environment gets its own variable.applied.

Payload

ts
{
    type: 'variable.applied',
    data: {
        environmentId: string
        added: number     // variables created by this apply
        updated: number   // variables whose value changed
        removed: number   // variables deleted by this apply
    }
}

Example

json
{
    "type": "variable.applied",
    "data": {
        "environmentId": "0192a1b2-c3d4-7000-8000-000000000020",
        "added": 2,
        "updated": 5,
        "removed": 1
    }
}

The payload is counts only. No variable names, no encrypted values, no plaintext. If you need to know which variables moved, read the environment or its version history back through the API.