{"id":42667112,"url":"https://github.com/munir131/attachment-downloader","last_synced_at":"2026-01-29T10:10:57.202Z","repository":{"id":25423715,"uuid":"103964743","full_name":"munir131/attachment-downloader","owner":"munir131","description":"Gmail attachment downloader","archived":false,"fork":false,"pushed_at":"2026-01-02T15:45:28.000Z","size":218,"stargazers_count":39,"open_issues_count":9,"forks_count":14,"subscribers_count":6,"default_branch":"main","last_synced_at":"2026-01-08T02:42:51.134Z","etag":null,"topics":["attachment","download","files","free","from","gmail","labels","to"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/munir131.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2017-09-18T16:35:52.000Z","updated_at":"2026-01-02T15:32:40.000Z","dependencies_parsed_at":"2026-01-02T17:06:07.647Z","dependency_job_id":null,"html_url":"https://github.com/munir131/attachment-downloader","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/munir131/attachment-downloader","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/munir131%2Fattachment-downloader","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/munir131%2Fattachment-downloader/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/munir131%2Fattachment-downloader/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/munir131%2Fattachment-downloader/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/munir131","download_url":"https://codeload.github.com/munir131/attachment-downloader/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/munir131%2Fattachment-downloader/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28875450,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-29T09:47:23.353Z","status":"ssl_error","status_checked_at":"2026-01-29T09:47:19.357Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["attachment","download","files","free","from","gmail","labels","to"],"created_at":"2026-01-29T10:10:55.953Z","updated_at":"2026-01-29T10:10:57.186Z","avatar_url":"https://github.com/munir131.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Gmail Bulk Attachment Downloader\n\n**Note:** This application requires Node.js version 22 or higher, or Bun.js version 1.0.0 or higher.\n\nCurrently Gmail does not provide a way to download attachments from multiple emails in a single click. This utility allows you to do just that.\n\n## Setup\n\n1. Enable the GMAIL API and get `credentials.json` from [Google Developers Console](https://developers.google.com/gmail/api/quickstart/nodejs).\n2. Save `credentials.json` in the root folder of the project.\n3. Clone the project:\n   ```bash\n   git clone https://github.com/munir131/attachment-downloader\n   ```\n4. Install dependencies:\n   \n   **Using npm (Node.js):**\n   ```bash\n   npm install\n   ```\n   \n   **Using bun:**\n   ```bash\n   bun install\n   ```\n\n## Usage\n\n### Interactive Mode\n\nSimply run the program without arguments to start the interactive wizard:\n\n**Using Node.js:**\n```bash\nnode index.js\n```\n\n**Using bun:**\n```bash\nbun index.js\n```\n\nIt will ask you:\n1. Where to store files (default: `./files`)\n2. How to filter emails (by Label, From address, or All)\n\n### Automated / CLI Mode\n\nYou can run the program in non-interactive mode by providing arguments. This is useful for scripts or cron jobs.\n\n**Using Node.js:**\n```bash\nnode index.js [options]\n```\n\n**Using bun:**\n```bash\nbun index.js [options]\n```\n\n**Options:**\n\n| Option | Description | Example |\n|--------|-------------|---------|\n| `--from` | Download attachments from emails sent by a specific address | `--from \"example@gmail.com\"` |\n| `--label`| Download attachments from emails with a specific label | `--label \"Invoices\"` |\n| `--dir`  | Directory to save attachments (default: `./files`) | `--dir \"./downloads\"` |\n| `--fy`   | Organize downloaded files into folder structure by Financial Year | `--fy` |\n\n**Examples:**\n\nDownload all attachments from a specific sender:\n```bash\n# Using Node.js\nnode index.js --from \"boss@company.com\" --dir \"./work_docs\"\n\n# Using bun\nbun index.js --from \"boss@company.com\" --dir \"./work_docs\"\n```\n\nDownload files from a specific label organized by financial year:\n```bash\n# Using Node.js\nnode index.js --label \"Receipts\" --fy\n\n# Using bun\nbun index.js --label \"Receipts\" --fy\n```\n\n## Development\n\n### Testing\n\n**Using Node.js:**\n```bash\nnpm test\n```\n\n**Using bun:**\n```bash\nbun test\n```\n\n### Development Mode\n\n**Using Node.js:**\n```bash\nnpm run dev\n```\n\n**Using bun:**\n```bash\nnpm run dev:bun\n```\n\n## Binary Downloads\n\nFor convenience, pre-compiled binaries are available in the [GitHub Releases](https://github.com/munir131/attachment-downloader/releases) page. These binaries include all dependencies and don't require Node.js or Bun.js to be installed.\n\n### Available Binaries:\n- `attachment-downloader-linux-x64` - Linux x64\n- `attachment-downloader-macos-x64` - macOS x64  \n- `attachment-downloader-windows-x64.exe` - Windows x64\n\n### Using Binaries:\n\n1. Download the appropriate binary for your platform from the releases page\n2. Make the binary executable (Linux/macOS only):\n   ```bash\n   chmod +x attachment-downloader-linux-x64\n   ```\n3. Run the binary:\n   ```bash\n   # Linux/macOS\n   ./attachment-downloader-linux-x64 --help\n   \n   # Windows\n   .\\attachment-downloader-windows-x64.exe --help\n   ```\n\nAll command-line options work identically to the Node.js/Bun.js versions.\n\n### Building Binaries Locally:\n\nYou can also build binaries locally using Bun.js:\n\n```bash\n# Install Bun.js if not already installed\ncurl -fsSL https://bun.sh/install | bash\n\n# Install dependencies\nbun install\n\n# Build binary for current platform\nbun run build:binary\n\n# Build for all platforms (requires cross-compilation setup)\nbun run build:binary:all\n```\n\n## Bun.js Support\n\nThis project fully supports Bun.js as an alternative to Node.js. Bun.js offers:\n\n- **Faster installation times** with its built-in package manager\n- **Improved performance** due to its JavaScriptCore engine\n- **Native TypeScript support** (though this project uses JavaScript)\n- **Smaller bundle sizes** and faster startup times\n- **Binary compilation** for creating standalone executables\n\nAll features work identically whether using Node.js, Bun.js, or the pre-compiled binaries.\n\n## Contributors\n\nThanks to all the people who already contributed!\n\n\u003ca href=\"https://github.com/munir131/attachment-downloader/graphs/contributors\"\u003e\n  \u003cimg src=\"https://contrib.rocks/image?repo=munir131/attachment-downloader\" /\u003e\n\u003c/a\u003e\n\nMade with [contrib.rocks](https://contrib.rocks).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmunir131%2Fattachment-downloader","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmunir131%2Fattachment-downloader","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmunir131%2Fattachment-downloader/lists"}