Skip to main content
Glama

exchange_api_key

Exchange an API key for a session

Exchanges a durable lasoak_ API key for a short-lived id_token (one hour) plus a refresh_token, and returns an auth_url to hand your human so they can watch what you do. This is the first call an agent makes. The reply's id_token authenticates every other endpoint here.

If you have no key, your human creates one at https://laso.finance/agent/dashboard — there is no other way to obtain one.

Free.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
api_keyYesYour `lasoak_` API key.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added
  2. Removed
  3. First observed

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden and does substantial work: it discloses token lifetime, the presence of a human-visible `auth_url`, the durable key prefix, the fact that this is the entry point for all other calls, and that it is free. It does not state whether the API key remains valid after exchange, but the description still provides unusually rich behavioral context.

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 front-loaded with the core action and then delivers token details, usage positioning, and acquisition instructions in compact paragraphs. Every sentence earns its place, including the final 'Free.' which adds cost transparency without bloat.

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?

Despite having no output schema, the description explains the returned values (`id_token`, `refresh_token`, `auth_url`) and their roles. It covers the single parameter fully via the schema, explains the prerequisite for obtaining a key, and gives the call's place in the agent lifecycle, making it complete for such a simple tool.

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 100%, and the parameter is a single `api_key` string with an example and description already. The tool description adds only the adjective 'durable' and the URL for obtaining a key, which is helpful context but not substantial new parameter-level semantics beyond the schema.

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 states a specific verb and resource: exchanging a durable `lasoak_` API key for a session containing `id_token`, `refresh_token`, and `auth_url`. It clearly positions this as the first call an agent makes, which distinguishes it from siblings like `create_agent_api_key` and `refresh_token`.

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?

It explicitly says this is the first call an agent makes and that the returned `id_token` authenticates every other endpoint, giving clear when-to-use context. It also explains how to obtain a key if the agent lacks one, though it does not explicitly contrast with the `refresh_token` sibling for later sessions.

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