Skip to main content
Glama

Get invoice

codecks_get_invoice
Read-onlyIdempotent

Retrieve a single invoice by ID with optional field selection and relation expansion. Choose markdown or JSON output for readable or structured invoice data.

Instructions

Get a single invoice by ID with optional field selection.

Available fields: chargeData, charged, createdAt, invoiceNumber, subtotal, total, url Relations: account

Example selection: ["chargeData", "charged", "createdAt"]

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>"
    },
    "name": "codecks_get_invoice"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesModel ID
selectionNoSelection array (fields/relations)
response_formatNoOutput format: 'markdown' for human-readable or 'json' for structured datamarkdown
include_relationsNoAttempt safe first-level relation expansion with guarded fallback

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.6/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, openWorldHint and destructiveHint=false, so the safety profile is covered. The description adds that field selection is optional and enumerates the fields/relations that can be projected, which is useful behavioral context. It says nothing about behavior on a missing/invalid ID, permission requirements, or how relation expansion behaves, which leaves meaningful gaps.

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?

The purpose sentence is front-loaded, and the field list and example are compact and directly actionable. The only mild redundancy is that the example array partially restates the field list, but it is short enough to earn its place by showing the required format.

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 carries some burden, and the enumerated field set effectively describes what can come back, which is a good substitute. The include_relations parameter and response_format are left to the schema, and the description does not explain how "Relations: account" interacts with include_relations, which is a modest gap for an otherwise simple read tool.

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%, so the baseline is 3; the description earns an extra point by enumerating the concrete valid field names (chargeData, charged, createdAt, invoiceNumber, subtotal, total, url), the available relation (account), and a literal example selection array. That goes beyond the schema's generic "Selection array (fields/relations)" and tells the agent what strings are actually legal.

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?

"Get a single invoice by ID with optional field selection" gives a specific verb (get), resource (invoice), cardinality (single, by ID), and notes the projection capability. It is clearly distinct from a listing tool in spirit, but it never names codecks_list_invoice, so the sibling differentiation is left implicit.

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 "single invoice by ID" implies this is for fetching one known invoice rather than browsing, which is a reasonable usage signal. However, there is no explicit when-to-use / when-not-to-use statement or pointer to codecks_list_invoice for enumerating invoices, so the agent still has to infer the routing.

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