Skip to main content
Glama

generate-api-key

Generate a Common Paper API key for the current OAuth user. Pass optional api_key.description. Returns attributes.key once — treat it as a secret; do not echo it to the user unless they ask. Persist the key in client/session storage and reuse it for future HTTP calls; only call this tool again if a request fails with 401/403 or the stored key is missing. Use the key as Authorization: Bearer for direct HTTP calls (e.g. uploading attachments to POST /v1/attachments).

Input Schema

NameRequiredDescriptionDefault
bodyYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations only tell the agent this is a non-read-only, non-idempotent write. The description adds far beyond that: the key is returned once, must be treated as a secret, must not be echoed, must be persisted and reused, and is consumed as an Authorization: Bearer header. These are operational traits structured fields cannot convey.

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?

Front-loads the purpose, then layers secret-handling, caching, and header-usage guidance. Every sentence is operationally useful, though the single dense paragraph could be broken up for faster scanning.

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

Completeness5/5

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

An output schema exists, yet the description still flags the one returned value that matters (attributes.key) and its secrecy. Combined with the reuse and 401/403 retry policy, an agent has everything needed to call and correctly handle the result.

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 description calls out 'optional api_key.description', adding the optionality nuance, but says nothing about user_id, which is fully documented only inside the nested schema. Top-level coverage is low and the description only partially compensates, so a baseline 3 is appropriate.

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 and resource ('Generate a Common Paper API key') and scopes it precisely to 'the current OAuth user'. No sibling tool does key generation, so the agent can route to this unambiguously.

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

Usage Guidelines5/5

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

Gives explicit when-to-call and when-not-to-call guidance: cache the key, only re-invoke on 401/403 or a missing stored key. This is exactly the routing/reuse policy an agent needs and leaves nothing to inference.

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.