Skip to main content
Glama

Change the diary

diary_write
Destructive

Write or remove one day's entry in a trip's diary; owner only. put creates the day's entry or replaces it whole: entry.public defaults to false when omitted, so leave it out only to take an entry off the public share page. A date outside the trip's dates is validation_failed. delete removes the day's entry; deleting a day that has none succeeds and changes nothing. Both take an optional expectedUpdatedAt (the entry's updatedAt as you read it): if the entry changed or was removed since, nothing is written and the answer is stale_write with the current version (actual, or null when the day has no entry). To write a day you saw empty without overwriting an entry someone else wrote meanwhile, put with expectedAbsent: true instead (never together with expectedUpdatedAt, which is bad_request); a day that has an entry by then answers stale_write with its version as actual. A trip's diary holds at most one entry per calendar day of the trip, addressed by the trip id and the date (YYYY-MM-DD, the trip's local calendar date, between the trip's startDate and endDate inclusive). An entry's body is plain text (1-8000 characters, not only whitespace; line breaks are kept). public says whether the entry shows on the trip's public share page; the owner and linked crew see every entry either way. IDs are 6-character case-sensitive alphanumeric strings. Timestamps are UTC ISO 8601. Distances are integer meters. Durations are integer seconds.

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.8/5.0
Behavior5/5

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

Annotations supply only destructiveHint=true; the description carries the real behavioral burden and does so well: delete is idempotent (deleting a day with no entry succeeds and changes nothing), dates outside the trip range yield validation_failed, and optimistic-concurrency failures return stale_write with `actual` (or null). It also discloses the public-visibility consequence and who can still see private entries.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The operation-specific content is front-loaded and dense with no wasted clauses, but the trailing block ('IDs are 6-character... Distances are integer meters. Durations are integer seconds.') is generic boilerplate, and distances/durations are irrelevant to a diary entry with no such parameters. That is a real, if small, cost in a long description.

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?

For a two-variant mutation tool with no output schema, the description covers the action split, validation failures, concurrency failure modes including the response field name, visibility semantics, and body constraints. An agent could call this correctly on the first attempt without further clarification.

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 coverage is high, so the structural constraints are already given, but the description adds meaning the schema cannot express: what `expectedUpdatedAt` is compared against and what happens on mismatch, the mutual exclusion of `expectedAbsent` with it, and the non-obvious default `public = false` with its share-page consequence. That is genuine semantic value beyond pattern/const declarations.

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?

Opens with a specific verb pair and resource: 'Write or remove one day's entry in a trip's diary; owner only.' That immediately distinguishes it from the read sibling diary_read and states the access scope (owner only) in the same clause.

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?

Explicitly routes between the two actions ('put' creates/replaces whole, 'delete' removes) and between the two concurrency modes: use 'expectedAbsent: true' to write a day seen empty, never together with 'expectedUpdatedAt' which is bad_request. It also gives the condition for omitting 'public'. There is essentially no inference left to the agent.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources