alefrost / pokedex

Personal project utilizing the PokeAPI project made by Paul Hallett
0 stars 0 forks source link

Learn to add PokeAPI data via script #1

Closed alefrost closed 10 years ago

alefrost commented 10 years ago

Explore the options for writing a script to fetch data and insert it into the couchDB instance. Looking into writing a bash script to do it.

alefrost commented 10 years ago

One thought is to use js to grab the pokedex and then loop over each Mon in the list and pass json to php to save json file in a directory. Then repeat process for things like moves, abilities, etc. saving each set as json files. Then, run a bash script to loop through all the .json files in the directory and insert them into couch db.

alefrost commented 10 years ago

I was able to connect to couchdb via javascript ajax function. This article explained the proper things to change/add to my couchdb configuration to enable CORS.

alefrost commented 10 years ago

Successfully able to add json object to couchdb instance using javascript! Next step is #2