Using the Twitter API
In this recipe, let's build a Twitter client app using the Twitter API. This is similar to the previous RSS reader recipe. Here, instead of RSS format you will receive the custom XML format related to the Twitter username or screen name.
Getting ready
First study the Twitter API resource page at:
https://dev.twitter.com/docs/api
There are many categories of API available such as Timelines, Tweets, Search, and so on. We will be using statuses/user_timeline
for a given user in this recipe.
How to do it...
In the next steps, we will create a client application, which will have a textbox to search for a name and return the latest updates for that username.
Open a new project and create a new Phone 7 Application with the name
Recipe2_TwiitterClient
.Right-click on the project folder and add a new class to the
TwitterFeed.cs
file. Open the file and add the new class to store the Twitter feed information. We will have one string variable calledContent
:public class TwitterFeed ...