telegraph


Nametelegraph JSON
Version 2.2.0 PyPI version JSON
download
home_pagehttps://github.com/python273/telegraph
SummaryTelegraph API wrapper
upload_time2022-10-26 18:37:49
maintainer
docs_urlNone
authorpython273
requires_python
licenseMIT
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Telegraph
[![PyPI](https://img.shields.io/pypi/v/telegraph.svg)](https://pypi.python.org/pypi/telegraph)
![Python Versions](https://img.shields.io/pypi/pyversions/telegraph.svg)
![License](https://img.shields.io/github/license/python273/telegraph.svg)

Python Telegraph API wrapper

- [Documentation](https://python-telegraph.readthedocs.io/en/latest/)

```bash
$ python3 -m pip install telegraph
# with asyncio support
$ python3 -m pip install 'telegraph[aio]'
```

## Example
```python
from telegraph import Telegraph

telegraph = Telegraph()
telegraph.create_account(short_name='1337')

response = telegraph.create_page(
    'Hey',
    html_content='<p>Hello, world!</p>'
)
print(response['url'])
```

## Async Example
```python
import asyncio
from telegraph.aio import Telegraph

async def main():
    telegraph = Telegraph()
    print(await telegraph.create_account(short_name='1337'))

    response = await telegraph.create_page(
        'Hey',
        html_content='<p>Hello, world!</p>',
    )
    print(response['url'])


asyncio.run(main())
```

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/python273/telegraph",
    "name": "telegraph",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "",
    "author": "python273",
    "author_email": "telegraph@python273.pw",
    "download_url": "https://files.pythonhosted.org/packages/49/81/1c9f99004e23555fb21b80a2ef6ddbecb3a7a4eefbc4aac75ffb5a9ccf71/telegraph-2.2.0.tar.gz",
    "platform": null,
    "description": "# Telegraph\n[![PyPI](https://img.shields.io/pypi/v/telegraph.svg)](https://pypi.python.org/pypi/telegraph)\n![Python Versions](https://img.shields.io/pypi/pyversions/telegraph.svg)\n![License](https://img.shields.io/github/license/python273/telegraph.svg)\n\nPython Telegraph API wrapper\n\n- [Documentation](https://python-telegraph.readthedocs.io/en/latest/)\n\n```bash\n$ python3 -m pip install telegraph\n# with asyncio support\n$ python3 -m pip install 'telegraph[aio]'\n```\n\n## Example\n```python\nfrom telegraph import Telegraph\n\ntelegraph = Telegraph()\ntelegraph.create_account(short_name='1337')\n\nresponse = telegraph.create_page(\n    'Hey',\n    html_content='<p>Hello, world!</p>'\n)\nprint(response['url'])\n```\n\n## Async Example\n```python\nimport asyncio\nfrom telegraph.aio import Telegraph\n\nasync def main():\n    telegraph = Telegraph()\n    print(await telegraph.create_account(short_name='1337'))\n\n    response = await telegraph.create_page(\n        'Hey',\n        html_content='<p>Hello, world!</p>',\n    )\n    print(response['url'])\n\n\nasyncio.run(main())\n```\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Telegraph API wrapper",
    "version": "2.2.0",
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d3751bc2f8c4e4a736e2e582a1518eb4621db3c9dcb100f379fab5ab49c8d1ac",
                "md5": "9004b67a0c866fc60e25fa823f6c1a2f",
                "sha256": "d20b2a5d7cfdd66890c8c3fd60aa8585cabb7c6b03579d3eb1cd8af056ed9971"
            },
            "downloads": -1,
            "filename": "telegraph-2.2.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "9004b67a0c866fc60e25fa823f6c1a2f",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 10749,
            "upload_time": "2022-10-26T18:37:47",
            "upload_time_iso_8601": "2022-10-26T18:37:47.899541Z",
            "url": "https://files.pythonhosted.org/packages/d3/75/1bc2f8c4e4a736e2e582a1518eb4621db3c9dcb100f379fab5ab49c8d1ac/telegraph-2.2.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "49811c9f99004e23555fb21b80a2ef6ddbecb3a7a4eefbc4aac75ffb5a9ccf71",
                "md5": "8122865dbf2e2b3eefef300f2b434eff",
                "sha256": "012908f18208c451c7189f4bda7c39a1369241ac436c7543bb6c3fccbe9cfd5d"
            },
            "downloads": -1,
            "filename": "telegraph-2.2.0.tar.gz",
            "has_sig": false,
            "md5_digest": "8122865dbf2e2b3eefef300f2b434eff",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 8011,
            "upload_time": "2022-10-26T18:37:49",
            "upload_time_iso_8601": "2022-10-26T18:37:49.049310Z",
            "url": "https://files.pythonhosted.org/packages/49/81/1c9f99004e23555fb21b80a2ef6ddbecb3a7a4eefbc4aac75ffb5a9ccf71/telegraph-2.2.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2022-10-26 18:37:49",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "python273",
    "github_project": "telegraph",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "lcname": "telegraph"
}
        
Elapsed time: 0.03207s