Skip to main content
Glama

Add an expense to XMemo

add_expense

Record a financial transaction in your personal ledger, specifying amount, item, and optional date, category, or merchant.

Instructions

Record one expense in the XMemo Ledger. Call this whenever the user states a concrete expense, purchase, income, or refund — for example, 'I spent 25 on lunch' or 'log this expense' — not only on an explicit 'record this'. Capture date, amount, currency, item, and merchant/category when present.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
itemYesThe purchased item or service, for example 2 watermelons or Nintendo Switch 2.
noteNoOptional completion note.
pathNoA simple user-facing category or path for this memory, such as preferences, projects/xmemo, or personal/travel.finance/ledger/expenses
scopeNoOptional scope that narrows memory access; leave blank for the token default.
amountYesPositive transaction amount as a number.
bucketNoMemory bucket or namespace to read from or write to; use % only for tools that support wildcard reads.private
team_idNoOptional team/workspace identifier for team-scoped memory access.
agent_idNoOptional client-supplied agent label for memory attribution.
categoryNoOptional spending category, such as food, transport, or electronics.
currencyNoCurrency code or label, such as CNY, RMB, JPY, yen, or USD. For ledger search/list tools, leave blank unless the user explicitly requested one currency; labels are normalized to codes.CNY
merchantNoOptional merchant or store name.
device_idNoOptional client-supplied device identifier for attribution.
device_labelNoOptional human-readable device label for attribution.
payment_methodNoOptional payment method, such as card, cash, Alipay, or WeChat Pay.
transaction_dateNoTransaction date in YYYY-MM-DD. Leave blank to use today's UTC date.
agent_instance_idNoOptional stable, non-secret agent instance ID for per-client attribution.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

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

Annotations are minimal (readOnlyHint false, destructiveHint false) and the description adds little beyond stating it records an expense. No mention of auth requirements, rate limits, or side effects. With annotations present, the description should add context but fails to do so.

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?

Two sentences clearly stating purpose and usage. Very concise and front-loaded with the core action. No wasted words, though the second sentence is slightly long but still efficient.

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?

With 16 parameters and an output schema, the description covers the core recording action sufficiently. It does not explain relationships to sibling tools or error handling, but the output schema exists and the usage guidelines are adequate.

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 baseline is 3. The description mentions capturing date, amount, etc., which maps to parameters, but adds no extra meaning beyond the schema descriptions. It does not clarify parameter interactions or constraints.

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 starts with a specific verb 'Record' and resource 'one expense in the XMemo Ledger'. It clearly differentiates from sibling tools like list_ledger_transactions by focusing on recording, not querying. The examples clarify the scope.

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?

Provides clear guidance: 'Call this whenever the user states a concrete expense... not only on an explicit record this.' It gives concrete examples, though it does not explicitly state when not to use or list alternatives, which would elevate the score.

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/yonro/memory-os-cli'

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