add_document_attachment
Attach a file to a Huly document by specifying teamspace, document, filename, and content type. Provide a local file path, remote URL, or base64-encoded data.
Instructions
Add an attachment to a Huly document. Convenience method that finds the document by teamspace and title/ID. Provide ONE of: filePath, fileUrl, or data.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | No | Base64-encoded file data (fallback for small files <10KB) | |
| pinned | No | Whether to pin the attachment (default: false) | |
| fileUrl | No | URL to fetch file from (for remote files) | |
| document | Yes | a string that will be trimmed | |
| filePath | No | Local file path to upload (preferred - avoids context flooding) | |
| filename | Yes | a string that will be trimmed | |
| teamspace | Yes | a string that will be trimmed | |
| contentType | Yes | a string that will be trimmed | |
| description | No | Attachment description |