1
0
mirror of https://github.com/zedeus/nitter.git synced 2025-12-13 07:42:48 -05:00

Use old user endpoint to avoid graphql rate limits

This commit is contained in:
Zed
2020-06-01 09:46:17 +02:00
parent 39863703b3
commit 74534e8fef
4 changed files with 21 additions and 1 deletions

View File

@@ -32,6 +32,12 @@ proc getListMembers*(list: List; after=""): Future[Result[Profile]] {.async.} =
url = listMembers ? ps
result = parseListMembers(await fetch(url, oldApi=true), after)
proc getProfile*(username: string): Future[Profile] {.async.} =
let
ps = genParams({"screen_name": username})
url = userLookup ? ps
result = parseUserShow(await fetch(url, oldApi=true), username)
proc getTimeline*(id: string; after=""; replies=false): Future[Timeline] {.async.} =
let
ps = genParams({"userId": id, "include_tweet_replies": $replies}, after)