Skip to main content

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

  1. Build deltachat-rpc-server with cargo build -p deltachat-rpc-server.
  2. 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


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

deltachat_rpc_client-1.150.0.tar.gz (41.6 kB view details)

Uploaded Source

Built Distribution

deltachat_rpc_client-1.150.0-py3-none-any.whl (32.6 kB view details)

Uploaded Python 3

File details

Details for the file deltachat_rpc_client-1.150.0.tar.gz.

File metadata

File hashes

Hashes for deltachat_rpc_client-1.150.0.tar.gz
Algorithm Hash digest
SHA256 88d3989e9209c663dacf5ac35abf54f7db2c0cab9cb30df98914660c92af946c
MD5 7b33fcb52ff6d654c9cadc5e62af8ae3
BLAKE2b-256 192b7aac04cfbd1684344a708b7fd4edb5c2b2d7511800f1ab94bc0d30b7bc51

See more details on using hashes here.

Provenance

The following attestation bundles were made for deltachat_rpc_client-1.150.0.tar.gz:

Publisher: publish-deltachat-rpc-client-pypi.yml on deltachat/deltachat-core-rust

Attestations:

File details

Details for the file deltachat_rpc_client-1.150.0-py3-none-any.whl.

File metadata

File hashes

Hashes for deltachat_rpc_client-1.150.0-py3-none-any.whl
Algorithm Hash digest
SHA256 44a66623a5cd7bdd13f9d55e2f22f044719981b30e5ba9a8871e4ca23829b8df
MD5 7bd6b09fc1a90d018855f503a824eeb9
BLAKE2b-256 4ed42b6b687a4912363eaf132173595e99a6964c3adb13b2d0292db8e15c6aea

See more details on using hashes here.

Provenance

The following attestation bundles were made for deltachat_rpc_client-1.150.0-py3-none-any.whl:

Publisher: publish-deltachat-rpc-client-pypi.yml on deltachat/deltachat-core-rust

Attestations:

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page