Skip to main content
Glama

agent_buy_course

Build a checkout for one or more courses

Turn a course into a purchase. Give one or more product ids and this creates a real cart on the store and returns a checkout link that completes the sale. Free to call; the course price is paid at checkout. Use agent_search_courses to find the product id first. Multiple ids go in one cart, so a recommended set can be bought together in a single transaction.

Responses:

200: Successful Response (Success Response) Content-Type: application/json

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
storeNomain
product_idsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.9/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does disclose the important traits: this is a real side-effecting mutation ('creates a real cart on the store'), it is free to call ('the course price is paid at checkout'), and it returns a checkout link. It omits auth/permission requirements, cart lifetime or abandonment, and idempotency, so it is not fully complete for a purchase tool.

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-loaded and mostly waste-free: purpose, side effect, cost, prerequisite, and batching are each one sentence. The trailing '### Responses: **200** ... Content-Type: application/json' block is boilerplate noise that adds nothing for the agent.

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

Completeness3/5

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

There is no output schema, and the description usefully covers the return value (a checkout link). However, for a two-parameter purchasing tool it leaves the 'store' parameter and any error/permission behavior unaddressed, so an agent lacks full information to invoke it correctly in every case.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate and only partially does. It clarifies product_ids is accept-one-or-more but never explains the wire format (the schema types it as a single string, so comma-separation is left to guesswork), and the 'store' parameter with default 'main' is not mentioned anywhere in the description or 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?

States a concrete verb and resource in plain terms ('Build a checkout for one or more courses', 'creates a real cart on the store and returns a checkout link'), and explicitly distinguishes itself from agent_search_courses, which only finds the product id. An agent can route between browsing and buying without opening either 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 an explicit precondition and sequencing ('Use agent_search_courses to find the product id first') and explains the multi-id case ('Multiple ids go in one cart... single transaction'). It does not state when NOT to use it (e.g., existing cart handling or preview/review alternatives), but context is otherwise unambiguous.

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.