Skip to main content
Glama

Patch instance configuration

patch_instance_config
Destructive

Update part of an instance's configuration (like clerk config patch). Values you send are deep-merged into the current configuration and apply to the live instance immediately; top-level keys you leave out are unchanged. Returns the before and after values of the changed keys and the new config_version. Run with dry_run first to validate and preview the change. Setting connection_oauth_apple.bundle_id for native Sign in with Apple needs a matching iOS app, so register it first with create_ios_application.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "application_id": "<application_id>",
      "instance": "<instance>",
      "config": "<config>"
    },
    "name": "patch_instance_config"
  }
}

Input Schema

NameRequiredDescriptionDefault
configYesConfiguration keyed by top-level config key, in the shape get_instance_config returns. get_instance_config_schema lists the valid keys and fields.
dry_runNoPreview the change without applying it.
instanceYesInstance to target: "development", "production", or a full instance ID (ins_…).
destructiveNoAllow changes that delete resources instead of resetting them: session templates, custom OAuth providers, and minimum app versions (a null entry or platform in native_app_minimum_versions).
application_idYesClerk application ID (app_…).

Output Schema

NameRequiredDescriptionDefault
afterNo
beforeNo
dry_runNo
config_versionNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedInput schema / properties / config / description
      Previous value: -"Config JSON, keyed by top-level section."New value: +"Configuration keyed by top-level config key, in the shape get_instance_config returns. get_instance_config_schema lists the valid keys and fields."
    • changedInput schema / properties / destructive / description
      Previous value: -"Allow changes that delete resources (session templates, custom OAuth providers) instead of resetting them."New value: +"Allow changes that delete resources instead of resetting them: session templates, custom OAuth providers, and minimum app versions (a null entry or platform in native_app_minimum_versions)."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "https://json-schema.org/draft/2020-12/schema",
      +  "additionalProperties": {},
      +  "properties": {
      +    "after": {
      +      "anyOf": [
      +        {
      +          "additionalProperties": {},
      +          "propertyNames": {
      +            "type": "string"
      +          },
      +          "type": "object"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "before": {
      +      "anyOf": [
      +        {
      +          "additionalProperties": {},
      +          "propertyNames": {
      +            "type": "string"
      +          },
      +          "type": "object"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "config_version": {
      +      "type": "string"
      +    },
      +    "dry_run": {
      +      "type": "boolean"
      +    }
      +  },
      +  "type": "object"
      +}
  2. Added

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare destructiveHint=true and idempotentHint=false; the description adds the material context that changes "apply to the live instance immediately" and that omitted top-level keys are preserved, plus it discloses the return payload (before/after values and new config_version). It does not explain the `destructive` flag's scope in prose, which is the remaining behavioral gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences, front-loaded with the merge semantics and live-apply warning, then the return shape, then the safety workflow and precondition. Every clause carries distinct information; there is no restatement of the name or redundant framing.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a live-mutating config tool with 5 params and nested objects, the definition covers merge behavior, immediate effect, return values, and a dry-run workflow, and an output schema exists so return details needn't be expanded. The one omission is any prose about the destructive-flag escape hatch for deletion, which matters for an operation annotated destructiveHint=true.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema baseline is already 3; the description earns above that by explaining the merge semantics of `config` (deep-merge, absent top-level keys unchanged) and by framing dry_run as a validation preview rather than just a boolean. It says nothing extra about the `destructive` parameter, so it isn't fully additive.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb+resource ("Update part of an instance's configuration") and pins down the semantics with "deep-merged" plus the analogy to `clerk config patch`, which implicitly distinguishes it from a full replace. It stops short of explicitly naming put_instance_config as the whole-object alternative, so the agent must infer that contrast.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives actionable process guidance ("Run with dry_run first to validate and preview the change") and a concrete prerequisite for a common sub-case (register the iOS app with create_ios_application before setting connection_oauth_apple.bundle_id). It does not state when to choose this over put_instance_config, which is the main missing routing signal.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources