- MySQL
- Miniconda
- conda create -n playlist
- pip install -r requirements.txt
- mysql.server start
- USER='fill in your db user' PASSWORD='fill in your db password' py.test main_test.py
- mysql.server start
- USER='fill in your db user' PASSWORD='fill in your db password' python main.py
When the api server starts, it creates a database called daily_motion and two tables (playlist and video).
curl -X POST \http://localhost:8080/playlists/first%20playlist
curl -X PUT \http://localhost:8080/playlists/1/first
curl -X GET \http://localhost:8080/playlists
curl -X GET \http://localhost:8080/playlists/1
curl -X DELETE \http://localhost:8080/playlists/1
curl -X POST \http://localhost:8080/videos/1/title/thumbnail
curl -X PUT \http://localhost:8080/videos/1/1/2
curl -X GET \http://localhost:8080/videos
curl -X GET \http://localhost:8080/videos/1
curl -X DELETE \http://localhost:8080/videos/1/1
- Separate playlists and videos tests into different modules
- Handle database changes like tables changes
- Handle 500 errors due to Database IOs (try catch)
- Authentication
- Query params
- Improve function docstring