{"id":18519338,"url":"https://github.com/fate0/pastebot","last_synced_at":"2025-07-23T10:06:33.776Z","repository":{"id":57451023,"uuid":"102860236","full_name":"fate0/pastebot","owner":"fate0","description":"一个监控 pastebin 的敏感内容，并发微博的 bot","archived":false,"fork":false,"pushed_at":"2017-09-12T14:18:24.000Z","size":24,"stargazers_count":15,"open_issues_count":0,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-12T17:50:16.821Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fate0.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}},"created_at":"2017-09-08T12:42:30.000Z","updated_at":"2020-11-30T06:48:40.000Z","dependencies_parsed_at":"2022-09-26T17:31:24.201Z","dependency_job_id":null,"html_url":"https://github.com/fate0/pastebot","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/fate0/pastebot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fate0%2Fpastebot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fate0%2Fpastebot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fate0%2Fpastebot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fate0%2Fpastebot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fate0","download_url":"https://codeload.github.com/fate0/pastebot/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fate0%2Fpastebot/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265336610,"owners_count":23749193,"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":[],"created_at":"2024-11-06T17:16:07.314Z","updated_at":"2025-07-23T10:06:33.747Z","avatar_url":"https://github.com/fate0.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pastebot\n\n[pastebot](http://weibo.com/pastebot) 是一个监控 pastebin 的敏感内容，并发微博的 bot\n\n### 安装\n\n使用 GitHub 安装\n```\n$ pip install -U git+https://github.com/fate0/pastebot.git\n```\n\n或使用源码安装:\n\n```\n$ python setup.py install\n```\n\n### 使用\n\n基本命令:\n\n```\n$ pastebot\nUsage: pastebot [OPTIONS] COMMAND [ARGS]...\n\nOptions:\n  --version   Show the version and exit.\n  -h, --help  Show this message and exit.\n\nCommands:\n  serve  开始运行 pastebot\n  weibo  生成 weibo access token\n```\n\n生成 weibo access token\n\n```\n$ pastebot weibo -h\nUsage: pastebot weibo [OPTIONS]\n\n  生成 weibo access token\n\nOptions:\n  --key TEXT     微博 App Key  [required]\n  --secret TEXT  微博 App Secret  [required]\n  --domain TEXT  微博安全域名  [required]\n  -h, --help     Show this message and exit.\n  \n$ pastebot weibo --key 1234 --secret 123123123123 --domain yourodmain.com\ninput auth_code: asdfsdfsdf\n\n返回 access_token: you_access_token\n过期时间: 37.329166666666666h\n用户 uid: 111111\n\n```\n\n使用 `pastebot serve` 运行监控\n\n```\n$ pastebot serve -h\nUsage: pastebot serve [OPTIONS]\n\n  开始运行 pastebot\n\nOptions:\n  --tokens TEXT    微博 access tokens  [required]\n  --dsn TEXT       sentry dsn\n  --pool INTEGER   线程池大小\n  --qps FLOAT      qps\n  --timeout FLOAT  请求 timeout\n  -h, --help       Show this message and exit.\n\n$ pastebot serve --token you_access_token1,your_access_token2\n```\n\n因为同一个应用下的 access_token 有发送消息条数限制，所以可以设置多个 access_token\n\n### 参考\n\n* [PasteHunter](https://github.com/kevthehermit/PasteHunter)\n* [dumpmon](https://github.com/jordan-wright/dumpmon)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffate0%2Fpastebot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffate0%2Fpastebot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffate0%2Fpastebot/lists"}