{ "info": { "author": "Matthew Fisher", "author_email": "me@bacongobbler.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Software Development :: Libraries", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "Python-Stackato\n===============\n\n[![PyPi version](https://pypip.in/v/python-stackato/badge.png)](https://crate.io/packages/python-stackato/)\n[![PyPi downloads](https://pypip.in/d/python-stackato/badge.png)](https://crate.io/packages/python-stackato/)\n\nA wrapper to the Stackato Client API. Allows users to make requests to the Stackato API. Easy Peasy Lemon Squeezy.\n\nTo read up more on the Stackato Client API, please see the documentation [here](http://docs.stackato.com/api/client.html).\n\n## Installation\n\n pip install python-stackato\n\nalternatively...\n\n git clone https://github.com/bacongobbler/python-stackato\n python setup.py install\n\n## Usage\n\nTake a look at the examples/ folder for some real-life examples.\n\n### Logging into the client\n\n```python\nfrom stackato import Session\n\ns = Session(\"https://api.stackato-xxxx.local/\")\ns.login(\"username\", \"password\")\n```\n\n### Passwordless Authentication\n\nThis is for when you have previously logged in and the token is stored\nwithin your client token file (hidden at ~/.stackato/client/token)\n\n```python\nfrom stackato import Session\ns = Session(\"https://api.stacka.to/\")\nif s.login():\n print(s._get('info'))\n```\n\n### Storing the authentication token locally, and deleting an app\n\n```python\nfrom stackato import Session\n\n# Spot the difference!\ns = Session(\"https://api.stackato-xxxx.local/\")\n\nif s.login(store_token=True):\n s.delete_app('demo')\n```\n\n### Lisng all services bound to an app\n\n```python\nfrom stackato import Session\n\ns = Session(\"https://api.stackato-xxxx.local/\")\n\nif s.login():\n print(s.get_app('demo').services)\n```\n\n### Forcing your app to increase its number of instances by one\n\n```python\nfrom stackato import Session\n\ns = Session(\"https://api.stackato-xxxx.local/\")\n\nif s.login():\n app = s.get_app('demo')\n app['instances'] += 1\n \n # make a PUT request to the application\n if s.put_app('demo', app):\n print('added one more instance to this application.')\n```\n\n### Making a custom GET request\n\nThis will also work with _post(), _put(), and _delete(). You can also take a look at _request() if you want to make your own custom request call.\n\n```python\nfrom stackato import Session\n\ns = Session(\"https://api.stackato-xxxx.local/\")\n\nif s.login():\n print(s._get('stackato/usage?all=1'))\n```\n", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://www.github.com/bacongobbler/python-stackato/", "keywords": null, "license": "MIT License", "maintainer": null, "maintainer_email": null, "name": "python-stackato", "package_url": "https://pypi.org/project/python-stackato/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/python-stackato/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://www.github.com/bacongobbler/python-stackato/" }, "release_url": "https://pypi.org/project/python-stackato/1.4/", "requires_dist": null, "requires_python": null, "summary": "Python interface to Stackato", "version": "1.4" }, "last_serial": 884590, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "c828523504414089381cecdfa4fb61df", "sha256": "01eb292887fb3c8b6162c4482434257a84985befdfa3a0c5dce14e9bdc4d4cef" }, "downloads": -1, "filename": "python-stackato-0.1.tar.gz", "has_sig": false, "md5_digest": "c828523504414089381cecdfa4fb61df", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4180, "upload_time": "2013-07-29T18:23:08", "url": "https://files.pythonhosted.org/packages/f7/ad/b557fc99d47360a01afb508a793ba035891a41e1afdc36bd524ba895d420/python-stackato-0.1.tar.gz" } ], "1.0": [ { "comment_text": "", "digests": { "md5": "2e1cc88886e1f7b9cdbaa069a0dcb5cf", "sha256": "c65def9d70d159f2e6e1c711f74ac9e276fa7ace04292092254f70d20c3966db" }, "downloads": -1, "filename": "python-stackato-1.0.tar.gz", "has_sig": false, "md5_digest": "2e1cc88886e1f7b9cdbaa069a0dcb5cf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4184, "upload_time": "2013-07-29T18:35:17", "url": "https://files.pythonhosted.org/packages/45/d6/b84dca4bc6a9d7f1007da98a2d16be845ed2c30c095fc7b1cf0807286bd9/python-stackato-1.0.tar.gz" } ], "1.1": [], "1.2": [], "1.3": [ { "comment_text": "", "digests": { "md5": "598bfc5ae695c56ccee7e781bbccba0f", "sha256": "b5a9ec8db2df88671645045921445f33869cba0f0451e46dd829cf4237613662" }, "downloads": -1, "filename": "python-stackato-1.3.tar.gz", "has_sig": false, "md5_digest": "598bfc5ae695c56ccee7e781bbccba0f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4351, "upload_time": "2013-09-05T16:04:48", "url": "https://files.pythonhosted.org/packages/ab/a1/5ffa6aa5f01efa62d141ef458ef2299ad8e2614762f9d17ad805a6fcfa37/python-stackato-1.3.tar.gz" } ], "1.4": [ { "comment_text": "", "digests": { "md5": "46e1a5c173c62ad0c87aca1f81492b0b", "sha256": "9832b4f1bcea75061d6f0f2f96a7ebe18fa38287b5352d3b6871d994cf58aca2" }, "downloads": -1, "filename": "python-stackato-1.4.tar.gz", "has_sig": false, "md5_digest": "46e1a5c173c62ad0c87aca1f81492b0b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4309, "upload_time": "2013-10-08T21:06:13", "url": "https://files.pythonhosted.org/packages/f0/2b/ad9625d665830cc199a52cfa6dc1476ae830ed4e32004eb5ea582e806745/python-stackato-1.4.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "46e1a5c173c62ad0c87aca1f81492b0b", "sha256": "9832b4f1bcea75061d6f0f2f96a7ebe18fa38287b5352d3b6871d994cf58aca2" }, "downloads": -1, "filename": "python-stackato-1.4.tar.gz", "has_sig": false, "md5_digest": "46e1a5c173c62ad0c87aca1f81492b0b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4309, "upload_time": "2013-10-08T21:06:13", "url": "https://files.pythonhosted.org/packages/f0/2b/ad9625d665830cc199a52cfa6dc1476ae830ed4e32004eb5ea582e806745/python-stackato-1.4.tar.gz" } ] }