Skip to main content
Glama

create_cospend_bill

Create an expense bill in a Cospend project by specifying project, amount, payer, and members who share the cost. Returns the new bill's ID.

Instructions

Create a bill (expense) in a Cospend project. Requires PARTICIPANT access.

Args: project_id: String project id. what: Short description of the expense (e.g. "Pizza"). amount: Total amount paid. payer: Member id of the person who paid. payed_for: Non-empty list of member ids who share the cost. Cospend requires at least one ower per bill — passing [] raises ValueError (the server would reject it on create and silently no-op on update, so we reject it up front for both). date: Date string "YYYY-MM-DD". Defaults to today (UTC) if both date and timestamp are omitted; the underlying API requires one. timestamp: Alternative to date — Unix seconds. If both are set, the server uses timestamp. comment: Free-form longer note. category_id: Category id (see project's categories). Omit for uncategorized (id=0). payment_mode_id: Payment mode id (see project's paymentmodes). Omit for unset (id=0). repeat: Repetition mode: "n"=no repeat (default), "d"=daily, "w"=weekly, "b"=biweekly, "s"=semi-monthly, "m"=monthly, "y"=yearly. repeat_freq: Every N units (default 1). E.g. repeat="m", repeat_freq=3 means quarterly. repeat_until: Stop repeating after this date "YYYY-MM-DD". repeat_all_active: 0 (default) = repeat with the same owers, 1 = on each repetition use whoever is currently active.

Returns: JSON {"bill_id": } — the integer id of the new bill.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dateNo
whatYes
payerYes
amountYes
repeatNon
commentNo
payed_forYes
timestampNo
project_idYes
category_idNo
repeat_freqNo
repeat_untilNo
payment_mode_idNo
repeat_all_activeNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.7.0

TDQS

A4.8/5.0
Behavior5/5

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

Annotations only provide negative hints (not read-only, not idempotent, not destructive), so the description carries the behavioral burden. It discloses that an empty payed_for list raises ValueError and explains server-side behavior on create vs update, documents date/timestamp defaulting and precedence, and specifies the return value as JSON {"bill_id": <int>}. No contradiction with 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?

The purpose and permission are front-loaded, and the Args section is dense but purposeful given the 14-parameter surface. Every parameter gets a meaningful explanation, default, or constraint, with no filler or redundant prose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a write operation with 14 parameters, no schema descriptions, and sparse annotations, the description is complete. It covers prerequisites, edge cases, defaults, output shape, and client/server behavior, leaving no critical information missing for correct invocation.

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 description coverage is 0%, and the description compensates fully by documenting all 14 parameters. It provides formats for date and timestamp, enumerates repeat values, explains defaults, and clarifies cross-parameter constraints such as date/timestamp precedence and payed_for non-emptiness.

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 and resource: 'Create a bill (expense) in a Cospend project.' It also states the required access level, which immediately distinguishes this from sibling tools like get_cospend_bill, update_cospend_bill, and delete_cospend_bill.

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?

The description establishes clear context by stating the create action and the PARTICIPANT access requirement. It does not explicitly name alternatives or exclusions, but the purpose is unambiguous enough that an agent can identify when to use this tool versus update or delete siblings.

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