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.138.3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | fbc449a17418e2004d12b10e046e5a401f654b00b4d1f13f683b8eef6e3c3d7f |
|
MD5 | a6cb64e18ad8935985c5f339969d2a59 |
|
BLAKE2b-256 | 923983acdfe217c273cbc4bae81c0000afdb9b68ac1485a878b95298698b7ca1 |
Close
Hashes for deltachat_rpc_client-1.138.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d41f38f265686525d047f52f00184d478e9dd6db6b4df26b403c5cc9e04d32a9 |
|
MD5 | 1903d086aff33a276cb0cdba7497f7af |
|
BLAKE2b-256 | e618299724046b9d168effd8d1f4ab94f90a3ad54293d27a3758aa8f3d3af501 |