{ "info": { "author": "DMTF, https://www.dmtf.org/standards/feedback", "author_email": "", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "License :: OSI Approved :: BSD License", "Programming Language :: Python", "Topic :: Communications" ], "description": "python-redfish-library\n======================\n\n.. image:: https://travis-ci.org/DMTF/python-redfish-library.svg?branch=master\n :target: https://travis-ci.org/DMTF/python-redfish-library\n.. image:: https://img.shields.io/pypi/v/redfish.svg?maxAge=2592000\n\t:target: https://pypi.python.org/pypi/redfish\n.. image:: https://img.shields.io/github/release/DMTF/python-redfish-library.svg?maxAge=2592000\n\t:target: https://github.com/DMTF/python-redfish-library/releases\n.. image:: https://img.shields.io/badge/License-BSD%203--Clause-blue.svg\n\t:target: https://raw.githubusercontent.com/DMTF/python-redfish-library/master/LICENSE\n.. image:: https://img.shields.io/pypi/pyversions/redfish.svg?maxAge=2592000\n\t:target: https://pypi.python.org/pypi/redfish\n.. image:: https://api.codacy.com/project/badge/Grade/1283adc3972d42b4a3ddb9b96660bc07\n\t:target: https://www.codacy.com/app/rexysmydog/python-redfish-library?utm_source=github.com&utm_medium=referral&utm_content=DMTF/python-redfish-library&utm_campaign=Badge_Grade\n\n\n.. contents:: :depth: 1\n\n\nDescription\n-----------\n\nREST (Representational State Transfer) is a web based software architectural style consisting of a set of constraints that focuses on a system's resources. The Redfish library performs the basic HTTPS operations GET, POST, PUT, PATCH and DELETE on resources using the HATEOAS (Hypermedia as the Engine of Application State) Redfish architecture. API clients allow you to manage and interact with the system through a fixed URL and several URIs. Go to the `wiki <../../wiki>`_ for more details.\n\n\nInstalling\n----------\n\n.. code-block:: console\n\n\tpip install redfish\n\n\nBuilding from zip file source\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n.. code-block:: console\n\n\tpython setup.py sdist --formats=zip (this will produce a .zip file)\n\tcd dist\n\tpip install redfish-x.x.x.zip\n\n\nRequirements\n------------\n\nEnsure the system does not have the OpenStack \"python-redfish\" module installed on the target system. This module is using a conflicting package name that this library already uses. The module in question can be found here: https://pypi.org/project/python-redfish/\n\n\nUsage\n----------\n\nA set of examples is provided under the examples directory of this project. In addition to the directives present in this paragraph, you will find valuable implementation tips and tricks in those examples.\n\n\nImport the relevant python module\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nFor a Redfish compliant application import the relevant python module.\n\nFor Redfish compliant application:\n\n.. code-block:: python\n\n\timport redfish\n\n\nCreate a Redfish Object\n~~~~~~~~~~~~~~~~~~~~~~~\n\nThe Redfish Objects contain 3 parameters: the target secured URL (i.e. \"https://IP\" or \"https://X.Y.Z.T\"), an user name and its password.\nThere are additional 2 optional parameters: timeout (in seconds before a connection initialization times out) and max_retry (how many times a request will retry after a timeout). If unset these default to None and 10 respectively.\nTo crete a Redfish Object, call the redfish_client method:\n\n.. code-block:: python\n\n\tREDFISH_OBJ = redfish.redfish_client(base_url=login_host, username=login_account, \\\n password=login_password, default_prefix='/redfish/v1')\n\n\nLogin to the server\n~~~~~~~~~~~~~~~~~~~\n\nThe login operation is performed when creating the REDFISH_OBJ. You can continue with a basic authentication, but it would less secure.\n\n.. code-block:: python\n\n\tREDFISH_OBJ.login(auth=\"session\")\n\n\nPerform a GET operation\n~~~~~~~~~~~~~~~~~~~~~~~\n\nA simple GET operation can be performed to obtain the data present in any valid path.\nAn example of rawget operation on the path \"/redfish/v1/systems/1\" is shown below:\n\n.. code-block:: python\n\n\tresponse = REDFISH_OBJ.get(\"/redfish/v1/systems/1\", None)\n\n\nPerform a POST operation\n~~~~~~~~~~~~~~~~~~~~~~~~\n\nA POST operation can be performed to create a resource or perform an action.\nAn example of a POST operation on the path \"/redfish/v1/systems/1/Actions/ComputerSystem.Reset\" is shown below:\n\n.. code-block:: python\n\n\tbody = {\"ResetType\": \"GracefulShutdown\"}\n\tresponse = REDFISH_OBJ.post(\"/redfish/v1/systems/1/Actions/ComputerSystem.Reset\", body=body)\n\n\nWorking with Tasks\n~~~~~~~~~~~~~~~~~~\n\nA POST operation may result in a task, describing an operation with a duration greater than the span of a single request.\nThe action message object that is_processing will return a Task resource that can be accessed reviewed when polled with monitor.\nAn example of a POST operation with a possible Task is shown below.\n\n.. code-block:: python\n\n\tbody = {\"ResetType\": \"GracefulShutdown\"}\n\tresponse = REDFISH_OBJ.post(\"/redfish/v1/systems/1/Actions/ComputerSystem.Reset\", body=body)\n if(response.is_processing):\n task = response.monitor(context)\n\n while(task.is_processing):\n retry_time = task.retry_after\n task_status = task.dict['TaskState']\n time.sleep(retry_time if retry_time else 5)\n task = response.monitor(context)\n\n\nLogout the created session\n~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nMake sure you logout every session you create as it will remain alive until it times out.\n\n.. code-block:: python\n\n\tREDFISH_OBJ.logout()\n\n\nA logout deletes the current sesssion from the system. The redfish_client object destructor includes a logout statement.\n\n\nContributing\n------------\n\n1. Fork it!\n2. Create your feature branch: `git checkout -b my-new-feature`\n3. Commit your changes: `git commit -am 'Add some feature'`\n4. Push to the branch: `git push origin my-new-feature`\n5. Submit a pull request :D\n\n\nRelease Process\n---------------\n\n1. Update `CHANGELOG.md` with the list of changes since the last release\n2. Update the ``__version__`` variable in ``src/redfish/__init__.py``, and ``setup.py`` to reflect the new library version\n3. Push changes to Github\n4. Create a new release in Github\n5. Push the new library version to pypi.org: ``python setup.py sdist && twine upload dist/*``\n\n\nCopyright and License\n---------------------\n\nCopyright Notice:\nCopyright 2016-2019 DMTF. All rights reserved.\nLicense: BSD 3-Clause License. For full text see link: `https://github.com/DMTF/python-redfish-library/blob/master/LICENSE.md `_", "description_content_type": "text/x-rst", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/DMTF/python-redfish-library", "keywords": "Redfish", "license": "BSD 3-clause \"New\" or \"Revised License\"", "maintainer": "", "maintainer_email": "", "name": "redfish", "package_url": "https://pypi.org/project/redfish/", "platform": "", "project_url": "https://pypi.org/project/redfish/", "project_urls": { "Homepage": "https://github.com/DMTF/python-redfish-library" }, "release_url": "https://pypi.org/project/redfish/2.1.3/", "requires_dist": null, "requires_python": "", "summary": "Redfish Python Library", "version": "2.1.3" }, "last_serial": 5960010, "releases": { "2.0.0": [ { "comment_text": "", "digests": { "md5": "2c369e06760a5ff33304558c38d6d1db", "sha256": "87b2fd688506bc1150fe61fa5a07c885730ebe293b200cd914df1530ff8e11ea" }, "downloads": -1, "filename": "redfish-2.0.0.tar.gz", "has_sig": false, "md5_digest": "2c369e06760a5ff33304558c38d6d1db", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28380, "upload_time": "2018-05-25T14:46:49", "url": "https://files.pythonhosted.org/packages/8f/23/636b80a739684dd23d532112141007fdfefdad8977448af263c9fdd603bf/redfish-2.0.0.tar.gz" } ], "2.0.1": [ { "comment_text": "", "digests": { "md5": "357dea3b1472d28e10b9e398696612c9", "sha256": "f551c5e572e98df21bd7c6db2653c7de85ef9d7a3c8a63ef7902bd3787a9ce4e" }, "downloads": -1, "filename": "redfish-2.0.1.tar.gz", "has_sig": false, "md5_digest": "357dea3b1472d28e10b9e398696612c9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28374, "upload_time": "2018-05-25T14:51:12", "url": "https://files.pythonhosted.org/packages/7e/15/448ca286ae94fe270ec8d6e05b78eb3f58bdb361fc454137ffb5c17f6071/redfish-2.0.1.tar.gz" } ], "2.0.2": [ { "comment_text": "", "digests": { "md5": "97a82f10ffc9eeb823a8b8a21d882a2a", "sha256": "bc9702a2609ac3e96f2ed1acba01b4e40cfe5992d74d103acc3062ee45eb278c" }, "downloads": -1, "filename": "redfish-2.0.2.tar.gz", "has_sig": false, "md5_digest": "97a82f10ffc9eeb823a8b8a21d882a2a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 30724, "upload_time": "2018-09-07T19:22:11", "url": "https://files.pythonhosted.org/packages/b9/36/51c5f265c3fbae941d109f4b127731d9c850f19e1bb48d589df66411e0f9/redfish-2.0.2.tar.gz" } ], "2.0.3": [ { "comment_text": "", "digests": { "md5": "88f78bfde555d2ecbbbbc1001c0f449b", "sha256": "8c6e617d9ae44d6fc5d0802ccabbd244beac926f6009975acd89230df74382cd" }, "downloads": -1, "filename": "redfish-2.0.3.tar.gz", "has_sig": false, "md5_digest": "88f78bfde555d2ecbbbbc1001c0f449b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 30939, "upload_time": "2018-10-19T12:49:25", "url": "https://files.pythonhosted.org/packages/e3/f3/804ac4699b0f2de016b5f27ca776469840761bc2604ab2b4701753da60ad/redfish-2.0.3.tar.gz" } ], "2.0.4": [ { "comment_text": "", "digests": { "md5": "4fb273adfa2b887cf32164ccdd1d4865", "sha256": "84980c82444ca9fd72490c2626518b79c255e52ac285447d9afe88f2c2469852" }, "downloads": -1, "filename": "redfish-2.0.4.tar.gz", "has_sig": false, "md5_digest": "4fb273adfa2b887cf32164ccdd1d4865", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 31948, "upload_time": "2018-10-26T12:28:19", "url": "https://files.pythonhosted.org/packages/2f/03/d135a4ad8ec04086ffb21492121ca6ed0a77e0e67a4b2a75f744f92084a8/redfish-2.0.4.tar.gz" } ], "2.0.5": [ { "comment_text": "", "digests": { "md5": "1b46d902e6dc02798d6b0b587be84556", "sha256": "dcd1123f50f39c44a3c35ac4ed141a42f02a591f2e823558ccde7bb57ca5a09b" }, "downloads": -1, "filename": "redfish-2.0.5.tar.gz", "has_sig": false, "md5_digest": "1b46d902e6dc02798d6b0b587be84556", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 31944, "upload_time": "2018-11-30T18:17:00", "url": "https://files.pythonhosted.org/packages/1f/5f/2b2585cdd6239bf8cead7f5fb593739992ce364ea2473b3219cf8a80abee/redfish-2.0.5.tar.gz" } ], "2.0.6": [ { "comment_text": "", "digests": { "md5": "f22bef312ee61755c49fb5a924db8a71", "sha256": "312599676382306252f4950ec39f2152b032f1087e9ee058dda91742f257bcfa" }, "downloads": -1, "filename": "redfish-2.0.6.tar.gz", "has_sig": false, "md5_digest": "f22bef312ee61755c49fb5a924db8a71", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 32239, "upload_time": "2019-01-11T14:32:29", "url": "https://files.pythonhosted.org/packages/f3/7e/447c72279b7bed254b9844bd4a72a718b057fc5549308e814be12a165c7f/redfish-2.0.6.tar.gz" } ], "2.0.7": [ { "comment_text": "", "digests": { "md5": "aa173dd525b12ff9b8f56efc3b648606", "sha256": "cc6a2422e3b8f6fd9986a86a6672c589f50a67abe73f978a336a653ce375bd10" }, "downloads": -1, "filename": "redfish-2.0.7.tar.gz", "has_sig": false, "md5_digest": "aa173dd525b12ff9b8f56efc3b648606", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 32526, "upload_time": "2019-02-08T16:00:40", "url": "https://files.pythonhosted.org/packages/dd/f4/32a15f4a69b9e57aaba01c7e70560902430ff08be25c9eef6cb0521e3b1c/redfish-2.0.7.tar.gz" } ], "2.0.8": [ { "comment_text": "", "digests": { "md5": "66fdbef310b3a9982807ddd8478b4598", "sha256": "3fa752bab932e387ea435d3c38a05696441584e17d94fa7a94a9c44aa4557059" }, "downloads": -1, "filename": "redfish-2.0.8.tar.gz", "has_sig": false, "md5_digest": "66fdbef310b3a9982807ddd8478b4598", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 33310, "upload_time": "2019-05-17T14:59:36", "url": "https://files.pythonhosted.org/packages/46/53/4f6301eb7d315715b5decbb79b824bddaaef071cf329f2b4bfb40b7fbb28/redfish-2.0.8.tar.gz" } ], "2.0.9": [ { "comment_text": "", "digests": { "md5": "9cdfe8ef0376e103749ecb89e54a920b", "sha256": "8257a14c49ee872813fbfdf2d074b609637ec87f09e80beb61a065440c69ea0e" }, "downloads": -1, "filename": "redfish-2.0.9.tar.gz", "has_sig": false, "md5_digest": "9cdfe8ef0376e103749ecb89e54a920b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 33744, "upload_time": "2019-06-28T12:04:17", "url": "https://files.pythonhosted.org/packages/f9/53/155db293117877674f69c2a6ddacf933d1cbdbd78c84fb2e7e868c9bc9ca/redfish-2.0.9.tar.gz" } ], "2.1.0": [ { "comment_text": "", "digests": { "md5": "aea9f7fa5c39c2285809c1b9246c27ce", "sha256": "4e0f7bfe4d062680c2e8fe721c6b450eade3eab4583db9e3d66bf3ecffd22df6" }, "downloads": -1, "filename": "redfish-2.1.0.tar.gz", "has_sig": false, "md5_digest": "aea9f7fa5c39c2285809c1b9246c27ce", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 33719, "upload_time": "2019-07-12T12:39:56", "url": "https://files.pythonhosted.org/packages/3c/7b/a57d5380a1ad125875e5d23257cd6217c3a699106b693fe2f876417cea0d/redfish-2.1.0.tar.gz" } ], "2.1.1": [ { "comment_text": "", "digests": { "md5": "82a8f15dcd1083bbf7928514f78520dc", "sha256": "9e45b8bb7a4740b43013d12be175eb9846e70b3b58085a343325f2f7eccc3556" }, "downloads": -1, "filename": "redfish-2.1.1.tar.gz", "has_sig": false, "md5_digest": "82a8f15dcd1083bbf7928514f78520dc", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 33778, "upload_time": "2019-08-16T12:19:23", "url": "https://files.pythonhosted.org/packages/90/75/d8b6d683b8625f20328b205bbfcd054d582e41dad1d2b1562bc8a93eeaeb/redfish-2.1.1.tar.gz" } ], "2.1.2": [ { "comment_text": "", "digests": { "md5": "537992bc02d1694b66ee4b1a518be591", "sha256": "c883efbecbffe87fa6206c42fa8a97e204142fc2514ed624aaefe6cc1d98c520" }, "downloads": -1, "filename": "redfish-2.1.2.tar.gz", "has_sig": false, "md5_digest": "537992bc02d1694b66ee4b1a518be591", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 33833, "upload_time": "2019-09-16T17:46:36", "url": "https://files.pythonhosted.org/packages/3d/98/156767899650b4ff71d462629973430b8fe29213d2082f021157beba8657/redfish-2.1.2.tar.gz" } ], "2.1.3": [ { "comment_text": "", "digests": { "md5": "7771504fe1ffa032fb373e1916e5bcb9", "sha256": "320f0f009d4a3c1ba33ea46c114d1592427db54bd954fd74323b2abaeb4dd448" }, "downloads": -1, "filename": "redfish-2.1.3.tar.gz", "has_sig": false, "md5_digest": "7771504fe1ffa032fb373e1916e5bcb9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 34079, "upload_time": "2019-10-11T12:19:28", "url": "https://files.pythonhosted.org/packages/c9/17/63721640ac37dfa1c0a392263f5fcd3938cd2b3b52c718bfa0b8a4b69388/redfish-2.1.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "7771504fe1ffa032fb373e1916e5bcb9", "sha256": "320f0f009d4a3c1ba33ea46c114d1592427db54bd954fd74323b2abaeb4dd448" }, "downloads": -1, "filename": "redfish-2.1.3.tar.gz", "has_sig": false, "md5_digest": "7771504fe1ffa032fb373e1916e5bcb9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 34079, "upload_time": "2019-10-11T12:19:28", "url": "https://files.pythonhosted.org/packages/c9/17/63721640ac37dfa1c0a392263f5fcd3938cd2b3b52c718bfa0b8a4b69388/redfish-2.1.3.tar.gz" } ] }