SlideShare a Scribd company logo
Integrating Google APIs into your
 Applications

Chris Schalk
Google Developer Advocate
9/23/2008
Agenda


    • Client Side APIs
      – Maps API
      – AJAX APIs
           • Search, Feed, Translation
    • Google Server-side APIs
      – Google Data
      – Calendar, Blogger, YouTube...
      – Demo with JSF
    • OpenSocial/Gadgets
      – How to build gadgets
      – OpenSocial - What is it??
      – How to host OpenSocial gadgets


2                                 (c)2008 Google
Agenda


    • Client Side APIs
      – Maps API
      – AJAX APIs
           • Search, Feed, Translation
    • Google Server-side APIs
      – Google Data
      – Calendar, Blogger, YouTube...
      – Demo with JSF
    • OpenSocial/Gadgets
      – How to build gadgets
      – OpenSocial - What is it??
      – How to host OpenSocial gadgets


3                                 (c)2008 Google
Google Maps API


    • JavaScript Client API
    • Build a Customized Maps
      application
    • Easy to mashup with other
      technologies
    • Also works with Flash
    • Can generate static Maps
      images via REST




4                                 (c)2008 Google
Google AJAX APIs

Delivering the Web to Your Applications (Search, Feeds, Language)

                           • RESTful data access layer
                           – JSON/JSON-P
AJAX APIs                  • JavaScript Runtime
                           – Designed for ease of use
                           • JavaScript Controls and UI elements
                           – Custom integration and styling




                              (c)2008 Google
Google AJAX APIs Background
• Comprehensive access to Google Systems (Search, Feeds,
  Language)
• End to end API stack:
   • Data Access via JavaScript Methods and REST
   • Built in Native UI and Large Suite of Advanced Controls
• Large, diverse customer base
   • Sites: Long Tail and Short Tail Sites (100 pv/d – 10m+ pv/d)
   • Developers: Pro Web Developers – Scripters – Bloggers
• High Speed, Low Latency, Globally Available


    JavaScript Controls and UI elements

         JavaScript Runtime Layer
                                                AJAX
        RESTful Data Access Layer               APIs
Google AJAX Search API


• Web
• Video
• News
• Image
• Local
• Book
• Blog




                  (c)2008 Google
Google AJAX Feed API

• Load
• Find
• Lookup




                   (c)2008 Google
Google AJAX Language API




• Translation
• Language Detection




                       (c)2008 Google
Demo - Trying out some of the AJAX APIs
Some notable AJAX APIs Applications
Time - AJAX Search API (news)
http://www.time.com/time/politics
http://www.time.com/time/global_business/united-states

NYTimes - AJAX Feed API
http://thecaucus.blogs.nytimes.com

People - AJAX Feed API + gadgets
http://www.people.com/people/news/0,,,00.html
http://www.google.com/uds/gadgets/people_ads/people_ads.html

SnowCovered - AJAX Language API
http://www.snowcovered.com/Snowcovered2/

Walkscore - AJAX Search API (local) + Maps API
http://www.walkscore.com/get-score.php?street=1600+amphitheatre+parkway+94043&go=Go
http://www.walkscore.com/rankings/San_Francisco

Google Elections apps:
http://www.google.com/2008election/
http://www.google.com/2008election/convention.html

Background:
http://www.searchmashups.blogspot.com/

                                       (c)2008 Google
Agenda


     • Client Side APIs
       – Maps API
       – AJAX APIs
           • Search, Feed, Translation
     • Google Server-side APIs
       – Google Data
       – Calendar, Blogger, YouTube...
       – Demo with JSF
     • OpenSocial/Gadgets
       – How to build gadgets
       – OpenSocial - What is it??
       – How to host OpenSocial gadgets


12                                  (c)2008 Google
ServerSide Google APIs Overview

     • Google Data APIs
        – Common set of APIs for working with multiple online Google
          technologies
       – Google Apps APIs, Base Data API, Data API, Calendar Data API, Code Search
          Data API, Contacts Data API, Finance Portfolio Data API, Health Data API,
          Notebook Data API, Spreadsheets Data API, Picasa Web Albums Data API,
          Google Documents List Data API, Webmaster Tools Data API, YouTube Data
          API



       – Support for multiple languages
           •   Python
           •   PHP
           •   .Net
           •   Java
           •   JavaScript



13                                      (c)2008 Google
Google Data APIs Overview

     • Google Data APIs, aka “Gdata”, is a protocol based on the Atom
      1.0 and RSS 2.0 syndication formats, plus the Atom Publishing
      Protocol
     • “Gdata” extends those standards in various ways, using the
      extension mechanisms built into the standards. A GData feed
      conforms to either the Atom or RSS syndication formats. The
      GData publishing model conforms to the Atom Publishing Protocol.
     • To acquire information from a service that supports GData, you
      send an HTTP GET request; the service returns results as an Atom
      or RSS feed.
     • You can update data (where supported by a particular GData
      service) by sending an HTTP PUT request.
     • GData provides a general model for feeds, queries, and results.
      You can use it to send queries and updates to any service that has
      a GData interface.

14                                  (c)2008 Google
ServerSide Google APIs Overview

     • Other server-side Google APIs…
     • Google Chart API




      Also other restful services, AJAX apis, OpenSocial RESTful API




15                                (c)2008 Google
Working with the Data APIs in Java



     • Getting the Gdata Jar files
     • Running the sample app
     • Add Jars to your IDE
     • That’s it!




16                       (c)2008 Google
Some basic data operations w/ Calendar API


     • Querying all of your calendars
     • Querying the events in all of your calendars
     • Querying specific events based on a text string
     • Querying events based on a date range
     • Creating new calendar events
     • Deleting/Updating calendar events




17                         (c)2008 Google
Using the Calendar Data API with JSF




18                      (c)2008 Google
Using the Calendar Data API with JSF

       Basic Architecture




                   CalendarServices

                     Managed Bean
19                          (c)2008 Google
Introducing the Google Charts API


     • Simple REST based dynamic chart generator

     • Offers the creation of on-the-fly charts of multiple types
       – http://chart.apis.google.com/chart?cht=p3&chd=t:60,40&chs=25
          0x100&chl=Hello|World




20                                 (c)2008 Google
The JSF Custom Chart Component




21                    (c)2008 Google
Google data APIs/ RESTful services summary


     • The Google Data APIs offer full online data access to
     multiple Google Services

     • Gdata supports multiple client languages

     • Other simple, RESTful, online services also offered
     by Google

        • Charts API, AJAX APIs…

     • Relatively straightforward to integrate with server-side
     Java / JSF

22                           (c)2008 Google
More info…


     • http://code.google.com

     • http://code.google.com/apis/gdata/

     • http://code.google.com/apis/chart




23                          (c)2008 Google
Agenda


     • Client Side APIs
       – Maps API
       – AJAX APIs
            • Search, Feed, Translation
     • Google Server-side APIs
       – Google Data
       – Calendar, Blogger, YouTube...
       – Demo with JSF
     • OpenSocial/Gadgets
       – How to build gadgets
       – OpenSocial - What is it??
       – How to host OpenSocial gadgets


24                                 (c)2008 Google
Building Gadgets


     • It’s just JavaScript embedded in an XML file!
     • Runs within a “container” environment
        – iGoogle
        – Other environments coming online through OpenSocial

     • Gadget’s relation to OpenSocial
        – Gadgets serve as the base architecture for OpenSocial
          applications




25                                (c)2008 Google
•




26
•




27
Too many platforms!



28
Standards based
      OpenSocial



     Write once…
        Deploy everywhere


29
Use multiple times
        Cooooool!



30
Not just Social Network Sites



 • Social network sites - Profiles and home pages
     ex: MySpace, Hi5

 • Personal dashboards – Widgets
     ex: iGoogle, My Yahoo

 • Sites based around a Social Object
     ex: Flickr, YouTube

 • Enterprise systems
     ex: Oracle, SalesForce.com

 • Any web site

31
OpenSocial Roadmap



     • Version 0.5 was released in a “developer release” on Nov
     1st.
         • First “sandbox” was made available on Orkut

     • Version 0.6 was released in December
        • Initial version of Shindig server software was launched as Apache
        incubator project
        • Other sandboxes came live - Hi5, Ning, Plaxo …

     • Version 0.7 (production) was released in January
        • MySpace, Hi5, Orkut currently running with 0.7


32
OpenSocial v0.8 is here!


     • Latest evolution of OpenSocial as defined by the
     OpenSocial development community
         • Updated JavaScript API
         • Now contains a RESTful API

     • Shindig supports v0.8 today
        • iGoogle now supports 0.8!
        • hi5 almost done with their support
        • orkut currently working on their implementation
        • Other containers also working on 0.8

     • Specification is here:
     http://www.opensocial.org/Technical-Resources/opensocial-spec-v08
33
OpenSocial Hi-level Details

     • A set of open, standard APIs for building
     social applications

     • APIs based on Web standards:
     HTML/CSS, JavaScript, REST+OAuth

     • Reference Implementation: Shindig
        • Apache Open Source Project

     • A global community of thousands of
     developers
34
OpenSocial Core Services


• People & Friends
     •   Access friends information programmatically

• Activities
     •   See what you’re friends are up to
     •   Share what you are doing


• Persistence
     •   Provide state without a server
     •   Share data with your friends



35
OpenSocial Client APIs



     • JavaScript API - for browser based client development
        •    Standard Web development technologies
              •   HTML + Javascript, CSS, AJAX
        •    Can integrate with 3rd party servers
              •   PHP, Perl, Java, C/C++

     • RESTful API - for server based client development
        •    Based on Atom publishing protocol
        •    Data transfer is Atom or JSON
        •    More on RESTful API later…



36
Building JavaScript OpenSocial Applications


     • If you know how to develop gadgets, you know how to
       develop JavaScript OpenSocial applications!

        •    Follows same approach as gadgets
              • JavaScript/HTML/CSS embedded in an XML
                 document
              • XML document containing gadget is hosted on the
                 Internet
        •    OpenSocial applications are “gadgets++”
              • Gadgets development, but with additional Social
                 capabilities

37
OpenSocial People & Friends Example

      An OpenSocial example to show the owner’s friends


     function getFriends(id) {
      var params = {};
      params[opensocial.IdSpec.Field.USER_ID] =
                     opensocial.IdSpec.PersonId.OWNER;
      params[opensocial.IdSpec.Field.GROUP_ID] = quot;FRIENDSquot;;


      var idspec = opensocial.newIdSpec(params);


      var req = opensocial.newDataRequest();
      req.add(req.newFetchPeopleRequest(idspec), quot;reqquot;);
      req.send(onLoadFriends);
     };


38
OpenSocial People & Friends Example

      An OpenSocial example to show the owner’s friends


     var html= quot;Listing friends:<br/>quot;;


     function printPerson(person) {
      html += quot;<br/>quot; + person.getDisplayName();
     };


     function onLoadFriends(dataResponse) {
      dataResponse.get(quot;reqquot;).getData().each(printPerson);
      document.getElementById('message').innerHTML = html;
     };



39
Activities Example

         Posting an Activity


     function postActivity(text) {
        var params = {};
        params[opensocial.Activity.Field.TITLE] = text;
        var activity = opensocial.newActivity(params);
        opensocial.requestCreateActivity(activity,
          opensocial.CreateActivityPriority.HIGH, callback);
     }


     postActivity(quot;This is a sample activity, created at quot; +
       new Date().toString())
     }




40
Persistence Example

       Storing persisted data


     function populateMyAppData() {
       var req = opensocial.newDataRequest();
       var data1 = Math.random() * 5;
       var data2 = Math.random() * 100;

       req.add(req.newUpdatePersonAppDataRequest(quot;VIEWERquot;,
                            quot;AppField1quot;, data1));
       req.add(req.newUpdatePersonAppDataRequest(quot;VIEWERquot;,
                            quot;AppField2quot;, data2));
       req.send(requestMyData);
     }




41
Persistence Example

        Fetching persisted data


     function requestMyData() {
       var req = opensocial.newDataRequest();
       var fields = [quot;AppField1quot;, quot;AppField2quot;];

       req.add(req.newFetchPersonRequest(
         opensocial.DataRequest.PersonId.VIEWER), quot;viewerquot;);
       req.add(req.newFetchPersonAppDataRequest(quot;VIEWERquot;,
         fields), quot;viewer_dataquot;);
       req.send(handleReturnedData);
     }




42
OpenSocial JavaScript client application in action

     Gadget using JavaScript Client API communicates
     with OpenSocial server



                                        OpenSocial
                           JSON           Server


                                      Gadget XML Source
         browser




43
Integrating OpenSocial applications with external servers

     The OpenSocial persistence service provides a way to
     store/share small amounts of data on the OpenSocial
     server, but…

     • What if you need to store more data than your
       container allows?

     • Solution: You can make independent requests out
       to external servers.
        • Use: gadgets.io.makeRequest
        • Can also make authenticated requests using Oauth
        • Can use cloud services from: Joyent, Amazon or
          AppEngine!


44
Integrating OpenSocial applications with external servers

     An example request to an external server

               gadgets.io.makeRequest



                             OpenSocial
                               Server                   External
                    1                        2           Server


     browser


          1. Initial request made from gadget
          2. Server routes request to external server

                           Requests can be secured using OAuth!
45
Demonstration

     • Building OpenSocial Client Applications




46
How to host OpenSocial Applications


     1. Can build your own server that implements
     OpenSocial specification…

     2. Or can use “Shindig” - Reference implementation for
     OpenSocial
        • Gadget Server
           –Renders gadget XML as HTML/JS/CSS
        • OpenSocial Data Server
           –RESTful API server (in-progress)



47
Serverside OpenSocial
      How to implement an OpenSocial server


     Shindig
       orkut, hi5, iGoogle, tianya.cn, …
       • Gadget Server
            –Renders gadget XML as HTML/JS/CSS
       • OpenSocial Data Server
            –RESTful API server
       •   Gadget Container JavaScript
            –Core gadgets JavaScript environment



48
How Shindig works
     • Gadget Server
     • OpenSocial Data Server


                                 Shindig
       Yoursite.com
                                 Gadget
               Gadget            Server


                                OpenSocial
                                DataServer



49                                           49
Why use Shindig?

     •   Strong open source community

     •   High quality production-ready code

     •   Update easily as OpenSocial evolves

     •   Fully compliant with OpenSocial v0.7, v0.8

     •   Shindig is language neutral (Java, PHP)




50
Shindig success at hi5

     • Big Traffic
        • 10k req/sec Edge
        • 6k req/sec Origin


     • Hundreds of Developers
     • 1800+ Apps
     • 1 Billion hits/day
     … on 42 Shindig servers




51                                51
Demonstration: Trying out Shindig




52                                       52
Thank You!

     http://chrisschalk.com




53             (c)2008 Google
Integrating Google APIs into Your Applications

More Related Content

Viewers also liked

Immediato, sostenibile, efficiente. Il gas naturale per la decarbonizzazione
Immediato, sostenibile, efficiente. Il gas naturale per la decarbonizzazioneImmediato, sostenibile, efficiente. Il gas naturale per la decarbonizzazione
Immediato, sostenibile, efficiente. Il gas naturale per la decarbonizzazioneSnam
 
2016 Italgas Capital Market Day
2016 Italgas Capital Market Day2016 Italgas Capital Market Day
2016 Italgas Capital Market DaySnam
 
Veracity Embracing Uncertainty
Veracity Embracing UncertaintyVeracity Embracing Uncertainty
Veracity Embracing UncertaintyGalen Murdock
 
Snam 2016 3Q results
Snam 2016 3Q resultsSnam 2016 3Q results
Snam 2016 3Q resultsSnam
 
2016-2020 Strategy & Targets
2016-2020 Strategy & Targets2016-2020 Strategy & Targets
2016-2020 Strategy & TargetsSnam
 
Snam 2016 Interim Results
Snam 2016 Interim ResultsSnam 2016 Interim Results
Snam 2016 Interim ResultsSnam
 
Snam 2016 1Q results
Snam 2016 1Q resultsSnam 2016 1Q results
Snam 2016 1Q resultsSnam
 
Easy rest service using PHP reflection api
Easy rest service using PHP reflection apiEasy rest service using PHP reflection api
Easy rest service using PHP reflection apiMatthieu Aubry
 
2016 Full-Year Results and Plan Update
2016 Full-Year Results and Plan Update2016 Full-Year Results and Plan Update
2016 Full-Year Results and Plan UpdateSnam
 
Detecting Events on the Web in Real Time with Java, Kafka and ZooKeeper - Jam...
Detecting Events on the Web in Real Time with Java, Kafka and ZooKeeper - Jam...Detecting Events on the Web in Real Time with Java, Kafka and ZooKeeper - Jam...
Detecting Events on the Web in Real Time with Java, Kafka and ZooKeeper - Jam...JAXLondon2014
 
Google Maps API for Android
Google Maps API for AndroidGoogle Maps API for Android
Google Maps API for AndroidMaksim Golivkin
 
Image Optimization for the Web at php|works
Image Optimization for the Web at php|worksImage Optimization for the Web at php|works
Image Optimization for the Web at php|worksStoyan Stefanov
 
Google Maps Presentation
Google Maps PresentationGoogle Maps Presentation
Google Maps PresentationDavid Kamerer
 
Google drive for nonprofits webinar
Google drive for nonprofits webinarGoogle drive for nonprofits webinar
Google drive for nonprofits webinarCraig Grella
 

Viewers also liked (20)

Immediato, sostenibile, efficiente. Il gas naturale per la decarbonizzazione
Immediato, sostenibile, efficiente. Il gas naturale per la decarbonizzazioneImmediato, sostenibile, efficiente. Il gas naturale per la decarbonizzazione
Immediato, sostenibile, efficiente. Il gas naturale per la decarbonizzazione
 
2016 Italgas Capital Market Day
2016 Italgas Capital Market Day2016 Italgas Capital Market Day
2016 Italgas Capital Market Day
 
Veracity Embracing Uncertainty
Veracity Embracing UncertaintyVeracity Embracing Uncertainty
Veracity Embracing Uncertainty
 
Snam 2016 3Q results
Snam 2016 3Q resultsSnam 2016 3Q results
Snam 2016 3Q results
 
2016-2020 Strategy & Targets
2016-2020 Strategy & Targets2016-2020 Strategy & Targets
2016-2020 Strategy & Targets
 
Snam 2016 Interim Results
Snam 2016 Interim ResultsSnam 2016 Interim Results
Snam 2016 Interim Results
 
Snam 2016 1Q results
Snam 2016 1Q resultsSnam 2016 1Q results
Snam 2016 1Q results
 
Easy rest service using PHP reflection api
Easy rest service using PHP reflection apiEasy rest service using PHP reflection api
Easy rest service using PHP reflection api
 
2016 Full-Year Results and Plan Update
2016 Full-Year Results and Plan Update2016 Full-Year Results and Plan Update
2016 Full-Year Results and Plan Update
 
Detecting Events on the Web in Real Time with Java, Kafka and ZooKeeper - Jam...
Detecting Events on the Web in Real Time with Java, Kafka and ZooKeeper - Jam...Detecting Events on the Web in Real Time with Java, Kafka and ZooKeeper - Jam...
Detecting Events on the Web in Real Time with Java, Kafka and ZooKeeper - Jam...
 
Image galley ppt
Image galley pptImage galley ppt
Image galley ppt
 
Google Maps API for Android
Google Maps API for AndroidGoogle Maps API for Android
Google Maps API for Android
 
Image Optimization for the Web at php|works
Image Optimization for the Web at php|worksImage Optimization for the Web at php|works
Image Optimization for the Web at php|works
 
Google Maps
Google MapsGoogle Maps
Google Maps
 
Api presentation
Api presentationApi presentation
Api presentation
 
Google Maps Presentation
Google Maps PresentationGoogle Maps Presentation
Google Maps Presentation
 
Google drive for nonprofits webinar
Google drive for nonprofits webinarGoogle drive for nonprofits webinar
Google drive for nonprofits webinar
 
PHP Project PPT
PHP Project PPTPHP Project PPT
PHP Project PPT
 
Php Presentation
Php PresentationPhp Presentation
Php Presentation
 
Google Maps API 101
Google Maps API 101Google Maps API 101
Google Maps API 101
 

Similar to Integrating Google APIs into Your Applications

Using the Google AJAX APIs
Using the Google AJAX APIsUsing the Google AJAX APIs
Using the Google AJAX APIsChris Schalk
 
Frank Mantek Google G Data
Frank Mantek Google G DataFrank Mantek Google G Data
Frank Mantek Google G Datadeimos
 
Google G Data Reading And Writing Data On The Web
Google G Data Reading And Writing Data On The WebGoogle G Data Reading And Writing Data On The Web
Google G Data Reading And Writing Data On The WebQConLondon2008
 
Google G Data Reading And Writing Data On The Web 1
Google G Data Reading And Writing Data On The Web 1Google G Data Reading And Writing Data On The Web 1
Google G Data Reading And Writing Data On The Web 1QConLondon2008
 
Advanced Gadget And Ui Development Using Googles Ajax Ap Is
Advanced Gadget And Ui Development Using Googles Ajax Ap IsAdvanced Gadget And Ui Development Using Googles Ajax Ap Is
Advanced Gadget And Ui Development Using Googles Ajax Ap IsGoogleTecTalks
 
Gwt training presentation
Gwt training presentationGwt training presentation
Gwt training presentationMUFIX Community
 
Devfest09 App Engine Java
Devfest09  App Engine  JavaDevfest09  App Engine  Java
Devfest09 App Engine JavaChris Schalk
 
Google Opening up to Developers - From 2 to 55 APIs in 3 years
Google Opening up to Developers - From 2 to 55 APIs in 3 yearsGoogle Opening up to Developers - From 2 to 55 APIs in 3 years
Google Opening up to Developers - From 2 to 55 APIs in 3 yearsPatrick Chanezon
 
South America 2008: Open Social For Brand Advertising and Media
South America 2008: Open Social For Brand Advertising and MediaSouth America 2008: Open Social For Brand Advertising and Media
South America 2008: Open Social For Brand Advertising and MediaPatrick Chanezon
 
Open Social Summit Korea Overview
Open Social Summit Korea OverviewOpen Social Summit Korea Overview
Open Social Summit Korea OverviewChris Schalk
 
Introduction to serverless computing on Google Cloud
Introduction to serverless computing on Google CloudIntroduction to serverless computing on Google Cloud
Introduction to serverless computing on Google Cloudwesley chun
 
Google API
Google APIGoogle API
Google APIkueppi
 
Opensocial Haifa Seminar - 2008.04.08
Opensocial Haifa Seminar - 2008.04.08Opensocial Haifa Seminar - 2008.04.08
Opensocial Haifa Seminar - 2008.04.08Ari Leichtberg
 
Exploring Google APIs with Python
Exploring Google APIs with PythonExploring Google APIs with Python
Exploring Google APIs with Pythonwesley chun
 
Review of Google I/O
Review of Google I/OReview of Google I/O
Review of Google I/O Jeffrey Barke
 
Ajaxworld Opensocial Presentation
Ajaxworld Opensocial PresentationAjaxworld Opensocial Presentation
Ajaxworld Opensocial PresentationChris Schalk
 
G Suite & Google APIs coding workshop
G Suite & Google APIs coding workshopG Suite & Google APIs coding workshop
G Suite & Google APIs coding workshopwesley chun
 
Introduction to Google Cloud Platform Technologies
Introduction to Google Cloud Platform TechnologiesIntroduction to Google Cloud Platform Technologies
Introduction to Google Cloud Platform TechnologiesChris Schalk
 
Day1 before getting_started
Day1 before getting_startedDay1 before getting_started
Day1 before getting_startedAhsanul Karim
 
Powerful Google Cloud tools for your hack
Powerful Google Cloud tools for your hackPowerful Google Cloud tools for your hack
Powerful Google Cloud tools for your hackwesley chun
 

Similar to Integrating Google APIs into Your Applications (20)

Using the Google AJAX APIs
Using the Google AJAX APIsUsing the Google AJAX APIs
Using the Google AJAX APIs
 
Frank Mantek Google G Data
Frank Mantek Google G DataFrank Mantek Google G Data
Frank Mantek Google G Data
 
Google G Data Reading And Writing Data On The Web
Google G Data Reading And Writing Data On The WebGoogle G Data Reading And Writing Data On The Web
Google G Data Reading And Writing Data On The Web
 
Google G Data Reading And Writing Data On The Web 1
Google G Data Reading And Writing Data On The Web 1Google G Data Reading And Writing Data On The Web 1
Google G Data Reading And Writing Data On The Web 1
 
Advanced Gadget And Ui Development Using Googles Ajax Ap Is
Advanced Gadget And Ui Development Using Googles Ajax Ap IsAdvanced Gadget And Ui Development Using Googles Ajax Ap Is
Advanced Gadget And Ui Development Using Googles Ajax Ap Is
 
Gwt training presentation
Gwt training presentationGwt training presentation
Gwt training presentation
 
Devfest09 App Engine Java
Devfest09  App Engine  JavaDevfest09  App Engine  Java
Devfest09 App Engine Java
 
Google Opening up to Developers - From 2 to 55 APIs in 3 years
Google Opening up to Developers - From 2 to 55 APIs in 3 yearsGoogle Opening up to Developers - From 2 to 55 APIs in 3 years
Google Opening up to Developers - From 2 to 55 APIs in 3 years
 
South America 2008: Open Social For Brand Advertising and Media
South America 2008: Open Social For Brand Advertising and MediaSouth America 2008: Open Social For Brand Advertising and Media
South America 2008: Open Social For Brand Advertising and Media
 
Open Social Summit Korea Overview
Open Social Summit Korea OverviewOpen Social Summit Korea Overview
Open Social Summit Korea Overview
 
Introduction to serverless computing on Google Cloud
Introduction to serverless computing on Google CloudIntroduction to serverless computing on Google Cloud
Introduction to serverless computing on Google Cloud
 
Google API
Google APIGoogle API
Google API
 
Opensocial Haifa Seminar - 2008.04.08
Opensocial Haifa Seminar - 2008.04.08Opensocial Haifa Seminar - 2008.04.08
Opensocial Haifa Seminar - 2008.04.08
 
Exploring Google APIs with Python
Exploring Google APIs with PythonExploring Google APIs with Python
Exploring Google APIs with Python
 
Review of Google I/O
Review of Google I/OReview of Google I/O
Review of Google I/O
 
Ajaxworld Opensocial Presentation
Ajaxworld Opensocial PresentationAjaxworld Opensocial Presentation
Ajaxworld Opensocial Presentation
 
G Suite & Google APIs coding workshop
G Suite & Google APIs coding workshopG Suite & Google APIs coding workshop
G Suite & Google APIs coding workshop
 
Introduction to Google Cloud Platform Technologies
Introduction to Google Cloud Platform TechnologiesIntroduction to Google Cloud Platform Technologies
Introduction to Google Cloud Platform Technologies
 
Day1 before getting_started
Day1 before getting_startedDay1 before getting_started
Day1 before getting_started
 
Powerful Google Cloud tools for your hack
Powerful Google Cloud tools for your hackPowerful Google Cloud tools for your hack
Powerful Google Cloud tools for your hack
 

More from Chris Schalk

Google App Engine Overview and Update
Google App Engine Overview and UpdateGoogle App Engine Overview and Update
Google App Engine Overview and UpdateChris Schalk
 
Building Integrated Applications on Google's Cloud Technologies
Building Integrated Applications on Google's Cloud TechnologiesBuilding Integrated Applications on Google's Cloud Technologies
Building Integrated Applications on Google's Cloud TechnologiesChris Schalk
 
How to build Kick Ass Games in the Cloud
How to build Kick Ass Games in the CloudHow to build Kick Ass Games in the Cloud
How to build Kick Ass Games in the CloudChris Schalk
 
Building Kick Ass Video Games for the Cloud
Building Kick Ass Video Games for the CloudBuilding Kick Ass Video Games for the Cloud
Building Kick Ass Video Games for the CloudChris Schalk
 
Building Integrated Applications on Google's Cloud Technologies
Building Integrated Applications on Google's Cloud TechnologiesBuilding Integrated Applications on Google's Cloud Technologies
Building Integrated Applications on Google's Cloud TechnologiesChris Schalk
 
GDD 2011 - How to build kick ass video games for the cloud
GDD 2011 - How to build kick ass video games for the cloudGDD 2011 - How to build kick ass video games for the cloud
GDD 2011 - How to build kick ass video games for the cloudChris Schalk
 
Quick Intro to Google Cloud Technologies
Quick Intro to Google Cloud TechnologiesQuick Intro to Google Cloud Technologies
Quick Intro to Google Cloud TechnologiesChris Schalk
 
Intro to Google's Cloud Technologies
Intro to Google's Cloud TechnologiesIntro to Google's Cloud Technologies
Intro to Google's Cloud TechnologiesChris Schalk
 
Introduction to Google's Cloud Technologies
Introduction to Google's Cloud TechnologiesIntroduction to Google's Cloud Technologies
Introduction to Google's Cloud TechnologiesChris Schalk
 
Google App Engine's Latest Features
Google App Engine's Latest FeaturesGoogle App Engine's Latest Features
Google App Engine's Latest FeaturesChris Schalk
 
Building Apps on Google Cloud Technologies
Building Apps on Google Cloud TechnologiesBuilding Apps on Google Cloud Technologies
Building Apps on Google Cloud TechnologiesChris Schalk
 
Google App Engine's Latest Features
Google App Engine's Latest FeaturesGoogle App Engine's Latest Features
Google App Engine's Latest FeaturesChris Schalk
 
Building Multi-platform Video Games for the Cloud
Building Multi-platform Video Games for the CloudBuilding Multi-platform Video Games for the Cloud
Building Multi-platform Video Games for the CloudChris Schalk
 
Building Enterprise Applications on Google Cloud Platform Cloud Computing Exp...
Building Enterprise Applications on Google Cloud Platform Cloud Computing Exp...Building Enterprise Applications on Google Cloud Platform Cloud Computing Exp...
Building Enterprise Applications on Google Cloud Platform Cloud Computing Exp...Chris Schalk
 
Introduction to Google's Cloud Technologies
Introduction to Google's Cloud TechnologiesIntroduction to Google's Cloud Technologies
Introduction to Google's Cloud TechnologiesChris Schalk
 
Javaedge 2010-cschalk
Javaedge 2010-cschalkJavaedge 2010-cschalk
Javaedge 2010-cschalkChris Schalk
 
Google Cloud Technologies Overview
Google Cloud Technologies OverviewGoogle Cloud Technologies Overview
Google Cloud Technologies OverviewChris Schalk
 
Introducing App Engine for Business
Introducing App Engine for BusinessIntroducing App Engine for Business
Introducing App Engine for BusinessChris Schalk
 
Introduction to Google Cloud platform technologies
Introduction to Google Cloud platform technologiesIntroduction to Google Cloud platform technologies
Introduction to Google Cloud platform technologiesChris Schalk
 
Google App Engine for Business 101
Google App Engine for Business 101Google App Engine for Business 101
Google App Engine for Business 101Chris Schalk
 

More from Chris Schalk (20)

Google App Engine Overview and Update
Google App Engine Overview and UpdateGoogle App Engine Overview and Update
Google App Engine Overview and Update
 
Building Integrated Applications on Google's Cloud Technologies
Building Integrated Applications on Google's Cloud TechnologiesBuilding Integrated Applications on Google's Cloud Technologies
Building Integrated Applications on Google's Cloud Technologies
 
How to build Kick Ass Games in the Cloud
How to build Kick Ass Games in the CloudHow to build Kick Ass Games in the Cloud
How to build Kick Ass Games in the Cloud
 
Building Kick Ass Video Games for the Cloud
Building Kick Ass Video Games for the CloudBuilding Kick Ass Video Games for the Cloud
Building Kick Ass Video Games for the Cloud
 
Building Integrated Applications on Google's Cloud Technologies
Building Integrated Applications on Google's Cloud TechnologiesBuilding Integrated Applications on Google's Cloud Technologies
Building Integrated Applications on Google's Cloud Technologies
 
GDD 2011 - How to build kick ass video games for the cloud
GDD 2011 - How to build kick ass video games for the cloudGDD 2011 - How to build kick ass video games for the cloud
GDD 2011 - How to build kick ass video games for the cloud
 
Quick Intro to Google Cloud Technologies
Quick Intro to Google Cloud TechnologiesQuick Intro to Google Cloud Technologies
Quick Intro to Google Cloud Technologies
 
Intro to Google's Cloud Technologies
Intro to Google's Cloud TechnologiesIntro to Google's Cloud Technologies
Intro to Google's Cloud Technologies
 
Introduction to Google's Cloud Technologies
Introduction to Google's Cloud TechnologiesIntroduction to Google's Cloud Technologies
Introduction to Google's Cloud Technologies
 
Google App Engine's Latest Features
Google App Engine's Latest FeaturesGoogle App Engine's Latest Features
Google App Engine's Latest Features
 
Building Apps on Google Cloud Technologies
Building Apps on Google Cloud TechnologiesBuilding Apps on Google Cloud Technologies
Building Apps on Google Cloud Technologies
 
Google App Engine's Latest Features
Google App Engine's Latest FeaturesGoogle App Engine's Latest Features
Google App Engine's Latest Features
 
Building Multi-platform Video Games for the Cloud
Building Multi-platform Video Games for the CloudBuilding Multi-platform Video Games for the Cloud
Building Multi-platform Video Games for the Cloud
 
Building Enterprise Applications on Google Cloud Platform Cloud Computing Exp...
Building Enterprise Applications on Google Cloud Platform Cloud Computing Exp...Building Enterprise Applications on Google Cloud Platform Cloud Computing Exp...
Building Enterprise Applications on Google Cloud Platform Cloud Computing Exp...
 
Introduction to Google's Cloud Technologies
Introduction to Google's Cloud TechnologiesIntroduction to Google's Cloud Technologies
Introduction to Google's Cloud Technologies
 
Javaedge 2010-cschalk
Javaedge 2010-cschalkJavaedge 2010-cschalk
Javaedge 2010-cschalk
 
Google Cloud Technologies Overview
Google Cloud Technologies OverviewGoogle Cloud Technologies Overview
Google Cloud Technologies Overview
 
Introducing App Engine for Business
Introducing App Engine for BusinessIntroducing App Engine for Business
Introducing App Engine for Business
 
Introduction to Google Cloud platform technologies
Introduction to Google Cloud platform technologiesIntroduction to Google Cloud platform technologies
Introduction to Google Cloud platform technologies
 
Google App Engine for Business 101
Google App Engine for Business 101Google App Engine for Business 101
Google App Engine for Business 101
 

Recently uploaded

Server-Driven User Interface (SDUI) at Priceline
Server-Driven User Interface (SDUI) at PricelineServer-Driven User Interface (SDUI) at Priceline
Server-Driven User Interface (SDUI) at PricelineUXDXConf
 
ODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupCatarinaPereira64715
 
IoT Analytics Company Presentation May 2024
IoT Analytics Company Presentation May 2024IoT Analytics Company Presentation May 2024
IoT Analytics Company Presentation May 2024IoTAnalytics
 
Enterprise Security Monitoring, And Log Management.
Enterprise Security Monitoring, And Log Management.Enterprise Security Monitoring, And Log Management.
Enterprise Security Monitoring, And Log Management.Boni Yeamin
 
Designing for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastDesigning for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastUXDXConf
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonDianaGray10
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomCzechDreamin
 
AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101vincent683379
 
ECS 2024 Teams Premium - Pretty Secure
ECS 2024   Teams Premium - Pretty SecureECS 2024   Teams Premium - Pretty Secure
ECS 2024 Teams Premium - Pretty SecureFemke de Vroome
 
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya HalderCustom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya HalderCzechDreamin
 
UiPath Test Automation using UiPath Test Suite series, part 2
UiPath Test Automation using UiPath Test Suite series, part 2UiPath Test Automation using UiPath Test Suite series, part 2
UiPath Test Automation using UiPath Test Suite series, part 2DianaGray10
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekCzechDreamin
 
Connecting the Dots in Product Design at KAYAK
Connecting the Dots in Product Design at KAYAKConnecting the Dots in Product Design at KAYAK
Connecting the Dots in Product Design at KAYAKUXDXConf
 
Agentic RAG What it is its types applications and implementation.pdf
Agentic RAG What it is its types applications and implementation.pdfAgentic RAG What it is its types applications and implementation.pdf
Agentic RAG What it is its types applications and implementation.pdfChristopherTHyatt
 
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxAbida Shariff
 
"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor TurskyiFwdays
 
PLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsPLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsStefano
 
Strategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering TeamsStrategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering TeamsUXDXConf
 
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Jeffrey Haguewood
 
Transforming The New York Times: Empowering Evolution through UX
Transforming The New York Times: Empowering Evolution through UXTransforming The New York Times: Empowering Evolution through UX
Transforming The New York Times: Empowering Evolution through UXUXDXConf
 

Recently uploaded (20)

Server-Driven User Interface (SDUI) at Priceline
Server-Driven User Interface (SDUI) at PricelineServer-Driven User Interface (SDUI) at Priceline
Server-Driven User Interface (SDUI) at Priceline
 
ODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User Group
 
IoT Analytics Company Presentation May 2024
IoT Analytics Company Presentation May 2024IoT Analytics Company Presentation May 2024
IoT Analytics Company Presentation May 2024
 
Enterprise Security Monitoring, And Log Management.
Enterprise Security Monitoring, And Log Management.Enterprise Security Monitoring, And Log Management.
Enterprise Security Monitoring, And Log Management.
 
Designing for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastDesigning for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at Comcast
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
 
AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101
 
ECS 2024 Teams Premium - Pretty Secure
ECS 2024   Teams Premium - Pretty SecureECS 2024   Teams Premium - Pretty Secure
ECS 2024 Teams Premium - Pretty Secure
 
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya HalderCustom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
 
UiPath Test Automation using UiPath Test Suite series, part 2
UiPath Test Automation using UiPath Test Suite series, part 2UiPath Test Automation using UiPath Test Suite series, part 2
UiPath Test Automation using UiPath Test Suite series, part 2
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří Karpíšek
 
Connecting the Dots in Product Design at KAYAK
Connecting the Dots in Product Design at KAYAKConnecting the Dots in Product Design at KAYAK
Connecting the Dots in Product Design at KAYAK
 
Agentic RAG What it is its types applications and implementation.pdf
Agentic RAG What it is its types applications and implementation.pdfAgentic RAG What it is its types applications and implementation.pdf
Agentic RAG What it is its types applications and implementation.pdf
 
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
 
"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi
 
PLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsPLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. Startups
 
Strategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering TeamsStrategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering Teams
 
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
 
Transforming The New York Times: Empowering Evolution through UX
Transforming The New York Times: Empowering Evolution through UXTransforming The New York Times: Empowering Evolution through UX
Transforming The New York Times: Empowering Evolution through UX
 

Integrating Google APIs into Your Applications

  • 1. Integrating Google APIs into your Applications Chris Schalk Google Developer Advocate 9/23/2008
  • 2. Agenda • Client Side APIs – Maps API – AJAX APIs • Search, Feed, Translation • Google Server-side APIs – Google Data – Calendar, Blogger, YouTube... – Demo with JSF • OpenSocial/Gadgets – How to build gadgets – OpenSocial - What is it?? – How to host OpenSocial gadgets 2 (c)2008 Google
  • 3. Agenda • Client Side APIs – Maps API – AJAX APIs • Search, Feed, Translation • Google Server-side APIs – Google Data – Calendar, Blogger, YouTube... – Demo with JSF • OpenSocial/Gadgets – How to build gadgets – OpenSocial - What is it?? – How to host OpenSocial gadgets 3 (c)2008 Google
  • 4. Google Maps API • JavaScript Client API • Build a Customized Maps application • Easy to mashup with other technologies • Also works with Flash • Can generate static Maps images via REST 4 (c)2008 Google
  • 5. Google AJAX APIs Delivering the Web to Your Applications (Search, Feeds, Language) • RESTful data access layer – JSON/JSON-P AJAX APIs • JavaScript Runtime – Designed for ease of use • JavaScript Controls and UI elements – Custom integration and styling (c)2008 Google
  • 6. Google AJAX APIs Background • Comprehensive access to Google Systems (Search, Feeds, Language) • End to end API stack: • Data Access via JavaScript Methods and REST • Built in Native UI and Large Suite of Advanced Controls • Large, diverse customer base • Sites: Long Tail and Short Tail Sites (100 pv/d – 10m+ pv/d) • Developers: Pro Web Developers – Scripters – Bloggers • High Speed, Low Latency, Globally Available JavaScript Controls and UI elements JavaScript Runtime Layer AJAX RESTful Data Access Layer APIs
  • 7. Google AJAX Search API • Web • Video • News • Image • Local • Book • Blog (c)2008 Google
  • 8. Google AJAX Feed API • Load • Find • Lookup (c)2008 Google
  • 9. Google AJAX Language API • Translation • Language Detection (c)2008 Google
  • 10. Demo - Trying out some of the AJAX APIs
  • 11. Some notable AJAX APIs Applications Time - AJAX Search API (news) http://www.time.com/time/politics http://www.time.com/time/global_business/united-states NYTimes - AJAX Feed API http://thecaucus.blogs.nytimes.com People - AJAX Feed API + gadgets http://www.people.com/people/news/0,,,00.html http://www.google.com/uds/gadgets/people_ads/people_ads.html SnowCovered - AJAX Language API http://www.snowcovered.com/Snowcovered2/ Walkscore - AJAX Search API (local) + Maps API http://www.walkscore.com/get-score.php?street=1600+amphitheatre+parkway+94043&go=Go http://www.walkscore.com/rankings/San_Francisco Google Elections apps: http://www.google.com/2008election/ http://www.google.com/2008election/convention.html Background: http://www.searchmashups.blogspot.com/ (c)2008 Google
  • 12. Agenda • Client Side APIs – Maps API – AJAX APIs • Search, Feed, Translation • Google Server-side APIs – Google Data – Calendar, Blogger, YouTube... – Demo with JSF • OpenSocial/Gadgets – How to build gadgets – OpenSocial - What is it?? – How to host OpenSocial gadgets 12 (c)2008 Google
  • 13. ServerSide Google APIs Overview • Google Data APIs – Common set of APIs for working with multiple online Google technologies – Google Apps APIs, Base Data API, Data API, Calendar Data API, Code Search Data API, Contacts Data API, Finance Portfolio Data API, Health Data API, Notebook Data API, Spreadsheets Data API, Picasa Web Albums Data API, Google Documents List Data API, Webmaster Tools Data API, YouTube Data API – Support for multiple languages • Python • PHP • .Net • Java • JavaScript 13 (c)2008 Google
  • 14. Google Data APIs Overview • Google Data APIs, aka “Gdata”, is a protocol based on the Atom 1.0 and RSS 2.0 syndication formats, plus the Atom Publishing Protocol • “Gdata” extends those standards in various ways, using the extension mechanisms built into the standards. A GData feed conforms to either the Atom or RSS syndication formats. The GData publishing model conforms to the Atom Publishing Protocol. • To acquire information from a service that supports GData, you send an HTTP GET request; the service returns results as an Atom or RSS feed. • You can update data (where supported by a particular GData service) by sending an HTTP PUT request. • GData provides a general model for feeds, queries, and results. You can use it to send queries and updates to any service that has a GData interface. 14 (c)2008 Google
  • 15. ServerSide Google APIs Overview • Other server-side Google APIs… • Google Chart API Also other restful services, AJAX apis, OpenSocial RESTful API 15 (c)2008 Google
  • 16. Working with the Data APIs in Java • Getting the Gdata Jar files • Running the sample app • Add Jars to your IDE • That’s it! 16 (c)2008 Google
  • 17. Some basic data operations w/ Calendar API • Querying all of your calendars • Querying the events in all of your calendars • Querying specific events based on a text string • Querying events based on a date range • Creating new calendar events • Deleting/Updating calendar events 17 (c)2008 Google
  • 18. Using the Calendar Data API with JSF 18 (c)2008 Google
  • 19. Using the Calendar Data API with JSF Basic Architecture CalendarServices Managed Bean 19 (c)2008 Google
  • 20. Introducing the Google Charts API • Simple REST based dynamic chart generator • Offers the creation of on-the-fly charts of multiple types – http://chart.apis.google.com/chart?cht=p3&chd=t:60,40&chs=25 0x100&chl=Hello|World 20 (c)2008 Google
  • 21. The JSF Custom Chart Component 21 (c)2008 Google
  • 22. Google data APIs/ RESTful services summary • The Google Data APIs offer full online data access to multiple Google Services • Gdata supports multiple client languages • Other simple, RESTful, online services also offered by Google • Charts API, AJAX APIs… • Relatively straightforward to integrate with server-side Java / JSF 22 (c)2008 Google
  • 23. More info… • http://code.google.com • http://code.google.com/apis/gdata/ • http://code.google.com/apis/chart 23 (c)2008 Google
  • 24. Agenda • Client Side APIs – Maps API – AJAX APIs • Search, Feed, Translation • Google Server-side APIs – Google Data – Calendar, Blogger, YouTube... – Demo with JSF • OpenSocial/Gadgets – How to build gadgets – OpenSocial - What is it?? – How to host OpenSocial gadgets 24 (c)2008 Google
  • 25. Building Gadgets • It’s just JavaScript embedded in an XML file! • Runs within a “container” environment – iGoogle – Other environments coming online through OpenSocial • Gadget’s relation to OpenSocial – Gadgets serve as the base architecture for OpenSocial applications 25 (c)2008 Google
  • 29. Standards based OpenSocial Write once… Deploy everywhere 29
  • 30. Use multiple times Cooooool! 30
  • 31. Not just Social Network Sites • Social network sites - Profiles and home pages ex: MySpace, Hi5 • Personal dashboards – Widgets ex: iGoogle, My Yahoo • Sites based around a Social Object ex: Flickr, YouTube • Enterprise systems ex: Oracle, SalesForce.com • Any web site 31
  • 32. OpenSocial Roadmap • Version 0.5 was released in a “developer release” on Nov 1st. • First “sandbox” was made available on Orkut • Version 0.6 was released in December • Initial version of Shindig server software was launched as Apache incubator project • Other sandboxes came live - Hi5, Ning, Plaxo … • Version 0.7 (production) was released in January • MySpace, Hi5, Orkut currently running with 0.7 32
  • 33. OpenSocial v0.8 is here! • Latest evolution of OpenSocial as defined by the OpenSocial development community • Updated JavaScript API • Now contains a RESTful API • Shindig supports v0.8 today • iGoogle now supports 0.8! • hi5 almost done with their support • orkut currently working on their implementation • Other containers also working on 0.8 • Specification is here: http://www.opensocial.org/Technical-Resources/opensocial-spec-v08 33
  • 34. OpenSocial Hi-level Details • A set of open, standard APIs for building social applications • APIs based on Web standards: HTML/CSS, JavaScript, REST+OAuth • Reference Implementation: Shindig • Apache Open Source Project • A global community of thousands of developers 34
  • 35. OpenSocial Core Services • People & Friends • Access friends information programmatically • Activities • See what you’re friends are up to • Share what you are doing • Persistence • Provide state without a server • Share data with your friends 35
  • 36. OpenSocial Client APIs • JavaScript API - for browser based client development • Standard Web development technologies • HTML + Javascript, CSS, AJAX • Can integrate with 3rd party servers • PHP, Perl, Java, C/C++ • RESTful API - for server based client development • Based on Atom publishing protocol • Data transfer is Atom or JSON • More on RESTful API later… 36
  • 37. Building JavaScript OpenSocial Applications • If you know how to develop gadgets, you know how to develop JavaScript OpenSocial applications! • Follows same approach as gadgets • JavaScript/HTML/CSS embedded in an XML document • XML document containing gadget is hosted on the Internet • OpenSocial applications are “gadgets++” • Gadgets development, but with additional Social capabilities 37
  • 38. OpenSocial People & Friends Example An OpenSocial example to show the owner’s friends function getFriends(id) { var params = {}; params[opensocial.IdSpec.Field.USER_ID] = opensocial.IdSpec.PersonId.OWNER; params[opensocial.IdSpec.Field.GROUP_ID] = quot;FRIENDSquot;; var idspec = opensocial.newIdSpec(params); var req = opensocial.newDataRequest(); req.add(req.newFetchPeopleRequest(idspec), quot;reqquot;); req.send(onLoadFriends); }; 38
  • 39. OpenSocial People & Friends Example An OpenSocial example to show the owner’s friends var html= quot;Listing friends:<br/>quot;; function printPerson(person) { html += quot;<br/>quot; + person.getDisplayName(); }; function onLoadFriends(dataResponse) { dataResponse.get(quot;reqquot;).getData().each(printPerson); document.getElementById('message').innerHTML = html; }; 39
  • 40. Activities Example Posting an Activity function postActivity(text) {    var params = {};    params[opensocial.Activity.Field.TITLE] = text;    var activity = opensocial.newActivity(params);    opensocial.requestCreateActivity(activity,      opensocial.CreateActivityPriority.HIGH, callback); } postActivity(quot;This is a sample activity, created at quot; +   new Date().toString()) } 40
  • 41. Persistence Example Storing persisted data function populateMyAppData() {   var req = opensocial.newDataRequest();   var data1 = Math.random() * 5;   var data2 = Math.random() * 100;   req.add(req.newUpdatePersonAppDataRequest(quot;VIEWERquot;,                        quot;AppField1quot;, data1));   req.add(req.newUpdatePersonAppDataRequest(quot;VIEWERquot;,                        quot;AppField2quot;, data2));   req.send(requestMyData); } 41
  • 42. Persistence Example Fetching persisted data function requestMyData() {   var req = opensocial.newDataRequest();   var fields = [quot;AppField1quot;, quot;AppField2quot;];   req.add(req.newFetchPersonRequest(     opensocial.DataRequest.PersonId.VIEWER), quot;viewerquot;);   req.add(req.newFetchPersonAppDataRequest(quot;VIEWERquot;,     fields), quot;viewer_dataquot;);   req.send(handleReturnedData); } 42
  • 43. OpenSocial JavaScript client application in action Gadget using JavaScript Client API communicates with OpenSocial server OpenSocial JSON Server Gadget XML Source browser 43
  • 44. Integrating OpenSocial applications with external servers The OpenSocial persistence service provides a way to store/share small amounts of data on the OpenSocial server, but… • What if you need to store more data than your container allows? • Solution: You can make independent requests out to external servers. • Use: gadgets.io.makeRequest • Can also make authenticated requests using Oauth • Can use cloud services from: Joyent, Amazon or AppEngine! 44
  • 45. Integrating OpenSocial applications with external servers An example request to an external server gadgets.io.makeRequest OpenSocial Server External 1 2 Server browser 1. Initial request made from gadget 2. Server routes request to external server Requests can be secured using OAuth! 45
  • 46. Demonstration • Building OpenSocial Client Applications 46
  • 47. How to host OpenSocial Applications 1. Can build your own server that implements OpenSocial specification… 2. Or can use “Shindig” - Reference implementation for OpenSocial • Gadget Server –Renders gadget XML as HTML/JS/CSS • OpenSocial Data Server –RESTful API server (in-progress) 47
  • 48. Serverside OpenSocial How to implement an OpenSocial server Shindig orkut, hi5, iGoogle, tianya.cn, … • Gadget Server –Renders gadget XML as HTML/JS/CSS • OpenSocial Data Server –RESTful API server • Gadget Container JavaScript –Core gadgets JavaScript environment 48
  • 49. How Shindig works • Gadget Server • OpenSocial Data Server Shindig Yoursite.com Gadget Gadget Server OpenSocial DataServer 49 49
  • 50. Why use Shindig? • Strong open source community • High quality production-ready code • Update easily as OpenSocial evolves • Fully compliant with OpenSocial v0.7, v0.8 • Shindig is language neutral (Java, PHP) 50
  • 51. Shindig success at hi5 • Big Traffic • 10k req/sec Edge • 6k req/sec Origin • Hundreds of Developers • 1800+ Apps • 1 Billion hits/day … on 42 Shindig servers 51 51
  • 53. Thank You! http://chrisschalk.com 53 (c)2008 Google