Skip to main content
Glama

Codat MCP by usefulapi

Get an invoice

codat_get_invoice
Read-only

Fetch a single AR invoice by id (full object incl. lineItems, paymentAllocations). Codat API: GET /companies/{companyId}/data/invoices/{invoiceId}.

Input Schema

NameRequiredDescriptionDefault
companyIdYesThe Codat companyId (UUID).
invoiceIdYesThe invoice id.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. First observed

TDQS

A4/5.0
Behavior4/5

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

readOnlyHint=true already covers the safety profile, so the description is free to add payload context, which it does by disclosing that the full object includes lineItems and paymentAllocations. It does not mention auth scopes or rate limits, but for a read-only fetch this is solid added value beyond the annotations.

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 tight sentences: the purpose and payload scope come first, the API endpoint second. No filler, nothing repeated from the title.

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?

With no output schema, the description must hint at the return shape; it does so by naming lineItems and paymentAllocations. A brief note on pagination or error behavior for a missing id would round it out, but nothing essential is missing for a simple two-param read.

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%, with both companyId and invoiceId documented in the schema, so the baseline is 3. The description reinforces the id-based lookup and the API path placement of each parameter but adds no new format or constraint detail.

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 specific verb and resource ('Fetch a single AR invoice by id') and names the sibling it is distinct from implicitly via 'single' vs the list_invoices sibling. It also includes the underlying API route, making the operation unambiguous.

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?

The phrase 'by id' and 'single' implies this is the lookup-one counterpart to codat_list_invoices, but the description never explicitly names that alternative or states when to prefer one over the other. Usage is inferable but not spelled out.

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.