Skip to main content
Join the official Python Developers Survey 2018 and win valuable prizes: Start the survey!

A RESTful web API for Mezzanine CMS.

Project description

https://pypip.in/version/mezzanine-api/badge.svg https://pypip.in/license/mezzanine-api/badge.svg

Created by George Cushen

Overview

Mezzanine API is a RESTful web API built using the Django framework which extends the Mezzanine content management platform. The API empowers developers to automate, extend and combine Mezzanine with other services such as Ember.js or a mobile app.

Features

  • REST API resources for posts, pages, users, and categories
  • Apply filters and search queries to narrow down results
  • OAuth 2.0 allows users to authorize and revoke access to third party applications without the need for those applications to request the user’s credentials
  • Web browsable API
  • Endpoints documented with Swagger UI
  • Leverages Django Rest Framework

Roadmap

  • More endpoints
  • Refinement
  • Writeable API access
  • Test Suite
  • Further documentation for configuration and customization

Installation

  1. Install from PyPI:

    $ pip install mezzanine-api
    
  2. Add the following apps to INSTALLED_APPS in your Mezzanine settings.py:

    INSTALLED_APPS = (
        ...
        'mezzanine_api',
        'rest_framework',
        'rest_framework_swagger',
        'oauth2_provider',
    )
    
  3. Also, add the following lines at the end of your settings.py module:

    #####################
    # REST API SETTINGS #
    #####################
    try:
        from mezzanine_api.settings import *
    except ImportError as e:
        pass
    
  4. Add the following code in your Mezzanine urls.py somewhere after the urlpatterns = [] line:

    # REST API URLs
    urlpatterns += patterns("",
        ("^api/", include("mezzanine_api.urls")),
    )
    
  5. Migrate the database to support Oauth2:

    $ python manage.py migrate
    
  6. Start the server:

    $ python manage.py runserver
    
  7. Visit http://127.0.0.1:8000/api/docs/ to view the endpoint documentation and query the API.

Contributing

Mezzanine API is an open source project managed using the Git version control system. The repository is hosted on GitHub , so contributing is as easy as forking the project and committing back your enhancements.

Support

If you have questions about the API, consider discussing them on the mezzanine-users mailing list.

Otherwise, if you have found a bug, please use the GitHub issue tracker and include the steps necessary to reproduce it.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
mezzanine_api-0.2.0-py2.py3-none-any.whl (14.1 kB) Copy SHA256 hash SHA256 Wheel py2.py3 May 13, 2015
mezzanine-api-0.2.0.tar.gz (10.8 kB) Copy SHA256 hash SHA256 Source None May 13, 2015

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page