Skip to main content

UNKNOWN

Project description

https://drone.io/bitbucket.org/eodolphi/flask-json-resource/status.png

Flask JSON Resource

Quickly create REST api’s using json-schema.

Minimal Example

from flask import Flask

from flask.ext.pymongo import PyMongo
from json_resource import Schema
from flask.ext.json_resource import API

app = Flask('test')
app.debug = True

db = PyMongo(app)
api = API(app, db)

@api.register()
class TestResource(api.Resource):
    schema = Schema({'id': 'test'})


class TestResourceCollection(api.CollectionResource):
    schema = Schema({'id': 'test-collection'})
    objects = TestResource.objects

Project details


Download files

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

Source Distribution

flask_json_resource-0.2.18.tar.gz (18.5 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page