Skip to main content
Glama

attach_sharepoint_document

Attach a SharePoint document to an Onplana project workspace as a LINK reference (externalProvider=SHAREPOINT). The file stays in SharePoint; Onplana stores only the URL + metadata. No file is downloaded or copied in V1 (security stance). Caller must have read access to the SharePoint site. siteId comes from list_sharepoint_sites; driveItemId, and driveId for a file outside the default library, come from list_sharepoint_files.

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": {
      "projectId": "<projectId>",
      "siteId": "<siteId>",
      "driveItemId": "<driveItemId>"
    },
    "name": "attach_sharepoint_document"
  }
}

Input Schema

NameRequiredDescriptionDefault
siteIdYes
driveIdNoSharePoint library id (from list_sharepoint_files) when the file is not in the default library of the site.
libraryIdNoOnplana document library in the project to attach into. Defaults to the first library of the project.
projectIdYes
driveItemIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / driveId
      Added value: +{
      +  "description": "SharePoint library id (from list_sharepoint_files) when the file is not in the default library of the site.",
      +  "type": "string"
      +}
    • addedInput schema / properties / libraryId / description
      Added value: +"Onplana document library in the project to attach into. Defaults to the first library of the project."
  2. Added

TDQS

A4.4/5.0
Behavior4/5

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

With annotations already covering safety (readOnly, destructive=false), the description still earns credit by disclosing the LINK-only security stance, that Onplana stores only URL + metadata, and that nothing is downloaded or copied in V1. It does not address what happens on a repeated attach (relevant since idempotentHint=false) or what the response returns, which keeps it from a 5.

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?

Four sentences, front-loaded with the operation and its linking semantics, then constraints, then ID sourcing. No restatement of the name and no filler; every sentence carries decision-relevant information.

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 5-parameter mutation with no output schema, it covers purpose, exclusivity (link, not copy), permissions, and provenance of the required IDs. Missing only edge behavior: duplicate attach handling and what is returned on success.

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?

At 40% schema coverage the description has to compensate, and it does for the three required-or-conditional IDs: it names the source tool for siteId, driveItemId, and the conditional driveId ('for a file outside the default library'). libraryId and projectId are left to the schema, so coverage is good but not complete.

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?

States a specific verb (attach), resource (SharePoint document), and target (Onplana project workspace) with the key mechanism spelled out: a LINK reference, externalProvider=SHAREPOINT, file stays in SharePoint. That mechanism detail is what separates it from upload_library_document or attach_file_from_url without the agent needing to compare schemas.

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?

Gives prerequisites (caller must have read access to the SharePoint site) and routes the agent to the two prerequisite tools that produce the required IDs: list_sharepoint_sites for siteId and list_sharepoint_files for driveItemId/driveId. It never states when NOT to use it (e.g. when the file should be copied into Onplana rather than linked), so it falls short of a 5.

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.