Skip to main content
Glama

Organize transactions

annotate
DestructiveIdempotent

Categorize, tag, rename, and organize transactions. Set party, category, transfer status, or ignored flag. Bulk operations: apply rules, detect recurring bills and subscriptions. Raw bank data is never modified, but a change replaces the earlier label, note or flag on that transaction, and revert clears manual overrides.

When reporting back to the user, translate counts and outcomes to plain English ("I categorized 14 transactions"). Don't echo schema field names.

ACTIONS:

  • Classify: categorize, set_party, tag, untag, annotate (set notes/url). Tags are normalized (lowercased, spaces→hyphens — "Greece Trip" stores as "greece-trip"); tag/untag input is normalized to match. untag is source-aware: removing a system (auto) tag also stops it from coming back on the next automatic refresh (re-tagging lifts the suppression); rule-applied tags are refused — edit or delete the rule instead.

  • Reserved tags: 'one-time' excludes a txn from recurring detection/forecast (effective next detection run, or immediately via detect_recurring); 'refund' is the system's own marker for a returned charge. Reimbursables lifecycle: • 'reimbursable': a charge you paid and expect to be paid back for. • 'reimbursed': that charge has now been paid back (goes on the charge, never on the payout). • 'reimbursement': the incoming money that pays you back (goes on the payout, never on the charge). Tagging an inflow 'reimbursement' auto-files it under 'Admin › Reimbursements' (contra-expense) if not already an expense. HSA withdrawals (transfers/investments) and FSA payouts (income) are not reimbursements.

  • Metadata: set_metadata (key+value; one value per key — set replaces), remove_metadata (key, optional value). Custom keys only: "tag"/"notes"/"receipt" are reserved and rejected with a pointer to their dedicated actions. Keys are trimmed + lowercased.

  • Flag: mark_transfer, mark_ignored, set_recurring (also takes a split part's id from detail parts[].id; ids it can't link come back in skipped with a reason)

  • Person: set_person (person: a name, id or "me" from admin entity person; null clears) — who the rows count toward; beats person rules. revert leaves it.

  • Revert: revert (clear manual overrides, restore import defaults; leaves splits)

  • Split: split ONE charge (transaction_ids: [id], no filter) into parts from a receipt you read: parts: [{ amount, category_name?, party_name?, display_name?, notes? }], 2-50, summing exactly to the charge (else refused; nothing is spread). An app-store bill: one part per item, party_name the app. Re-splitting replaces the parts (a part linked to a series by hand keeps its link when a new part has its party and amount; unlinked_series names any series that lost one); unsplit (transaction_ids) removes them. A written split or unsplit re-runs recurring detection, so a split-out app's series appears without a detect_recurring call. Ignored, transfer, investment and financing charges don't split; a pending charge's parts move to its posted charge if the amount holds (health lists ones that stopped counting). preview:true validates and shows creates_party per part. Detail rows and explain show parts; spending reports (summary, by, time series) count each part in its own category and party.

  • Bulk: detect_recurring (creates/updates recurring_series — use preview:true to preview), apply_rules (applies saved rules — use preview:true to preview, rule_ids to limit which rules), infer_categories (fills a placeholder category from the party's own history elsewhere in the ledger; skips manual overrides and any party whose history isn't decisive; preview:true first). detect_recurring (always) and apply_rules with no filter/transaction_ids sweep the whole household: preview:true is a true dry run (no writes, no swept_at) and returns NO token — apply by re-running the same call without preview. NOTE filter.is_uncategorized will NOT find its targets — that means category IS NULL, and these rows carry a placeholder category. Select them with filter.category: ["Other Expense", "Other Income", "Uncategorized"] plus a date range COMPOUND: categorize accepts party_name/party_id to set both in one call. set_party accepts category_name/category_id/group_name to set both in one call.

TARGET: transaction_ids (max 5000) OR filter — one is required for most actions; if both are sent, the filter is ignored and a hint says so. detect_recurring takes no filter (use detect_start). FILTERS: filter.party, filter.category, filter.group, filter.tag, filter.exclude_tag are exact match (case-insensitive), accept string or string[]. filter.country ("GR" / "GRC" / "Greece") and filter.city select by where the merchant is. filter.person / filter.exclude_person select by who rows count toward. filter.account matches name or display name (exact, case-insensitive). filter.search is text search across display name, party name, description, check number, tags and notes ("a or b" for several terms; "$625.34" also matches that amount). Date scope: filter.period (same named periods as query: this_month, last_month, ...) OR filter.start/end (YYYY-MM-DD) — not both. No date scope = ALL TIME. Also: amount_min/max, direction, is_uncategorized, is_recurring, is_transfer, is_ignored, is_pending, is_flagged, has_url, include_hidden. Unknown filter keys are rejected with a validation error (never silently dropped). Date keys at the TOP level (query's flat shape) are also rejected — they belong inside filter. TOKEN (filter-targeted writes only — explicit transaction_ids and filterless sweeps need none): call with preview:true → { matched, token, preview:[sample], will_set? }, review the matched rows and validated category/party/series targets (creates_party says whether a requested party name needs creation), then re-send the SAME action + filter WITH that token to execute (the token param says what makes one stale). Over 20000 matches is rejected: narrow filter.period/filter.account or pass explicit transaction_ids. Preview rows match detail: amt is signed (inflows positive, outflows negative), desc is the displayed name, raw is the original bank memo. RESPONSE: { affected: N, action, matched?, token?, will_set?: { category_id?, party_id?, party_name?, creates_party?, recurring_series_id? }, range?: { start, end } | "all", detail?: { ... }, warnings?: [...], hint? }. split: detail.parts [{ id, amt, desc?, cat?, grp?, party?, notes? }]; split/unsplit/apply_rules: recurring?: { created, updated } when detection changed series. range echoes a filter write's effective date scope — check it matches your intent before and after bulk actions. REQUIRED PER ACTION: categorize needs category_id or category_name; set_party needs party_id or party_name; tag/untag need tag_name; annotate needs notes or url (notes:"" clears the note); set_recurring needs recurring_series_id; set_metadata needs key + value; remove_metadata needs key; set_person needs person (null clears). mark_transfer/mark_ignored/revert need no payload. A missing one is rejected up front, before any write or preview. When affected=0, an error field explains why (e.g. party not found, category not found, missing required field, no matching transactions, missing/stale token) — or, when the requested state already holds (re-applying a tag), a hint says so. When overriding a rule-classified transaction (≤5 explicit IDs, categorize/set_party/mark_transfer/mark_ignored), warnings include rule details and recovery instructions. The write always succeeds; warnings are advisory. NOTE: To explain/debug a transaction's classification, use query { explain: true, transaction_id: "" } instead.

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": {
      "action": "<action>"
    },
    "name": "annotate"
  }
}

Input Schema

NameRequiredDescriptionDefault
endNoDo not use: end belongs inside filter: { filter: { end: ... } }
keyNoMetadata key (for set_metadata/remove_metadata)
urlNoReceipt URL to attach
notesNoNotes to add
partsNosplit: the parts of ONE charge (transaction_ids with a single id), 2-50, which must sum exactly to it: [{ amount, category_name?, party_name?, display_name?, notes? }]. Replaces any earlier split of that charge
startNoDo not use: start belongs inside filter: { filter: { start: ... } }
tokenNoREQUIRED to execute a filter-based write. Get it from a prior preview:true call (the response includes `token`) and pass it back unchanged. It binds the action + the exact set of matched transactions, so the write is rejected if that set, the scope, or the household changed since the preview (including a same-count swap). Not needed when targeting explicit transaction_ids, nor for detect_recurring or a filterless apply_rules (their previews return no token).
valueNoMetadata value (for set_metadata/remove_metadata)
actionYesAction to perform
filterNoTarget transactions by filter
periodNoDo not use: period belongs inside filter: { filter: { period: ... } }
personNoset_person: a person's name, id or "me" (admin entity person); null clears the manual choice so person rules apply again
dry_runNoDo not use: use preview: true (there is no dry_run param)
previewNoPreview without writing: matched transactions and validated will_set targets for filter-based targeting (creates_party reports whether a requested party name needs creation), or for detect_recurring the series it would create/update/deactivate and the links it would add/clear. Only a filter-targeted preview returns a token
group_idNoCategory group ID
party_idNoParty to assign
rule_idsNoLimit which rules to apply
tag_nameNoTag name
group_nameNoCategory group name
is_ignoredNoMark as ignored (excluded from all reports)
party_nameNoParty name (creates if needed)
party_typeNoParty type classification
category_idNoCategory to assign
is_transferNoMark as transfer
detect_startNoStart date for detect_recurring lookback (default: 18 months ago). A narrower window re-estimates every matched series from less history and UNLINKS its auto-linked charges older than the window — preview:true first
category_nameNoCategory name — must be an existing category (the taxonomy is a fixed set; use admin category list)
transaction_idsNoTarget specific transactions by ID
overwrite_manualNoOverwrite manual enrichments when applying rules
recurring_series_idNoLink to recurring series

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / filter / properties / search / description
      Previous value: -"Text search across display name, party name, description, and check number"New value: +"Text search across display name, party name, description, check number, tags and notes. Several terms: \"a or b\" or \"a | b\" (a row matching any term is returned; up to 10). A dollar amount like \"$625.34\" or \"1,200\" also matches rows of exactly that amount"
  2. Changed2 schema fields changed
    • changedInput schema / properties / action / enum
      Previous value: -[
      -  "categorize",
      -  "set_party",
      -  "tag",
      -  "untag",
      -  "annotate",
      -  "set_recurring",
      -  "mark_transfer",
      -  "mark_ignored",
      -  "detect_recurring",
      -  "apply_rules",
      -  "infer_categories",
      -  "set_metadata",
      -  "remove_metadata",
      -  "revert",
      -  "set_person"
      -]New value: +[
      +  "categorize",
      +  "set_party",
      +  "tag",
      +  "untag",
      +  "annotate",
      +  "set_recurring",
      +  "mark_transfer",
      +  "mark_ignored",
      +  "detect_recurring",
      +  "apply_rules",
      +  "infer_categories",
      +  "set_metadata",
      +  "remove_metadata",
      +  "revert",
      +  "set_person",
      +  "split",
      +  "unsplit"
      +]
    • addedInput schema / properties / parts
      Added value: +{
      +  "description": "split: the parts of ONE charge (transaction_ids with a single id), 2-50, which must sum exactly to it: [{ amount, category_name?, party_name?, display_name?, notes? }]. Replaces any earlier split of that charge",
      +  "items": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "amount": {
      +        "description": "The part's amount in the charge's currency, whole units (> 0; a signed value is accepted when its sign matches the charge: negative for spending)",
      +        "type": "number"
      +      },
      +      "category_id": {
      +        "description": "The part's category, by id (or category_name). Omit to keep the charge's",
      +        "minLength": 1,
      +        "type": "string"
      +      },
      +      "category_name": {
      +        "description": "The part's category, by exact name. Alias: cat, category",
      +        "type": "string"
      +      },
      +      "display_name": {
      +        "description": "What the part reads as (an item title). Alias: desc",
      +        "maxLength": 200,
      +        "type": "string"
      +      },
      +      "notes": {
      +        "description": "A note on the part. Alias: note",
      +        "maxLength": 65536,
      +        "type": "string"
      +      },
      +      "party_id": {
      +        "description": "Who the part was paid to, by id (or party_name). Omit to keep the charge's",
      +        "format": "uuid",
      +        "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      +        "type": "string"
      +      },
      +      "party_name": {
      +        "description": "Who the part was paid to, by name (created if needed; the app for an app-store line). Alias: party",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "amount"
      +    ],
      +    "type": "object"
      +  },
      +  "maxItems": 50,
      +  "minItems": 2,
      +  "type": "array"
      +}
  3. Changed4 schema fields changed
    • changedInput schema / properties / action / enum
      Previous value: -[
      -  "categorize",
      -  "set_party",
      -  "tag",
      -  "untag",
      -  "annotate",
      -  "set_recurring",
      -  "mark_transfer",
      -  "mark_ignored",
      -  "detect_recurring",
      -  "apply_rules",
      -  "infer_categories",
      -  "set_metadata",
      -  "remove_metadata",
      -  "revert"
      -]New value: +[
      +  "categorize",
      +  "set_party",
      +  "tag",
      +  "untag",
      +  "annotate",
      +  "set_recurring",
      +  "mark_transfer",
      +  "mark_ignored",
      +  "detect_recurring",
      +  "apply_rules",
      +  "infer_categories",
      +  "set_metadata",
      +  "remove_metadata",
      +  "revert",
      +  "set_person"
      +]
    • addedInput schema / properties / filter / properties / exclude_person
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    }
      +  ],
      +  "description": "Drop rows counting toward these people"
      +}
    • addedInput schema / properties / filter / properties / person
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    }
      +  ],
      +  "description": "Who the rows count toward: name(s), \"me\" or \"shared\""
      +}
    • addedInput schema / properties / person
      Added value: +{
      +  "description": "set_person: a person's name, id or \"me\" (admin entity person); null clears the manual choice so person rules apply again",
      +  "type": [
      +    "string",
      +    "null"
      +  ]
      +}
  4. Changed3 schema fields changed
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / filter / properties / amount_max / minimum
      Added value: +0
    • addedInput schema / properties / filter / properties / amount_min / minimum
      Added value: +0
  5. Changed3 schema fields changed
    • addedInput schema / properties / notes / maxLength
      Added value: +65536
    • addedInput schema / properties / url / maxLength
      Added value: +65536
    • addedInput schema / properties / value / maxLength
      Added value: +65536
  6. Changed1 schema field changed
    • changedInput schema / properties / preview / description
      Previous value: -"Preview without writing: matched transactions for filter-based targeting, or for detect_recurring the series it would create/update/deactivate and the links it would add/clear. Only a filter-targeted preview returns a token"New value: +"Preview without writing: matched transactions and validated will_set targets for filter-based targeting (creates_party reports whether a requested party name needs creation), or for detect_recurring the series it would create/update/deactivate and the links it would add/clear. Only a filter-targeted preview returns a token"
  7. Changed2 schema fields changed
    • changedInput schema / properties / filter / properties / amount_max / description
      Previous value: -"Maximum absolute amount (dollars)"New value: +"Maximum absolute amount (household's currency)"
    • changedInput schema / properties / filter / properties / amount_min / description
      Previous value: -"Minimum absolute amount (dollars)"New value: +"Minimum absolute amount (household's currency)"
  8. Changed2 schema fields changed
    • addedInput schema / properties / filter / properties / city
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    }
      +  ],
      +  "description": "Merchant city — exact match, case-insensitive"
      +}
    • addedInput schema / properties / filter / properties / country
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    }
      +  ],
      +  "description": "Merchant country — ISO alpha-2 (\"GR\"), alpha-3 (\"GRC\") or English name (\"Greece\")"
      +}
  9. First observed

TDQS

A4.9/5.0
Behavior5/5

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

Annotations already disclose destructiveHint/idempotentHint, but the description adds far more: raw bank data is never modified while a change replaces the prior label/note/flag, revert clears manual overrides but leaves splits, untag suppresses auto-tag re-application, writes over 20000 matches are rejected, and override warnings are advisory only. These are exactly the mutation semantics an agent needs before writing.

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?

Structure is strong — a lead summary, per-action bullets, then target/filter/token/response sections — and most sentences carry load. It is nonetheless very long, with the token/preview contract restated in the description and again in the token parameter, which pulls it below top marks.

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?

Outstanding for a 17-action, 29-parameter tool with no output schema: the description supplies a RESPONSE shape (affected/action/token/will_set/range/warnings), the affected=0 error contract, and split/preview edge cases. Nothing essential for correct invocation is left to inference.

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

Parameters5/5

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

Although schema coverage is 100%, the description still adds meaning the schema cannot: tag normalization ('Greece Trip' → 'greece-trip'), reserved tags and the reimbursable lifecycle, per-action required payloads, the compound categorize/set_party cross-targeting, and the critical caveat that filter.is_uncategorized will not find its targets (use filter.category: ["Other Expense", ...] instead).

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?

Opens with a specific verb stack and resource: 'Categorize, tag, rename, and organize transactions. Set party, category, transfer status, or ignored flag.' It also names the boundary against the sibling query tool ('use query { explain: true }'), so the agent can pick it over alternatives without opening the schema.

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 states when a preview + token is required vs. not ('explicit transaction_ids and filterless sweeps need none'), warns that rule-applied tags are refused and should be handled by editing the rule, and directs classification debugging to the query sibling. Exclusions and alternatives are both present.

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