Name | teamwork-python JSON |
Version |
0.1.0
JSON |
| download |
home_page | None |
Summary | The python bot-framework SDK for Teamwork (https://teamwork.app) |
upload_time | 2024-10-30 22:25:59 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.10 |
license | None |
keywords |
teamwork
bot-framework
sdk
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
<img src="https://teamwork.app/static/teamwork_logo_word-7f2b02a09653c972fd5a9e80ea6abbf2.svg" alt="Teamwork Logo" width="400"/>
# Teamwork Python Bot-framework SDK
The official [Teamwork](https://teamwork.app) python bot-framework SDK.
## Installation
Install the packages using pip:
```sh
pip install teamwork-python
```
## Pre-requisites
Before you start, you need to create a bot on your Teamwork app console platform and get the API token.
## Usage
You can use the SDK to interact with the Teamwork Bot-framework API.
### Get user profile
```python
from teamwork import AsyncClient
client = AsyncClient("ENDPOINT_URL", "API_TOKEN")
# by id
user = await client.user.by_id(1001)
# by username
user = await client.user.by_username("john.doe@example.com")
```
### Send message
This is to let your bot account send a message to other end-user or group chats.
```python
from teamwork import ReceiverType
# to a user
res = await client.message.send("Hello world!", 1001, ReceiverType.USER)
# to a group chat
res = await client.message.send("Hello everyone!", 59239, ReceiverType.GROUP)
```
Optionally, you can send a "typing" signal to the target, indicating that the bot is typing before you actually send the message
```python
# first, send the signal
res = await client.message.sending_typing_signal(1001, ReceiverType.USER)
# Sometime later, send the actual message
res = await client.message.send("Hello world!", 1001, ReceiverType.USER)
```
## License
This project is licensed under the MIT License.
Raw data
{
"_id": null,
"home_page": null,
"name": "teamwork-python",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.10",
"maintainer_email": null,
"keywords": "teamwork, bot-framework, sdk",
"author": null,
"author_email": "Danny Kok <dannykok1@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/e3/92/d4bbc7e3e74c1d93b554fa79cae9636679e7e4dbaf715cd90c72773d007e/teamwork_python-0.1.0.tar.gz",
"platform": null,
"description": "<img src=\"https://teamwork.app/static/teamwork_logo_word-7f2b02a09653c972fd5a9e80ea6abbf2.svg\" alt=\"Teamwork Logo\" width=\"400\"/>\n\n# Teamwork Python Bot-framework SDK\n\nThe official [Teamwork](https://teamwork.app) python bot-framework SDK.\n\n## Installation\n\nInstall the packages using pip:\n\n```sh\npip install teamwork-python\n```\n\n## Pre-requisites\n\nBefore you start, you need to create a bot on your Teamwork app console platform and get the API token.\n\n## Usage\n\nYou can use the SDK to interact with the Teamwork Bot-framework API.\n\n### Get user profile\n\n```python\nfrom teamwork import AsyncClient\n\nclient = AsyncClient(\"ENDPOINT_URL\", \"API_TOKEN\")\n\n# by id\nuser = await client.user.by_id(1001)\n\n# by username\nuser = await client.user.by_username(\"john.doe@example.com\")\n```\n\n### Send message\n\nThis is to let your bot account send a message to other end-user or group chats.\n\n```python\nfrom teamwork import ReceiverType\n\n# to a user\nres = await client.message.send(\"Hello world!\", 1001, ReceiverType.USER)\n\n# to a group chat\nres = await client.message.send(\"Hello everyone!\", 59239, ReceiverType.GROUP)\n\n```\n\nOptionally, you can send a \"typing\" signal to the target, indicating that the bot is typing before you actually send the message\n\n```python\n# first, send the signal\nres = await client.message.sending_typing_signal(1001, ReceiverType.USER)\n\n# Sometime later, send the actual message\nres = await client.message.send(\"Hello world!\", 1001, ReceiverType.USER)\n\n```\n\n## License\n\nThis project is licensed under the MIT License.\n",
"bugtrack_url": null,
"license": null,
"summary": "The python bot-framework SDK for Teamwork (https://teamwork.app)",
"version": "0.1.0",
"project_urls": {
"Homepage": "https://teamwork.app",
"Repository": "https://github.com/dannykok/teamwork-python"
},
"split_keywords": [
"teamwork",
" bot-framework",
" sdk"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "da59010bb0edb8b53ad520e4e06417bda36cb644b54790e84c3526be7973b56a",
"md5": "0d5735e62f2df1d15895feb8b9fe513d",
"sha256": "50e9b845b34974e4d5e94505542d4f9a74e74db13ef8a090a6726f30f057757a"
},
"downloads": -1,
"filename": "teamwork_python-0.1.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "0d5735e62f2df1d15895feb8b9fe513d",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.10",
"size": 6178,
"upload_time": "2024-10-30T22:25:57",
"upload_time_iso_8601": "2024-10-30T22:25:57.891399Z",
"url": "https://files.pythonhosted.org/packages/da/59/010bb0edb8b53ad520e4e06417bda36cb644b54790e84c3526be7973b56a/teamwork_python-0.1.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "e392d4bbc7e3e74c1d93b554fa79cae9636679e7e4dbaf715cd90c72773d007e",
"md5": "6ef829bee5200b5b8f11245995d7dc0f",
"sha256": "e7d11ccbcd6b1fd1817071c6dded8f7808df6f7d7007df826abd1a15a9b90cac"
},
"downloads": -1,
"filename": "teamwork_python-0.1.0.tar.gz",
"has_sig": false,
"md5_digest": "6ef829bee5200b5b8f11245995d7dc0f",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.10",
"size": 5487,
"upload_time": "2024-10-30T22:25:59",
"upload_time_iso_8601": "2024-10-30T22:25:59.707952Z",
"url": "https://files.pythonhosted.org/packages/e3/92/d4bbc7e3e74c1d93b554fa79cae9636679e7e4dbaf715cd90c72773d007e/teamwork_python-0.1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-10-30 22:25:59",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "dannykok",
"github_project": "teamwork-python",
"github_not_found": true,
"lcname": "teamwork-python"
}