[twitter-dev] Re: No oauth_verifier in custom URI (Desktop)
Something new on this topic? /Jeena
[twitter-dev] Re: xauth error -1012
Same here. I get this with the XAuthTwitterEngineDemo: Twitter request failed: BCC3F69C-36CE-4C86-B50B-8E8B094E2DCD with error:Error Domain=HTTP Code=403 Operation could not be completed. (HTTP error 403.) Has any of you guys figured out how to fix this? On Apr 26, 7:00 pm, luckyman luckyman...@gmail.com wrote: Hi, I have same problem. Received approval from Twitter. But the same thing. Do you have solutions? On Apr 21, 5:13 am, sae twitp...@gmail.com wrote: Hi, I just set up my application forxauthand started testing. It keeps failing with error message: Error Domain=NSURLErrorDomain Code=-1012UserInfo=0x268d70 Operation couldnotbecompleted. (NSURLErrorDomain error -1012.) What is this error? Is anything wrong with my app setting, or my parameter maynotbe correct? Any clue will be really appreciated... Here is the copy of signature-base-string and authorization header, which all look ok to me: POSThttps%3A%2F%2Fapi.twitter.com%2Foauth %2Faccess_tokenoauth_consumer_key%3Dxx%26oauth_nonce %3D684B1D0C-4276-47BD-9A43-C31FDDD0DD8A%26oauth_signature_method %3DHMAC-SHA1%26oauth_timestamp%3D1271708678%26oauth_version %3D1.0%26x_auth_mode%3Dclient_auth%26x_auth_password%3Dxx %26x_auth_username%3Dy OAuth realm=\\, oauth_consumer_key=\\, oauth_signature_method=\HMAC-SHA1\, oauth_signature=\rg5s%2BW8wMxSx5MJt0wV3idqjriI%3D\, oauth_timestamp=\1271708678\, oauth_nonce=\684B1D0C-4276-47BD-9A43-C31FDDD0DD8A\, oauth_version=\1.0\; -- Subscription settings:http://groups.google.com/group/twitter-development-talk/subscribe?hl=en
Re: [twitter-dev] WebSockets protocol for streaming API
I'll just briefly disagree with you about point 2. OAuth does not require that you have a browser available. With Twitter supporting xAuth your desktop or mobile application can take a persons username and password and exchange them for an Access Token for accessing protected resources via OAuth without ever firing up the browser. You can find out more about twitter and xauth at http://dev.twitter.com/pages/xauth I think you are missing the point as to why twitter don't want web client to use the user streams right now. Much fewer people use desktop applications than use mobile or web applications. If you upgrade your desktop app to use the user streams then all of your customers have to upgrade their app, which will happen slowly over time. If you upgrade a web app all of your clients get upgraded all simultaneously. It sounds like it's purely a capacity issue at the moment. Michael Brunton-Spall Developer Advocate guardian.co.uk On 16 May 2010 06:42, M. Edward (Ed) Borasky zn...@borasky-research.netwrote: I'm going to keep the whole thread here because I think some important distinctions are being raised / discussed. 1. As a developer, I have to create a (minimum) viable product. Viable implies there must be a user interface beyond the command line. Yes, I know Cameron Kaiser thinks otherwise, but the people that I'm hoping will pay me money for a Twitter desktop product will most likely not want a command line product. 2. The most efficient way for me to deliver that UI, given oAuth, is to fire up a native browser and use it for at least the oAuth authentication and view portion of my application. I'm also guessing that one of the industry standard JavaScript libraries will be involved. Lots of wheels to not re- invent, etc.. 3. Twitter shouldn't have to care about the model and controller portions of my application. I'm guessing they'll not be in browser-side JavaScript, though, unless the JavaScript engines are a lot more efficient than I think they are. ;-) 4. That leaves the interface to user streams. Twitter should only have to care about connection-related and bandwidth-related parameters, *not* about whether I connect with Perl, Ruby, PHP, Python, JavaScript, C, Java, or even Lisp, Scheme or Forth. And Twitter shouldn't have to care whether the code is executed inside a browser by an interpreter, by compiled Java applet code, outside the browser by interpreted or compiled code, etc. Remember, I've got to have the browser anyway! In my case I'm guessing the connection will be Perl and outside the browser, because I know how to do things efficiently in Perl better than the others. And I'm guessing my model will require Perl efficiency as well. But if someone can build the whole enchilada in a browser, it shouldn't matter to Twitter as long as the connection and bandwidth properties are predictable / controllable. And, in fact, if *they're* ready to go to market the day user streams graduates to production status and I'm still futzing with my Perl code, well, I lose. ;-) 5. So let me throw a *huge* what if? on the table. What if there was an official Twitter-supported @anywhere - user streams capability? Then we *could* write a large chunk of a Twitter client in browser-side JavaScript. Maybe even simple models could be done that way too, but certainly the view and controller pieces could. See Antonio Cangiano's (@acangiano) blog post for a little motivation: http://antoniocangiano.com/2010/05/14/the-most-important-programming-language- today/ On Saturday, May 15, 2010 03:22:32 pm Abraham Williams wrote: I'm not particularly familiar with the specifics of WebSockets but here is the draft documentation: http://dev.w3.org/html5/websockets/ I don't see Chrome Extensions as being any different from desktop applications as they are both manually installed by the user on their desktop. Abraham On Sat, May 15, 2010 at 09:02, John Kalucki j...@twitter.com wrote: The first release of User Streams is not intended for web clients due to capacity constraints. http://apiwiki.twitter.com/ChirpUserStreams All services, mobile and browser-based clients must not use Streaming until we've sorted out Desktop clients at some scale. One problem at a time. That being said, of course we'd like to encourage experimentation with other client types, so that clients can evolve as we scale out the service. While others at Twitter are well-versed in the latest browser technologies, I'm totally and willfully ignorant. If you could give a brief summary of how the existing Streaming API does not work for WebSockets, that might be helpful. What's missing? -John Kalucki http://twitter.com/jkalucki Infrastructure, Twitter Inc. On Fri, May 14, 2010 at 9:38 PM, Cezar Sá Espinola ceza...@gmail.com wrote: Hey guys, Quick question, are there any plans on
[twitter-dev] OAuth issue, using mostly supplied code.
Hopefully someone can help me out with this one, as I'm pretty stuck.. I'm using the PHP example on here: http://dev.twitter.com/pages/oauth_single_token function getConnectionWithAccessToken($oauth_token, $oauth_token_secret) { $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET, $oauth_token, $oauth_token_secret); return $connection; } $connection = getConnectionWithAccessToken(abcdefg, hijklmnop); $content = $connection-get(statuses/home_timeline); along with the OAuth.php and twitterOAuth.php classes from @abraham's code. I've triple checked that all the keys are correct (copied and pasted from my twitter account). I'm using my OAuth_Token and OAuth_Token_Secret, not the sample strings in the above code. No matter what I request in the 'get', I get an Invalid / Used nonce error back. The Oauth.php and twitteroauth.php files are 100% untouched, and when I view the request, the nonce and timestamp are changing with every request. If I change the OAuth_Token key I get an expired token error, but changing the other keys doesn't have any effect, so it might be related to the keys I'm using? Any help would be GREATLY appreciated!
[twitter-dev] Re: oAuth Echo problems
I am having the exact same issue with Twitpic. I use the same code to generate the OAuth header for Twitpic as I do for Twitter, but Twitpic always returns a 401. On May 15, 6:26 pm, Rich rhyl...@gmail.com wrote: To follow up, if I simply actually call verify_credentials it returns a valid json object for my request but returns a status code of 401 On May 16, 12:01 am, Rich rhyl...@gmail.com wrote: Has anyone else had problems with oAuth echo and services like TwitPic I'm using the SAME objective-c library to generate the oAuth signature as for the client (which by the way the client works fine so the oAuth signatures for that are fine). I'm generating the oAuth headers as if it were forhttps://api.twitter.com/1/account/verify_credentials.jsonandadd it to the http headers as per Raffi's documenation. When I look at the oAuth headers they look fine, but TwitPic constantly returns a 401
[twitter-dev] Re: alert() in anywhere.js
Are we really talking about incorrect installations here? Twitter's own @Anywhere documentation page (http://dev.twitter.com/anywhere/ begin) is throwing this same error in older browsers, including Chrome 3.0.195. On May 15, 6:26 pm, Abraham Williams 4bra...@gmail.com wrote: I agree that @Anywhere should degrade gracefully when configured properly on unsupported platforms and not prompt incorrect alert()s. But I do think alert()s are probably the best way to notify developers of incorrect installations. Abraham On Sat, May 15, 2010 at 11:55, Larry la...@topsy.com wrote: I can reliably reproduce this with Firefox 3.0.8 at the following url: http://cornsyrup.org/~larry/anywhere/index.html Error console is reporting S.get is not a function Larry On May 15, 11:31 am, Larry la...@topsy.com wrote: Our site has been running @anywhere for over a week now without error. Yesterday my coworker was getting the alert(). He is running an older version of Firefox (3.0.8) on Ubuntu, so there might be another cause other than missing clientID or version? I still believe alert() is intrusive, especially for this case where it works fine except for this edge case. Instead of users complaining about broken hovercards, they are complaining about alert dialogs. Larry On May 14, 8:38 pm, Abraham Williams 4bra...@gmail.com wrote: Both of which are issues that will pretty much stop @Anywhere from working and need to be noticed as soon as possible at installation. Hiding them in console.log will make it more likely that @Anywhere will be installe improperly and the admins will only find out when users complain. Abraham On Fri, May 14, 2010 at 15:57, Larry la...@topsy.com wrote: I just came across a coworker's browser that triggered an alert() call from anywhere.js. While okay for development, the use of alert() is not friendly for production websites. Could these be converted console.log() or some other benign mechanism? Grepping through anywhere.js I found two instances of alert(): alert(To set up @anywhere, please provide a client ID); alert(No version matching +Z); Cheers Larry -- Abraham Williams | Developer for hire |http://abrah.am @abraham |http://projects.abrah.am|http://blog.abrah.am This email is: [ ] shareable [x] ask first [ ] private. -- Abraham Williams | Developer for hire |http://abrah.am @abraham |http://projects.abrah.am|http://blog.abrah.am This email is: [ ] shareable [x] ask first [ ] private.
[twitter-dev] What the hell is to set up @anywhere, please provide a client id
Why the hell am I suddenly getting to set up @anywhere, please provide a client id when I try to use the search.twitter.com (unless I disable javascript) ?
[twitter-dev] xAuth now returns a 403 when posting a tweet
I have been using the xAuth code by Aral Balkan for my iPhone apps: http://aralbalkan.com/3133/ The code had been working fine for a couple of months both getting token and posting tweets. I rerun the code today, and all of a sudden while getting the token still work, posting a tweet always returns a 403: Twitter request failed: 18C9AA7E-05BF-408D-A8CE-7480A2FAD4CB with error:Error Domain=HTTP Code=403 “Operation could not be completed. (HTTP error 403.)” Has something changed on Twitter's end regarding the xAuth protocol since March 11, which is when Aral Balkan's code was last modified? Any ideas? Thanks. -- neptune2000
[twitter-dev] Stream Pad Player?
Is there anyway I can add a stream pad player to my twitter profile? If so that would be awesome!!
[twitter-dev] Re: oAuth Echo problems
I've spent a good 12 hours on this so far and this is where I've got to 1) I use the same code to generate the oAuth header for echo and communicating to the Twitter API 2) I generate a fake request to verify_credentials and generate the oauth http header but change Authorization to X-Verify-Credentials- Authorization and add the X-Auth-Service-Provider header 3) I change the request url to the TwitPic api and post the image 4) TwitPic comes back with a 401 oauth header error (specifically says oauth header in the response) To check the oAuth header was OK I change my code to use Authorization instead of X-Verify-Credentials-Authorization and send it directly to verify_credentials (obviously ignoring the image data part!) Twitter responds with JSON and an HTTP status of 200, so I'm pretty sure that my oAuth header is right On May 16, 12:36 am, gotosleep gotosl...@gmail.com wrote: I am having the exact same issue with Twitpic. I use the same code to generate the OAuth header for Twitpic as I do for Twitter, but Twitpic always returns a 401. On May 15, 6:26 pm, Rich rhyl...@gmail.com wrote: To follow up, if I simply actually call verify_credentials it returns a valid json object for my request but returns a status code of 401 On May 16, 12:01 am, Rich rhyl...@gmail.com wrote: Has anyone else had problems with oAuth echo and services like TwitPic I'm using the SAME objective-c library to generate the oAuth signature as for the client (which by the way the client works fine so the oAuth signatures for that are fine). I'm generating the oAuth headers as if it were forhttps://api.twitter.com/1/account/verify_credentials.jsonandaddit to the http headers as per Raffi's documenation. When I look at the oAuth headers they look fine, but TwitPic constantly returns a 401
Re: [twitter-dev] Re: alert() in anywhere.js
This does sound like a regression of some kind. We'll get this fixed ASAP. On Sat, May 15, 2010 at 3:41 PM, JohnB johnfakor...@yahoo.com wrote: Are we really talking about incorrect installations here? Twitter's own @Anywhere documentation page (http://dev.twitter.com/anywhere/ begin) is throwing this same error in older browsers, including Chrome 3.0.195. -- Dan Webb Front-end Engineer, Platform d...@twitter.com / @danwrong +1 415 425 5631
Re: [twitter-dev] OAuth issue, using mostly supplied code.
Make sure your clock is properly synced. If it is more the a few minutes off it can cause the same error. Abraham On Sun, May 16, 2010 at 01:49, wparsons willpars...@gmail.com wrote: Hopefully someone can help me out with this one, as I'm pretty stuck.. I'm using the PHP example on here: http://dev.twitter.com/pages/oauth_single_token function getConnectionWithAccessToken($oauth_token, $oauth_token_secret) { $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET, $oauth_token, $oauth_token_secret); return $connection; } $connection = getConnectionWithAccessToken(abcdefg, hijklmnop); $content = $connection-get(statuses/home_timeline); along with the OAuth.php and twitterOAuth.php classes from @abraham's code. I've triple checked that all the keys are correct (copied and pasted from my twitter account). I'm using my OAuth_Token and OAuth_Token_Secret, not the sample strings in the above code. No matter what I request in the 'get', I get an Invalid / Used nonce error back. The Oauth.php and twitteroauth.php files are 100% untouched, and when I view the request, the nonce and timestamp are changing with every request. If I change the OAuth_Token key I get an expired token error, but changing the other keys doesn't have any effect, so it might be related to the keys I'm using? Any help would be GREATLY appreciated! -- Abraham Williams | Developer for hire | http://abrah.am @abraham | http://projects.abrah.am | http://blog.abrah.am This email is: [ ] shareable [x] ask first [ ] private.
[twitter-dev] Re: Problem with status encoding... I guess
Hello Konpaku, thanks for you answer. I am encoding my text with UTF8, I don´t know what you mean by your files Also, I don´t know if BOM is necesarry cause as I mentioned before, it works with other international characters, but I will give that a try though thanks On May 15, 8:48 pm, Konpaku Kogasa kogasa.l...@gmail.com wrote: Hello, I had a few bugs with encoding, I was not using UTF8 and now I do, so I am able to tweet stauff like Peñarol á é í ó ú (spanish lang characters). I was making some tests and I noticed that if I want to set '!' as my status (just the exclamation mark) it dos not work... I get an Incorrect signature error message. I had this issue before. Check the encoding of your files. It needs to be set to UTF-8 (can't remember if it's with or without BOM though..) - Konpaku Kogasa
Re: [twitter-dev] WebSockets protocol for streaming API
On Sunday, May 16, 2010 12:58:13 am Michael Brunton-Spall wrote: I'll just briefly disagree with you about point 2. OAuth does not require that you have a browser available. With Twitter supporting xAuth your desktop or mobile application can take a persons username and password and exchange them for an Access Token for accessing protected resources via OAuth without ever firing up the browser. You can find out more about twitter and xauth at http://dev.twitter.com/pages/xauth I'm aware of xauth, but I'm likely going to stick with browser-based oAuth and with a browser-based view component of the application. It's too hard to get a portable native desktop UI any other way. People know how to use browsers. For example, think about the SugarCRM Community Edition. If you run that as a stand-alone desktop application on a Windows, Linux or Mac desktop, what you've actually got is a whole PHP stack model/view/controller application with your browser pointing to localhost. Using a browser for the UI and a model/view/controller stack vastly increases the number of open source tools I can bring to bear. I think you are missing the point as to why twitter don't want web client to use the user streams right now. Much fewer people use desktop applications than use mobile or web applications. If you upgrade your desktop app to use the user streams then all of your customers have to upgrade their app, which will happen slowly over time. If you upgrade a web app all of your clients get upgraded all simultaneously. It sounds like it's purely a capacity issue at the moment. First of all, this is a new application, not an upgrade to an existing one. Second, since it depends on Twitter and user streams, it's not going to be deployed until Twitter has the capacity to support it. And third, it *is* going to be a desktop application, not deployed on servers or mobiles. I simply don't want to have technologies ruled out because they're usually used on servers, like a web application stack. -- M. Edward (Ed) Borasky http://borasky-research.net/m-edward-ed-borasky/ @znmeb A mathematician is a device for turning coffee into theorems. ~ Paul Erdős
[twitter-dev] Re: Problem with status encoding... I guess
Hello, Hello Konpaku, thanks for you answer. I am encoding my text with UTF8, I don´t know what you mean by your files Sorry I meant all the source files. Also what language and oAuth library are you using for this? - Konpaku Kogasa
Re: [twitter-dev] Re: Announcing Twurl: OAuth-enabled curl for the Twitter API
Am 15.05.2010 21:38, schrieb Patrick Kennedy: I bet coffee and 10 seconds with either of you would fix my problem, but no worries. On Sat, May 15, 2010 at 9:02 PM, kuhkatzkuhk...@googlemail.com wrote: Am 14.05.2010 23:40, schrieb Faried Nawaz: On May 15, 12:41 am, kuhkatzkuhk...@googlemail.comwrote: so i suppose i am doing things wrong. i followed your instructions, but when i apply the diff, i get this: $ patch -i twurldiff Close. You can do either one of patch -p 1 -i twurldiff or git apply twurldiff Faried. tried the first approach, gave me an error with lib/twurl.rb, but with looking into the .rej and manually patching the file i succeded, finally. thanks for your help =) someone of us might consider trying to help you if you could provide further details on where exacly what goes wrong. doesnt work is never a good way to call for help.
[twitter-dev] Re: oAuth Echo problems
After chatting with one of the engineers at TwitPic they appear to have fixed the invalid oauth header issue, now I get a 401 error saying my API key is invalid even though it's a copy and paste from their site On May 16, 3:18 pm, Rich rhyl...@gmail.com wrote: I've spent a good 12 hours on this so far and this is where I've got to 1) I use the same code to generate the oAuth header for echo and communicating to the Twitter API 2) I generate a fake request to verify_credentials and generate the oauth http header but change Authorization to X-Verify-Credentials- Authorization and add the X-Auth-Service-Provider header 3) I change the request url to the TwitPic api and post the image 4) TwitPic comes back with a 401 oauth header error (specifically says oauth header in the response) To check the oAuth header was OK I change my code to use Authorization instead of X-Verify-Credentials-Authorization and send it directly to verify_credentials (obviously ignoring the image data part!) Twitter responds with JSON and an HTTP status of 200, so I'm pretty sure that my oAuth header is right On May 16, 12:36 am, gotosleep gotosl...@gmail.com wrote: I am having the exact same issue with Twitpic. I use the same code to generate the OAuth header for Twitpic as I do for Twitter, but Twitpic always returns a 401. On May 15, 6:26 pm, Rich rhyl...@gmail.com wrote: To follow up, if I simply actually call verify_credentials it returns a valid json object for my request but returns a status code of 401 On May 16, 12:01 am, Rich rhyl...@gmail.com wrote: Has anyone else had problems with oAuth echo and services like TwitPic I'm using the SAME objective-c library to generate the oAuth signature as for the client (which by the way the client works fine so the oAuth signatures for that are fine). I'm generating the oAuth headers as if it were forhttps://api.twitter.com/1/account/verify_credentials.jsonandaddit to the http headers as per Raffi's documenation. When I look at the oAuth headers they look fine, but TwitPic constantly returns a 401
Re: [twitter-dev] WebSockets protocol for streaming API
I did a quick reading, and I couldn't tell if WS connections are restricted back to the domain of the calling page, or if arbitrary connections are allowed. If the former, there may not be a reason for the Streaming API to support this. If the latter, perhaps there's a valid use case. Looking at the protocol itself, this wouldn't be trivial to support, but it might not be that bad either. We'll have to keep an eye on the installed browser base and see when this might make sense. It is too bad that they didn't allow HTTP connections with incremental byte reads in addition to WB connections on that interface. I'm sure they had their reasons. -John Kalucki http://twitter.com/jkalucki Infrastructure, Twitter Inc. On Sat, May 15, 2010 at 3:22 PM, Abraham Williams 4bra...@gmail.com wrote: I'm not particularly familiar with the specifics of WebSockets but here is the draft documentation: http://dev.w3.org/html5/websockets/ I don't see Chrome Extensions as being any different from desktop applications as they are both manually installed by the user on their desktop. Abraham On Sat, May 15, 2010 at 09:02, John Kalucki j...@twitter.com wrote: The first release of User Streams is not intended for web clients due to capacity constraints. http://apiwiki.twitter.com/ChirpUserStreams All services, mobile and browser-based clients must not use Streaming until we've sorted out Desktop clients at some scale. One problem at a time. That being said, of course we'd like to encourage experimentation with other client types, so that clients can evolve as we scale out the service. While others at Twitter are well-versed in the latest browser technologies, I'm totally and willfully ignorant. If you could give a brief summary of how the existing Streaming API does not work for WebSockets, that might be helpful. What's missing? -John Kalucki http://twitter.com/jkalucki Infrastructure, Twitter Inc. On Fri, May 14, 2010 at 9:38 PM, Cezar Sá Espinola ceza...@gmail.com wrote: Hey guys, Quick question, are there any plans on supporting WebSockets protocol for the Streaming API? That'd be awesome for browser based Twitter clients (i.e. Google Chrome extensions). Without this it'll be very difficult for this kind of client to lavarage benefit from the upcoming user streams. Thanks a lot for all your hard work, Cezar Sá Espinola @cezarsa -- Abraham Williams | Developer for hire | http://abrah.am @abraham | http://projects.abrah.am | http://blog.abrah.am This email is: [ ] shareable [x] ask first [ ] private.
Re: [twitter-dev] WebSockets protocol for streaming API
Ed, Efficiency isn't the only goal of user streams, but it is an important one when considering systems at this scale. When optimizing such a system, you generally go looking for the biggest reward first. We've identified applications that run on the desktop, such as Tweetdeck, Seesmic, and friends, as a larger consumer of resources on a per-user basis. They're always on and always polling at the maximum rate and the traffic comes directly from the desktop. So be it, as this is core to their utility and nature. Browser-based clients are service-based. The aggregate user streams demand from service-based applications, of all types, not just browser clients, far exceeds that of desktops. We cannot possibly launch into service-based demand. It's too vast. To ration access in this environment would be hard for everyone. Also most services do not place quite as large of a per-user load on the REST API. Browsers don't reload, or reload infrequently. Services mediate the load is various ways. Etc. Finally, services are not best served by user streams as they are today. They should have all of their requested traffic delivered over a small number of multiplexed streams. It's not ideal to open 10^5 or 10^6 connections from a given service to Twitter, only to have their aggregate traffic be far less than a Gardenhose feed. The service-side complexity to manage all these connections is large, and the resource utilization on our end is quite high. User streams, with a connection per user, would be an efficiency loss here, where multiplexed streams would be a tremendous efficiency gain. So, services, as a category, are too big to tackle first, they probably offer an efficiency loss, and, with a little more work, services can be supported with a huge efficiency gain for everyone. So we're initially going for the biggest efficiency win with the smallest feature set against the smallest reasonably partitionable market given the limited resources we have available. -John Kalucki http://twitter.com/jkalucki Infrastructure, Twitter Inc. On Sun, May 16, 2010 at 8:04 AM, M. Edward (Ed) Borasky zn...@borasky-research.net wrote: On Sunday, May 16, 2010 12:58:13 am Michael Brunton-Spall wrote: I'll just briefly disagree with you about point 2. OAuth does not require that you have a browser available. With Twitter supporting xAuth your desktop or mobile application can take a persons username and password and exchange them for an Access Token for accessing protected resources via OAuth without ever firing up the browser. You can find out more about twitter and xauth at http://dev.twitter.com/pages/xauth I'm aware of xauth, but I'm likely going to stick with browser-based oAuth and with a browser-based view component of the application. It's too hard to get a portable native desktop UI any other way. People know how to use browsers. For example, think about the SugarCRM Community Edition. If you run that as a stand-alone desktop application on a Windows, Linux or Mac desktop, what you've actually got is a whole PHP stack model/view/controller application with your browser pointing to localhost. Using a browser for the UI and a model/view/controller stack vastly increases the number of open source tools I can bring to bear. I think you are missing the point as to why twitter don't want web client to use the user streams right now. Much fewer people use desktop applications than use mobile or web applications. If you upgrade your desktop app to use the user streams then all of your customers have to upgrade their app, which will happen slowly over time. If you upgrade a web app all of your clients get upgraded all simultaneously. It sounds like it's purely a capacity issue at the moment. First of all, this is a new application, not an upgrade to an existing one. Second, since it depends on Twitter and user streams, it's not going to be deployed until Twitter has the capacity to support it. And third, it *is* going to be a desktop application, not deployed on servers or mobiles. I simply don't want to have technologies ruled out because they're usually used on servers, like a web application stack. -- M. Edward (Ed) Borasky http://borasky-research.net/m-edward-ed-borasky/ @znmeb A mathematician is a device for turning coffee into theorems. ~ Paul Erdős
Re: [twitter-dev] WebSockets protocol for streaming API
On Mon, May 17, 2010 at 12:35 AM, John Kalucki j...@twitter.com wrote: Browser-based clients are service-based. There are many counter examples that are not service-based. (Hootsuite, Brizzly and err tDash). Instead of generalizing browser-based clients, would it not be better to specifically address service-based clients (and thus exclude them from the user stream API)? -- Harshad RJ http://hrj.wikidot.com
[twitter-dev] Problem(s) moving to a newer version of the API
I've been waiting a week for some response to a question. I just found that the question never was distributed. I'll try again. I've made a little progress on my own, but not much. I feel like I'm beating my head against a wall, and I'm very frustrated. To recap: I have a prototype application which was based on the example on Abraham's web site. It works with an old version of twitterOAuth, and I'm trying to upgrade it to use version 0.2.0-beta2 (I gather that's the most current version), which I need to develop my prototype further. It doesn't work, and I don't know why. First, a word about terminology: there seems to be a lot of confusion about “key” versus “token.” The documentation I've read seems to distinguish the two, but doesn't use them consistently. I'm using “token” to denote the combination of a key and secret. Here's what I'm doing now: 1. Create a TwitterOAuth object with consumer key and consumer secret. 2. Call $oauth-requestToken($callback); save the resulting token for later use. 3. CAll $oath-getAuthorizeURL($request_token,false). 4. Link to the returned URL. 5. On return to the callback, create a TwitterOAuth object with consumer key, consumer secret, request key, and request secret. 6. call $oath-getAccessToken($verifier), where $verifier comes from the URL's parameter string. 7. Use the resulting access token to create a new TwitterOAuth object with consumer key, consumer secret, access key, and access secret. 8. Try to perform an operation. Everything seems to work well up to step 8, where I get back a response that says, “Could not authenticate you.” I'm baffled. It seems to me that either this thing works or it doesn't, and if it doesn't, there's no logical process for figuring out why. I noticed one odd thing which might be a clue. I understand that the oauth_token returned to the callback URL is supposed to the same as the request key passed to the oauth_token passed to the authorization URL (and thus, I assume, the request key in the request token passed to getAuthorizeURL. It ain't so. The value returned to the callback URL doesn't match anything else I recognize.
[twitter-dev] Weird inconsistency in social graph
I've been poking around with this little ruby script running it every now and then the last few weeks: http://gist.github.com/403113 (I'm trying to get an understanding of the rate of change in my social graph by being able to compare my graph to any point in time I previously ran the script.) I turned up a weird inconstancy though. Some Twitter employees that are following me (or maybe not following me) appear and disappear randomly from my social graph. Like @mm who every few times shows she follows me (who I don't think is actually following me because I can't DM her to check), and also @dougw on rare occasion shows he isn't following me (which I know he is because I can DM him). I thought it was a fluke or caching issue but it's been like that for over a 2 weeks and hasn't cleared up (even before the accept bug). Seems to only happen with twitter employees but that may be just a coincidence, or maybe it might its a bug with some internal feature you have enabled for twitter employees that is acting up maybe. Any ideas? Not a critical issue but just wondering out of curiosity. Attached are the results from making 3 requests of my followers social graph a few seconds apart. The second one has @mm, but the other two don't. --- followers/1274040599.txt2010-05-16 13:09:59.0 -0700 +++ followers/1274040541.txt2010-05-16 13:09:01.0 -0700 @@ -80,6 +80,7 @@ 129004024 16909593 11009852 +7101692 19130449 14793018 129424089 Zac Bowling @zbowling 39600909 14380462 1142711 123643162 15391023 138543652 89044620 65415178 7557 92865690 41280728 28338565 16324081 44579983 137908690 108719030 15150351 142430267 134587852 32897297 18628681 142055010 140525243 136977879 108844424 74613484 75210878 138075151 13288902 13744592 15936194 117135861 14074881 121069642 139781026 134399964 139342954 19356814 14745819 75265089 111541882 128930929 136439186 6686342 137926273 72702593 133563688 133388947 70570451 39685056 104448721 110102920 50753911 62432436 13396902 24430595 26101798 14694677 56214804 135047518 21220586 15925986 12543022 135705680 15066929 9715522 14860302 9347472 1374361 13503902 19223 13259942 65585979 7082702 16722928 11815982 133703782 46783 812049 129004024 16909593 11009852 19130449 14793018 129424089 15781775 17459313 28890407 22582599 48352523 64906489 18237002 32658080 26015915 113368617 103703103 14129318 127762744 125449133 128824623 22419681 79518901 100772620 128015200 124428985 6856622 10937622 22043299 16638239 18486852 16881073 5848282 122766410 6883712 14117730 105963996 105843108 27971734 7134102 14559712 14573643 45282898 16023185 74673 14880920 126389013 23772882 62778374 70407105 9253522 14134276 8864422 1693421 8713712 125878497 61413756 28482162 124582977 14114105 14702477 83074508 116038995 16296704 123636203 121528064 117117359 804358 14317493 122253561 86712934 73877793 55241054 119534015 117697200 119335689 42738861 19966048 833071 91838094 7334402 10202 8940282 1401881 335893 116113431 111212900 785148 36967262 42106933 15669526 14295423 26376718 118639445 10957902 16116901 41507308 4959461 86854621 24218879 10284472 68042098 23720707 115435506 103862202 115499976 25544326 20355172 20408506 54460111 18608106 109293 11039092 54434620 75174395 24143539 8602182 11957802 109003537 26170776 12193 1582391 106496169 89350277 17790274 39998762 109283287 14498374 14398449 83130412 106222709 11392102 14688796 59701884 94183896 41925691 103584743 103258331 103265618 103246379 14556090 10076682 3741421 38037584 51012735 24349486 165293 21062686 17540895 68498232 22127489 12255212 9436992 14056632 1132291 68512051 22441611 86772969 102564878 81794569 102213497 13190472 85397914 8448552 102201516 15253419 11294522 45538687 612 79016364 24303 100338530 53767782 98092929 18624058 94045028 76246319 94812598 89113720 69523030 88696846 18167958 9118502 38937224 66906245 6987882 16164520 9678372 99900142 7234682 14492032 33944319 55767870 98061278 62252399 95988164 18892257 36873203 8654602 96978077 59858937 17960394 7612682 16936110 16208514 48506440 96930326 14551773 14362200 84239329 15789884 7275352 97506989 18225739 13545 2205921 14270329 96377901 13464192 23923340 96303998 18278306 47652631 22461067 95801409 71696778 41804469 40176787 35218640 18464551 93299683 96328313 9007632 24443061 88334518 87626226 75233126 85656051 95488747 91777621 14738561 94325602 34395913 18303140 27427474 45608097 20174987 94964549 14522944 28304831 19720019 18113175 10762342 15392391 53130511 92589759 46718643 28282442 92390154 89516707 87636054 83055503 17741757 65019615 15318975 2806761 8614702 87546862 44640797 14671263 14396780 22366323 15665583 89854436 22935006 79006150 83731305 58880714 9263952 19160166 30137587 18720900 9360692 69604419 16303389 15371839 11644922 68386991 39470541 45784665 75949513 16813828 32418877 1609 88299939 84018570 10076782 27615066 68251169 25988350 30405446 20639602 71568103 87156160 17172786 11825392 70172933 86785588 14460422 32639070
[twitter-dev] PNG's not uploading
THe API has not been uploading PNG's as avatars/profile pix that my app sends. Then I tried on twitter.com directly and surprisingly got the there was a problem updating your profile message. I tried with a JPG on the website and it worked fine. Are you aware of the issue? -H
Re: [twitter-dev] WebSockets protocol for streaming API
Web sockets allows you to support cross domain access however you want by checking the Origin: header. If you only want to allow your own domain, then you can compare the Origin equals your own domain and if you want to allow some domains or all domains you can whitelist as you want. According to the lastest version of the draft spec's security concern: http://tools.ietf.org/html/draft-hixie-thewebsocketprotocol-55#section-7 One thing to understand is that WebSockets are not really HTTP. WebSockets handshakes may start out looking like an HTTP in the initial request and initial response but that only so that it's possible for a web server serving HTTP today could be used to handle the requests and be able to tell that it's a WebSocket and internally switch over to handling the request as a WebSocket internally. Websockets are not like HTTP though in that they are full duplex communication (real two way communication). It avoids some of the tricks you have to do with AJAX Comet/Long polling/http streaming by giving the browsers something more like traditional TCP/IP sockets to communicate back the server while still working through HTTP proxies and firewalls. Jetty, the web server that Twitter uses today on the streaming side supports WebSockets in its latest version (http://blogs.webtide.com/gregw/entry/jetty_websocket_server). Most of the web socket server implementations that exist today are built on top of traditional web servers, but they don't use epoll or any kind of event based async sockets (most design around having a single thread handle the connections for a user) and so they are unable to handle massive numbers of simultaneous open concurrent connections like you can with Jetty or FriendFeed's Tornado (http://www.tornadoweb.org/). I would love to see a streaming server implementation using WebSockets from Twitter, not only just for access from web browsers but from desktop clients that support websockets. There are some doors that open with that like being able to send back messages to Twitter up the socket (like sending a tweet, or changing the paramaters of what we are filtering on the stream, or request all sorts of things that you would have to do on the querystring and have to reconnect to change them). Zac Bowling @zbowling On Sun, May 16, 2010 at 11:29 AM, John Kalucki j...@twitter.com wrote: I did a quick reading, and I couldn't tell if WS connections are restricted back to the domain of the calling page, or if arbitrary connections are allowed. If the former, there may not be a reason for the Streaming API to support this. If the latter, perhaps there's a valid use case. Looking at the protocol itself, this wouldn't be trivial to support, but it might not be that bad either. We'll have to keep an eye on the installed browser base and see when this might make sense. It is too bad that they didn't allow HTTP connections with incremental byte reads in addition to WB connections on that interface. I'm sure they had their reasons. -John Kalucki http://twitter.com/jkalucki Infrastructure, Twitter Inc. On Sat, May 15, 2010 at 3:22 PM, Abraham Williams 4bra...@gmail.com wrote: I'm not particularly familiar with the specifics of WebSockets but here is the draft documentation: http://dev.w3.org/html5/websockets/ I don't see Chrome Extensions as being any different from desktop applications as they are both manually installed by the user on their desktop. Abraham On Sat, May 15, 2010 at 09:02, John Kalucki j...@twitter.com wrote: The first release of User Streams is not intended for web clients due to capacity constraints. http://apiwiki.twitter.com/ChirpUserStreams All services, mobile and browser-based clients must not use Streaming until we've sorted out Desktop clients at some scale. One problem at a time. That being said, of course we'd like to encourage experimentation with other client types, so that clients can evolve as we scale out the service. While others at Twitter are well-versed in the latest browser technologies, I'm totally and willfully ignorant. If you could give a brief summary of how the existing Streaming API does not work for WebSockets, that might be helpful. What's missing? -John Kalucki http://twitter.com/jkalucki Infrastructure, Twitter Inc. On Fri, May 14, 2010 at 9:38 PM, Cezar Sá Espinola ceza...@gmail.com wrote: Hey guys, Quick question, are there any plans on supporting WebSockets protocol for the Streaming API? That'd be awesome for browser based Twitter clients (i.e. Google Chrome extensions). Without this it'll be very difficult for this kind of client to lavarage benefit from the upcoming user streams. Thanks a lot for all your hard work, Cezar Sá Espinola @cezarsa -- Abraham Williams | Developer for hire | http://abrah.am @abraham | http://projects.abrah.am | http://blog.abrah.am This email is: [ ] shareable [x] ask first [ ] private.
Re: [twitter-dev] Field constraints
Is there a reference that explains the field types and constraints of the data coming from the Twitter API? unfortunately, no - we don't have a centralized document listing all this (although, we probably should). Some things are a bit uncertain. For example, are user IDs 32bit or 64 bit integers? right now, there are less than 2^32 users, if that helps :P are there any other fields that are ambiguous? -- Raffi Krikorian Twitter Platform Team http://twitter.com/raffi
Re: [twitter-dev] WebSockets protocol for streaming API
as a fallback - some people have had some success using http://github.com/r/twstreamer to get access to the stream from javascript (using flash as a bridge). usual caveats around production-izing streams apply. On Sat, May 15, 2010 at 5:38 AM, Cezar Sá Espinola ceza...@gmail.comwrote: Hey guys, Quick question, are there any plans on supporting WebSockets protocol for the Streaming API? That'd be awesome for browser based Twitter clients (i.e. Google Chrome extensions). Without this it'll be very difficult for this kind of client to lavarage benefit from the upcoming user streams. Thanks a lot for all your hard work, Cezar Sá Espinola @cezarsa -- Raffi Krikorian Twitter Platform Team http://twitter.com/raffi
Re: [twitter-dev] Twitter returns different tweet ids.
how are you defining correct? ie - what are you comparing the ids against so as to lead you to think they are not correct? On Sat, May 15, 2010 at 2:25 PM, omergul123 omergul...@gmail.com wrote: Hello. when I call the statuses/home_timeline api method ro retrieve the tweets, the ids of the tweets that are returned are not correct. What could be the problem? All the data except the tweet id are returned correctly. I use the jmathai's twitter client: http://github.com/jmathai/twitter-async -- Raffi Krikorian Twitter Platform Team http://twitter.com/raffi
[twitter-dev] Re: How to filter out utf-8 characters in java
Hi, Dears! If one of yours could help me, I will really be happy. I have no experience with PHP. If you access the follow link, the prototype will send a request to the Search PHP Twitter Class with the tag educacao. In my language, it to be educação. So, some tweets results could be show like educação. http://www.portabilis.com.br/tcc/search_PHP_API/index.php?twitterq=educacaoSubmit=Enviar+dados The follow link show the Search.php class that makes the process: http://www.portabilis.com.br/tcc/search_PHP_API/search.phps I guess that some convertion function could be resolve it, like iconv(‘utf-8′,’iso-8859-1′), or something else. But I dont know exactly what to do and where. Looking to search.php, some suggestion? Thank you very much. On 13 maio, 17:47, Zac Bowling zbowl...@gmail.com wrote: PHP treats strings as c strings basically (char/byte arrays). It won't really do anything special automagically and leaves it up to you to make sure you treat your strings safely. Make sure your code is encoded in utf-8 and make sure your content types are set to UTF-8 in your responses. Use UTF-8 wherever you can in your dbs and use utf8_encode/decode and the mb functions replacements where you can't. If you are making http requests mark your encodings in your requests correctly (with CURL set your charset to UTF-8 in your request headers). In java, all strings are high level representations of chars (internally UCS2 wide chars but you don't need to worry about that). You just need to make sure you decode/encode properly and mark your charsets in your requests and responses everywhere. Zac Sent from my iPad On May 13, 2010, at 10:51 AM, Matt Sanford m...@twitter.com wrote: Higiustin, I don't think it's the same issue since yours is more PHP specific. My guess is that the PHP library in question or the code you're using to process the results is incorrectly converting between UTF-8 and ISO-8859-1 [1]. Maybe someone on the list with some more PHP knowledge can suggest a fix. Thanks; — Matt Sanford / @mzsanford [1] = The UTF-8 encoding of ã is two bytes. When those same two bytes are interpreted as ISO-8859-1 (a.k.a ISO-Latin-1) they are interpreted as two characters, like so (fixed width font required): UTF-8 Bytes vs. Same bytes in ISO-8859-1 n 0x6E n ã 0xC3 à 0xA3 £ o 0x6F o On May 12, 7:19 pm,giustintgiu...@gmail.com wrote: I have similar problems. When I try to search using the tag não the result is não. The API that I used were Twitter Search API from Ryan Faerman (http:// ryanfaerman.com/twittersearch/) Regards. On 12 maio, 21:47, Matt Sanford m...@twitter.com wrote: Hi there, All characters in Tweets are utf-8. I'm assuming you're looking for something specific like accents or ASCII-art punctuation. Can you describe your problem in a little more detail? I might be able to help once I know what you're trying to prevent. Thanks; — Matt Sanford / @mzsanford On May 12, 4:21 pm, adamjamesdrew theikl...@gmail.com wrote: any ideas?
[twitter-dev] How to use PHP Twitter Search API with the operators OR SINCE HASHTAG etc
Hi, Using the PHP Twitter Search by Ryan Faerman, I'm trying to create a mashup to my final university project. The class is that: http://greenservr.com/projects/twittersearch/TwitterSearch.phps What I would like to know? In the Search API Twitter, you can use many methods, and I dont know if this class include all them. Examples: 1. searching tweets with tags brasil or copa since 2010-05-15. http://search.twitter.com/search?q=brasil+OR+copa+since%3A2010-05-15 2. just using the operator OR, to the tags twitter or you: http://search.twitter.com/search?q=twitter+OR+you 3. With the #hashtag: http://search.twitter.com/search?q=%23twitter FONT: http://search.twitter.com/operators Looking at the TwitterSearch.phps, how can I create a script to bring the results to me using OR ou SINCE operators? Look up my example: http://www.portabilis.com.br/tcc/search_PHP_API/index.php?twitterq=brasil+copaSubmit=Enviar+dados The link above bring me tweets that exists brasil AND copa tags. I dont wanna AND but OR operator. Someone could help me with this? Regards,
[twitter-dev] Re: How to use PHP Twitter Search API with the operators OR SINCE HASHTAG etc
Hi, myself and dears mates! :) It is very simple, but I'm not saw before. So, a example with the operator OR is: http://www.portabilis.com.br/tcc/search_PHP_API/index.php?twitterq=brasil+OR+copaSubmit=Enviar+dados Thanks. On 17 maio, 00:04, giustin tgiu...@gmail.com wrote: Hi, Using the PHP Twitter Search by Ryan Faerman, I'm trying to create a mashup to my final university project. The class is that:http://greenservr.com/projects/twittersearch/TwitterSearch.phps What I would like to know? In the Search API Twitter, you can use many methods, and I dont know if this class include all them. Examples: 1. searching tweets with tags brasil or copa since 2010-05-15.http://search.twitter.com/search?q=brasil+OR+copa+since%3A2010-05-15 2. just using the operator OR, to the tags twitter or you:http://search.twitter.com/search?q=twitter+OR+you 3. With the #hashtag:http://search.twitter.com/search?q=%23twitter FONT:http://search.twitter.com/operators Looking at the TwitterSearch.phps, how can I create a script to bring the results to me using OR ou SINCE operators? Look up my example: http://www.portabilis.com.br/tcc/search_PHP_API/index.php?twitterq=br... The link above bring me tweets that exists brasil AND copa tags. I dont wanna AND but OR operator. Someone could help me with this? Regards,
[twitter-dev] new api for entity's mentioned by @raffi
Hi, Does anyone know when the new api for entities will be available? I think an api to get all metadata for a twitter user id would be far more useful and also lower api traffic way more. Any chance of seeing this one? Thanks, David
[twitter-dev] Re: xAuth now returns a 403 when posting a tweet
Item closed. Twitter now returns 403 when re-sending the same message, which is what the referenced demo program does. On May 15, 12:56 pm, neptune2000 papa.ma...@gmail.com wrote: I have been using the xAuth code by Aral Balkan for my iPhone apps: http://aralbalkan.com/3133/ The code had been working fine for a couple of months both getting token and posting tweets. I rerun the code today, and all of a sudden while getting the token still work, posting a tweet always returns a 403: Twitter request failed: 18C9AA7E-05BF-408D-A8CE-7480A2FAD4CB with error:Error Domain=HTTP Code=403 “Operation could not be completed. (HTTP error 403.)” Has something changed on Twitter's end regarding the xAuth protocol since March 11, which is when Aral Balkan's code was last modified? Any ideas? Thanks. -- neptune2000
[twitter-dev] Re: Twitter xAuth with Chilkat Hail Mary - Internal Server Error (500)
I figured it out. Here's my tip for anyone struggling with xAuth for Twitter without the help of a library: The Hueniverse Interactive Walkthrough This lets you test your values to see if they're valid. Just choose the Create Your Own option, plug in your variables and see what it spits out for base signature, signature, timestamp etc. This would have cut many hours off of my debug time. Hope it helps you! http://hueniverse.com/2008/10/beginners-guide-to-oauth-part-iv- signing-requests/ -ZPC On May 12, 1:11 pm, Peter Cross zanbi...@gmail.com wrote: Greetings, Can anyone spot what I'm doing wrong here? I've been busting my head on it for way too many hours. Any help much appreciated! -ZPC === == HTTP Requirements: * You are using POST * You are using SSL * Your xAuth parameters are the ONLY parameters in your POST body * You're setting a Content-Type header of application/x-www-form- urlencoded * You're using HTTP header-based OAuth -- not attaching OAuth parameters to the URL or POST body * You're HTTP Authorization header should only have oauth parameters in it, not any of the xauth parameters === == My Pseudo Code: Dim objRequest as new chilkatHttpRequest Dim objResponse as chilkatHttpResponse Dim sUrl as string Dim sPost as string Dim sAuthorize as string sUrl =https://api.twitter.com/oauth/access_token sAuthorize = OAuth oauth_consumer_key=WITNI0aegpKoIYX7altq3A, oauth_nonce=TCHRFIGDJS403105000810185, oauth_signature_method=HMAC- SHA1, oauth_timestamp=1273680007, oauth_version=1.0, oauth_signature=rY9qTi1o4Ew+/6rS4248VY81i9M= objRequest.UsePost objRequest.AddHeader Authorization, sAuthorize sPost = x_auth_mode=client_authx_auth_password=XXXx_auth_username=XXX objRequest.LoadBodyFromString sPost, utf-8 TRIED BOTH OF THESE: Set objResponse = m_objHttp.PostUrlEncoded(sUrl, objRequest) sDomain = m_objHttp.GetDomain(sUrl) objRequest.Path = m_objHttp.GetUrlPath(sUrl) Set objResponse = m_objHttp.SynchronousRequest(sDomain, 443, 1, objRequest) === == This is what I get back from the Chilkat HTTP Event Log: SocketConnect = api.twitter.com:443 HostnameResolve = api.twitter.com ResolvedToIp = 168.143.161.29 SocketConnected = api.twitter.com:443 SslHandshake = Starting SslHandshake = Finished HttpRequestBegin = POST,api.twitter.com:443/oauth/access_token RequestHeader = POST /oauth/access_token HTTP/1.1 Authorization: OAuth oauth_consumer_key=WITNI0aegpKoIYX7altq3A, oauth_nonce=TCHRFIGDJS403105000810185, oauth_signature_method=HMAC- SHA1, oauth_timestamp=1273680007, oauth_version=1.0, oauth_signature=rY9qTi1o4Ew+/6rS4248VY81i9M= Host: api.twitter.com Content-Type: application/x-www-form-urlencoded Content-Length: 0 StartSendingRequest = 370 PercentDone = 100 HttpInfo = Begin reading response ResponseHeader = HTTP/1.1 500 Internal Server Error Date: Wed, 12 May 2010 16:29:06 GMT Server: hi Status: 500 Internal Server Error X-Transaction: 1273681746-82104-13101 Last-Modified: Wed, 12 May 2010 16:29:06 GMT Content-Type: text/html; charset=utf-8 Content-Length: 4659 Pragma: no-cache X-Revision: DEV Expires: Tue, 31 Mar 1981 05:00:00 GMT Cache-Control: no-cache, no-store, must-revalidate, pre-check=0, post- check=0 Set-Cookie: k=76.109.171.34.1273681744410025; path=/; expires=Wed, 19-May-10 16:29:04 GMT; domain=.twitter.com Set-Cookie: guest_id=127368174665612036; path=/; expires=Fri, 11 Jun 2010 16:29:06 GMT Set-Cookie: _twitter_sess=BAh7CToPY3JlYXRlZF9hdGwrCOAaWY0oAToRdHJhbnNfcHJvbXB0MDoHaWQi %250AJTA1NWE5MjEzZDQyODNmMWIyZDkwYTA2ZmM2ZWU5OGVhIgpmbGFzaElDOidB %250AY3Rpb25Db250cm9sbGVyOjpGbGFzaDo6Rmxhc2hIYXNoewAGOgpAdXNlZHsA--32c34802 010f03dfd32dafd5977de62874d7b166; domain=.twitter.com; path=/ Vary: Accept-Encoding Connection: close HttpStatusCode = 500 ResponseContentLength = 4659 ResponseContentLength = 4659 PercentDone = 42 HttpInfo = Connection:close header is present HttpInfo = Finished reading response PercentDone = 100 ###
[twitter-dev] Weird text gets added to my site's URL
It appears that when I'm not logged into Twitter and visit my site that has @anywhere on it, this is added to the end of all my URLs: #?oauth_error_reason=not_authed How can I get rid of this? Is there a fix? (My site is http://www.adamcapriola.com/ You can try to see if you can reproduce the error I guess.) Thanks so much in advance. Best, Adam
[twitter-dev] The pseudo-code for base string in OAuth page is wrong.
Hello, After carefully reading your OAuth page instructions, I concluded that the pseudo-code for base string in Signing Requests section of Authenticating Requests pages is wrong (http://dev.twitter.com/pages/ auth#signing-requests). The pseudo-code only URL encodes the parameters once, but i must be twice, as you can see from the example in this same page: oauth_callback = http://localhost:3005/the_dance/process_callback?service_provider_id=11 url_encode( oauth_callback ) = http%3A%2F%2Flocalhost%3A3005%2Fthe_dance%2Fprocess_callback %3Fservice_provider_id%3D11 url_encode( url_encode( oauth_callback ) ) = http%253A%252F%252Flocalhost%253A3005%252Fthe_dance %252Fprocess_callback%253Fservice_provider_id%253D11 note how : is encoded in the two forms: the first, as %3A, while the second, as %253A. Thanks and sorry for the annoyance. Rafael
Re: [twitter-dev] WebSockets protocol for streaming API
Hey guys, thanks for the responses. You're right, the motive why I can't use the WebSockets interface is that although the header information for the WebSockets protocol is based on HTTP headers, it's not HTTP and you cannot open a WebSocket connection to an HTTP endpoint. The only other option for network connectivity within browser based clients is using the XmlHttpRequest interface for opening HTTP connections, that's perfectly fine for the REST and the search APIs, however, trying to establish a persistent connection with the XmlHttpRequest interface for use with the streaming API doesn't seem possible. As for cross-origin requests policy I think WebSockets rely on the Cross-Origin Resource Sharing specification [1] authorizing or not the connection based on a whitelist sent by the server on the response header. So that's probably a non-issue. Another benefit that I can imagine is that WebSockets allow a 2-way persistent connection. Because it's a 2-way connection that could make it a lot easier to update the filter predicate without the necessity of reconnecting, but that's another story. :) [1] http://www.w3.org/TR/access-control/ Again, thanks for your hard work, Cezar Sá Espinola @cezarsa On Sun, May 16, 2010 at 3:29 PM, John Kalucki j...@twitter.com wrote: I did a quick reading, and I couldn't tell if WS connections are restricted back to the domain of the calling page, or if arbitrary connections are allowed. If the former, there may not be a reason for the Streaming API to support this. If the latter, perhaps there's a valid use case. Looking at the protocol itself, this wouldn't be trivial to support, but it might not be that bad either. We'll have to keep an eye on the installed browser base and see when this might make sense. It is too bad that they didn't allow HTTP connections with incremental byte reads in addition to WB connections on that interface. I'm sure they had their reasons. -John Kalucki http://twitter.com/jkalucki Infrastructure, Twitter Inc. On Sat, May 15, 2010 at 3:22 PM, Abraham Williams 4bra...@gmail.com wrote: I'm not particularly familiar with the specifics of WebSockets but here is the draft documentation: http://dev.w3.org/html5/websockets/ I don't see Chrome Extensions as being any different from desktop applications as they are both manually installed by the user on their desktop. Abraham On Sat, May 15, 2010 at 09:02, John Kalucki j...@twitter.com wrote: The first release of User Streams is not intended for web clients due to capacity constraints. http://apiwiki.twitter.com/ChirpUserStreams All services, mobile and browser-based clients must not use Streaming until we've sorted out Desktop clients at some scale. One problem at a time. That being said, of course we'd like to encourage experimentation with other client types, so that clients can evolve as we scale out the service. While others at Twitter are well-versed in the latest browser technologies, I'm totally and willfully ignorant. If you could give a brief summary of how the existing Streaming API does not work for WebSockets, that might be helpful. What's missing? -John Kalucki http://twitter.com/jkalucki Infrastructure, Twitter Inc. On Fri, May 14, 2010 at 9:38 PM, Cezar Sá Espinola ceza...@gmail.com wrote: Hey guys, Quick question, are there any plans on supporting WebSockets protocol for the Streaming API? That'd be awesome for browser based Twitter clients (i.e. Google Chrome extensions). Without this it'll be very difficult for this kind of client to lavarage benefit from the upcoming user streams. Thanks a lot for all your hard work, Cezar Sá Espinola @cezarsa -- Abraham Williams | Developer for hire | http://abrah.am @abraham | http://projects.abrah.am | http://blog.abrah.am This email is: [ ] shareable [x] ask first [ ] private.
[twitter-dev] Re: MGTwitterEngine with OAuth and XAuth support
Thanks Steve! I'm using it, but I always get back a 401 error when trying to do a request. - My apps have been granted xAuth access by Twitter (I tried with multiple consumer keys and secrets) - I fetch the token with -[MGTwitterEngine getXAuthAccessTokenForUsername:password:] - I get the token back in -[id accessTokenReceved:forRequest:] - I set it on the Twitter engine with -[MGTwitterEngine setAccessToken:] - I try to send an update with -[MGTwitterEngine sendUpdate:] and I always get a 401 error back (with no description of the 401) Is it working for someone? Any idea of what is going on in my case? Thanks a lot, Mathieu On May 1, 6:57 pm, Steve Streza stevestr...@gmail.com wrote: Hey everyone, I'm one of the collaborators on theMGTwitterEngineproject for Mac and iPhone developers. We've finished our initial implementation of OAuth and XAuth support withinMGTwitterEngine. This uses the OAuthConsumer framework to handle the business end of OAuth, meaning that there are only a couple newMGTwitterEngineAPIs you need to use (and we've got a wiki guide for migrating to OAuth). We expect most users of the framework to want to use XAuth to obtain an access token, so we have a convenience API for handling that (of course, you'll need to obtain the opt-in from Twitter). After getting XAuth access, it shouldn't take more than a half hour to get set up to obtain your access token and start sending requests. We're also planning on releasing a new version ofMGTwitterEnginewith support for some new APIs and bug fixes, as well as OAuth. We're hoping to get this out by WWDC, or at least before the OAuth deadline. We're aware of the buffer needed for App Store approval, so we'll be trying to finish this up ASAP. You can grab the code from the project page here:http://github.com/mattgemmell/MGTwitterEngine/ You can read the migration guide here:http://wiki.github.com/mattgemmell/MGTwitterEngine/migrating-from-bas... Feedback is always welcome. If you have any issues, please file them in the project issue tracker here:http://github.com/mattgemmell/MGTwitterEngine/issues Now stop using basic auth already. Thanks, Steve
[twitter-dev] Re: OAuth issue, using mostly supplied code.
Bingo!! Thanks so much Abraham!! My server time was out by a few hours, synced it up and I get results just like expected!! On May 16, 10:31 am, Abraham Williams 4bra...@gmail.com wrote: Make sure your clock is properly synced. If it is more the a few minutes off it can cause the same error. Abraham On Sun, May 16, 2010 at 01:49, wparsons willpars...@gmail.com wrote: Hopefully someone can help me out with this one, as I'm pretty stuck.. I'm using the PHP example on here: http://dev.twitter.com/pages/oauth_single_token function getConnectionWithAccessToken($oauth_token, $oauth_token_secret) { $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET, $oauth_token, $oauth_token_secret); return $connection; } $connection = getConnectionWithAccessToken(abcdefg, hijklmnop); $content = $connection-get(statuses/home_timeline); along with the OAuth.php and twitterOAuth.php classes from @abraham's code. I've triple checked that all the keys are correct (copied and pasted from my twitter account). I'm using my OAuth_Token and OAuth_Token_Secret, not the sample strings in the above code. No matter what I request in the 'get', I get an Invalid / Used nonce error back. The Oauth.php and twitteroauth.php files are 100% untouched, and when I view the request, the nonce and timestamp are changing with every request. If I change the OAuth_Token key I get an expired token error, but changing the other keys doesn't have any effect, so it might be related to the keys I'm using? Any help would be GREATLY appreciated! -- Abraham Williams | Developer for hire |http://abrah.am @abraham |http://projects.abrah.am|http://blog.abrah.am This email is: [ ] shareable [x] ask first [ ] private.