Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/bx2/queuer

A simple Flask-based app for queued registration.
https://github.com/bx2/queuer

Last synced: 13 days ago
JSON representation

A simple Flask-based app for queued registration.

Awesome Lists containing this project

README

        

Queuer
======

A very simple, flask-based app to handle queued registration.

Install the app:
----------------

```
# Install requirements
$ pip install -r requirements.txt

# Create an empty database
$ python db.py

# Run the service
$ python app.py
```

Give it a try:
--------------

```
>> import requests, json
>> requests.get('http://localhost:5000/registrations').json()
[]
>> requests.post('http://localhost:5000/registrations',
headers={'Content-Type': 'application/json'},
data=json.dumps({'email': '[email protected]'}).json()
{
"created_on": "2014-06-28T23:01:24.312810",
"email": "[email protected]",
"invited": false,
"position": 1,
"waiting_before": 0
}
>> requests.get('http://localhost:5000/registrations/[email protected]').json()
{
"created_on": "2014-06-28T23:01:24.312810",
"email": "[email protected]",
"invited": false,
"position": 1,
"waiting_before": 0
}
```

Don't forget that you must past a `Content-Type: application/json` header along
w/ your request!

Credits:
--------

Big thanks to Max Mautner (https://github.com/mmautner) for publishing his `simple_api` project
which made it much easier for me to write Queuer.