Skip to main content
Glama

discard_envelope

Discard draft digital signature envelopes when deletion permissions are unavailable. This tool moves envelopes to a discarded state as an alternative to permanent deletion.

Instructions

Discard a draft envelope. Moves it to discarded state. Use this instead of delete when the API key lacks ROLE_ENVELOPE_DELETE.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
envelopeIdYesEnvelope UUID

Implementation Reference

  • The core implementation of the discard_envelope operation that makes the API call.
    export function discardEnvelope(creds, envelopeId) {
      return apiCall('POST', `/api/envelopes/${envelopeId}/discard`, creds);
    }
  • src/index.js:295-309 (registration)
    The MCP tool registration for 'discard_envelope', wrapping the api.discardEnvelope function.
    server.tool(
      'discard_envelope',
      'Discard a draft envelope. Moves it to discarded state. Use this instead of delete when the API key lacks ROLE_ENVELOPE_DELETE.',
      {
        envelopeId: z.string().describe('Envelope UUID'),
      },
      async ({ envelopeId }) => {
        try {
          const data = await api.discardEnvelope(creds, envelopeId);
          return result(data);
        } catch (err) {
          return errorResult(err);
        }
      }
    );
Behavior4/5

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

With no annotations provided, the description carries the full burden and effectively discloses key behavioral traits: it's a mutation operation (discarding), specifies the state change (moves to discarded), and mentions permission constraints (API key lacking ROLE_ENVELOPE_DELETE). It doesn't cover rate limits or error handling, but provides solid context for a single-param tool.

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 front-loaded with the core action, uses two efficient sentences with zero waste, and every part (purpose, state change, usage guideline) earns its place without redundancy.

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?

For a mutation tool with no annotations and no output schema, the description is quite complete: it explains what the tool does, when to use it, and permission constraints. It could mention what 'discarded state' entails or error cases, but covers the essentials well given the simplicity.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema already documents the 'envelopeId' parameter as an 'Envelope UUID'. The description doesn't add any additional meaning or context about the parameter beyond what the schema provides, meeting the baseline for high coverage.

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 specific action ('Discard a draft envelope') and the resource ('envelope'), distinguishing it from sibling tools like 'delete_envelope' by specifying it moves the envelope to a discarded state rather than deleting it.

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?

It explicitly provides when to use this tool ('Use this instead of delete when the API key lacks ROLE_ENVELOPE_DELETE'), offering clear guidance on alternatives and prerequisites based on permissions.

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/davidsimoes/digisign-mcp'

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