A python client wraper for Spotware Open API 2.0
Project description
spotware_connect
A python client wraper for Spotware Open API 2 https://connect.spotware.com/docs/open_api_2
Free software: GNU General Public License v3
Documentation: https://spotware_connect.readthedocs.io.
Quickstart
Install with pip:
$ pip install spotware-connect
A sample to request server version:
import spotware_connect as sc c = sc.Client() @c.event def connect(): c.emit("VersionReq") @c.message(msgtype="VersionRes") def version(msg, payload, version, **kargs): print("Server version: ", version) c.stop() c.start(timeout=5) # optional timeout in seconds
See the usage in docs for a complete example with App Authorization.
Features
Simple client for connecting, sending and receiving Protobuf Messages
Use decorators to specify wich messages to process
No need to worry about sockets, bytes and message structure
Use abbreviated names for sending and receiving payloads: VersionReq translates to ProtoOAVersionReq
Requests limit 5/second more information about limits here
Credits
This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.
Using twisted for network layer
History
0.1.0 (2020-02-25)
First release on PyPI.
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
File details
Details for the file spotware_connect-0.1.2.tar.gz
.
File metadata
- Download URL: spotware_connect-0.1.2.tar.gz
- Upload date:
- Size: 55.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a08cc7b9b7e906c112399c7bf938af91b1bed60d4f68058e9afc42371b296d5f |
|
MD5 | 86ceb4e5a59635cb84a2ce38fb3778d3 |
|
BLAKE2b-256 | 0978e2bfbdc62d9ab4145b95ff6f0a771bf4ab828b45b147b1c1c827dd91fcdb |
File details
Details for the file spotware_connect-0.1.2-py2.py3-none-any.whl
.
File metadata
- Download URL: spotware_connect-0.1.2-py2.py3-none-any.whl
- Upload date:
- Size: 52.2 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 016bce755426b9b50b1fa81e6121401f4f6dd7aa67485b8356230358797ace73 |
|
MD5 | 289f366ec557bac73e75383f7ee1883c |
|
BLAKE2b-256 | 21ee431c4dd28f35fcdff575c342c1f663c5214672730a63a0ab180b969a5e42 |