Let me clarify... You can do one of

1) Use GET, and specify the parameters as part of the URL query string
(e.g. 
"http://stream.twitter.com/1/statuses/filter.json?track=Microsoft<http://stream.twitter.com/1/statuses/filter.json?
track=Microsoft>
")
2) Use POST, and pass your arguments in through some VB method.  In this
case the URL will be
"http://stream.twitter.com/1/statuses/filter.json<http://stream.twitter.com/1/statuses/filter.json?
track=Microsoft>
"

  ---Mark

http://twitter.com/mccv


On Fri, Mar 5, 2010 at 2:55 PM, Mad Euchre <mad.ukrain...@gmail.com> wrote:

> I switch to post after reading John's response.
>
> When creating an HTTP client from within a program, you should be able
> to
> configure the POST parameters via method calls. If you can't, it's a
> pretty
> worthless HTTP library. Each client library is different, check your
> docs.
>
> -John Kalucki
>
> On Mar 5, 4:38 pm, Mark McBride <mmcbr...@twitter.com> wrote:
> > I think this is slightly backwards.  You want to use the GET method, but
> set
> > up the URI you have (with the track=Microsoft parameter).  You will also
> > need to authenticate.
> >
> > Note that this is a streaming API.  I don't know VB all that well, but
> > there's a reasonable chance that this call only returns data when the
> HTTP
> > call has finished.  The streaming API will *never* finish, so you'll need
> to
> > parse data as it's available.  Without looking at VB doc I have no idea
> how
> > you would set that up.
> >
> >   ---Mark
> >
> > http://twitter.com/mccv
> >
> >
> >
> > On Fri, Mar 5, 2010 at 9:54 AM, Mad Euchre <mad.ukrain...@gmail.com>
> wrote:
> > > Thanks.
> >
> > > Now I'm using the post method.
> >
> > > How should I use the track parameter? Something like this?
> >
> > >  address = New Uri("http://stream.twitter.com/1/statuses/filter.json?
> > > track=Microsoft")
> >
> > > I'm getting connected but no data  that matches Microsoft is streaming
> > > over.No data for that matter.
> >
> > > I'm passing my name and pw in the request.credentials method. The
> > > server returned a 200 OK when I added the credentials but not when it
> > > was in the URL alone.
> >
> > > ie; address = New Uri("http://stream.twitter.com/1/statuses/
> > > filter.json?track=Microsoft - name:pw"
> >
> > > Thanks,
> >
> > > Peter
> >
> > > On Mar 2, 5:19 pm, John Kalucki <j...@twitter.com> wrote:
> > > > The text file approach only applies to POST parameters set from the
> curl
> > > > command, and in no other case.
> >
> > > > When creating an HTTP client from within a program, you should be
> able to
> > > > configure the POST parameters via method calls. If you can't, it's a
> > > pretty
> > > > worthless HTTP library. Each client library is different, check your
> > > docs.
> >
> > > > -John Kaluckihttp://twitter.com/jkalucki
> > > > Infrastructure, Twitter Inc.
> >
> > > > On Tue, Mar 2, 2010 at 12:42 PM, Mad Euchre <mad.ukrain...@gmail.com
> >
> > > wrote:
> > > > > This is the VB code I would use to start any http stream
> >
> > > > >            request = DirectCast(WebRequest.Create("http://
> > > > > stream.twitter.com/1/statuses/filter.json - name:pw"),
> HttpWebRequest)
> > > > >            request.Credentials = New NetworkCredential("name",
> "pw")
> > > > >            ' Get response
> > > > >            response = DirectCast(request.GetResponse(),
> > > > > HttpWebResponse)
> >
> > > > >            ' Get the response stream into a reader
> > > > >            reader = New StreamReader(response.GetResponseStream())
> >
> > > > > The streaming api documentation says to create a file called
> track.txt
> > > > > and add text similar to this without the quotes.   "track=peter,
> paul,
> > > > > mary"
> >
> > > > > Then use curl @track.txthttp://
> > > stream.twitter.com/1/statuses/filter.json
> > > > > - name:pw
> >
> > > > > I can't believe I have to shell out to DOS and run the curl command
> > > > > line.
> >
> > > > > My direct question is how do others incorportate the @track.txt in
> the
> > > > > VB.Net web request?
> >
> > > > > Maybe something like this?
> >
> > > > >http://stream.twitter.com/1/statuses/filter.json-name:pw?
> > > > > track.txt
> >
> > > > > Thanks- Hide quoted text -
> >
> > > > - Show quoted text -- Hide quoted text -
> >
> > - Show quoted text -
>

Reply via email to