Hour 5. Making Your First API Call

What You’ll Learn in This Hour:

How to make a simple URL call

How to make a call in php

Making a Simple Twitter API Call

OK, it’s time make a call to Twitter and get a response. Let’s dive right in and make a simple call to the Twitter service to get the latest public timeline. Depending on your browser and its configuration you may need to view source to see the proper formatting.

Open a web browser, type in the following, and press Enter:


You should get something like the following:

<statuses type="array"><status>  <created_at>Thu Dec 31 03:31:08 +0000 2009</created_at>  <id>7220013867</id>  <text>Lorem ipsum dolor sit amet, consectetur adipisicing elit, ...

Get Sams Teach Yourself the Twitter API in 24 Hours now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.