{"id":30770501,"url":"https://github.com/sanand0/gmailmbox","last_synced_at":"2025-09-04T23:08:48.537Z","repository":{"id":307467665,"uuid":"850334670","full_name":"sanand0/gmailmbox","owner":"sanand0","description":"Download mails from GMail into .mbox via API","archived":false,"fork":false,"pushed_at":"2024-09-19T03:58:40.000Z","size":3,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-30T13:54:53.842Z","etag":null,"topics":["tool"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sanand0.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2024-08-31T13:42:00.000Z","updated_at":"2025-04-17T07:01:22.000Z","dependencies_parsed_at":"2025-07-31T13:39:02.432Z","dependency_job_id":"a6677690-9efd-4dcc-903f-81b5a85b88d1","html_url":"https://github.com/sanand0/gmailmbox","commit_stats":null,"previous_names":["sanand0/gmailmbox"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/sanand0/gmailmbox","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sanand0%2Fgmailmbox","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sanand0%2Fgmailmbox/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sanand0%2Fgmailmbox/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sanand0%2Fgmailmbox/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sanand0","download_url":"https://codeload.github.com/sanand0/gmailmbox/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sanand0%2Fgmailmbox/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273685604,"owners_count":25149722,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-04T02:00:08.968Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["tool"],"created_at":"2025-09-04T23:08:43.425Z","updated_at":"2025-09-04T23:08:48.526Z","avatar_url":"https://github.com/sanand0.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GMail Sync\n\nThis script lets me sync GMail to .mbox via the API (not IMAP), allowing me to analyze it offline.\n\n## Usage\n\nClone this repository:\n\n```bash\ngit clone https://github.com/sanand0/gmailmbox.git\ncd gmailmbox\n```\n\nOn Google Cloud Console, download `credentials.json` into `gmailmbox/`:\n\n- [Create a new project](https://developers.google.com/workspace/guides/create-project)\n- [Enable the Gmail API](https://support.google.com/googleapi/answer/6158841)\n- [Create OAuth2 Client ID](https://developers.google.com/workspace/guides/create-credentials) for a Desktop app\n- Download the JSON as `credentials.json`\n\n\u003c!--\nHere is my link: https://console.cloud.google.com/apis/credentials?authuser=2\u0026project=straive-internal-apps\n--\u003e\n\nThen install and run:\n\n```bash\npython gmailmbox.py --mbox emails.mbox --q \"in:anywhere -in:spam -in:trash -invite\"\n# or\nuv run gmailmbox.py --mbox emails.mbox --q \"in:anywhere -in:spam -in:trash -invite\"\n\n# To refresh only new emails:\nuv run gmailmbox.py --mbox emails.mbox --q \"in:anywhere -in:spam -in:trash -invite\" --update\n```\n\nThis will sync all emails that match the query to the .mbox file.\n\nParameters:\n\n- `--mbox`: Path to the .mbox file (default: \"emails.mbox\")\n- `--q`: Gmail search query (default: \"in:anywhere -in:spam -in:trash -invite\")\n- `--update`: Only update new emails (default: False)\n\n\u003c!--\n\nIn my laptop, I run:\n\ncd /github/sanand0/gmailmbox\nuv run gmailmbox.py --mbox C:/Anand/Mail/straive.mbox  --update\n--\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsanand0%2Fgmailmbox","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsanand0%2Fgmailmbox","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsanand0%2Fgmailmbox/lists"}