attach_link
Attach an external URL as a zero-byte link, either inside a library (libraryId) or on a task (taskId), exactly one of the two. With libraryId the link becomes a WorkspaceDocument in that library; provider is one of MIRO, FIGMA, NOTION, CONFLUENCE, GOOGLE_DOCS, EXCALIDRAW, OTHER_LINK and url must be http(s); requires project.content.create on the library's project (Viewers are read-only). With taskId the link is the same one a task's Attachments "Add link" makes in the web app: it lands in the project's Project Documents folder and lists with the task's linked files. provider is one of MIRO, FIGMA, NOTION, CONFLUENCE, GOOGLE_DOCS, EXCALIDRAW, OTHER_LINK, SHAREPOINT, MICROSOFT_DRIVE, url must be https, a SHAREPOINT link must be on a SharePoint Online host and a MICROSOFT_DRIVE link on SharePoint Online or personal OneDrive, and those two need a plan with Microsoft files. Linking to a task is available while Onplana has task links turned on, and follows the task attachment rule (project contributors, managers, and the task's assignee or collaborators). The same address already on the task returns the existing link with created: false.
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": {
"provider": "<provider>",
"name": "<name>",
"url": "<url>"
},
"name": "attach_link"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | 1..2048 chars. Library: http(s). Task: https. | |
| name | Yes | Library: 1..200 chars. Task: 1..255 chars. | |
| taskId | No | The task to link the URL to. Give this or libraryId. | |
| provider | Yes | ||
| libraryId | No | The library to add the link to. Give this or taskId. | |
| externalFileId | No | Task links only, optional: the Microsoft Graph drive item id of a SharePoint or OneDrive file. |