I would be able to retrieve HTML markup of what is stored in Twitter Card (https://dev.twitter.com/docs/cards).
Up until now I used TweetSharp library to retrieve tweets from some user's timeline. But, what is not surprising, because cards are new thing, it is not included.
Does anyone know, if it is possible to access card (data cached by Twitter crawler) with API?
So let’s get started. Wait, but what are the requirements? In order to begin using the Twitter API, you’ll need an account with Twitter that will get you access to an API Key (Consumer Key). Getting credentials to the Twitter API is really simple.
Get access to the Twitter API To make any request to the Twitter API (in python or anywhere else) you require your API Key and Access Token. For this, you need to apply for a developer account with Twitter and have your account approved. Once approved, you can create a project and associate it with a sample App.
If you need to find your access tokens and keys again, then in the left hand menu select Projects & Apps > your project name. You’ll see a page that will enable you to regenerate your keys and tokens if you have lost them. The Twitter api documentation describes these like this:
This will allow you to access the Twitter developer portal. 2. Head over to the Twitter Dev Site and Create a New Application Navigate to apps.twitter.com, sign in, and create a new application. After that, fill out all the app details and… …Voila! You now should be able to access all the required API Keys and authorization credentials.
The Twitter cards themselves are not exposed through the Twitter API.
What you'll need to do is make a request to the URL mentioned and examine the <head>
element to see if they have the Twitter Card info in there.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With