Skip to main content
Glama

Xero Create Credit Note

xero_create_credit_note

Create Xero credit notes for customer or supplier accounts by supplying a contact, line items, date, reference, and credit note type.

Instructions

Create a credit note. Requires XERO_WRITE_ENABLED=true.

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": {
      "contact_id": "<contact_id>",
      "line_items": "<line_items>"
    },
    "name": "xero_create_credit_note"
  }
}

Input Schema

NameRequiredDescriptionDefault
dateNoCredit note date (YYYY-MM-DD)
referenceNoReference
contact_idYesContact UUID
line_itemsYesJSON array of line items
credit_note_typeNoACCRECCREDIT or ACCPAYCREDITACCRECCREDIT

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

C2.9/5.0
Behavior2/5

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

With no annotations, the description carries the full behavioral burden and largely does not meet it: it does not say whether the note is created as draft or authorized, whether it affects the contact's balance immediately, what happens on failure, or what the XERO_WRITE_ENABLED flag implies (e.g. whether it is a server config or per-call). The one useful disclosure—an environment prerequisite—is real but minimal.

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 short sentences, front-loaded with the action, with no filler. It is efficient, though the result is under-specification rather than tight completeness.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The output schema and full parameter descriptions relieve the description of documenting return values and args. However, for an unannotated mutation tool on a financial resource, an agent still lacks confirmation of the write's effects and any validation rules, leaving a real gap even if a modest one.

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 each of the five parameters (date, reference, contact_id, line_items, credit_note_type) is already documented in the schema. The description adds no meaning beyond that, including nothing about the ACCRECCREDIT vs ACCPAYCREDIT distinction or the expected shape of the line_items JSON string. Baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific verb and resource ("Create a credit note"), which is enough to tell it apart from siblings like xero_void_credit_note or xero_create_invoice. It does not explicitly contrast with those siblings, so it falls short of a 5.

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

Usage Guidelines2/5

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

There is no guidance on when to choose this over xero_create_invoice or xero_void_credit_note, nor on preconditions beyond the write flag. The only usage constraint given is that XERO_WRITE_ENABLED=true must be set, which is an environment gate rather than selection guidance.

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