Server for CS446 project
export FLASK_APP=app.py
flask run
GET /words
- Returns list of 10 words
To ingest new words into mongodb:
- Create an Oxford Dictionary API account at https://developer.oxforddictionaries.com/signup?plan_ids[]=2357356361005
- Create a
.env
file in directory of cs446-server/ containing mongodb and oxford API credentials- Replace
OXFORD_APP_ID
andOXFORD_SECRET
env variables with your Application ID and Application Key
- Replace
python scrape_oxford.py
- this randomly sampleswords.txt
and appends words toparsed_words_us.txt
andparsed_words_uk.txt
python upload_words.py
- this ingests the words fromparsed_words_us.txt
andparsed_words_uk.txt
into mongodb