Skip to main content
Glama

Update work package relation

update_work_package_relation
Idempotent

Update an existing work package relation by changing its type, lag, or description. Adjust scheduling gaps or correct link types on the fly.

Instructions

Change an existing relation's type, lag or description.

Use it to widen the gap between a predecessor and its successor, to correct a link that was created with the wrong type, or to explain why two work packages are connected. Returns the updated relation.

Pitfalls. At least one of type, lag or description must be given. Relations carry no lock version, so this is a plain overwrite with no conflict detection — a concurrent edit is silently replaced; re-read the relation if that matters. The two work packages cannot be changed here: delete the relation and create a new one instead. Raising the lag on a follows relation reschedules the successor, so dates can move.

Cross-references: create_work_package_relation makes one; delete_work_package_relation removes it; get_work_package(include=['relations']) lists the ids.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
lagNoNew lag in working days; valid only while the relation is 'follows' or 'precedes'. Omit to leave it untouched, pass 0 to remove an existing lag. When lag is given without type, the current type is read first and a lag on a non-scheduling relation is refused before any write.
typeNoNew relation type. Omit to keep the current one. Switching to or from 'follows'/'precedes' changes whether the relation schedules dates.
descriptionNoNew note for the relation. Omit to leave it untouched; pass an empty string to clear it.
relation_idYesId of the relation to change. It comes from create_work_package_relation or get_work_package(include=['relations']) — it is not a work package id.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNoRelation id. Pass it to update_work_package_relation or delete_work_package_relation — it is not a work package id.
lagNoWorking days kept between the predecessor and the successor. Only follows/precedes relations carry one; null everywhere else.
typeNoRelation type as OpenProject stored it, read from the 'from' work package (e.g. 'follows' means 'from' is scheduled after 'to').
descriptionNoFree-text note stored on the relation; null when unset.
reverse_typeNoThe same relation read from the 'to' work package: 'follows' <-> 'precedes', 'blocks' <-> 'blocked', 'relates' <-> 'relates'.
to_work_packageNoWork package the relation points to.
from_work_packageNoWork package the relation starts at.
Behavior5/5

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

The description adds substantial behavioral context beyond annotations, including the plain-overwrite/no-conflict-detection behavior, the silent replacement of concurrent edits, and the rescheduling side effect of raising lag. Annotations only hint at idempotency and non-read-only, so this fills the gap.

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 well-structured with a clear opening line, a 'Use it to' section, pitfalls, and cross-references. It is front-loaded with the purpose and each sentence adds value. Despite length, it remains focused and readable.

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 tool with 4 parameters and an output schema, the description covers all critical aspects: what can be updated, what cannot be changed, concurrency behavior, side effects, and alternatives. The existing output schema covers return values, so no further explanation is needed.

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 100%, so parameter semantics are already strong. The description adds the runtime constraint that at least one of type, lag, or description must be given, and notes the scheduling implication of 'follows'/'precedes'. This goes beyond what the schema states.

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's function: 'Change an existing relation's type, lag or description.' It uses a specific verb and resource, and distinguishes itself from siblings by noting that the two work packages cannot be changed here and by cross-referencing create/delete relation tools.

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 provides explicit use cases ('widen the gap... correct a link... explain why two work packages are connected'), a clear exclusion ('The two work packages cannot be changed here'), and cross-references to alternative tools (create/delete/get). It also warns about the at-least-one-field requirement.

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/kar-thik/openproject-mcp'

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