Skip to main content
Glama

ERP: Attach document

erp_attach_document

Attach one of the caller's own documents to an assignment. The document is COPIED into the company's storage under that task — the personal original stays personal and untouched, and the copy is visible to everyone who can see the task. Name the document by its id from list_documents; upload it first with upload_document_base64 if it is not there yet. CONFIRMATION: this tool is PROPOSED, never performed directly. You get status='confirmation_required' with an action_id and a plan_token, and the write happens only after confirm_action.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "assignment_id": "<assignment_id>",
      "project_id": "<project_id>",
      "document_id": "<document_id>"
    },
    "name": "erp_attach_document"
  }
}

Input Schema

NameRequiredDescriptionDefault
project_idYes
document_idYes
assignment_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Annotations only declare that this is a non-read-only, non-destructive, closed-world write. The description adds the important behavior: the file is copied into company storage, the personal original is left untouched, and the copy becomes visible to everyone with access to the task. It also discloses the confirmation protocol, including the status value, action_id, and plan_token.

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?

The copy semantics and prerequisites come first, and the confirmation block is clearly labeled and easy to scan. The only slight redundancy is 'the personal original stays personal and untouched,' which restates the preceding clause.

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?

With no output schema and minimal annotations, the description still covers the mutation's effect, the visibility change, and the deferred-execution model, which are what an agent needs in order to call it safely. It omits error cases and permission requirements, but otherwise it is sufficient for a 3-parameter tool.

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 coverage is 0%, so the description must explain the parameters, and it only explains document_id by pointing to list_documents and the upload prerequisite. project_id and assignment_id remain undefined, and there is no explanation of whether project_id must match the assignment's project or of ID formats.

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 gives a specific verb and resource pair: 'Attach one of the caller's own documents to an assignment.' It also implicitly separates this tool from the upload and listing siblings by describing the copy semantics and naming the target object (assignment/task).

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 routes the agent: get the document id from list_documents, or run upload_document_base64 first if the document does not exist yet. It also states the required confirm_action follow-up, so the when and how chain is fully specified.

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