Skip to main content
Glama
Pirainuthal

odoo-mcp-server

by Pirainuthal

Count Odoo records

count_records
Read-only

Count Odoo records matching a domain filter without transferring record data, enabling quick size checks before queries or updates.

Instructions

Count the records matching a domain (cheap; no data is transferred).

Input Schema

NameRequiredDescriptionDefault
modelYesTechnical model name, e.g. 'res.partner', 'sale.order', 'account.move'.
domainNoOdoo domain: a list of [field, operator, value] conditions, optionally combined with '&', '|', '!' in prefix notation. Conditions are AND-ed by default. Example: [["customer_rank", ">", 0], ["country_id.code", "=", "IN"]]. Omit or pass [] to match all records.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and openWorldHint=true, so the safety profile is covered. The description adds a genuine behavioral trait beyond them — that the call is cheap and transfers no record data — but says nothing about permissions, errors on invalid model names, or how an omitted domain affects results.

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?

A single front-loaded sentence with zero waste; the key verb and resource come first and the efficiency note is a compact qualifier. Nothing could be removed without losing information.

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 and the parameters are fully documented, so return values and input format needn't be explained. The remaining gap is minor: no note on what happens with an unknown model or which models are accessible, but an agent has what it needs to call it correctly.

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%, with both 'model' and 'domain' fully documented including operator syntax and the empty-domain behavior. The description mentions the domain concept but adds no syntax or format detail beyond the schema, so the baseline 3 applies.

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 gives a specific verb ('Count') and resource ('records matching a domain'), which is clearly distinguishable from search_records or read_record by the counting semantics. It does not explicitly name a sibling as the alternative, so it stops short of a 5.

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

Usage Guidelines3/5

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

The parenthetical '(cheap; no data is transferred)' implies you should reach for this when you only need a total rather than the records themselves, but the description never says 'use this instead of search_records when...'. Usage must be inferred from the efficiency hint rather than stated.

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