Skip to main content
Glama
configcat

ConfigCat MCP Server

Official

replace-setting-value-v2

Replace the default value and targeting rules of a feature flag or setting in a specific environment, with full control over modifications and audit logging.

Instructions

This endpoint replaces the value and the Targeting Rules of a Feature Flag or Setting in a specified Environment identified by the SDK key passed in the X-CONFIGCAT-SDKKEY header.

Only the defaultValue, targetingRules, and percentageEvaluationAttribute fields are modifiable by this endpoint.

Important: As this endpoint is doing a complete replace, it's important to set every other field that you don't want to change to its original state. Not listing one means it will reset.

For example: We have the following resource of a Feature Flag.

{
  "defaultValue": {
    "boolValue": false
  },
  "targetingRules": [
    {
      "conditions": [
        {
          "userCondition": {
            "comparisonAttribute": "Email",
            "comparator": "sensitiveTextEquals",
            "comparisonValue": {
              "stringValue": "test@example.com"
            }
          }
        }
      ],
      "percentageOptions": [],
      "value": {
        "boolValue": true
      }
    }
  ]
}

If we send a replace request body as below:

{
  "defaultValue": {
    "boolValue": true
  }
}

Then besides that the default served value is set to true, all the Targeting Rules are deleted. So we get a response like this:

{
  "defaultValue": {
    "boolValue": true
  },
  "targetingRules": []
}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
environmentIdYesThe identifier of the Environment.
settingIdYesThe identifier of the Setting.
reasonNoThe reason note for the Audit Log if the Product's "Config changes require a reason" preference is turned on.
requestBodyYes
Behavior4/5

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

With no annotations, the description carries the full burden. It transparently explains that the endpoint does a complete replace, lists which fields are modifiable, and provides an example showing the reset effect. It also mentions the required SDK key header.

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

Conciseness4/5

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

The description is well-structured with a clear explanation, important note, and an illustrative example. It is somewhat lengthy but every part adds value.

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?

Given the complexity (nested objects) and no output schema, the description covers the essential behavioral aspects, warnings, and example. It could mention the return type but is still sufficiently complete for an agent to use correctly.

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

Parameters3/5

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

The input schema already describes parameters thoroughly (75% coverage). The description adds context about the replace behavior and includes an example, but does not add new semantics beyond what the schema provides.

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?

The description clearly states that the tool replaces the value and targeting rules of a Feature Flag or Setting. It specifies the modifiable fields and uses a complete replace approach. However, it does not explicitly differentiate itself from sibling tools like 'replace-setting-value' or 'update-setting-value-v2'.

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

Usage Guidelines3/5

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

The description warns about the complete replace behavior and the need to include all fields to avoid reset, which helps when to use this tool (full replacement). It does not explicitly state when to use alternatives like 'update-setting-value-v2'.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/configcat/mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server