Skip to main content
Glama

Declare a counterparty's default transaction category

well_set_counterparty_default_category

Declare what spend at ONE counterparty is — asked once about the counterparty, instead of once per transaction.

REQUIRED: company_id, from well_list_counterparties. category — a LABEL from the closed list this schema carries. The vocabulary is fixed: there is no free-text category and no way to mint one.

This is the counterparty's DEFAULT, not one row's category. Every transaction of this counterparty categorized from here on takes the label without a model call.

It also reaches backward. The counterparty's existing transactions are relabelled too, in the background over the minutes or hours after the call. Rows a person answered are never touched: a transaction someone categorized or confirmed by hand keeps what they gave it. Tell the user a declaration rewrites the counterparty's history, so they are not surprised by it. To change ONE row instead, use well_set_transaction_category, which sets that transaction and leaves the counterparty alone.

A declaration is trusted at once. The other way a counterparty gets a default is by being taught: three corrections to the same category on three distinct transactions. A declaration skips that, because the person has already said what the answer is.

It overrides whatever the counterparty carried before, including a category the system had inferred from corrections and one an earlier declaration already wrote onto these same rows. A later transaction-level correction still wins over the declaration on the row it names, and teaches the counterparty that the default is wrong.

Do not declare a default for a counterparty whose spend has more than one nature. A marketplace or a cloud vendor selling hardware, compute and advertising to the same buyer has no single answer, and a declaration would state one. Leave those to the classifier and correct them per line.

Not for the workspace's own company. A default is about the other party; the server refuses it on the own company.

When the token authorizes one workspace, call this directly — no other tool call is needed first. When it authorizes several, this read will not guess which one you mean: pass workspace_id on the call.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
categoryYesThe category label spend at this counterparty defaults to. Must be one of the labels in this list.
company_idYesThe counterparty to declare a default for, from well_list_counterparties.
workspace_idNoTarget workspace. Omit when the token authorizes one workspace. Required when it authorizes several — a write lands in exactly one workspace and this call would not say which.
conversation_idNoThe conversation id returned by the previous Well result, in its meta under well/conversation_id, in its structuredContent, or in its JSON text block. Pass it back on every call in the same conversation, including a call a card makes, so the chosen workspace and the earlier answers still apply. It decides the conversation on its own: nothing the host states about the session replaces it. Omit it only on the first call of a conversation.
idempotency_keyNoOptional client-supplied key. A retried write with the same key returns the original result instead of re-applying the operation.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNo
successYes
categoryNoThe label the counterparty's default now carries.
company_idNo
company_nameNo
conversation_idNoThe conversation this result belongs to. Pass it back as the conversation_id argument on every later Well call in the same conversation.
conversation_id_noteNoPresent only when the server opened a fresh lane, stating that no choice recorded earlier was read.
conversation_id_sourceNoWhere the conversation id came from: the host's own request meta, the caller's argument, or a fresh lane the server opened.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.9/5.0
Behavior5/5

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

Even though annotations already mark this as a mutating write, the description adds substantial behavioral context: the declaration applies to future transactions, relabels existing ones in the background, never touches manually answered rows, overrides previously inferred or declared defaults, and later corrections win. It aligns with annotations and gives an agent the side effects needed to warn a user safely.

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

Conciseness5/5

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

The description is long but warranted: it uses bold headers and short paragraphs to organize purpose, requirements, forward and backward effects, override rules, exclusions, and multi-workspace handling. It is front-loaded with the core meaning, and each section delivers information an agent must know before calling the tool.

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 mutating tool with side effects and several caveats, the description covers everything needed to call it correctly and inform the user: default semantics, backward relabeling, manual-row protection, precedence rules, mixed-nature warning, own-company refusal, and workspace_id handling. An output schema exists, so the description need not explain return values.

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

Parameters4/5

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

Schema coverage is 100% with strong per-parameter descriptions, so the baseline is 3. The description adds extra meaning by stating company_id comes from well_list_counterparties, that category is a fixed closed-list label with no free-text alternative, and exactly when workspace_id is required versus omitted. It adds less beyond the schema for conversation_id and idempotency_key, so 4 rather than 5.

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 opens with a specific verb and resource: 'Declare what spend at ONE counterparty is — asked once about the counterparty, instead of once per transaction.' It immediately clarifies this sets a default, not a per-row category, and later explicitly contrasts itself with well_set_transaction_category. An agent can distinguish this tool from its closest sibling without inspecting schemas.

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?

It gives explicit when-to-use guidance (per counterparty, not per transaction), names the alternative for single-row changes, and states clear exclusions: do not use for mixed-nature counterparties, do not use for the workspace's own company, and pass workspace_id when multiple workspaces are authorized. This is far beyond implied usage.

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