I am writing some python code where I want access the streaming API. I have been able to access the RESTful API. I have my OAUTH_TOKEN and OAUTH_TOKEN_SECRET, which I used for the RESTful API access. For the streaming API, I am not sure if I need to pass additional OAUTH parameters as when I try right now I get error 401, which means unauthorized. I tried:
x = requests.get(url=“https://stream.twitter.com/1.1/statuses/filter.json?track=canucks”, auth=oauth)
I’ve defined oauth as:
oauth = OAuth1(CONSUMER_KEY,
I did see a page on the dev site for authorizing a request https://dev.twitter.com/docs/auth/authorizing-request and it passes several parameters. Any help/pointers for how I can proceed is greatly appreciated. I am not a full-time programmer, but I am learning python as much as I can on the fly by reading various web pages online.