Skip to content

slimovich/api-example-djangoRestFramework

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🛠 Status: WIP

Under developement, WIP. Be patient.

Overview

Implement an API using django and djangorestframwork

Features

  • /towns - ​Returns a list of towns.
  • /aggs ​- Returns aggregation results on towns’ populations
  • /query ​- Returns the generated SQLite query for the JSON query given as input

Quick start

  • install the dependencies locally
./setup/scripts/install
  • migrate the database
./setup/scripts/migrate
  • populate the database
./setup/scripts/populate_db
  • run unit test
./setup/scripts/test
  • run the server
./setup/scripts/run

Test

Use the script populate_db to populate data base with src/data/French_Towns_Data.csv