The data used in Klipfolio is extracted by a Python script running in AWS Lambda.
The scripts run every day at 02:00AM GMT. The scheduler can be found at Amazon EventBridge
The scripts fetches data inside a date range, determined in each by two variables xpto_date_start
and xpto_date_end
:
For example in opens_6M function we see the two variables open_date_start
and open_date_end
that determine the period for the last 6 months.
The reference is ALWAYS the current year and month, although, if you want to fetch past data you can change the variables cur_month
and cur_year
to the desired ones.
# Open 6M
open_date_start = (datetime.date(cur_year, cur_month, 1) + datetime.timedelta(-5*365/12)).strftime('%Y-%m-%d')
open_date_end = last_day_of_month(datetime.date(cur_year, cur_month, 1)).strftime('%Y-%m-%d')
cur_month = datetime.datetime.today().month
cur_year = datetime.datetime.today().year
Example
If you want to get data of total matters opened in the last 6 monhts at March 2018 you can to it simply assigning:
cur_month = 3
cur_year = 2018
And call the function clicking on TEST
.
The output is stored on PhotoClaim's Dropbox at https://www.dropbox.com/sh/.../...?dl=0