{"id":19272052,"url":"https://github.com/shockz-offsec/scraping-notion-backup","last_synced_at":"2025-06-25T23:38:34.862Z","repository":{"id":159441033,"uuid":"625346444","full_name":"shockz-offsec/Scraping-Notion-Backup","owner":"shockz-offsec","description":"This script automates the backup process of Notion data into Markdown and CSV formats, removing the need for tokens and private Notion APIs. It also removes AWS identifiers in the markdown files, folders, and internal references in the backup.","archived":false,"fork":false,"pushed_at":"2024-09-03T14:34:25.000Z","size":65,"stargazers_count":7,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-25T23:38:14.603Z","etag":null,"topics":["automation","background","backup","export","linux","local","markdown","notion","python","remover","selenium","web-scraping","windows"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/shockz-offsec.png","metadata":{"files":{"readme":"README.md","changelog":null,"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}},"created_at":"2023-04-08T20:38:20.000Z","updated_at":"2025-03-01T02:19:57.000Z","dependencies_parsed_at":"2024-01-21T23:59:15.148Z","dependency_job_id":"b2c6fd71-225f-492b-9a93-c2dbad34ee7d","html_url":"https://github.com/shockz-offsec/Scraping-Notion-Backup","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/shockz-offsec/Scraping-Notion-Backup","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shockz-offsec%2FScraping-Notion-Backup","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shockz-offsec%2FScraping-Notion-Backup/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shockz-offsec%2FScraping-Notion-Backup/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shockz-offsec%2FScraping-Notion-Backup/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shockz-offsec","download_url":"https://codeload.github.com/shockz-offsec/Scraping-Notion-Backup/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shockz-offsec%2FScraping-Notion-Backup/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261973305,"owners_count":23238548,"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","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":["automation","background","backup","export","linux","local","markdown","notion","python","remover","selenium","web-scraping","windows"],"created_at":"2024-11-09T20:35:15.190Z","updated_at":"2025-06-25T23:38:34.824Z","avatar_url":"https://github.com/shockz-offsec.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Scraping-Notion-Backup (No Longer Maintained)\nThis script automates the backup process of Notion data into Markdown and CSV formats, without the need for tokens or the use of private Notion APIs. \nMoreover, the script processes the data to remove any AWS identifiers that may be present in the markdown files, folders, and internal references to other files in the backup.\n\nCan run on both Windows and Linux\n\n\u003e !! At no time is the information (credentials, tokens) used in the script are recompiled.!!\n\n## Requirements \u0026 Installation\n\nTo use this tool, you need to have the Selenium module installed. You can install it by running the following command in your terminal:\n\n```bash\npip install selenium\n```\n\nAfter that, you can download the repository by running the following commands:\n\n```bash\ngit clone https://github.com/shockz-offsec/Scraping-Notion-Backup.git\ncd Scraping-Notion-Backup\n```\n\n### Compatibility\n\nThis script is compatible with both Windows and Linux operating systems and requires Python 3.\n\n## Configuration\n\nThe script's configuration is defined in the config.json file, which has the following structure:\n\n```json\n{\n    \"REMOVE_IDS\": true,\n    \"DOWNLOAD_PATH\": \"C:\\\\Users\\\\YourUsername\\\\Downloads\",\n    \"TARGET_PATH\": \"C:\\\\path\\\\to\\\\your\\\\backup\\\\folder\",\n    \"DEBUG_PATH\": \"C:\\\\path\\\\to\\\\your\\\\logs\\\\folder\",\n    \"EMAIL\":\"your_notion_email\",\n    \"PASSWORD\":\"your_password\"\n}\n```\n\n* `REMOVE_IDS`: a boolean parameter that indicates whether the script should remove AWS identifiers from the downloaded files.\n* `DOWNLOAD_PATH`: the path where the downloaded files will be stored.\n* `TARGET_PATH`: the path where the processed backup files will be stored.\n* `DEBUG_PATH`: the path where the script logs will be saved.\n* `EMAIL`: the email address associated with the Notion account.\n* `PASSWORD`: the password associated with the Notion account.\n\n## How it works\n\nThe backup process is entirely carried out in the background using web scraping, without requiring any user input. \n\nThe export is downloaded and processed according to the user's choice in the configuration file, which can remove AWS identifiers from markdown files, folders, and internal file references. Old backups are then deleted, leaving only the current and most recent backup. \n\nThe processed export is compressed into a zip file with the format notion_export-dd-mm-yyyy.zip. Additionally, the script generates a log file of all the actions performed during the process, using the format debug-dd-mm-yyyy.log.\n\nThe script uses the Firefox webdriver (geckodriver), which is automatically installed during the setup process.\n\n## Usage\n\n```bash\npython3 scrapping_backup_notion.py\n```\n\n## Automating backups\n\nIn Windows, you can automate the script by creating a scheduled task with the Windows Task Scheduler. This can be done by creating a `.bat` file with the following contents:\n\n```batch\n@echo off\nC:\\Python3\\python.exe \"C:\\path\\to\\scrapping_backup_notion.py\"\n```\nThis will allow the script to run automatically at specified intervals without requiring manual intervention.\n\nIn Linux you can use Cron for example.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshockz-offsec%2Fscraping-notion-backup","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshockz-offsec%2Fscraping-notion-backup","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshockz-offsec%2Fscraping-notion-backup/lists"}