[racket] How to connect to twitter streaming API?
Caveat: I'm only going by what I found here:
https://dev.twitter.com/docs. But I havent tried any of it out so I
dont know if I'll be able to field any more detailed questions. Also,
apologies if you already know all this.
1) Looks like the first thing you need to do is to create a twitter
app: https://dev.twitter.com/apps
2) Then it looks like you need to generate an OAuth signature. There's
a sidebar in your link that does this.
3) Then you have to use the authorization token you get back in any
api calls you make. More info here:
https://dev.twitter.com/docs/auth/authorizing-request
4) To use racket to make the api calls, looks like post-pure-port
might do what you want:
http://docs.racket-lang.org/net/url.html?q=post-pure-port#%28def._%28%28lib._net%2Furl..rkt%29._post-pure-port%29%29
Then use read-json with the created port to get back a racket json object:
http://docs.racket-lang.org/json/index.html?q=read-json#%28def._%28%28lib._json%2Fmain..rkt%29._read-json%29%29
On Tue, May 14, 2013 at 4:46 AM, SD <s.dedalo+racket at gmail.com> wrote:
> Dear All,
> This is my first message here, and first of all thank you for the excellent
> documentation already available.
>
> I tried to browse the past messages and the documentation available online
> but I couldn't find any information on how to query the twitter streaming
> API. I'm interested in getting JSON messages that meet certain criteria from
> the filtering API:
> https://dev.twitter.com/docs/api/1.1/post/statuses/filter
> (notice the POST here).
>
> Do you have any experience with this?
>
> Thanks,
> SD
>
> ____________________
> Racket Users list:
> http://lists.racket-lang.org/users
>