Skip to main content
Glama

decline_share

DestructiveIdempotent

Decline a pending share offered to you. This deletes direct shares, hides group shares, and removes federated shares (except federated group shares).

Instructions

Decline a share offered to the current user that is waiting to be accepted.

Declining a share made directly to the user deletes it, so the owner has to share again to offer it again. A declined group share is only hidden from this user: Nextcloud keeps it in list_pending_shares (marked declined) and accept_share can still take it. A declined federated share is removed and the other server is told, except for a federated group share, which Nextcloud keeps offering (under a new id once the user had accepted it before).

Args: share_id: The pending share's id from list_pending_shares, as a string (federated share ids can be too long for a JSON number). federated: True for a federated share from another server (federated: true in list_pending_shares).

Returns: Confirmation message.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
share_idYes
federatedNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.9.0

TDQS

A4.7/5.0
Behavior5/5

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

Annotations only declare destructive/idempotent/not-read-only; the description goes well beyond by explaining per-type consequences: direct shares are deleted and must be re-offered, group shares are only hidden and still viewable/acceptable, federated shares are removed and the remote server notified. This is exactly the contextual detail annotations cannot convey.

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?

Front-loaded with the core action, then the branches. The federated-group-share parenthetical is dense but informative rather than redundant, though it is the longest sentence and slightly testing readability.

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?

Covers the action, the source of its input, all three behavioral branches, and the two parameters, and an output schema exists so the terse 'Confirmation message' return note suffices. Nothing an agent needs to call it correctly is missing.

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?

With 0% schema coverage for two parameters, the description fully compensates: share_id is the id from list_pending_shares and must be passed as a string because federated ids can overflow a JSON number, and federated flags a share from another server as reported in list_pending_shares. Both parameters are meaningful and unambiguous.

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?

Specific verb+resource with scope: 'Decline a share offered to the current user that is waiting to be accepted.' The agent can distinguish this from accept_share and delete_share without opening any schema.

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?

It situates the tool in the pending-share workflow (share_id comes from list_pending_shares) and names accept_share as the surviving alternative for declined group shares, but never states an explicit 'use this instead of delete_share when...' rule. Clear context, no explicit exclusions.

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

Deploy Server

Other Tools