Skip to main content
Glama

add_line

Add a line to a one2many or many2many list field, fill its cells in order, and get invalid required cells listed for correction.

Instructions

Add a line to a one2many/many2many list field (e.g. order_line) and fill it: click "Add a line", set each cell in the given order (put the main many2one such as product_id first), validate the row. If required cells are missing the row stays in edition and invalid_cells lists them (fill them with set_field(..., line="editing", list_field=...)). Falls back to the popup form when the list is not editable inline. create: label of the add link when there are several.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fieldYes
scopeNoauto
createNo
valuesYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

No annotations are provided, so the description carries the burden. It details the flow (click add, set cells in order, validate), mentions behavior when required cells are missing (invalid_cells), and fallback to popup. It also explains the 'create' parameter. This is transparent about its behavior, though it could also mention, for example, potential side effects.

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 description is dense but informative, covering key aspects in a few sentences. It could be slightly more structured (e.g., separate usage and parameters) but is far from verbose.

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?

Given there is an output schema (though not provided here), the description covers the essential behavior, edge cases (missing cells fallback), and parameter hints. It might be missing details on 'scope' and 'values' structure, but it's sufficient for a complex tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description must compensate. It explains 'field' and 'values' implicitly, mentions 'create' as the label for the add link. It doesn't describe 'scope' or the structure of 'values' in detail, but it provides enough context for an agent to infer usage.

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 clearly states the tool adds a line to a one2many/many2many list field (e.g., order_line) and fills it. It distinguishes from siblings like delete_line by focusing on adding, and provides concrete examples.

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 explains when to use it (adding lines) and gives a fallback behavior (popup form) when inline editing is not possible. However, it doesn't explicitly contrast with similar tools like set_field, but it's clear enough.

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