Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Building AJAX Applications Using Yahoo! Web Services


Published on

Yahoo! is opening up to developers using Web services. Today our services enable developers to access Yahoo! properties as diverse as Web search, maps, Flickr, comparison shopping, and many more -- and we're making more available all the time. In this session you'll learn how you can incorporate Yahoo! Web services in your application or Web site, and see a demonstration of integration between Yahoo! Web Services, the new Yahoo! Presentation Library, and ASP.NET "Atlas".

Published in: Technology
  • Be the first to comment

  • Be the first to like this

Building AJAX Applications Using Yahoo! Web Services

  1. 1. Building Web Applications Using Yahoo! Web Services Jeffrey McManus Director, Yahoo! Developer Network March, 2006
  2. 2. About this talk <ul><li>About Yahoo! Web services </li></ul><ul><ul><li>How to build a .NET application using Y! Web services </li></ul></ul><ul><ul><li>Using ASP.NET Atlas with Y! Web services </li></ul></ul><ul><li>About the Yahoo! User Interface Libraries and Ajax technologies </li></ul><ul><li>A look ahead </li></ul>
  3. 3. Our Goals: Building a Developer Ecosystem on the Yahoo! Platform <ul><li>Provide as many compelling products for developers as possible </li></ul><ul><ul><li>Web service APIs, tools, libraries, etc. </li></ul></ul><ul><ul><li>Create and grow a developer community </li></ul></ul><ul><li>Disseminate information about our developer offerings </li></ul><ul><li>Provide exceptional support for developers </li></ul>
  4. 4. Developer Momentum <ul><li>We entered 2005 with a smattering of third-party developers (mostly private partnerships, negotiated on a one-off basis) </li></ul><ul><li>We exited 2005 with a community of tens of thousands of developers </li></ul><ul><li>We will continue to make integrating with Yahoo! easier and easier on both a technical and a business level </li></ul>
  6. 7. Search Web Services <ul><li>Audio Search </li></ul><ul><ul><li>Album Search </li></ul></ul><ul><ul><li>Artist Search </li></ul></ul><ul><ul><li>Podcast Search </li></ul></ul><ul><ul><li>Download Location </li></ul></ul><ul><ul><li>Song Search </li></ul></ul><ul><li>Autos Custom </li></ul><ul><li>Content Analysis </li></ul><ul><li>Image Search </li></ul><ul><li>Local Search </li></ul><ul><li>MyWeb Search </li></ul><ul><li>News Search </li></ul><ul><li>Site Explorer </li></ul><ul><li>Video Search </li></ul><ul><li>Web Search </li></ul><ul><ul><li>Context Search </li></ul></ul><ul><ul><li>Related Queries </li></ul></ul><ul><ul><li>Spelling Suggestion </li></ul></ul>
  7. 8. Web Search API: Inputs <ul><li>query </li></ul><ul><li>region </li></ul><ul><li>type (all, any, phrase) </li></ul><ul><li># of results </li></ul><ul><li>start position </li></ul><ul><li>format (html, msword, pdf, ppt, etc.) </li></ul><ul><li>language </li></ul><ul><li>country </li></ul><ul><li>site </li></ul><ul><li>subscription </li></ul><ul><li>license (creative commons) </li></ul><ul><li>output (xml, json, php) </li></ul><ul><li>callback (json) </li></ul>
  8. 9. Web Search API: Outputs <ul><li>totalResultsAvailable, totalResultsReturned </li></ul><ul><li>Title </li></ul><ul><li>Summary </li></ul><ul><li>Url </li></ul><ul><li>ClickUrl </li></ul><ul><li>MimeType </li></ul><ul><li>ModificationDate </li></ul><ul><li>Cache (Url + size) </li></ul>
  9. 10. Use Martin Brown’s .NET Wrapper Classes to Call Search Web Services <ul><li>Downloads and parses search results from most of our search APIs </li></ul><ul><ul><li>No HTTP-handling or XML-parsing necessary </li></ul></ul><ul><ul><li>Generated from schema using xsd.exe </li></ul></ul><ul><ul><li>Full source code (C# and VB.NET) included </li></ul></ul><ul><li> </li></ul>
  10. 11. Example: Performing a Web Search Using the Brown Wrapper <ul><li>This is a “traditional” request/response example (no Ajax stuff...yet) </li></ul>
  11. 12. Simple Maps API <ul><li>Plot up to 100 points on a Yahoo! map without programming and without limits </li></ul><ul><li>Add geoRSS tags to an existing RSS feed to plot RSS data points on a map </li></ul>
  12. 13. Demo: Simple Maps
  13. 14. Ajax Maps API <ul><li> </li></ul>
  14. 15. Flash Maps API <ul><li> </li></ul><ul><li>Example: </li></ul>
  15. 16. Maps “Building Block” APIs <ul><li>Geocoding API </li></ul><ul><li>Map Image API </li></ul><ul><li>Traffic API </li></ul><ul><li>Local Search API </li></ul><ul><ul><li>Returns long/lat for plotting on maps </li></ul></ul>
  16. 17. Music Engine Plug-Ins <ul><li>Yahoo! Music Engine provides personalized streaming radio, music purchase, and unlimited subscription music </li></ul><ul><li>The music client application is pluggable </li></ul><ul><ul><li>Create plug-ins written in C++ or JavaScript </li></ul></ul><ul><ul><li>Applications run in embedded IE within the Music Engine client </li></ul></ul><ul><li> </li></ul><ul><li> </li></ul>
  17. 18. Trip Planner API <ul><li>Return information on where to go and what to do from Yahoo! Trip Planner ( </li></ul><ul><li>Retrieve trips planned from a specific Yahoo! user </li></ul><ul><li>Example: </li></ul>
  18. 19. Shopping API <ul><li>Retrieve product and pricing information from our database of products </li></ul><ul><li> </li></ul><ul><li>Example: </li></ul>
  19. 20. Shopping API 2.0 <ul><li>New features for the Yahoo! comparison shopping API </li></ul><ul><ul><li>Search-narrowing options </li></ul></ul><ul><ul><ul><li>Shoes >> Men’s Shoes >> Size 9 </li></ul></ul></ul><ul><ul><li>Build a product hierarchy based on that of </li></ul></ul><ul><ul><li>Variable product image sizes to fit your layout </li></ul></ul>
  20. 21. Shopping Paid Syndication Beta <ul><li>Make money by referring traffic to Yahoo! Shopping advertising partners </li></ul><ul><li>Now accepting beta applications: </li></ul>
  21. 22. Flickr API <ul><li>Flickr is a photo-sharing community that makes it easy to upload, organize/tag, and share photos </li></ul><ul><li>Flickr API makes it easy to build applications that incorporate Flickr </li></ul><ul><li> </li></ul>
  22. 23. <ul><li>Event-sharing community </li></ul><ul><ul><li>Joined Yahoo! in 2005 </li></ul></ul><ul><li> </li></ul>
  23. 24. MyWeb and <ul><li>Save your bookmarks to the Web </li></ul><ul><li>Tag, label, share URLs with your friends </li></ul><ul><li> has an API today, MyWeb has search today with read/write coming soon </li></ul>
  24. 25. New: JavaScript Developer Center <ul><li>Provides assistance with scripting and AJAX development </li></ul><ul><li>JSON Web services support give JavaScript developers the ability to easily handle data without parsing XML </li></ul><ul><ul><li>Facilitates rapid development and creation of AJAX applications </li></ul></ul><ul><li> </li></ul>
  25. 26. Design Pattern Library <ul><li>Solutions and guidance to common Web user interface problems </li></ul><ul><li>Techniques reflect years of experience and user testing </li></ul><ul><ul><li>Includes solutions for such issues as accessibility </li></ul></ul><ul><li>Provided under a Creative Commons license </li></ul><ul><li> </li></ul>
  26. 27. New: Javascript User Interface Library <ul><li>A collection of JavaScript libraries you can use in your Web development </li></ul><ul><ul><li>Complex user interface controls </li></ul></ul><ul><ul><li>A cross-browser Ajax library </li></ul></ul><ul><ul><li>Drag-drop and event libraries </li></ul></ul><ul><li>To be updated frequently </li></ul><ul><li>Free and open-source (BSD license) </li></ul><ul><li> </li></ul>
  27. 28. Yahoo! JavaScript UI Components <ul><li>Animation </li></ul><ul><li>Connection Manager </li></ul><ul><li>DOM </li></ul><ul><li>Drag and Drop </li></ul><ul><li>Event </li></ul><ul><li>Calendar </li></ul><ul><li>Slider </li></ul><ul><li>TreeView </li></ul>CORE UTILITIES UI CONTROLS
  28. 29. JSON Serialization <ul><li>Provides a way to retrieve Web </li></ul><ul><ul><li>Excellent way to write Ajax applications because the data is in native JavaScript format </li></ul></ul><ul><ul><li>This happens to be the same way that Atlas communicates between client and server </li></ul></ul><ul><li>Referencing a JSON-emitting service in a <script> tag enables you to consume data without parsing or proxying </li></ul><ul><ul><li>Be careful that the source of the JSON is trustworthy </li></ul></ul>
  30. 31. Yahoo’s Mission <ul><li>To help users: </li></ul><ul><ul><li>Find </li></ul></ul><ul><ul><li>Use </li></ul></ul><ul><ul><li>Share </li></ul></ul><ul><ul><li>Expand ...all human knowledge </li></ul></ul>
  31. 32. Building a Participation Platform <ul><li>Today we provide a number of “find” services that are usable on and off Yahoo! </li></ul><ul><ul><li>Now we must address “use,” “share” and “expand” </li></ul></ul><ul><ul><li>This will enable a new wave of user participation based on the Yahoo! platform </li></ul></ul><ul><li>Services we provide to facilitate this must be: </li></ul><ul><ul><li>Bidirectional </li></ul></ul><ul><ul><li>Personalized </li></ul></ul><ul><ul><li>Secure </li></ul></ul>
  32. 33. Authentication and personal information <ul><li>One of the strengths of Yahoo! is personalization </li></ul><ul><ul><li>Enabling users to create, store and share information, and to personalize their experience </li></ul></ul><ul><li>We are now extending this to third-party applications and Web sites </li></ul><ul><li>Through secure authentication, we will enable Yahoo! users to get access to Yahoo! data in a way that is ubiquitous , easy , open , and secure </li></ul>
  33. 34. Yahoo! Search Your application or Web site Retrieve Web search results
  34. 35. Yahoo! Photos Your application or Web site Retrieve photos Upload, organize, tag and share photos
  35. 36. Browser-Based Authentication for Yahoo! Web Services <ul><li>Provides access to Yahoo! Web services through third-party Web sites </li></ul><ul><li>How it works: </li></ul><ul><ul><li>User discovers a third-party Web site </li></ul></ul><ul><ul><li>User authenticates with Yahoo! (not the third-party developer) </li></ul></ul><ul><ul><li>Yahoo! sends a token to the developer that enables her to make API calls on the user’s behalf </li></ul></ul><ul><ul><li>Yahoo! never shares the user name and password with the third-party developer </li></ul></ul><ul><ul><li>User can revoke permission from the third-party developer at any time </li></ul></ul>
  36. 37. How Browser-Based Authentication Works
  37. 38. SHARE
  38. 39. Yahoo! Application Gallery <ul><li>The Yahoo! Developer Network’s first consumer-oriented site </li></ul><ul><li>Showcases applications built using Yahoo! technology </li></ul><ul><ul><li>Widgets, Web sites, plug-ins, etc. </li></ul></ul><ul><li>Unifies the (many) disparate collections of applications that have been maintained here and there throughout Yahoo! </li></ul><ul><ul><li>Flickr, Search, Widgets, Maps, etc., etc. </li></ul></ul>
  39. 40. Application Gallery Features <ul><li>Developers can submit links and descriptions of their applications </li></ul><ul><li>Add tags to assist with discovery of applications, sites and widgets </li></ul><ul><li>Users can rate and review applications </li></ul><ul><ul><li>We’ll feature the highest-rated apps and developers </li></ul></ul><ul><li>Search for applications powered by the greatest search engine in the world, Yahoo! Search </li></ul>
  40. 42. What’s Next? <ul><li>Many of the simple, obvious, read-only integration points with Yahoo! are completed and available today </li></ul><ul><li>However: What we’ve done to date is only the tip of the iceberg </li></ul>
  41. 43. Coming Soon: Calendar API <ul><li>Yahoo! Calendar enables users to store calendar events, scheduled recurring appointments, share calendars across multiple users, and set alerts </li></ul><ul><li>The Yahoo! Calendar API enables Calendar integration with your Web site </li></ul><ul><ul><li>Will utilize Browser-Based Authentication </li></ul></ul><ul><ul><li>JSON and iCal support coming soon </li></ul></ul><ul><ul><li>Other formats will appear later in the year </li></ul></ul>
  42. 44. Coming Soon: Yahoo! Photos API <ul><li>A read/write API for the most popular photo-sharing site in the world, Yahoo! Photos </li></ul><ul><li>Will utilize Browser-Based Authentication </li></ul>
  43. 45. Questions? Comments? <ul><li>Yahoo! Developer Network: </li></ul><ul><li>My blog: </li></ul><ul><li>These slides: </li></ul><ul><li>Contact me: </li></ul>