Skip to main content
Glama
Backpack Battles MCP

Backpack Battles MCP

by 53721222-gif

bpb_buy_item

Purchase a shop item by slot or item ID and place it in storage; when the skill shop requires a choice, select one skill and return its ID for later placement.

Instructions

购买商店物品并放入储物箱。若 state.shop.choose_one=true(第 3/10 回合的技能商店),则选择一个技能并放入储物箱(返回 skill_id);技能是 1×1 可摆放物品,再用 bpb_place_item 摆进背包。购买后会补发 dropped 信号,触发 Unidentified Skill 等 onDropped 购买效果。用 slot(1-5)或 item_id 指定。

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "bpb_buy_item"
  }
}

Input Schema

NameRequiredDescriptionDefault
slotNo商店槽位,从 1 开始
item_idNo商店物品/技能的 id(来自 bpb_get_state)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/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 well: it discloses the non-obvious side effect that purchases land in 储物箱 rather than the backpack, that a dropped signal is re-emitted and triggers onDropped effects like Unidentified Skill, and that a skill_id is returned. It omits cost/currency deduction, purchase limits, and failure behavior.

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 core action, then the conditional skill case, then side effects, then parameter selection — a sensible order with no filler. Slightly dense with multiple clauses per sentence, but every sentence earns its place.

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

Completeness4/5

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

No output schema exists, and the description compensates by stating the return value (skill_id) and the downstream placement requirement. For a mutation tool with no annotations, only failure modes and currency mechanics remain unexplained.

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 description coverage is 100%, so slot and item_id are already documented, establishing a baseline of 3. The description only restates that either slot (1-5) or item_id selects the purchase and that item_id comes from bpb_get_state, adding little semantic detail 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?

States a specific verb and resource (购买商店物品并放入储物箱) and additionally spells out the conditional skill-purchase branch. An agent can distinguish it from bpb_sell_item, bpb_refresh_shop, and bpb_place_item purely from the text.

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?

Explains the branch condition (state.shop.choose_one=true → skill shop) and explicitly names the follow-up sibling bpb_place_item for placing the skill into the backpack, so the sequence of tools is clear. It does not cover failure/edge conditions such as an empty slot or insufficient currency.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.