Skip to main content
Glama

SaaS Pro Max

Upsert flag

upsert_flag
Destructive

Create or replace a feature flag. The body replaces the whole definition, so send the complete set of variants, rules and per-environment settings, not a patch. Requires the write scope and flags.write.

Input Schema

NameRequiredDescriptionDefault
appYesApplication id, or orgSlug/appSlug as returned by list_apps
keyYesLowercase letters, digits, - and _
kindNo
nameYes
rulesNo
variantsNo
descriptionNo
environmentsNo{ production: { enabled: true, rolloutPercent: 25 }, … }

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Annotations already flag destructiveHint=true and idempotentHint=false, and the description adds the specific consequence: omitted variants, rules and per-environment settings are wiped because the body replaces the whole definition. It also discloses the auth scopes required, which annotations do not cover.

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 operation, then the replace-not-patch warning, then the auth requirement. Every sentence carries distinct operational value with no filler.

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 destructive, nested-payload mutation with no output schema, the definition covers the critical risks: full replacement, data loss on omitted fields, and required scopes. It doesn't say what a successful response contains or how creation differs from replacement, but the essential calling information is present.

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?

With only 38% schema description coverage across 8 parameters (several nested), the description compensates partially by calling out the three complex payload fields — variants, rules, environments — and the replacement semantics that govern them. It adds nothing for app, key, name, kind or description, and the kind enum is unexplained.

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

Purpose5/5

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

States a specific verb plus resource — 'Create or replace a feature flag' — which immediately distinguishes it from the read-side sibling list_flags. An agent knows exactly what the operation does without opening the schema.

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 clear context for use: the body is a full replacement, not a patch, so callers must send the complete definition. It also names the required authorization (write scope and flags.write). It stops short of naming an alternative for partial updates, but no such sibling exists in this toolset.

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