tg-gateway


Nametg-gateway JSON
Version 1.0 PyPI version JSON
download
home_pageNone
SummaryA lightweight Telegram Gateway API SDK
upload_time2024-10-05 16:21:15
maintainerNone
docs_urlNone
authorNone
requires_python>=3.11
licenseNone
keywords asyncio client telegram telegram-gateway wrapper
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            
##########
tg_gateway
##########

**tg_gateway** is a Python library for interacting with the
`Telegram Gateway API <https://core.telegram.org/gateway>`_

Installation
------------

..  code-block:: bash

    pip install -U tg_gateway

Usage example
--------------

.. code-block:: python

    import asyncio
    import logging
    from typing import Final

    from tg_gateway import TelegramGateway

    API_TOKEN: Final[str] = "YOUR_TOKEN_HERE"


    async def main() -> None:
        logging.basicConfig(level=logging.DEBUG)
        gateway: TelegramGateway = TelegramGateway(api_token=API_TOKEN, force_detailed_errors=True)
        result = await gateway.send_verification_message(
            phone_number="+88812956932",
            code_length=8,
            callback_url="https://example.com",
        )
        logging.info(result)
        await gateway.session.close()


    if __name__ == "__main__":
        asyncio.run(main())


Contact
-------
For any questions or feedback, feel free to reach out to me on my `Telegram <https://t.me/wakaree>`_

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "tg-gateway",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.11",
    "maintainer_email": "wakaree <nullmatawasoradesu@gmail.com>",
    "keywords": "asyncio, client, telegram, telegram-gateway, wrapper",
    "author": null,
    "author_email": "wakaree <nullmatawasoradesu@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/f4/43/11b6b14ef7f7ce21b64914295092434e56cb231d1a1f91eecf26a09cdb3f/tg_gateway-1.0.tar.gz",
    "platform": null,
    "description": "\n##########\ntg_gateway\n##########\n\n**tg_gateway** is a Python library for interacting with the\n`Telegram Gateway API <https://core.telegram.org/gateway>`_\n\nInstallation\n------------\n\n..  code-block:: bash\n\n    pip install -U tg_gateway\n\nUsage example\n--------------\n\n.. code-block:: python\n\n    import asyncio\n    import logging\n    from typing import Final\n\n    from tg_gateway import TelegramGateway\n\n    API_TOKEN: Final[str] = \"YOUR_TOKEN_HERE\"\n\n\n    async def main() -> None:\n        logging.basicConfig(level=logging.DEBUG)\n        gateway: TelegramGateway = TelegramGateway(api_token=API_TOKEN, force_detailed_errors=True)\n        result = await gateway.send_verification_message(\n            phone_number=\"+88812956932\",\n            code_length=8,\n            callback_url=\"https://example.com\",\n        )\n        logging.info(result)\n        await gateway.session.close()\n\n\n    if __name__ == \"__main__\":\n        asyncio.run(main())\n\n\nContact\n-------\nFor any questions or feedback, feel free to reach out to me on my `Telegram <https://t.me/wakaree>`_\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A lightweight Telegram Gateway API SDK",
    "version": "1.0",
    "project_urls": {
        "Documentation": "https://core.telegram.org/gateway/api",
        "Repository": "https://github.com/py-stollen/tg_gateway"
    },
    "split_keywords": [
        "asyncio",
        " client",
        " telegram",
        " telegram-gateway",
        " wrapper"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "af91ed00f818249823cf3500bf2a464927e9e31a92be6776784b97b7d572c89d",
                "md5": "4174a3d211606d747dbcbe5ef4dfffc3",
                "sha256": "c6853c3421f71cb8723f15835bd120887ca39607e71f257cfbee912625808fa2"
            },
            "downloads": -1,
            "filename": "tg_gateway-1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "4174a3d211606d747dbcbe5ef4dfffc3",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.11",
            "size": 10301,
            "upload_time": "2024-10-05T16:21:14",
            "upload_time_iso_8601": "2024-10-05T16:21:14.310677Z",
            "url": "https://files.pythonhosted.org/packages/af/91/ed00f818249823cf3500bf2a464927e9e31a92be6776784b97b7d572c89d/tg_gateway-1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f44311b6b14ef7f7ce21b64914295092434e56cb231d1a1f91eecf26a09cdb3f",
                "md5": "078dec9afb7e6ed61d5c3b1624f06fa0",
                "sha256": "91ebd766f06d8ec24116d5b23ee03886b597021765971ac0acffd7120d09127d"
            },
            "downloads": -1,
            "filename": "tg_gateway-1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "078dec9afb7e6ed61d5c3b1624f06fa0",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.11",
            "size": 6842,
            "upload_time": "2024-10-05T16:21:15",
            "upload_time_iso_8601": "2024-10-05T16:21:15.934620Z",
            "url": "https://files.pythonhosted.org/packages/f4/43/11b6b14ef7f7ce21b64914295092434e56cb231d1a1f91eecf26a09cdb3f/tg_gateway-1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-05 16:21:15",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "py-stollen",
    "github_project": "tg_gateway",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "tg-gateway"
}
        
Elapsed time: 0.68385s