Skip to main content
Glama

Set Bring-Your-Own-Key Provider

set_byok_key
Idempotent

Add or update a BYOK provider API key. Key is encrypted at rest (AES-256-GCM). Requires paid plan (Pro+). Providers: openai (sk-…), claude (sk-ant-…), gemini (AIza… or AQ.…).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
api_keyYesRaw API key for the provider.
providerYesAI provider name.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare idempotentHint=true and destructiveHint=false, and the 'add or update' phrasing is consistent with that. The description adds value beyond annotations by disclosing encryption at rest (AES-256-GCM) and the plan-gating requirement, though it says nothing about rate limits or how an overwrite affects an existing key.

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 compact sentences, action front-loaded, followed by guarantee, then constraint, then input formats. Every sentence carries distinct information 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 two-parameter mutation tool with no output schema and annotations covering the safety profile, the description covers action, security, plan gating, and input formats. Only minor gaps remain, such as overwrite behavior on an existing provider key.

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 baseline is 3, but the description adds genuine meaning by pairing each provider enum value with its expected key prefix format (sk-, sk-ant-, AIza/AQ.), which helps validate input before the call.

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 pair ('Add or update') and resource ('BYOK provider API key'), which distinguishes it cleanly from delete_byok_key and get_byok_keys in the sibling list. An agent can identify the operation 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 a hard prerequisite ('Requires paid plan (Pro+)') and enumerates the supported providers, so the agent knows when the call is valid. It does not explicitly route to alternatives such as create_api_key or create_mcp_key, so it falls short of a 5.

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.