Skip to main content
Glama
aerolalit

Pane

Upsert Record

upsert_record
DestructiveIdempotent

Add a row to a pane's record collection, or return the existing row if the record key already exists. Use to insert todos, line items, comments, and more.

Instructions

Create a row in a pane's record collection, or return the existing row if record_key is already present (deduped:true). Use to add a todo, a line item, a comment, etc. The collection must be declared in the pane's record schema with 'agent' allowed to write. If you're still designing the pane, call get_skill first for the records-vs-events decision and the x-pane-collections schema grammar. Returns { record, deduped }.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataYesThe record body — any JSON value valid against the collection schema.
pane_idYesThe pane id.
collectionYesThe record collection name.
record_keyNoOptional stable key. Reusing an existing key returns the existing row (deduped:true).
Behavior5/5

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

Beyond annotations (idempotent, destructive), the description reveals the deduped return flag, the prerequisite of collection write permission, and the exact return shape { record, deduped }. No contradictions 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?

Four sentences with no superfluous words. First sentence states core behavior, second lists use cases, third gives prerequisite call, fourth specifies return value. Front-loaded and efficient.

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 no output schema, the description fully covers input requirements, dedup logic, preconditions (get_skill, collection write permission), and return shape. Siblings are many, but the description sufficiently differentiates the upsert behavior.

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 covers all parameters (100% coverage), so baseline is 3. The description adds value by explaining record_key's deduplication role and the data parameter as 'record body', providing context not explicit in schema descriptions.

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 defines the tool as an upsert operation: create a row or return existing if record_key is present (deduped:true). This distinguishes it from sibling tools like create_record (plain insert) and delete_record (removal).

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 advises when to use (add a todo, line item, comment) and when not to (if still designing, call get_skill first for records-vs-events decisions). It could explicitly contrast with create_record or delete_record, but the guidance is clear and helpful.

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/aerolalit/paneui'

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