ilo API
API v2
v2 of the API is in development and will let you access data for all of your connected accounts.
GET /v2/counters/<id>/
This endpoint lets you get data for a specific counter.
Note: there is no authentication on this endpoint.
Options
include
: add more data to the response. Options:
info
basic counter info (name
,last_updated
,is_monetary
)account
account informationtoday
today's changehistory
historical data
days
: if history
is requested, how many days of data to return, from today backwards e.g. 30
Example requests
GET https://api.ilo.so/v2/counters/ywjnff77/
{ "id": "ywjnff77", "count": 55394 }
If the counter is monetary (for example an "MRR" counter), a currency_code
attribute will be included by default.
{ "id": "ywjnff77", "count": 12345, "currency_code": "USD" }
GET https://api.ilo.so/v2/counters/ywjnff77/?include=info,account,today
{ "id": "ywjnff77", "count": 55394, "name": "Followers", "last_updated": 1731315619.1048, "is_monetary": false, "today": 2, "account": { "name": "@dr", "platform": { "id": "x", "name": "𝕏" } } }To get historical data, add
history
to include
and then how many days you want to return, like &days=28
.
GET https://api.ilo.so/v2/counters/ywjnff77/?include=info,today,history&days=14
{ "id": "ywjnff77", "count": 55394, "name": "Followers", "last_updated": 1731315619.1048, "is_monetary": false, "today": -5, "account": { "name": "@dr", "platform": { "id": "x", "name": "𝕏" } }, "history": [ { "2024-10-29": 55375 }, { "2024-10-30": 55379 }, ... { "2024-11-10": 55399 }, { "2024-11-11": 55394 } ], "history_daily": [ { "2024-10-29": 7 }, { "2024-10-30": 4 }, ... { "2024-11-10": 0 }, { "2024-11-11": -5 } ] }
API v1
The ilo v1 API lets you access some of your Twitter analytics programmatically.
Endpoints
There is currently only one endpoint available.
GET https://api.ilo.so/v1/stats/USERNAME/
With this endpoint you can get total and daily stats from your account.
Options
history
(default 7
): define how many days of data to return.
Example request
GET https://api.ilo.so/v1/stats/dr/?history=30
This will get 30 days of history for the @dr account.
Example response
{ "followers": 9521, "following": null, // deprecated since 17th September 2024 "tweets": 8144, "followers_total_daily": [ { "2021-02-19": 9376 }, { "2021-02-20": 9414 }, { "2021-02-21": 9448 }, { "2021-02-22": 9460 }, { "2021-02-23": 9486 }, { "2021-02-24": 9505 }, { "2021-02-25": 9521 } ], "following_total_daily": [], "tweets_total_daily": [ { "2021-02-19": 8085 }, { "2021-02-20": 8096 }, { "2021-02-21": 8099 }, { "2021-02-22": 8110 }, { "2021-02-23": 8118 }, { "2021-02-24": 8127 }, { "2021-02-25": 8144 } ], "followers_daily": [ { "2021-02-19": 13 }, { "2021-02-20": 38 }, { "2021-02-21": 34 }, { "2021-02-22": 12 }, { "2021-02-23": 26 }, { "2021-02-24": 19 }, { "2021-02-25": 16 } ], "following_daily": [], "tweets_daily": [ { "2021-02-19": 13 }, { "2021-02-20": 11 }, { "2021-02-21": 3 }, { "2021-02-22": 11 }, { "2021-02-23": 8 }, { "2021-02-24": 9 }, { "2021-02-25": 17 } ] }