simplebot


Namesimplebot JSON
Version 4.1.2 PyPI version JSON
download
home_pagehttps://github.com/simplebot-org/simplebot
SummarySimpleBot: Extensible bot for Delta Chat
upload_time2024-03-29 06:04:05
maintainerNone
docs_urlNone
authorThe SimpleBot Contributors
requires_python>=3.8
licenseNone
keywords deltachat bot email
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            > **⚠️ IMPORTANT:** This project is no longer heavily maintained you should use instead: https://github.com/deltachat-bot/deltabot-cli-py

<p align="center"><img height="180" width="180" src="https://github.com/simplebot-org/simplebot/raw/master/artwork/Bot.svg"></p>
<h1 align="center">SimpleBot</h1>

[![Latest Release](https://img.shields.io/pypi/v/simplebot.svg)](https://pypi.org/project/simplebot)
[![Supported Versions](https://img.shields.io/pypi/pyversions/simplebot.svg)](https://pypi.org/project/simplebot)
[![Downloads](https://pepy.tech/badge/simplebot)](https://pepy.tech/project/simplebot)
[![License](https://img.shields.io/pypi/l/simplebot.svg)](https://pypi.org/project/simplebot)
[![CI](https://github.com/simplebot-org/simplebot/actions/workflows/python-ci.yml/badge.svg)](https://github.com/simplebot-org/simplebot/actions/workflows/python-ci.yml)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
[![Contributors](https://img.shields.io/github/contributors/simplebot-org/simplebot.svg)](https://github.com/simplebot-org/simplebot/graphs/contributors)

> An extensible Delta Chat bot.

## Install

To install the latest stable version of SimpleBot run the following command (preferably in a [virtual environment](https://packaging.python.org/tutorials/installing-packages/#creating-and-using-virtual-environments)):

```sh
pip install simplebot
```

To test unreleased version:

```sh
pip install git+https://github.com/simplebot-org/simplebot
```

> **⚠️ NOTE:** If Delta Chat Python bindings package is not available for your platform you will need to compile and install the bindings manually, check [deltachat documentation](https://github.com/deltachat/deltachat-core-rust/blob/master/python/README.rst) for more info.

### Build with docker
```bash
# building image
docker build -t simplebot .
# running container with simplebot
# "/home/bot_volume" absolute path for storing bot data on host system
docker run -it -v /home/bot_volume:/root/.simplebot simplebot bash
```
In container bash you can do same bot running as in [quick start section](#quick-start-running-a-botplugins)

## Quick Start: Running a bot+plugins

(Replace variables `$ADDR` and `$PASSWORD` with the email and password for the account the bot will use)

1. Add an account to the bot:

	```sh
	simplebot init "$ADDR" "$PASSWORD"
	```

2. Install some plugins:

	```sh
	pip install simplebot-echo
	```

3. Start the bot:

	```sh
	simplebot serve
	```

## Plugins

SimpleBot is a base bot that relies on plugins to add functionality.

Everyone can publish their own plugins, search in PyPI to discover cool [SimpleBot plugins](https://pypi.org/search/?q=simplebot&o=&c=Environment+%3A%3A+Plugins)

> **⚠️ NOTE:** Plugins installed as Python packages (for example with `pip`) are global to all accounts you register in the bot, to separate plugins per account you need to run each account in its own virtual environment.

## Creating per account plugins

If you know how to code in Python, you can quickly create plugins and install them to tweak your bot.

Lets create an "echo bot", create a file named `echo.py` and write inside:

```python
import simplebot

@simplebot.filter
def echo(message, replies):
    """Echoes back received message."""
    replies.add(text=message.text)
```

That is it! you have created a plugin that will transform simplebot in an "echo bot" that will echo back any text message you send to it. Now tell simplebot to register your plugin:

```sh
simplebot plugin --add ./echo.py
```

Now you can start the bot and write to it from Delta Chat app to see your new bot in action.

Check the `examples` folder to see some examples about how to create plugins.

## Note for users

SimpleBot uses [Autocrypt](https://autocrypt.org/) end-to-end encryption
but note that the operator of the bot service can look into
messages that are sent to it.


## Credits

SimpleBot logo was created by Cuban designer "Dann".

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/simplebot-org/simplebot",
    "name": "simplebot",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "deltachat bot email",
    "author": "The SimpleBot Contributors",
    "author_email": "adbenitez@nauta.cu, holger@merlinux.eu",
    "download_url": "https://files.pythonhosted.org/packages/20/2b/dccc15e556e4dee259b12d3664675f6dca7f46d583b2eb19015f59c29746/simplebot-4.1.2.tar.gz",
    "platform": null,
    "description": "> **\u26a0\ufe0f IMPORTANT:** This project is no longer heavily maintained you should use instead: https://github.com/deltachat-bot/deltabot-cli-py\n\n<p align=\"center\"><img height=\"180\" width=\"180\" src=\"https://github.com/simplebot-org/simplebot/raw/master/artwork/Bot.svg\"></p>\n<h1 align=\"center\">SimpleBot</h1>\n\n[![Latest Release](https://img.shields.io/pypi/v/simplebot.svg)](https://pypi.org/project/simplebot)\n[![Supported Versions](https://img.shields.io/pypi/pyversions/simplebot.svg)](https://pypi.org/project/simplebot)\n[![Downloads](https://pepy.tech/badge/simplebot)](https://pepy.tech/project/simplebot)\n[![License](https://img.shields.io/pypi/l/simplebot.svg)](https://pypi.org/project/simplebot)\n[![CI](https://github.com/simplebot-org/simplebot/actions/workflows/python-ci.yml/badge.svg)](https://github.com/simplebot-org/simplebot/actions/workflows/python-ci.yml)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n[![Contributors](https://img.shields.io/github/contributors/simplebot-org/simplebot.svg)](https://github.com/simplebot-org/simplebot/graphs/contributors)\n\n> An extensible Delta Chat bot.\n\n## Install\n\nTo install the latest stable version of SimpleBot run the following command (preferably in a [virtual environment](https://packaging.python.org/tutorials/installing-packages/#creating-and-using-virtual-environments)):\n\n```sh\npip install simplebot\n```\n\nTo test unreleased version:\n\n```sh\npip install git+https://github.com/simplebot-org/simplebot\n```\n\n> **\u26a0\ufe0f NOTE:** If Delta Chat Python bindings package is not available for your platform you will need to compile and install the bindings manually, check [deltachat documentation](https://github.com/deltachat/deltachat-core-rust/blob/master/python/README.rst) for more info.\n\n### Build with docker\n```bash\n# building image\ndocker build -t simplebot .\n# running container with simplebot\n# \"/home/bot_volume\" absolute path for storing bot data on host system\ndocker run -it -v /home/bot_volume:/root/.simplebot simplebot bash\n```\nIn container bash you can do same bot running as in [quick start section](#quick-start-running-a-botplugins)\n\n## Quick Start: Running a bot+plugins\n\n(Replace variables `$ADDR` and `$PASSWORD` with the email and password for the account the bot will use)\n\n1. Add an account to the bot:\n\n\t```sh\n\tsimplebot init \"$ADDR\" \"$PASSWORD\"\n\t```\n\n2. Install some plugins:\n\n\t```sh\n\tpip install simplebot-echo\n\t```\n\n3. Start the bot:\n\n\t```sh\n\tsimplebot serve\n\t```\n\n## Plugins\n\nSimpleBot is a base bot that relies on plugins to add functionality.\n\nEveryone can publish their own plugins, search in PyPI to discover cool [SimpleBot plugins](https://pypi.org/search/?q=simplebot&o=&c=Environment+%3A%3A+Plugins)\n\n> **\u26a0\ufe0f NOTE:** Plugins installed as Python packages (for example with `pip`) are global to all accounts you register in the bot, to separate plugins per account you need to run each account in its own virtual environment.\n\n## Creating per account plugins\n\nIf you know how to code in Python, you can quickly create plugins and install them to tweak your bot.\n\nLets create an \"echo bot\", create a file named `echo.py` and write inside:\n\n```python\nimport simplebot\n\n@simplebot.filter\ndef echo(message, replies):\n    \"\"\"Echoes back received message.\"\"\"\n    replies.add(text=message.text)\n```\n\nThat is it! you have created a plugin that will transform simplebot in an \"echo bot\" that will echo back any text message you send to it. Now tell simplebot to register your plugin:\n\n```sh\nsimplebot plugin --add ./echo.py\n```\n\nNow you can start the bot and write to it from Delta Chat app to see your new bot in action.\n\nCheck the `examples` folder to see some examples about how to create plugins.\n\n## Note for users\n\nSimpleBot uses [Autocrypt](https://autocrypt.org/) end-to-end encryption\nbut note that the operator of the bot service can look into\nmessages that are sent to it.\n\n\n## Credits\n\nSimpleBot logo was created by Cuban designer \"Dann\".\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "SimpleBot: Extensible bot for Delta Chat",
    "version": "4.1.2",
    "project_urls": {
        "Homepage": "https://github.com/simplebot-org/simplebot"
    },
    "split_keywords": [
        "deltachat",
        "bot",
        "email"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3bafbe66cae9249c3bea50fc165fd0741be654091f832cd6410f057ee3b867d3",
                "md5": "06c974ca82d8d86ba3af837491409197",
                "sha256": "44fd955d8187147c6e4a257f08527310e3aa6185263e293993bde921a4930b00"
            },
            "downloads": -1,
            "filename": "simplebot-4.1.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "06c974ca82d8d86ba3af837491409197",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 141987,
            "upload_time": "2024-03-29T06:04:03",
            "upload_time_iso_8601": "2024-03-29T06:04:03.331616Z",
            "url": "https://files.pythonhosted.org/packages/3b/af/be66cae9249c3bea50fc165fd0741be654091f832cd6410f057ee3b867d3/simplebot-4.1.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "202bdccc15e556e4dee259b12d3664675f6dca7f46d583b2eb19015f59c29746",
                "md5": "500227f6a832d2d18d18bef7366b4f0a",
                "sha256": "5c07fbb7025a47160edf61c1ba568d9c3ca3aa526e18759fedbd55587ade23d7"
            },
            "downloads": -1,
            "filename": "simplebot-4.1.2.tar.gz",
            "has_sig": false,
            "md5_digest": "500227f6a832d2d18d18bef7366b4f0a",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 182073,
            "upload_time": "2024-03-29T06:04:05",
            "upload_time_iso_8601": "2024-03-29T06:04:05.867688Z",
            "url": "https://files.pythonhosted.org/packages/20/2b/dccc15e556e4dee259b12d3664675f6dca7f46d583b2eb19015f59c29746/simplebot-4.1.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-29 06:04:05",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "simplebot-org",
    "github_project": "simplebot",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "simplebot"
}
        
Elapsed time: 0.20908s