Add Attachment Tool
add_attachmentAttach links, HTML presentations, images, or PDFs to a project or task so colleagues open them from the project page, or pass a public URL for larger files.
Instructions
Attaches to a project a link (Figma, Drive, Behance: pass url and title) or a file (an HTML presentation, an image, a PDF: pass filename, plus text for a text file or base64 for a binary one; up to 10 MB through the conversation). For a file that is already online (a public image, a PDF, a Google Drive file shared with anyone who has the link), pass source_url instead: cemainou downloads it itself, so a large screenshot does not have to travel through the conversation. Colleagues open it from the project page; HTML opens isolated from the app. With client_visible, the project's client sees it too (a deliverable, a final PDF), only when the person asks for that. When the task already has a file this one is a newer version of (the same name, a new archive or export of the same work), ask the person once whether it replaces it and pass replaces with its id: the new version takes its place instead of piling up, so whoever takes the task over finds one final file. Only when the person asks or agrees. Never secrets or files with credentials. Limits per file: 10 MB as text or base64, 20 MB with source_url. For a larger file, or any file on this machine when you have a shell, use upload_link: it gives an upload command (curl), up to 20 MB per file, nothing through the conversation.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "add_attachment"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | For a link: the address (https://...). | |
| repo | No | The git remotes of the working directory (git remote -v). | |
| role | No | What it is, when clear: demo (a live demo or prototype: pinned at the top of the project and on its card), brief, design (mockups), presentation, document, contract (contracts, invoices, papers), source (source files), media (photos, video). | |
| task | No | A task number, to attach it to that task (e.g. a screenshot for a bug) instead of the project. | |
| text | No | The content of a text file (HTML, Markdown, SVG, CSV, TXT). | |
| title | No | What it is, e.g. "Presentation for the client". Required for a link; for a file, the name is used if left out. | |
| base64 | No | The content of a binary file (PNG, JPG, PDF), base64-encoded. | |
| project | No | Project slug or name, if not this session's. | |
| session | No | This session's id, from the cemainou line at the start of the session. The session's project wins over the repo. | |
| filename | No | For a file: its name with the extension, e.g. "presentation.html" or "logo.png". | |
| replaces | No | A task file's id (from start_task: those with can_replace): the new file or link takes its place and the old one is removed, in one step. Use it when a file changed, instead of adding one more. Only files you added, only while the task is open. | |
| source_url | No | Instead of text / base64: a public https link to the file (an image, a PDF, a text file; a Google Drive "share" link works if shared with anyone who has the link). cemainou downloads it, up to 10 MB. filename is optional (else from the link). | |
| client_visible | No | true: the project's client sees it too (only on a project visible to its client, only when the person asks). Not for task files. |