Read a MEGA text or PDF file
mega_read_fileDownload and return text contents of a file from MEGA. PDFs are automatically extracted to text; binary files are rejected.
Instructions
Download and return the text contents of a file. PDFs are extracted to text automatically. Provide either a path within a folder link, or a direct file link. Other binary files are rejected. Text reads are capped at MEGA_MAX_READ_BYTES; PDFs at MEGA_MAX_PDF_BYTES.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | File path within the folder link, e.g. 'notes/todo.md'. | |
| link | No | MEGA link: a folder link (with `path`) or a direct file link. | |
| maxBytes | No | Override max bytes to read (default 2000000). |