I've been following the Reddit API documentation but I think I'm doing something wrong. When I try searching one particular subreddit for a query, it brings back results for all subreddits.
In this example I want to return all the posts in /r/Volvo relating to wagons, however the query returns corresponding posts for numerous subbreddits.
http://www.reddit.com/r/volvo/search.xml?q=wagon
So am I missing something glaringly obvious? (I guess I am!)
Thanks in advance.
The default behavior returns results from all subreddits.
To restrict results to the subreddit, multireddit, or domain-listing in the URL, use the
restrict_sr
query parameter, like so:See also https://www.reddit.com/dev/api#GET_search