Simple framework for building Telegram agents with Django
Project description
Botnetics Agent
A simple framework for building Telegram agents with Django.
Installation
pip install botnetics-agent
Quick Start
botnetics init my-agent
cd my-agent
python agent.py
Test your agent:
curl -X POST http://localhost:8000/message/ \
-H "Content-Type: application/json" \
-d '{"text": "Hello", "chat_id": "123", "user_id": "456"}'
Features
- Simple message handling with decorators
- Built-in Django web server
- REST API endpoint for message processing
- Easy project scaffolding
- Docker support
Usage
Create a new agent:
from botnetics import BotneticsApp, Message
app = BotneticsApp(api_key="your-key")
@app.on_message
def handle_message(message: Message):
return Message(
text=f"You said: {message.text}",
chat_id=message.chat_id,
user_id=message.user_id
)
app.run()
License
MIT License
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file botnetics_agent-0.1.3.tar.gz.
File metadata
- Download URL: botnetics_agent-0.1.3.tar.gz
- Upload date:
- Size: 5.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8a4ccb8968d648408f22192bf4bc2be4647ec2e05a3225f42be55afc8f152514
|
|
| MD5 |
e828b917884a55a630c423c1c6e502f8
|
|
| BLAKE2b-256 |
5135308f5f6acb8a97cfc0b0dc03b699df532c4cdedf230be97361c90a1c8d99
|
Provenance
The following attestation bundles were made for botnetics_agent-0.1.3.tar.gz:
Publisher:
publish.yml on Behokus/botnetics-agent
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
botnetics_agent-0.1.3.tar.gz -
Subject digest:
8a4ccb8968d648408f22192bf4bc2be4647ec2e05a3225f42be55afc8f152514 - Sigstore transparency entry: 245959799
- Sigstore integration time:
-
Permalink:
Behokus/botnetics-agent@583acb40f5ea9e3a1c96bcb93566be3b33509743 -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/Behokus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@583acb40f5ea9e3a1c96bcb93566be3b33509743 -
Trigger Event:
release
-
Statement type:
File details
Details for the file botnetics_agent-0.1.3-py3-none-any.whl.
File metadata
- Download URL: botnetics_agent-0.1.3-py3-none-any.whl
- Upload date:
- Size: 6.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
14dec20b87aa0e33c64ddba4f532d2e99f0174bcce359c8cce7a4af58fc06dc5
|
|
| MD5 |
b90833ca4b2b61cc6ba4e013922b61bf
|
|
| BLAKE2b-256 |
c3f60f693a4bf9385fd75067af31ba1cef446a6676fb9dcc297249acb8136984
|
Provenance
The following attestation bundles were made for botnetics_agent-0.1.3-py3-none-any.whl:
Publisher:
publish.yml on Behokus/botnetics-agent
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
botnetics_agent-0.1.3-py3-none-any.whl -
Subject digest:
14dec20b87aa0e33c64ddba4f532d2e99f0174bcce359c8cce7a4af58fc06dc5 - Sigstore transparency entry: 245959800
- Sigstore integration time:
-
Permalink:
Behokus/botnetics-agent@583acb40f5ea9e3a1c96bcb93566be3b33509743 -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/Behokus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@583acb40f5ea9e3a1c96bcb93566be3b33509743 -
Trigger Event:
release
-
Statement type: