Skip to main content
Glama

get_cost_type

Read-onlyIdempotent

Retrieves a cost type by its ID from OpenProject's read-only API, providing cost type details when no collection endpoint exists.

Instructions

Get a cost type by id.

Cost types are entirely read-only in OpenProject's API (Community Edition) -- there is no create/update/delete endpoint, and no collection GET either (no list_cost_types tool exists because the endpoint does not exist upstream).

Input Schema

NameRequiredDescriptionDefault
cost_type_idYes

Output Schema

NameRequiredDescriptionDefault
idYes
nameYes
unitYes
is_defaultYes
unit_pluralYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.4.0

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/non-destructive, but the description adds genuinely new context: the entire cost-type resource is immutable in the upstream API, not just this call, and there is no collection endpoint. That scope information is not derivable from the annotations.

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 core action is front-loaded in the first sentence, and the second paragraph is short and purposeful, preempting a likely wrong instinct (searching for a list tool). The parenthetical "(no list_cost_types tool exists because the endpoint does not exist upstream)" is slightly redundant but earns its place as a guardrail.

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?

An output schema exists so return values need no explanation, and annotations cover the safety profile; the description fills the remaining conceptual gap about the resource's immutability. Only the provenance of cost_type_id is unaddressed, a minor omission for a one-parameter lookup.

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 coverage is 0% for the single cost_type_id parameter, and the description adds only "by id" — no format, range, or where to source a valid ID. With one required parameter, the description should compensate more than a bare restatement of the name.

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?

States a specific verb and resource ("Get a cost type by id") and goes further by explaining why apparent siblings are absent: cost types are read-only with no collection GET, so no list_cost_types exists. An agent can immediately tell this is a single-resource lookup, not a list or mutation.

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?

Explicitly rules out create/update/delete and list variants, preventing the agent from hunting for nonexistent endpoints or attempting writes. It stops short of saying where a valid cost_type_id comes from (e.g. via get_work_package_costs_by_type), which would complete the routing guidance.

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