Skip to main content
Glama

project_subtask_hours

Get total sub-task hours for a project in one call, with server-side filters for closed stages, single assignee, and custom periods. Sums delivery, allocated, and effective hours—no pagination needed.

Instructions

Total sub-task hours for one project, filtered server-side, in ONE call.

Sums delivery/allocated/effective hours over the project's sub-tasks (project.task with parent_id set). Use this instead of paginating project.task through search_read — especially for the "exactly one assignee" condition, which Odoo domains cannot express.

Args: project_id: project.project id (int, not name). only_closed_stages: Count only tasks whose stage name is in closed_stage_names (default False). Cancelled tasks DO count toward delivery hours (business decision 2026-07-15). closed_stage_names: Stage names treated as closed (default ["Done", "Cancelled", "Delivered"]). single_assignee_only: Count only tasks with exactly 1 user in user_ids (default False). group_by_month: Also bucket by local-time month of date_end; tasks without date_end are excluded from the buckets and summarised under "no_date_end" (default False). periods: Optional list of {"date_from": "YYYY-MM-DD", "date_to": "YYYY-MM-DD"} ranges applied to date_end, OR-combined (matching per-budget-period filtering, not a union). Empty/omitted = no date filter. timezone_offset: UTC offset for dates (default 7).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
periodsNo
project_idYes
group_by_monthNo
timezone_offsetNo
closed_stage_namesNo
only_closed_stagesNo
single_assignee_onlyNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It does an excellent job by disclosing nuanced behaviors such as 'Cancelled tasks DO count toward delivery hours (business decision 2026-07-15)' and that periods are 'OR-combined (matching per-budget-period filtering, not a union)'. However, it does not mention potential edge cases like error handling for invalid project_id, which would make it fully transparent.

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 description is front-loaded with a one-sentence summary, then provides usage guidance and a structured Args list. Every sentence earns its place, and the length is justified given the 7 parameters. No fluff or repetition.

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?

Given the tool's complexity (7 parameters), lack of annotations, and presence of an output schema, the description is remarkably complete. It covers all parameter semantics, usage context, and important edge cases like the OR-combining of periods and the 'no_date_end' bucket, leaving no significant gaps.

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%, so the description must compensate, and it does thoroughly. The 'Args' section explains every parameter in plain language, including types, defaults, and subtle semantics (e.g., 'tasks without date_end are excluded from the buckets and summarised under "no_date_end"'). This goes far beyond the bare schema.

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 uses a specific verb ('sums') and resource ('total sub-task hours for one project'), and explicitly differentiates itself from the sibling tool search_read by saying 'use this instead of paginating project.task through search_read'. This makes the tool's purpose unmistakable.

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

Usage Guidelines5/5

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

The description explicitly states when to use this tool instead of alternatives: 'Use this instead of paginating project.task through search_read — especially for the "exactly one assignee" condition, which Odoo domains cannot express.' It also notes the server-side filtering and single-call behavior, providing clear guidance.

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/minhhq-a1/odoo-pulse'

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