[Tutor] Create a database from api requests

Joao Carlos Silva de Oliveira Matos joao.oliveira at ufob.edu.br
Sat May 15 13:58:04 EDT 2021


Hello everyone,

My friends and I play tournaments every week and we decided to create a
league with the sum of points from each weekly tournament. The results can
be accessed via API Rest. The API response is a nested JSON file.
I started to run the code on the first of May, using a filter to only get
results from that day on. But I am realizing that the code is taking more
and more time to load since the amount of data only increases.
So I need to set up a database. Searching through the internet I saw two
accessible ways. The first one is to save this data in cache in an SQLite
file, the other one is to transform it into CSV and append new data every
day.
Could someone tell me what is the best strategy here? Transforming nested
JSON in data frames does not look so simple. I would like my code to run as
quickly as possible. Would anyone have good documentation or examples for
me to study?

--


More information about the Tutor mailing list