Skip to main content
Glama

Attach file to invoice

crunch_add_invoice_attachment

Attach files such as timesheets to a sales invoice while keeping existing attachments; add up to five files per invoice.

Instructions

Attach files (for example timesheets) to a sales invoice. Existing attachments are kept; an invoice can have up to 5.

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": {
      "invoice_id": "<invoice_id>",
      "attachments": "<attachments>"
    },
    "name": "crunch_add_invoice_attachment"
  }
}

Input Schema

NameRequiredDescriptionDefault
dry_runNoPreview: return the request that would be sent (for an update, the fields that would change) without sending it
invoice_idYesInvoice ID (see crunch_list_invoices)
attachmentsYesFiles to attach (an invoice can have up to 5)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.7.0

TDQS

A4/5.0
Behavior4/5

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

Adds real behavior beyond the annotations: existing attachments are preserved (append semantics, consistent with idempotentHint=false and destructiveHint=false) and there is a hard cap of 5 attachments per invoice. It stops short of saying what happens when the cap is exceeded or whether attachment affects invoice state.

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?

Two short front-loaded sentences: what it does first, then the preservation and limit constraints. No filler or redundancy.

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 three-parameter mutation with full schema coverage and annotations declaring the safety profile, the description covers the key non-obvious facts (merge behavior, 5-file cap). It omits error/limit behavior and any note about the response, though no output schema exists to cover that.

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 invoice_id, attachments, and the nested file options are already documented in the schema. The description adds only the "up to 5" constraint tied to the attachments array, which is marginal added meaning over the structured fields.

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: "Attach files ... to a sales invoice", with an example (timesheets) of what qualifies. The resource qualifier "sales invoice" distinguishes it from the expense-attachment sibling without needing to name it.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Implies when to use it (you have a file to attach to an existing invoice), but gives no explicit prerequisites such as whether the invoice must exist, be draft, or be issued before attachments are allowed. No alternative or alternative-path guidance is offered.

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

Deploy Server

Other Tools