This project has moved and is read-only. For the latest updates, please go here.

Calling unauthenticated OEmbed endpoint

Nov 19, 2013 at 4:17 PM
I'm working on an application which requires calling OEmbed for a large number of tweets. In the twitter documentation says that you should use the unauthenticated OEmbed endpoint in order to avoid hitting the rate limit, as this endpoint is not limited.

Is this possible using LinqToTwitter ? Or is it only possible to call the v1.1 endpoint using LinqToTwitter, and thus be subject to the rate limits?

The call I'm making to fetch the embed codes currently looks like this:
 using (var ctx = new TwitterContext(_authorization))
                var tweet = ctx.Status.Where(m =>
                    m.ID == tweetId &&
                    m.OEmbedHideMedia == true &&
                    m.OEmbedOmitScript == true &&
                    m.OEmbedMaxWidth == 315 &&
                    m.Type == StatusType.Oembed)

                return tweet == null ? "" : tweet.EmbeddedStatus.Html;
thanks in advance.
Nov 19, 2013 at 4:29 PM

The OP in that post was reading old v1.0 documentation. Earlier this year, Twitter deprecated v1.0 and everyone must now use v1.1, which LINQ to Twitter supports. In v1.1, all endpoints are rate limited. Here's the proper Twitter API documentation:

And the corresponding LINQ to Twitter documentation:

Nov 19, 2013 at 4:44 PM
Thanks very much for your response.

According to Twitter, when they deprecated v1.0 they continued to support unauthenticated calls to v1.0 Oembed enpoint as explained here

(also explains why their developer was still recommending using that endpoint in the discussion I linked to in my first post)

Is there any way I can call this endpoint with LinqToTwitter? I'm already using LinqToTwitter, so would rather continue to do so, rather than have to do it manually.