[twitter-dev] t.co reverse

2011-01-07 Thread Amaury
Hi guys !

Thanks to new Mac OS Twitter client a lot of URL in tweets are now
convert to t.co witch is include in API response for user/
timeline ...

Is there any way to reverse t.co simply like we can do with bit.ly
API ?


Thanks

@Amaury

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


Re: [twitter-dev] t.co reverse

2011-01-07 Thread Taylor Singletary
Hi Amaury,

There currently isn't a distinct API available to de-reference t.co URLs (or
directly produce them). However, most REST API timeline and status-bearing
methods support the include_entities=true parameter which will include an
additional set of fields, including unrolled t.co URLs. You can read more
about entities here: http://dev.twitter.com/pages/tweet_entities

For example with this request:
GET
http://api.twitter.com/1/statuses/show.json?id=23150950055153664include_entities=true

The tweet text was:
text: Emergent Behavior in Twitter Culture http://t.co/bcUPYxi via
@adage,

And the entities node shows the de-referenced URL in
entities/urls[0]/expanded_url:

entities: {
  places: [],
  urls: [
{
  expanded_url: http://adage.com/u/rby1pa;,
  url: http://t.co/bcUPYxi;,
  indices: [
37,
56
  ],
  display_url: adage.com/u/rby1pa
}
  ],
  hashtags: [],
  user_mentions: [
{
  name: Ad Age,
  id_str: 12480582,
  id: 12480582,
  indices: [
61,
67
  ],
  screen_name: adage
}
  ]
}

Thanks,
Taylor

On Fri, Jan 7, 2011 at 6:59 AM, Amaury amaury.lespling...@gmail.com wrote:

 Hi guys !

 Thanks to new Mac OS Twitter client a lot of URL in tweets are now
 convert to t.co witch is include in API response for user/
 timeline ...

 Is there any way to reverse t.co simply like we can do with bit.ly
 API ?


 Thanks

 @Amaury

 --
 Twitter developer documentation and resources: http://dev.twitter.com/doc
 API updates via Twitter: http://twitter.com/twitterapi
 Issues/Enhancements Tracker:
 http://code.google.com/p/twitter-api/issues/list
 Change your membership to this group:
 http://groups.google.com/group/twitter-development-talk


-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk