SlideShare a Scribd company logo
1 of 12
Download to read offline
Google+ API
#GDG #DevFestJkt #DevFest #2012
Oon Arfiandwi <oon@7langit.com>
Manager of Google Developer Group Jakarta
http://gplus.to/oonid
so, what can be covered
in 35 mins?
Google+ API in general
OAuth2.0 + REST API
Sign in with Google+, get to know about
People, Activities & Comments
Let’s code in Android + Google Play Services
Google+ History
Google+ API
http://developers.google.com/+
Plugins for your website + REST API
Mobile Platform (Android, iOS, mobile web)
Hangout API
History API (developer preview)
OAuth 2.0
Generate OAuth 2.0 Token
via Google Play Services
GoogleAuthUtil.getToken()
via Google APIs Client Library for Java
create API Project with Google APIs Console
open browser to URL from GoogleAuthorizationCodeRequestURL
get Token via execute GoogleAuthorizationCodeTokenRequest
Activate Service:
Google+ API
Google+ History API
Create:
OAuth 2.0 client ID
Google APIs Console
String googleAuthorizationCodeRequestUrl = new GoogleAuthorizationCodeRequestUrl(
	 	 ShrdPrfsStore.CLIENT_ID,ShrdPrfsStore.REDIRECT_URI,ShrdPrfsStore.SCOPE).build();
	
	webview.setWebViewClient(new WebViewClient() {
		 @Override
		 public void onPageFinished(WebView view, String url) {
		 	 if (url.startsWith(SharedPrefsStore.REDIRECT_URI)) {
	 	 	 	 try {
	 	 	 	 	 if (url.indexOf("code=") != -1) {
	 	 	 	 	 	 // Url is like http://localhost/?code=4/Z5DgC1IxNL-muPsrE2Sjy9zQn2pF
	 	 	 	 	 	 String code = url.substring...
	 	 	 	 	 	 TokenResponse accessTokenResponse =
new GoogleAuthorizationCodeTokenRequest(
	 	 	 	 	 	 	 new NetHttpTransport(), new JacksonFactory(),
	 	 	 	 	 	 	 ShrdPrfsStore.CLIENT_ID, ShrdPrfsStore.CLIENT_SECRET,
	 	 	 	 	 	 	 code, ShrdPrfsStore.REDIRECT_URI).execute();
	 	 	 	 	 	 ...
	 	 	 	 	 	 credentialStore.write(accessTokenResponse);
	 	 	 	 	 	 ...
	 	 	 	 	 }
	 	 	 	 } catch (IOException e) {}
	 	 	 }
		 };
	});
	webview.loadUrl(googleAuthorizationCodeRequestUrl);
OAuth 2.0 login with
Google+ Account
Registered Product Name:
DevFestJktPro
SCOPE:
plus.me
plus.moment.write
“Public”
A
ctivities
Access Google+ Activities
using OAuth access token
as GoogleCredential
Filter the Google+
Activities by user and
collections (eg: “public”)
Create Simple ListView
based on Google+ Activity
Titles
Google+ History API
http://developers.google.com/+/history/preview/
“Google+ history is a collection of moments that
describe activities the user has engaged across the web
and apps.”
Google+ history API privately save moments, users can
share those moments with others.
Moments in History
Types of Moments
AddActivity
BuyActivity
CheckInActivity
ListenActivity
ReviewActivity ...
Moments target URL
must include
attribute from
schema.org markup
Request new type of
Moments?
G
oogle+
H
istory
Google+ History preview
user interface, available for
registered developer
History of CheckInActivity
History of AddActivity (+1)
Google+ API
The end
or is it the beginning?
(quote from G+ History)
Questions?

More Related Content

What's hot

Firebase Basics - Dialog Demo for Group Tech Staff
Firebase Basics - Dialog Demo for Group Tech StaffFirebase Basics - Dialog Demo for Group Tech Staff
Firebase Basics - Dialog Demo for Group Tech StaffTharaka Devinda
 
Intro firebase
Intro firebaseIntro firebase
Intro firebaseMandy Pao
 
Android Jetpack
Android Jetpack Android Jetpack
Android Jetpack Tudor Sirbu
 
Introduction to AngularJS Framework
Introduction to AngularJS FrameworkIntroduction to AngularJS Framework
Introduction to AngularJS FrameworkRaveendra R
 
Phonegap for Android
Phonegap for AndroidPhonegap for Android
Phonegap for AndroidMuthu Kumar
 
Industrial Training in PhoneGap Application
Industrial Training in PhoneGap ApplicationIndustrial Training in PhoneGap Application
Industrial Training in PhoneGap ApplicationArcadian Learning
 
Timings API: Performance Assertion during the functional testing
 Timings API: Performance Assertion during the functional testing Timings API: Performance Assertion during the functional testing
Timings API: Performance Assertion during the functional testingPetrosPlakogiannis
 
Dicoding Developer Coaching #21: Android | Cara Membuat Widget di Aplikasi An...
Dicoding Developer Coaching #21: Android | Cara Membuat Widget di Aplikasi An...Dicoding Developer Coaching #21: Android | Cara Membuat Widget di Aplikasi An...
Dicoding Developer Coaching #21: Android | Cara Membuat Widget di Aplikasi An...DicodingEvent
 
SgCodeJam24 Workshop
SgCodeJam24 WorkshopSgCodeJam24 Workshop
SgCodeJam24 Workshopremko caprio
 
Dicoding Developer Coaching #34: Android | Modular Android App dengan Dynamic...
Dicoding Developer Coaching #34: Android | Modular Android App dengan Dynamic...Dicoding Developer Coaching #34: Android | Modular Android App dengan Dynamic...
Dicoding Developer Coaching #34: Android | Modular Android App dengan Dynamic...DicodingEvent
 
Node.js Crash Course (Jump Start)
Node.js Crash Course (Jump Start) Node.js Crash Course (Jump Start)
Node.js Crash Course (Jump Start) Haim Michael
 
The Glass Class - Tutorial 2 - Mirror API
The Glass Class - Tutorial 2 - Mirror APIThe Glass Class - Tutorial 2 - Mirror API
The Glass Class - Tutorial 2 - Mirror APIGun Lee
 
Hybrid App using WordPress
Hybrid App using WordPressHybrid App using WordPress
Hybrid App using WordPressHaim Michael
 

What's hot (20)

Firebase Basics - Dialog Demo for Group Tech Staff
Firebase Basics - Dialog Demo for Group Tech StaffFirebase Basics - Dialog Demo for Group Tech Staff
Firebase Basics - Dialog Demo for Group Tech Staff
 
Js frameworks
Js frameworksJs frameworks
Js frameworks
 
Intro firebase
Intro firebaseIntro firebase
Intro firebase
 
Android Jetpack
Android Jetpack Android Jetpack
Android Jetpack
 
Introduction to AngularJS Framework
Introduction to AngularJS FrameworkIntroduction to AngularJS Framework
Introduction to AngularJS Framework
 
Introducing Firebase by Google
Introducing Firebase by GoogleIntroducing Firebase by Google
Introducing Firebase by Google
 
Google Cloud Enpoints
Google Cloud EnpointsGoogle Cloud Enpoints
Google Cloud Enpoints
 
Phonegap for Android
Phonegap for AndroidPhonegap for Android
Phonegap for Android
 
Industrial Training in PhoneGap Application
Industrial Training in PhoneGap ApplicationIndustrial Training in PhoneGap Application
Industrial Training in PhoneGap Application
 
iOS App Using cordova
iOS App Using cordovaiOS App Using cordova
iOS App Using cordova
 
React Native
React NativeReact Native
React Native
 
Timings API: Performance Assertion during the functional testing
 Timings API: Performance Assertion during the functional testing Timings API: Performance Assertion during the functional testing
Timings API: Performance Assertion during the functional testing
 
Dicoding Developer Coaching #21: Android | Cara Membuat Widget di Aplikasi An...
Dicoding Developer Coaching #21: Android | Cara Membuat Widget di Aplikasi An...Dicoding Developer Coaching #21: Android | Cara Membuat Widget di Aplikasi An...
Dicoding Developer Coaching #21: Android | Cara Membuat Widget di Aplikasi An...
 
SgCodeJam24 Workshop
SgCodeJam24 WorkshopSgCodeJam24 Workshop
SgCodeJam24 Workshop
 
Dicoding Developer Coaching #34: Android | Modular Android App dengan Dynamic...
Dicoding Developer Coaching #34: Android | Modular Android App dengan Dynamic...Dicoding Developer Coaching #34: Android | Modular Android App dengan Dynamic...
Dicoding Developer Coaching #34: Android | Modular Android App dengan Dynamic...
 
Node.js Crash Course (Jump Start)
Node.js Crash Course (Jump Start) Node.js Crash Course (Jump Start)
Node.js Crash Course (Jump Start)
 
Meteor Introduction - Ashish
Meteor Introduction - AshishMeteor Introduction - Ashish
Meteor Introduction - Ashish
 
The Glass Class - Tutorial 2 - Mirror API
The Glass Class - Tutorial 2 - Mirror APIThe Glass Class - Tutorial 2 - Mirror API
The Glass Class - Tutorial 2 - Mirror API
 
Android CI and Appium
Android CI and AppiumAndroid CI and Appium
Android CI and Appium
 
Hybrid App using WordPress
Hybrid App using WordPressHybrid App using WordPress
Hybrid App using WordPress
 

Similar to Google+ API (2012)

The Big Picture and How to Get Started
The Big Picture and How to Get StartedThe Big Picture and How to Get Started
The Big Picture and How to Get Startedguest1af57e
 
Introduction to Web APIs and the Google+ API - BarCamp Phnom Penh 2011
Introduction to Web APIs and the Google+ API - BarCamp Phnom Penh 2011Introduction to Web APIs and the Google+ API - BarCamp Phnom Penh 2011
Introduction to Web APIs and the Google+ API - BarCamp Phnom Penh 2011traactivity
 
google drive and the google drive sdk
google drive and the google drive sdkgoogle drive and the google drive sdk
google drive and the google drive sdkfirenze-gtug
 
Power your apps with Gmail, Google Drive, Calendar, Sheets, Slides & more
Power your apps with Gmail, Google Drive, Calendar, Sheets, Slides & morePower your apps with Gmail, Google Drive, Calendar, Sheets, Slides & more
Power your apps with Gmail, Google Drive, Calendar, Sheets, Slides & morewesley chun
 
Exploring Google (Cloud) APIs with Python & JavaScript
Exploring Google (Cloud) APIs with Python & JavaScriptExploring Google (Cloud) APIs with Python & JavaScript
Exploring Google (Cloud) APIs with Python & JavaScriptwesley chun
 
Android dev toolbox
Android dev toolboxAndroid dev toolbox
Android dev toolboxShem Magnezi
 
Mobile 2.0 Open Ideas WorkShop: Building Social Media Enabled Apps on Android
Mobile 2.0 Open Ideas WorkShop: Building Social Media Enabled Apps on AndroidMobile 2.0 Open Ideas WorkShop: Building Social Media Enabled Apps on Android
Mobile 2.0 Open Ideas WorkShop: Building Social Media Enabled Apps on AndroidAlberto Ruibal
 
Getting started using Google APIs (2019)
Getting started using Google APIs (2019)Getting started using Google APIs (2019)
Getting started using Google APIs (2019)wesley chun
 
Google Integration in Android Apps - Mooscon 2013 Cebit
Google Integration in Android Apps - Mooscon 2013 CebitGoogle Integration in Android Apps - Mooscon 2013 Cebit
Google Integration in Android Apps - Mooscon 2013 CebitFriedger Müffke
 
Open Hack NYC Yahoo Social SDKs
Open Hack NYC Yahoo Social SDKsOpen Hack NYC Yahoo Social SDKs
Open Hack NYC Yahoo Social SDKsDustin Whittle
 
Build an AI/ML-driven image archive processing workflow: Image archive, analy...
Build an AI/ML-driven image archive processing workflow: Image archive, analy...Build an AI/ML-driven image archive processing workflow: Image archive, analy...
Build an AI/ML-driven image archive processing workflow: Image archive, analy...wesley chun
 
Google Apps Script: The authentic{ated} playground [2015 Ed.]
Google Apps Script: The authentic{ated} playground [2015 Ed.]Google Apps Script: The authentic{ated} playground [2015 Ed.]
Google Apps Script: The authentic{ated} playground [2015 Ed.]Martin Hawksey
 
Programming IoT Gateways in JavaScript with macchina.io
Programming IoT Gateways in JavaScript with macchina.ioProgramming IoT Gateways in JavaScript with macchina.io
Programming IoT Gateways in JavaScript with macchina.ioGünter Obiltschnig
 
Android chat in the cloud
Android chat in the cloudAndroid chat in the cloud
Android chat in the cloudfirenze-gtug
 
Using Google (Cloud) APIs
Using Google (Cloud) APIsUsing Google (Cloud) APIs
Using Google (Cloud) APIswesley chun
 
OAuth 2.0
OAuth 2.0 OAuth 2.0
OAuth 2.0 marcwan
 
Nk API - examples
Nk API - examplesNk API - examples
Nk API - examplesnasza-klasa
 
O365 DEVCamp Los Angeles June 16, 2015 Module 06 Hook into SharePoint APIs wi...
O365 DEVCamp Los Angeles June 16, 2015 Module 06 Hook into SharePoint APIs wi...O365 DEVCamp Los Angeles June 16, 2015 Module 06 Hook into SharePoint APIs wi...
O365 DEVCamp Los Angeles June 16, 2015 Module 06 Hook into SharePoint APIs wi...Ivan Sanders
 
Android ui layouts ,cntls,webservices examples codes
Android ui layouts ,cntls,webservices examples codesAndroid ui layouts ,cntls,webservices examples codes
Android ui layouts ,cntls,webservices examples codesAravindharamanan S
 

Similar to Google+ API (2012) (20)

The Big Picture and How to Get Started
The Big Picture and How to Get StartedThe Big Picture and How to Get Started
The Big Picture and How to Get Started
 
Introduction to Web APIs and the Google+ API - BarCamp Phnom Penh 2011
Introduction to Web APIs and the Google+ API - BarCamp Phnom Penh 2011Introduction to Web APIs and the Google+ API - BarCamp Phnom Penh 2011
Introduction to Web APIs and the Google+ API - BarCamp Phnom Penh 2011
 
google drive and the google drive sdk
google drive and the google drive sdkgoogle drive and the google drive sdk
google drive and the google drive sdk
 
Power your apps with Gmail, Google Drive, Calendar, Sheets, Slides & more
Power your apps with Gmail, Google Drive, Calendar, Sheets, Slides & morePower your apps with Gmail, Google Drive, Calendar, Sheets, Slides & more
Power your apps with Gmail, Google Drive, Calendar, Sheets, Slides & more
 
Exploring Google (Cloud) APIs with Python & JavaScript
Exploring Google (Cloud) APIs with Python & JavaScriptExploring Google (Cloud) APIs with Python & JavaScript
Exploring Google (Cloud) APIs with Python & JavaScript
 
Android dev toolbox
Android dev toolboxAndroid dev toolbox
Android dev toolbox
 
Mobile 2.0 Open Ideas WorkShop: Building Social Media Enabled Apps on Android
Mobile 2.0 Open Ideas WorkShop: Building Social Media Enabled Apps on AndroidMobile 2.0 Open Ideas WorkShop: Building Social Media Enabled Apps on Android
Mobile 2.0 Open Ideas WorkShop: Building Social Media Enabled Apps on Android
 
Getting started using Google APIs (2019)
Getting started using Google APIs (2019)Getting started using Google APIs (2019)
Getting started using Google APIs (2019)
 
Google Integration in Android Apps - Mooscon 2013 Cebit
Google Integration in Android Apps - Mooscon 2013 CebitGoogle Integration in Android Apps - Mooscon 2013 Cebit
Google Integration in Android Apps - Mooscon 2013 Cebit
 
Open Hack NYC Yahoo Social SDKs
Open Hack NYC Yahoo Social SDKsOpen Hack NYC Yahoo Social SDKs
Open Hack NYC Yahoo Social SDKs
 
Build an AI/ML-driven image archive processing workflow: Image archive, analy...
Build an AI/ML-driven image archive processing workflow: Image archive, analy...Build an AI/ML-driven image archive processing workflow: Image archive, analy...
Build an AI/ML-driven image archive processing workflow: Image archive, analy...
 
Google Apps Script: The authentic{ated} playground [2015 Ed.]
Google Apps Script: The authentic{ated} playground [2015 Ed.]Google Apps Script: The authentic{ated} playground [2015 Ed.]
Google Apps Script: The authentic{ated} playground [2015 Ed.]
 
Programming IoT Gateways in JavaScript with macchina.io
Programming IoT Gateways in JavaScript with macchina.ioProgramming IoT Gateways in JavaScript with macchina.io
Programming IoT Gateways in JavaScript with macchina.io
 
Android chat in the cloud
Android chat in the cloudAndroid chat in the cloud
Android chat in the cloud
 
Using Google (Cloud) APIs
Using Google (Cloud) APIsUsing Google (Cloud) APIs
Using Google (Cloud) APIs
 
Introduction to Google Apps Platform
Introduction to Google Apps PlatformIntroduction to Google Apps Platform
Introduction to Google Apps Platform
 
OAuth 2.0
OAuth 2.0 OAuth 2.0
OAuth 2.0
 
Nk API - examples
Nk API - examplesNk API - examples
Nk API - examples
 
O365 DEVCamp Los Angeles June 16, 2015 Module 06 Hook into SharePoint APIs wi...
O365 DEVCamp Los Angeles June 16, 2015 Module 06 Hook into SharePoint APIs wi...O365 DEVCamp Los Angeles June 16, 2015 Module 06 Hook into SharePoint APIs wi...
O365 DEVCamp Los Angeles June 16, 2015 Module 06 Hook into SharePoint APIs wi...
 
Android ui layouts ,cntls,webservices examples codes
Android ui layouts ,cntls,webservices examples codesAndroid ui layouts ,cntls,webservices examples codes
Android ui layouts ,cntls,webservices examples codes
 

Recently uploaded

Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clashcharlottematthew16
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 

Recently uploaded (20)

Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clash
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 

Google+ API (2012)

  • 1. Google+ API #GDG #DevFestJkt #DevFest #2012 Oon Arfiandwi <oon@7langit.com> Manager of Google Developer Group Jakarta http://gplus.to/oonid
  • 2. so, what can be covered in 35 mins? Google+ API in general OAuth2.0 + REST API Sign in with Google+, get to know about People, Activities & Comments Let’s code in Android + Google Play Services Google+ History
  • 3. Google+ API http://developers.google.com/+ Plugins for your website + REST API Mobile Platform (Android, iOS, mobile web) Hangout API History API (developer preview)
  • 4. OAuth 2.0 Generate OAuth 2.0 Token via Google Play Services GoogleAuthUtil.getToken() via Google APIs Client Library for Java create API Project with Google APIs Console open browser to URL from GoogleAuthorizationCodeRequestURL get Token via execute GoogleAuthorizationCodeTokenRequest
  • 5. Activate Service: Google+ API Google+ History API Create: OAuth 2.0 client ID Google APIs Console
  • 6. String googleAuthorizationCodeRequestUrl = new GoogleAuthorizationCodeRequestUrl( ShrdPrfsStore.CLIENT_ID,ShrdPrfsStore.REDIRECT_URI,ShrdPrfsStore.SCOPE).build(); webview.setWebViewClient(new WebViewClient() { @Override public void onPageFinished(WebView view, String url) { if (url.startsWith(SharedPrefsStore.REDIRECT_URI)) { try { if (url.indexOf("code=") != -1) { // Url is like http://localhost/?code=4/Z5DgC1IxNL-muPsrE2Sjy9zQn2pF String code = url.substring... TokenResponse accessTokenResponse = new GoogleAuthorizationCodeTokenRequest( new NetHttpTransport(), new JacksonFactory(), ShrdPrfsStore.CLIENT_ID, ShrdPrfsStore.CLIENT_SECRET, code, ShrdPrfsStore.REDIRECT_URI).execute(); ... credentialStore.write(accessTokenResponse); ... } } catch (IOException e) {} } }; }); webview.loadUrl(googleAuthorizationCodeRequestUrl);
  • 7. OAuth 2.0 login with Google+ Account Registered Product Name: DevFestJktPro SCOPE: plus.me plus.moment.write
  • 8. “Public” A ctivities Access Google+ Activities using OAuth access token as GoogleCredential Filter the Google+ Activities by user and collections (eg: “public”) Create Simple ListView based on Google+ Activity Titles
  • 9. Google+ History API http://developers.google.com/+/history/preview/ “Google+ history is a collection of moments that describe activities the user has engaged across the web and apps.” Google+ history API privately save moments, users can share those moments with others.
  • 10. Moments in History Types of Moments AddActivity BuyActivity CheckInActivity ListenActivity ReviewActivity ... Moments target URL must include attribute from schema.org markup Request new type of Moments?
  • 11. G oogle+ H istory Google+ History preview user interface, available for registered developer History of CheckInActivity History of AddActivity (+1)
  • 12. Google+ API The end or is it the beginning? (quote from G+ History) Questions?