Is there a way to get all posts for a given subreddit instead of just the posts newer than one month?

StackOverflow https://stackoverflow.com/questions/18881887

  •  29-06-2022
  •  | 
  •  

문제

Is there a way to get all posts for a given subreddit instead of just the posts newer than one month?

For example, this is the "last" page of posts from IAmA subreddit we can get to, http://www.reddit.com/r/IAmA/?count=900&limit=100&after=t3_1k3tm1, and clearly this is not the last page of posts. It does not include any posts older than one month.

도움이 되었습니까?

해결책

After playing around with Reddit, I found a way to fetch all posts of a given subreddit is to use its search interface: http://www.reddit.com/r/<subreddit>/search.json?restrict_sr=on&t=all. For example, you can get all posts under IAmA subreddit using this request endpoint: http://www.reddit.com/r/IAmA/search.json?restrict_sr=on&t=all

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top