Skip to main content
Glama

invoice_client_link_tenant

[REQUIRES APPROVAL] Asserts that a billing client IS an on-platform tenant (or pass counterparty_tenant_id null to unlink) and retro-stamps that client's existing invoices with the link in the same call — invoices_stamped in the result is the count. Linking requires the counterparty's 'cross_tenant_settlement' consent AND a live network relationship (an active match or a deal thread); unlinking passes neither gate, since it withdraws your own assertion rather than making a new one. NEXT: invoice_client_read to read back what linked.

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": {
      "id": "<id>",
      "counterparty_tenant_id": "<counterparty_tenant_id>"
    },
    "name": "invoice_client_link_tenant"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesThe invoice_client id (invoice_client_list shows them).
nameNo
emailNo
notesNo
phoneNo
addressNo
companyNo
client_idNoAlias of id.
contact_idNo
message_languageNo
reminder_cadenceNo
counterparty_tenant_idYesThe on-platform business this client IS (their tenant id). Pass null to unlink.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the annotations, it discloses that the call retro-stamps existing invoices, reports invoices_stamped, requires approval, and applies different gating to link versus unlink. These are material side effects and preconditions that the annotations alone do not convey.

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 approval requirement and core action are front-loaded, and each sentence adds necessary information about gating, side effects, or next steps. There is little waste despite the tool's complexity.

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?

For a high-complexity cross-tenant mutation with no output schema, the description covers purpose, gates, side effects, result count, and follow-up well. The remaining gap is the unexplained optional profile parameters in the schema, which could confuse invocation.

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 only 25%, and the description usefully explains the critical counterparty_tenant_id behavior (null unlinks) while the schema explains id. However, it leaves the other optional client-profile fields undocumented, so an agent cannot tell whether those fields are ignored or updated during linking.

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 states a precise verb and resource: it asserts that a billing client IS an on-platform tenant, with a clear null-unlink variant. It distinguishes the operation from sibling invoice_client tools by naming the cross-tenant link/unlink semantics and the retro-stamping side effect.

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 explicitly states when linking is allowed (counterparty's 'cross_tenant_settlement' consent plus a live relationship) and when unlinking is allowed (neither gate applies). It also points to invoice_client_read as the next step, so an agent has clear routing guidance.

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