Module for interacting with OpenWRT Luci RPC interface
Project description
================
openwrt-luci-rpc
================
.. image:: https://img.shields.io/pypi/v/openwrt_luci_rpc.svg
:target: https://pypi.python.org/pypi/openwrt_luci_rpc
.. image:: https://img.shields.io/travis/fbradyirl/openwrt-luci-rpc.svg
:target: https://travis-ci.org/fbradyirl/openwrt-luci-rpc/
.. image:: https://readthedocs.org/projects/openwrt-luci-rpc/badge/?version=latest
:target: https://openwrt-luci-rpc.readthedocs.io/en/latest/?badge=latest
:alt: Documentation Status
Python3 module for interacting with the OpenWRT Luci RPC interface
- Free software: Apache Software License 2.0
- Documentation: `https://openwrt-luci-rpc.readthedocs.io`.
Features
--------
- Allows you to use the Luci RPC interface to fetch connected devices
on your OpenWrt based router.
- Supports 17.X & 18.X or newer releases of OpenWrt.
Usage
-----
You will first need to install the package ``luci-mod-rpc`` on your
OpenWrt router.
::
opkg update
opkg install luci-mod-rpc
Once that is done, you can use this module to interact with the RPC
interface.
Install
~~~~~~~
.. code:: bash
pip install openwrt-luci-rpc
Use
~~~
.. code:: python
from openwrt_luci_rpc import OpenWrtRpc
router = OpenWrtRpc('http://192.168.1.1', 'root', 'mypassword')
result = router.get_all_connected_devices(only_reachable=True)
for device in result:
mac = device['macaddress']
name = device['hostname']
Development
~~~~~~~~~~~
See `contributing guide`_.
.. _contributing guide: CONTRIBUTING.rst
=======
History
=======
0.1.0 (2019-02-19)
------------------
* Initial release. Not working. Do not use.
0.2.0 (2019-02-19)
------------------
* Initial release. Not working. Do not use.
0.3.0 (2019-02-19)
------------------
* First working release on PyPI.
0.4.8 (2019-02-20)
------------------
* Fix travis deploy repo, once more.
0.4.9 (2019-02-20)
------------------
* Fix README formatting for docs.
0.4.10 (2019-02-20)
------------------
* Fix links to github repo
0.4.11 (2019-02-20)
------------------
* Updated usage in README.
0.4.12 (2019-02-20)
------------------
* Fix typo in README.
0.4.13 (2019-02-20)
------------------
* Fix README parse issue.
1.0.0 (2019-02-21)
------------------
* Updated to return all device information.
* Added extra unit tests.
1.0.1 (2019-02-22)
------------------
* Minor bug fixes and extra unit tests
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
openwrt-luci-rpc-1.0.1.tar.gz
(12.0 kB
view hashes)
Built Distribution
Close
Hashes for openwrt_luci_rpc-1.0.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c64f36022f3e91858901812c8b04d5be38dd58ca794c4aa630b939767a933ba0 |
|
MD5 | b2c856d577ea7c63e79dc0d1e04448b1 |
|
BLAKE2b-256 | efef537ed46f139b8ae0d3be82746a89c410bf0d274cb65a1d13d918d66a17b7 |