Skip to main content
Glama

create_invoice

Create invoices for subscription billing by providing line items, due date, and period dates. Specify customer, currency, gateway, and payment method.

Instructions

Create an invoice. POST /invoices. Required: companyCurrencyId, companyGatewayId, customerId, paymentMethodId, detail (array, at least one line item), dateDue, dateFrom, dateTo. Optional: billingAddress, shippingAddress (when provided: contactName, street1, city, zip, countryCode (ISO 3166-1 alpha-2), type residential|commercial), customerEmail (max 45), customerName (max 45), customerPhone (max 45), paymentType (offlinePaymentProvider|thirdPartyPaymentProvider|walletPaymentProvider|otherPayment), shippingAmount (CENTS), terms (max 200), comments (max 200). Detail: amount can be '41.00' (dollars) or 4100 (cents). Tool always sends cents to publicAPI.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
companyCurrencyIdYesCompany currency ID (required)
companyGatewayIdYesCompany gateway ID (required)
detailYesLine items (required, at least one). Each: amount as '41.00' (dollars) or 4100 (cents). Tool always sends cents to publicAPI. description (max 255), qty
customerIdYesCustomer ID (required)
customerEmailNoCustomer email (max 45)
customerNameNoCustomer name (max 45)
customerPhoneNoCustomer phone (max 45)
paymentMethodIdYesPayment method ID (required)
customerPaymentMethodIdNoCustomer payment method ID
paymentTypeNoofflinePaymentProvider, thirdPartyPaymentProvider, walletPaymentProvider, or otherPayment
dateDueYesDue date (valid date). Required.
dateFromYesPeriod from (valid date). Required.
dateToYesPeriod to (valid date). Required.
billingAddressNoOptional. If provided: contactName, street1, city, zip, countryCode (ISO 3166-1 alpha-2 country code, e.g. ES, AR, MX), type (residential|commercial)
shippingAddressNoOptional. Same shape as billingAddress
shippingAmountNoShipping amount in CENTS
termsNoTerms (max 200)
commentsNoComments (max 200)
Behavior3/5

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

With no annotations, the description carries the transparency burden. It discloses unit handling ('Tool always sends cents to publicAPI') but omits other behavioral traits like idempotency, error handling, or side effects.

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 description is a single paragraph that efficiently conveys purpose and parameters. It is front-loaded but could be more structured (e.g., using bullet lists). No redundant sentences.

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?

Given 18 parameters, nested objects, and no output schema, the description adequately covers required/optional, constraints, and unit behavior. It lacks response details but that's acceptable without an output schema.

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%, baseline 3. The description adds value by grouping required/optional, specifying max lengths, ISO country code, and valid enumeration values (e.g., paymentType, type), and clarifying amount unit conversion.

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 clearly states 'Create an invoice' and specifies the HTTP method 'POST /invoices'. It lists required and optional parameters, distinguishing it from siblings like charge_invoice or update_invoice.

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?

The description provides no guidance on when to use this tool versus alternatives (e.g., charge_invoice, create_subscription). No explicit context or exclusions are given, leaving the agent to infer appropriateness.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/rhinosaas/rebillia-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server