Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/mewebstudio/flask-rest-boilerplate

Flask Rest API Boilerplate
https://github.com/mewebstudio/flask-rest-boilerplate

flask jwt jwt-auth jwt-authentication postgresql python rest rest-api sqlalchemy swagger swagger-ui

Last synced: 2 days ago
JSON representation

Flask Rest API Boilerplate

Awesome Lists containing this project

README

        

# flask-rest-boilerplate

###### Installation
```bash
pip install -r requirements.pip
```

for development
```bash
cp .env.dev .env
```

for production
```bash
cp .env.prod .env
```

###### Migrate DB
```bash
$ python manage.py db init
$ python manage.py db migrate
$ python manage.py db upgrade
```

###### Load dummy data
```bash
$ python fixtures.py
```

###### Mailing example
```bash
from flask_mail import Message
from settings import mail

def send_email():
msg = Message(
subject='Hello',
sender=('Sender Name', '[email protected]'),
recipients=['[email protected]'],
html='

Hello,

body

',
)
mail.send(msg)
```