Skip to content

Update env

Rename an environment or make it the new default. Pass at least one of name or is_default; both are optional individually.

Example

You

make staging the default

Log10x

Updated env staging (env_id 8c2b…). It's now the default. The previous default prod has been un-defaulted.

Prerequisites

The env_id of the target env — get it from Login status or a prior Create env response.

Schema and samples

Input example

Real call against the demo env (captured by scripts/capture-tool-envelopes.mjs).

{
  "env_id": "9e6f0a2b-...-c2",
  "name": "staging-east"
}
Input schema

Agent-facing JSON Schema (the canonical shape the MCP server publishes via tools/list):

{
  "type": "object",
  "properties": {
    "env_id": {
      "type": "string",
      "minLength": 1,
      "description": "The `env_id` UUID of the environment to update. Get it from `log10x_login_status` (which lists all envs with their env_ids) or from a prior `log10x_create_env` response."
    },
    "name": {
      "type": "string",
      "minLength": 1,
      "description": "New display name for the env. Optional — omit to keep the current name."
    },
    "is_default": {
      "type": "boolean",
      "description": "When true, this env becomes the user's default — every tool call without an explicit `environment` arg routes here. The previous default is automatically un-defaulted by the backend. Optional — omit to leave the default flag unchanged."
    }
  },
  "required": [
    "env_id"
  ],
  "additionalProperties": false
}

Source: src/tools/update-env.ts.

Output example

Real envelope from the demo env. view: "summary" returns the full StructuredOutput with typed data. Long arrays + base64 PNG bodies trimmed for readability; the real call returns them in full.

Headline (the 1-line agent-facing answer):

Updated env 9e6f0a2b-...-c2: renamed "staging" → "staging-east".

{
  "schema_version": "1.0",
  "schema_epoch": "2026-05-25",
  "tool": "log10x_update_env",
  "view": "summary",
  "summary": {
    "headline": "Updated env 9e6f0a2b-...-c2: renamed \"staging\" → \"staging-east\"."
  },
  "data": {
    "ok": true,
    "env_id": "9e6f0a2b-...-c2",
    "before": {
      "name": "staging",
      "is_default": false
    },
    "after": {
      "name": "staging-east",
      "is_default": false
    },
    "changes": [
      "renamed \"staging\" → \"staging-east\""
    ]
  },
  "generated_at": "2026-05-26T00:00:00.000Z"
}
Output schema

The data block inside the StructuredOutput envelope:

interface ToolData {
  ok: boolean;
  env_id: string;
  before: { name: string; is_default: boolean };
  after: { name: string; is_default: boolean };
  changes: string[];
}

Envelope-level fields the agent should also read: summary.headline (1-line answer), actions[] (next-call chain hints as {tool, args, reason}), truncated: boolean, images[] (PNG attachments where applicable), schema_epoch (engine-ID stability boundary).