{ "info": { "author": "Matthew Treinish", "author_email": "mtreinish@kortar.org", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: GNU General Public License v3 (GPLv3)", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7" ], "description": "==========\npyopnsense\n==========\nYou can see the full rendered docs at: http://pyopnsense.readthedocs.io/en/latest/\n\nA python API client for the OPNsense API. This provides a python interface for\ninteracting with the OPNsense API.\n\n\nInstallation\n============\npyopnsense is available via pypi so all you need to do is run::\n\n pip install -U pyopnsense\n\nto get the latest pyopnsense release on your system. If you need to use a\ndevelopment version of pyopnsense you can clone the repo and install it locally\nwith::\n\n git clone https://github.com/mtreinish/pyopnsense && pip install -e pyopnsense\n\nwhich will install pyopnsense in your python environment in editable mode for\ndevelopment.\n\n.. _usage:\n\nUsage\n=====\n\nTo use pyopnsense you need a couple pieces of information, the API key and the\nAPI secret. Both can be created/found from the OPNsense web UI by navigating\nto: `System->Access->Users` under `API keys`.\n\nMore information on this can be found in the OPNsense documentation:\nhttps://docs.opnsense.org/development/how-tos/api.html\n\nOnce you have the API key and API secret you can use pyopnsense to interact\nwith your OPNsense installation. You can do this by passing your credentials\nto a client class. For example:\n\n.. code-block:: python\n\n from pyopnsense import diagnostics\n\n api_key = 'XXXXXX'\n api_secret = 'XXXXXXXXXXXXXXX'\n opnsense_url = 'http://192.168.1.1/api'\n\n netinsight_client = diagnostics.NetworkInsightClient(\n api_key, api_secret, opnsense_url)\n\n print(netinsight_client.get_interfaces())\n\nwhich will print a dictionary mapping physical devices to their interface label.\n\nThis same formula can be used to access each individual API endpoint you need\nto access. The basic structure of the library is setup to roughly mirror the\nendpoint tree of the OPNsense API. Each client module maps to the base endpoint\nand then there is a client class in those modules for the next level up off\nthat.\n\nYou can find more detail on how to use the clients in the API reference\ndocumentation found here:\n\nhttp://pyopnsense.readthedocs.io/en/latest/api.html\n\n\n\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "pyopnsense", "package_url": "https://pypi.org/project/pyopnsense/", "platform": "", "project_url": "https://pypi.org/project/pyopnsense/", "project_urls": null, "release_url": "https://pypi.org/project/pyopnsense/0.2.0/", "requires_dist": [ "pbr (>=1.6)", "six (>=1.9.0)", "requests (>=2.14.2)" ], "requires_python": "", "summary": "A python API client for OPNsense", "version": "0.2.0" }, "last_serial": 5349758, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "1fdf14900d39a4fd52f4e0f25c8df729", "sha256": "266df42d5115ed0ee2570c4f69c7fcc16e7f31a3e41d2737c950ed56c5763454" }, "downloads": -1, "filename": "pyopnsense-0.0.1.tar.gz", "has_sig": false, "md5_digest": "1fdf14900d39a4fd52f4e0f25c8df729", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16701, "upload_time": "2018-02-06T23:32:51", "url": "https://files.pythonhosted.org/packages/eb/6c/c65a2254a8f946ab447aa3fabf48de7a945de02f539758eb441230990746/pyopnsense-0.0.1.tar.gz" } ], "0.1.0": [ { "comment_text": "", "digests": { "md5": "94b5905071c1bbf31c30797d4d72334b", "sha256": "55b057d07008d728ad3170a92c369eda9db1a2f3bdeebca3175f3ceaf0ffc9d7" }, "downloads": -1, "filename": "pyopnsense-0.1.0.tar.gz", "has_sig": false, "md5_digest": "94b5905071c1bbf31c30797d4d72334b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21505, "upload_time": "2018-03-23T03:39:39", "url": "https://files.pythonhosted.org/packages/e2/94/e7fea74f6628015d3bd0a60cafb1eb9a017afa98e7efb1cd2045bc2a9bd8/pyopnsense-0.1.0.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "4905a5028a32b24e2b35921a4393608c", "sha256": "1bb5b6f004279a948806cb11fba0a69985699b7de7a8df44af6b457ecff81fcf" }, "downloads": -1, "filename": "pyopnsense-0.2.0-py3-none-any.whl", "has_sig": false, "md5_digest": "4905a5028a32b24e2b35921a4393608c", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 21055, "upload_time": "2019-06-02T20:09:26", "url": "https://files.pythonhosted.org/packages/71/c4/c7338a9ba9180228864472fbddff71188c485b8d9c962809b74de2d7702e/pyopnsense-0.2.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "44eea4265145dc8a92c7ba83878ad2ef", "sha256": "ec8eafce2f0a75c78f48cbfbae9c01b934ac99645ba0642ea625e1a8195da7d0" }, "downloads": -1, "filename": "pyopnsense-0.2.0.tar.gz", "has_sig": false, "md5_digest": "44eea4265145dc8a92c7ba83878ad2ef", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21227, "upload_time": "2019-06-02T20:09:27", "url": "https://files.pythonhosted.org/packages/e1/44/ee3e27d9bed4908b1223989021d83abfd4564b339b33f1e0e7efd7cccae5/pyopnsense-0.2.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "4905a5028a32b24e2b35921a4393608c", "sha256": "1bb5b6f004279a948806cb11fba0a69985699b7de7a8df44af6b457ecff81fcf" }, "downloads": -1, "filename": "pyopnsense-0.2.0-py3-none-any.whl", "has_sig": false, "md5_digest": "4905a5028a32b24e2b35921a4393608c", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 21055, "upload_time": "2019-06-02T20:09:26", "url": "https://files.pythonhosted.org/packages/71/c4/c7338a9ba9180228864472fbddff71188c485b8d9c962809b74de2d7702e/pyopnsense-0.2.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "44eea4265145dc8a92c7ba83878ad2ef", "sha256": "ec8eafce2f0a75c78f48cbfbae9c01b934ac99645ba0642ea625e1a8195da7d0" }, "downloads": -1, "filename": "pyopnsense-0.2.0.tar.gz", "has_sig": false, "md5_digest": "44eea4265145dc8a92c7ba83878ad2ef", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21227, "upload_time": "2019-06-02T20:09:27", "url": "https://files.pythonhosted.org/packages/e1/44/ee3e27d9bed4908b1223989021d83abfd4564b339b33f1e0e7efd7cccae5/pyopnsense-0.2.0.tar.gz" } ] }