{ "info": { "author": "Rich Jones", "author_email": "rich@openwatch.net", "bugtrack_url": null, "classifiers": [ "Environment :: Web Environment", "Framework :: Django", "Intended Audience :: Developers", "License :: OSI Approved :: Apache Software License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7", "Topic :: Internet :: WWW/HTTP", "Topic :: Internet :: WWW/HTTP :: Dynamic Content" ], "description": "![Easy peasy!](http://i.imgur.com/LQujlwt.png)\n\ndjango-easy-api\n===============\n\n**django_easy_api** lets you create an API for your Django project by changing only a single line of code! \n\nThe easiest way to use **django_easy_api** is to simply replace render_to_response:\n\n```python\n# from django.shortcuts import render_to_response\nfrom easy_api.shortcuts import render_to_response \n```\n\nSo if this returns a rendered HTML view:\n\n http://yoursite.com/item/23\n\nthen this returns a JSON serialized view of the same page:\n\n http://yoursite.com/item/23?api=json\n\nand this returns an XML serialized view of the same page:\n\n http://yoursite.com/item/23?api=xml\n\nHooray! You literally don't have to do anything else.\n\n#### Installation\n\n0. Install django-easy-split\n\n ```python\n pip install django-easy-api\n ```\n\n1. Add 'easy_api' to your INSTALLED_APPS setting like this:\n\n ```python\n INSTALLED_APPS = (\n ...\n 'easy_api',\n )\n ```\n\n## Usage\n\nThe easiest way to use **django_easy_api** is to simply replace render_to_response:\n\n```python\n# from django.shortcuts import render_to_response\nfrom easy_api.shortcuts import render_to_response \n```\n\nNow, all of your views will have API versions as well!\n\nIf you only want to use **django_easy_api** for certain views, you can use it explicitly:\n\n```python\nfrom easy_api.shortcuts import render_to_easy_api_response\n```\nand then use it in your view instead of render_to_response.\n\n## Notes\n\nOkay, okay, so it's not a FULL API. It's just for GETs. If you want a full-featured API, look at [Django-Rest-Framework](http://www.django-rest-framework.org/). However, if you just need a machine-readable version of your site, this is far and away the easiest way to do it!\n\n### TODO:\n\n* I don't know what it does for ForeignKeys. To be tested!\n* I haven't tested this in production, but it should work.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/Miserlou/django-easy-api", "keywords": null, "license": "MIT License", "maintainer": null, "maintainer_email": null, "name": "django-easy-api", "package_url": "https://pypi.org/project/django-easy-api/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-easy-api/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/Miserlou/django-easy-api" }, "release_url": "https://pypi.org/project/django-easy-api/0.3.0/", "requires_dist": null, "requires_python": null, "summary": "Create an API for you Django project with only a single line of code!", "version": "0.3.0" }, "last_serial": 1188093, "releases": { "0.3.0": [] }, "urls": [] }