{"id":20032257,"url":"https://github.com/weakish/telegraphet","last_synced_at":"2026-06-13T07:32:39.269Z","repository":{"id":146349811,"uuid":"255016198","full_name":"weakish/telegraphet","owner":"weakish","description":"command line tool to post content on telegra.ph","archived":false,"fork":false,"pushed_at":"2020-04-12T05:50:32.000Z","size":3,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-02T05:28:22.823Z","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":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/weakish.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":"2020-04-12T05:35:54.000Z","updated_at":"2023-01-26T12:43:27.000Z","dependencies_parsed_at":null,"dependency_job_id":"d99c89b6-1c63-4651-892c-81773e4afe3a","html_url":"https://github.com/weakish/telegraphet","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/weakish/telegraphet","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/weakish%2Ftelegraphet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/weakish%2Ftelegraphet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/weakish%2Ftelegraphet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/weakish%2Ftelegraphet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/weakish","download_url":"https://codeload.github.com/weakish/telegraphet/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/weakish%2Ftelegraphet/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34276501,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-13T02:00:06.617Z","response_time":62,"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":[],"created_at":"2024-11-13T09:36:29.193Z","updated_at":"2026-06-13T07:32:39.253Z","avatar_url":"https://github.com/weakish.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"This is the available [telegraph API][api]:\n\n- createAccount\n- createPage\n- editAccountInfo\n- editPage\n- getAccountInfo\n- getPage\n- getPageList\n- getViews\n- revokeAccessToken\n\n[api]: https://telegra.ph/api\n\nFirst, I do not care about page views, so I remove the `getViews` API.\n\nSecond, remove the account concept:\n\n- createPage\n- editPage\n- getPage\n\nHmm, `deletePage` is missing.\nAnd `editPage` requires an account or a special token.\nThus I make page immutable,\nand remove `editPage`.\nThus only two API interfaces are left:\n\n- createPage\n- getPage\n\nSince I only care about page content, then `getPage` is unnecessary (just go the url in browser).\n\nTherefore I wrote this simple script to post content to telegraph.\n\n```shell script\necho '\u003cp\u003eHello world!\u003c/p\u003e' | telegraphet hello\n```\n\nI still need to create an account beforehand though.\ntelegraph requires an account to create a new page.\n\n```shell script\ntelegraph --init PICKUP_A_USERNAME\n```\n\nIf you already have a telegraph, you can setup the access token via environment variable or configuration file.\n\n```shell script\n# config file\nmkdir -p ~/.config/telegraphet\necho '{ \"token\": \"YOUR_TOKEN\" }' \u003e ~/.config/telegraphet/config.json\n# environment variable\necho '\u003cp\u003ehi\u003c/p\u003e' | TELEGRAPH_TOKEN=YOUR_TOKEN telegraphet hi\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweakish%2Ftelegraphet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fweakish%2Ftelegraphet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweakish%2Ftelegraphet/lists"}