Skip to content

VRDate/pyrest

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 

Repository files navigation

PyRest

Example building rest services in python and interacting with DynamoDB

Setup

Pip & sqlite

sudo apt-get install pip    
sudo apt-get install sqlite3 libsqlite3-dev

Install Python Packages

flask, boto, dynamodb-mapper, urllib, httplib, json

PyRest Scripts

Run these scripts to see the example code work

Create a mock dynamo db; NOTE: you'll have to ctrl-z to break this script due to create_table bug

python src/main/db_create.py

Start rests services (in separate terminal)

python src/main/rest_test.py

Post data through rest service to mock dynamo db

python src/main/post_rest_test.py 1 'hello world'

Read back the data from mock dynamo db through rest service

python src/main/get_rest_test.py 1

Clean up the mock dynamodb

rm /tmp/pyrest.sqlite

Resources

REST Python Package

DynamoDB Python Package

About

example of python rest with flask

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published