Skip to main content
Glama

Create an invoice

create_invoice

Creates an on-chain crypto invoice with a specified amount, payment currency, and network, returning an invoice ID to bill in crypto or USD and track payment.

Instructions

Create an on-chain invoice (a "request") for a specific amount, currency and network. paymentCurrency picks the token and network, e.g. "USDC-base", "USDC-mainnet", "ETH-sepolia-sepolia" (use find_currency to look IDs up). invoiceCurrency is what the amount is denominated in; it defaults to paymentCurrency, or use "USD" to bill a dollar amount paid in crypto. Returns the invoice ID.

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": {
      "amount": "<amount>",
      "paymentCurrency": "<paymentCurrency>"
    },
    "name": "create_invoice"
  }
}

Input Schema

NameRequiredDescriptionDefault
payeeNoWallet that gets paid. Defaults to REQUEST_PAYEE.
payerNoWallet expected to pay (optional).
amountYes
referenceNoYour own note or invoice number, e.g. "INV-042 website".
invoiceCurrencyNo
paymentCurrencyYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare the write/read profile (readOnlyHint=false, destructiveHint=false, idempotentHint=false, openWorldHint=true), and the description adds the one behavioral fact annotations can't carry: "Returns the invoice ID" — important since there is no output schema. It does not mention auth/payee-wallet requirements or that each call produces a distinct on-chain request (the non-idempotent consequence), which would have pushed this higher.

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?

Four tight sentences, front-loaded with the action, then the two currency parameters in dependency order, then the return value. No filler or restatement of the title; the concrete ID examples earn their space because they encode a format the regex can't express.

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 non-idempotent write tool with no output schema, the description covers the action, the currency-ID convention, the invoiceCurrency default, and the return value, which is enough to call it correctly. It stops short of stating that the created invoice is an unpayable request until the payer acts, or what happens if the same invoice is created twice.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is only 50%, and the description compensates exactly where the schema cannot: it explains that paymentCurrency selects both token and network with concrete IDs like "USDC-base" and "ETH-sepolia-sepolia", which is not derivable from the bare pattern regex, and clarifies the relationship and default between paymentCurrency and invoiceCurrency. The remaining schema-described params (payee, payer, reference) already carry their own descriptions.

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 opens with a specific verb+resource+scope: "Create an on-chain invoice (a 'request') for a specific amount, currency and network." It pairs the term 'invoice' with its on-chain synonym 'request', and it names find_currency as the lookup sibling, so an agent can distinguish it from check_invoice or create_payment_link without opening a schema.

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

Usage Guidelines4/5

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

It gives clear routing for the currency-ID dependency ("use find_currency to look IDs up") and explains the key billing decision (set invoiceCurrency to "USD" to bill a dollar amount paid in crypto, otherwise it defaults to paymentCurrency). It does not address when to prefer create_payment_link or list_invoices instead, so the sibling differentiation is partial rather than complete.

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