Skip to main content
Glama
AlgoChains

AlgoChains MCP Server

Official
by AlgoChains

exchange_broker_oauth_code

Destructive

Exchange an OAuth authorization code for broker access and refresh tokens. Use after the user returns from the broker's authorization page to finalize authentication.

Instructions

Exchange an OAuth authorization code for broker access/refresh tokens. Call this after the user returns from the broker's authorization page.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYesAuthorization code from the broker callback URL
stateYesState token returned by generate_broker_auth_url
redirect_uriNo
Behavior3/5

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

Annotations already indicate destructiveHint=true and readOnlyHint=false. The description adds that it exchanges code for tokens, but does not disclose additional behavioral traits like error handling, rate limits, or side effects beyond what annotations imply. With annotations present, the description adds minimal value.

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?

The description is a single sentence that is front-loaded with the key action and context. No unnecessary words, every part earns its place.

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

Completeness2/5

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

The tool has no output schema and 3 parameters. The description does not explain the return value (access/refresh tokens) or error scenarios. Given the complexity of OAuth flows, an agent would benefit from knowing what the response contains and how to handle common errors. The description is too minimal for complete understanding.

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?

Schema coverage is 67% (2 of 3 parameters have descriptions). The tool description does not add any additional parameter semantics beyond the schema. For the 'redirect_uri' parameter, which lacks a schema description, the tool description also fails to provide meaning. Baseline 3 is appropriate given high schema coverage.

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?

The description clearly states the verb 'Exchange' and the resource 'OAuth authorization code for broker access/refresh tokens', and provides context ('after the user returns from the broker's authorization page'). It distinguishes from sibling tools like generate_broker_auth_url and connect_broker.

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?

The description explicitly says when to use this tool ('Call this after the user returns from the broker's authorization page'). It does not mention when not to use it, but given the context of the OAuth flow, the guidance is clear. A perfect score would require explicit exclusion of alternatives.

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/AlgoChains/algochains-mcp-server'

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