Skip to main content
Glama
Fakturia API MCP

Fakturia API MCP

by edjufy

calculate_subscription_item_price

Calculates a subscription item's price for a period and quantity, including custom pricing, quantity tiers, and pro-rating, so you can preview customer charges without creating an invoice.

Instructions

Calculate the price of a subscription item for a given period and quantity. Performs a price calculation taking into account the item catalog price, any custom prices, quantity tiers, and pro-rating for partial periods. Useful for previewing what a customer would be charged without actually creating an invoice.

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": {
      "contractNumber": "<contractNumber>",
      "subscriptionItemUUID": "<subscriptionItemUUID>"
    },
    "name": "calculate_subscription_item_price"
  }
}

Input Schema

NameRequiredDescriptionDefault
quantityNoThe quantity to calculate the price for. If omitted, the subscription item's configured quantity is used.
contractNumberYesThe contract number that the subscription item belongs to.
performanceDateEndNoThe end date of the billing period in YYYY-MM-DD format. Used for pro-rating calculations.
performanceDateStartNoThe start date of the billing period in YYYY-MM-DD format. Used for pro-rating calculations.
subscriptionItemUUIDYesThe unique UUID identifier of the subscription item to calculate the price for.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.4

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations provided, the description carries the full burden. It does signal non-mutation ('without actually creating an invoice'), which is the most important behavioral fact, but says nothing about rounding/currency behavior, permissions required, cost or rate limits, or what happens when the item has no catalog price.

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?

Three tight sentences with the core purpose front-loaded, followed by mechanism and then use case. Nothing is redundant or padded; a slightly clearer return-value hint could have been added without bloat.

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 pure calculation tool with a fully described schema and no output schema, the description covers what it computes, what feeds the computation, and why to call it. The main residual gap is the shape of the result (a single amount? a breakdown?), but a preview price is reasonably self-evident.

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%, so all five parameters are already documented, including the fallback behavior when quantity is omitted. The description adds context about why the dates matter (pro-rating for partial periods) and that quantity tiers affect the result, but does not add format or constraint detail beyond the schema.

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 opens with a specific verb and resource: 'Calculate the price of a subscription item for a given period and quantity.' It also enumerates the inputs to the calculation (catalog price, custom prices, tiers, pro-rating), so an agent knows exactly what work is performed. It doesn't name a sibling outright, but 'without actually creating an invoice' implicitly separates it from the create_*_price tools.

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 a concrete use case – previewing what a customer would be charged – which is the main reason to pick this over a price-creating tool. It does not state exclusions or preconditions (e.g. that the contract must be active, or that it is purely a read-side simulation), so there is some room left to inference.

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