Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

A REST API framework for building CRUD APIs using Flask and peewee (forked from sanic_crud https://github.com/Typhon66/sanic_crud)

Project Description

flask-peewee-crud forked from sanic_crud

flask-peewee-crud is a REST API framework for creating a CRUD (Create/Retrieve/Update/Delete) API using Flask and PeeWee You can use flask-peewee-crud to automatically create an API from your PeeWee models, see how it works in the Documentation

Contributions to the repository are welcome!

Example

from peewee import CharField, DateTimeField, SqliteDatabase, Model
import datetime
from flask import Flask
from flask_peewee_crud import generate_crud

db = SqliteDatabase('my_app.db')

class BaseModel(Model):
    class Meta:
        database = db

class Person(BaseModel):
    name = CharField()
    email = CharField()
    create_datetime = DateTimeField(default=datetime.datetime.now, null=True)

db.create_tables([Person])

app = Flask(__name__)
generate_crud(app, [Person])
app.run(host="0.0.0.0", port=8000, debug=True)

Installation

python -m pip install flask-peewee-crud

Documentation

Documentation can be found in the docs directory.

TODO

Release History

This version
History Node

0.3.0

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
flask-peewee-crud-0.3.0.tar.gz
(12.3 kB) Copy SHA256 Hash SHA256
Source None Oct 29, 2017

Supported By

Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Google Google Cloud Servers DreamHost DreamHost Log Hosting