Extreme EXOS asyncio client for JSON-RPC and RESTCONF
Project description
WORK IN PROGESS
Extreme EXOS asyncio Client
This repository contains an Extreme EXOS asyncio client, support for both JSON-RPC and RESTCONF options.
For reference on the EXOS JSON-RPC, refer to this document.
For reference on the EXOS RESTCONF support, refer to this document.
Device Configuration
In order to access the EXOS device via API you must enable the web server feature using either http or https.
enable web http
enable web https # requires ssl configuration as well.
JSON-RPC Usage
from aioexos.jsonrpc import Device
dev = Device(host='myhostname', username='user', password='Random')
show_one = await dev.cli('show switch')
show_many = await dev.cli(['show switch', 'show version'])
# get text instead of JSON/dict
show_text = await dev.cli('show switch', text=True)
RESTCONF Usage
The RESTCONF API supports only JSON body at this time. XML is not supported even though the documentation states that it does.
from aioexos.restconf import Device
dev = Device(host='myhostname', username='user', password='Random')
# login step required for session authentication
await dev.login()
# execute commands providing the restconf URL, supports all request methods
# (GET, POST, etc.)
res = await dev.get('/openconfig-system:system')
# close connection when done with commands
await dev.aclose()
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
Built Distribution
File details
Details for the file aio-exos-0.4.0.tar.gz
.
File metadata
- Download URL: aio-exos-0.4.0.tar.gz
- Upload date:
- Size: 9.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.1 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/1.5.0 colorama/0.4.4 CPython/3.10.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 82a11a161cd09bf96041826ddfe4d9325ba93db997c14e69bf8300f4d68fb67f |
|
MD5 | 5d7c10af7ac25affe6727923c773f5bb |
|
BLAKE2b-256 | 4359c8e0576dc610730c0eed1a7e40f787900353addc5fd85ff8be5f5e4328e9 |
File details
Details for the file aio_exos-0.4.0-py3-none-any.whl
.
File metadata
- Download URL: aio_exos-0.4.0-py3-none-any.whl
- Upload date:
- Size: 9.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.1 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/1.5.0 colorama/0.4.4 CPython/3.10.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c2fea8754e6a81456ad174fff7fb030ed5d971772b078541c184b70bff7298f2 |
|
MD5 | 0d69def7616213c717f3b490b7e1c9d0 |
|
BLAKE2b-256 | a922d9159683bb38e5528c8642aff805a8998704fc66f848f22f9ec91fa4a1a1 |