Python client for Delta Chat core JSON-RPC interface
Project description
Delta Chat RPC python client
RPC client connects to standalone Delta Chat RPC server deltachat-rpc-server
and provides asynchronous interface to it.
Getting started
To use Delta Chat RPC client, first build a deltachat-rpc-server
with cargo build -p deltachat-rpc-server
or download a prebuilt release.
Install it anywhere in your PATH
.
Create a virtual environment if you don't have one already and activate it.
$ python -m venv env
$ . env/bin/activate
Install deltachat-rpc-client
from source:
$ cd deltachat-rpc-client
$ pip install .
Testing
- Build
deltachat-rpc-server
withcargo build -p deltachat-rpc-server
. - Run
CHATMAIL_DOMAIN=nine.testrun.org PATH="../target/debug:$PATH" tox
.
Additional arguments to tox
are passed to pytest, e.g. tox -- -s
does not capture test output.
Using in REPL
Setup a development environment:
$ tox --devenv env
$ . env/bin/activate
$ python
>>> from deltachat_rpc_client import *
>>> rpc = Rpc()
>>> rpc.start()
>>> dc = DeltaChat(rpc)
>>> system_info = dc.get_system_info()
>>> system_info["level"]
'awesome'
>>> rpc.close()
Project details
Release history Release notifications | RSS feed
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
Close
Hashes for deltachat_rpc_client-1.148.2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 547fffae557883ca85e9f6ed9100a34a3db1c01607a189c28d88b10e70e198ce |
|
MD5 | 8ad2922e15f0d6e29678d4cffc316481 |
|
BLAKE2b-256 | 55da1dc83e1340e1df50a8ff4ba8e5730f323272786d781475b53dd8f13ed777 |
Close
Hashes for deltachat_rpc_client-1.148.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 00fa6f46323c5fd76451ba0e0d7ea56348f5cf0a6b31aa4b044ad224bf7b1602 |
|
MD5 | 8dc92c8cb19e92067b8325e94d21f62e |
|
BLAKE2b-256 | afc5ca73a31607afdce0c9f72f6bd2b5dc264de8b4da70e1c11e1291a0d8877f |