building a simple flask api for data storage and retrieval