Skip to main content
Glama

Complete deck on budget

complete_deck_on_budget
Read-onlyIdempotent

How to finish one deck (id or name) with budget to spend, in currency (default USD): the missing copies bought cheapest first while the budget lasts (buy, with text as "4 Card Name" lines for a shop), the copies that do not fit (over_budget, over_by), and the cards with no price yet (no_price_yet, left out of every total). A price is the cheapest non-foil printing among the priced ones, or the pinned printing's when the list pins one. Each over-budget card carries owned_stand_ins: cards the user owns with copies no deck claims outright, in the deck's colour identity, and cheaper_to_buy: cards whose cheapest price for every copy of the line fits what is left of the budget. With stand_ins_by "rules text" both come from the cards nearest by rules text (a nearer mana value and a more played card first), legal in the format; with "type and mana value" (no list for the card yet) they are mechanical filters only, still legal in the format, and cheaper_to_buy is empty; null for the commander, which gets none. Either way YOU judge whether one does the job. Say proxies beside a stand-in that has any, and name every deck in its shared_with: those copies are already borrowed. A line's claimed_by_other_decks means the user owns copies another deck claims: say so before they buy (claim_from_collection with allow_shared can borrow them). Name the cards in printings_not_compared as possibly cheaper: some of their printings have no price yet, and the nightly price refresh reaches every printing within a week (prices_queued is always 0: this tool queues nothing). Copies the user owns free (claimable) are not missing: run claim_from_collection first. Read-only: it changes nothing and starts no work. Relay rate_missing when present. stand_ins_withheld, when present, means the user's plan has no stand-ins: relay it once, as written.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "deck": "<deck>",
      "budget": "<budget>"
    },
    "name": "complete_deck_on_budget"
  }
}

Input Schema

NameRequiredDescriptionDefault
deckYesDeck id or name
budgetYesMoney to spend, in `currency`
currencyNoDisplay currency. USD/EUR come from Scryfall; CHF is always EUR × the stored ECB rate. A response that carries `rate_missing` could not price in CHF at all: tell the user that, not that the cards have no price.

Output Schema

NameRequiredDescriptionDefault
buyYes
deckYes
textYes
spendYes
budgetYes
over_byYes
completeYes
currencyYes
claimableYesFree copies not claimed: not missing, claim_from_collection takes them
left_overYes
over_budgetYes
no_price_yetYesLeft out of every total: say so
rate_missingNoPresent when CHF was asked and no CHF rate is stored: no CHF price could be given at all, the cards are not unpriced. Relay it.
prices_queuedYesAlways 0: this tool queues nothing; the nightly refresh reaches every printing within a week
total_estimatedYesEvery missing copy with a price; leaves out no_price_yet
stand_ins_withheldNoPresent when the user's plan has no stand-ins: relay it once, as written
printings_not_comparedYesPriced from part of their printings: one not yet priced may be cheaper

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Beyond the readOnlyHint/idempotentHint annotations it adds real behavior: prices are the cheapest non-foil printing, `prices_queued` is always 0 because the tool queues nothing, the nightly refresh reaches all printings within a week, and it starts no work. Much of the rest is interpreting output fields, which overlaps the output schema, so it falls short of a full 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The critical scoping ('cheapest first while the budget lasts') is front-loaded, and every clause carries operational detail rather than filler. However, it is one dense paragraph with long chained sentences and heavy backtick usage, which makes it slow to parse.

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?

For a complex pricing/stand-in calculation with an output schema, the description covers what an agent needs to act: pricing rules, budget arithmetic, no-price handling, stand-in modes (`rules text` vs `type and mana value`), legality constraints, and what to relay. Nothing material is left unstated.

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%, so deck, budget and currency are already documented, including the CHF/EUR×ECB caveat and the enum. The description adds only marginal framing ('budget to spend', default USD) rather than new syntax or constraints. Baseline 3 applies when the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb+resource: 'How to finish one deck (id or name) with `budget` to spend' plus the concrete outputs (`buy`, `over_budget`, `no_price_yet`). An agent can tell this is a budget-aware gap-filling calculation, not a plain deck view. It is framed as a procedure rather than a one-line purpose statement, which slightly muddies the opening.

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?

Explicitly routes the agent: 'Copies the user owns free (`claimable`) are not missing: run claim_from_collection first', and names claim_from_collection with allow_shared for `claimed_by_other_decks`. It also states what to relay (`rate_missing`, `stand_ins_withheld`) and that the caller must judge stand-ins itself. No ambiguity about when to use this versus the sibling.

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