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.141.2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 97d806a2d5ba789f94e4605de91b16207043ccde4fcbc0624d866eeb2efb4435 |
|
MD5 | 716196f38f10c6e13eb11443bd17e265 |
|
BLAKE2b-256 | b1fa57890c45df9059110664bd7f5915533430364e8c77c8b1c32939ed9b0b9c |
Close
Hashes for deltachat_rpc_client-1.141.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 61349023c8b5935a8335469d9c37af74c3fb1c691ef77f1c1646174d48cf1eea |
|
MD5 | f900220e4cf7475be612d86a67461560 |
|
BLAKE2b-256 | eb285ef8b9bbb0881fd64f7114b874666803d5d798204b97ea77ed8408bf807e |