SlideShare ist ein Scribd-Unternehmen logo
1 von 20
Downloaden Sie, um offline zu lesen
OPEN GRAPH API
AND HOW TO USE IT.
FACEBOOK DEVELOPERS MEETUP
AAYUSH SHRESTHA
FIND ME AT :
FB.COM/SHRESTHAAAYUSH
@AAYUSHSHRESTHA
AAYUSHONWEB@GMAIL.COM
HEAD OF EXPERIENCE DESIGN AND ARCHITECTURE - VIVEKA HEALTH
CO-FOUNDER - LISHN.COM
INTRODUCTION
GRAPH API
▸ Primary way for apps to get data in and out of the 

Facebook Social Graph
▸ HTTP Based REST API
▸ You can :
▸ query data
▸ post status and stories
▸ upload pictures and videos and more …
▸ V2.5
INTRODUCTION
SOCIAL GRAPH
▸ Representation of the information on Facebook
▸ NODES
▸ EDGES
▸ FIELDS
INTRODUCTION
SOCIAL GRAPH - NODES
▸ Every “thing”, such as a user, a photo, a comment, a page is a
node.
▸ User
▸ Photo
▸ Album
▸ Event
▸ Group
▸ Page
▸ Comment
▸ Story
▸ Video
▸ Link
▸ Note
INTRODUCTION
SOCIAL GRAPH - EDGES
▸ The connection between these “things” are edges.
▸ Feed
▸ Tagged
▸ Posts
▸ Picture
▸ Friends
▸ Activities
▸ Interests
▸ Likes
▸ Photos
▸ Statuses
▸ The information about these “things” are fields.
▸ User has : name, age, birthday, etc.
▸ Page has : name, description, category, etc
INTRODUCTION
SOCIAL GRAPH - FIELDS
LETS USE GRAPH API!!
BUT, HOLD ON!
LET’S USE GRAPH API
BEFORE JUMPING IN
▸ Making Graph API calls require an Access Token
▸ Get your Access Token using Facebook Login or one of the
SDK’s
▸ Get familiar with the Graph API Explorer

http://developers.facebook.com/tools/explorer
LET’S USE GRAPH API
TRAVERSING THROUGH THE GRAPH
▸ Authentication : OAuth 2.0
▸ Selection (or Query)
▸ Basic Operations (Publishing, Updating and Deleting)
▸ Searching
▸ Introspection
LET’S USE GRAPH API
SELECTION - SELECTING NODES
▸ graph.facebook.com/{node_id}
▸ graph.facebook.com/{node_username}
▸ graph.facebook.com/{node_id}?fields=id,name
▸ TRY THESE
1./me?field=id,name
2./me?field=album.limit(10){name,likes,count},photos
3./album_id
4./page_id
LET’S USE GRAPH API
SELECTION - SELECTING CONNECTIONS
▸ graph.facebook.com/{node_id}?fields={connection_name}
▸ graph.facebook.com/{node_id}/{connection_name}
▸ graph.facebook.com/{node_id}/{connection_name}?
fields=id,name
▸ TRY THESE
1./me/friends
2./me/friends/friend_id
3./albums
4./photos?type=uploaded
LET’S USE GRAPH API
PUBLISHING
▸ Publishing is done in edges
▸ graph.facebook.com/{node_id}/{connection_name} - POST
Request
▸ TRY THESE
1./me/feed - Fields : message=Hello World!
2./me/feed - Fields : message=Hello World!, privacy = {value : ‘SELF’}
LET’S USE GRAPH API
UPDATING
▸ Make POST Requests, now on nodes
▸ graph.facebook.com/{node_id} - POST Request
▸ TRY THESE
1. /{node_id} - Fields : message=Hello World Again!!
LET’S USE GRAPH API
DELETING
▸ Make DELETE Request on the node
▸ graph.facebook.com/{node_id} - DELETE Request
▸ TRY THESE
1./{story_id}
LET’S USE GRAPH API
SEARCHING
▸ graph.facebook.com/search
▸ TRY THESE
1./search?q=john&type=user
2./search?q=facebook+meetup&type=event
3./search?q=coffee&type=place&center={lat},{lon}&distance=1000
LET’S USE GRAPH API
INTROSPECTION
▸ graph.facebook.com/{node_id}?metadata=1
▸ JSON comes with the metadata of the node
▸ What type of node is this?
▸ What are its fields and what do they represent?
▸ What connections does this node possess?
▸ TRY THESE
1./me?metadata=1
ADVANCED STUFF
OPEN GRAPH STORIES
THANK YOU!!
FIND ME AT :
FB.COM/SHRESTHAAAYUSH
@AAYUSHSHRESTHA
AAYUSHONWEB@GMAIL.COM

Weitere ähnliche Inhalte

Was ist angesagt?

Data Mining: Concepts and Techniques (3rd ed.) — Chapter 5
Data Mining:  Concepts and Techniques (3rd ed.)— Chapter 5 Data Mining:  Concepts and Techniques (3rd ed.)— Chapter 5
Data Mining: Concepts and Techniques (3rd ed.) — Chapter 5 Salah Amean
 
Phython Programming Language
Phython Programming LanguagePhython Programming Language
Phython Programming LanguageR.h. Himel
 
Python for Data Science | Python Data Science Tutorial | Data Science Certifi...
Python for Data Science | Python Data Science Tutorial | Data Science Certifi...Python for Data Science | Python Data Science Tutorial | Data Science Certifi...
Python for Data Science | Python Data Science Tutorial | Data Science Certifi...Edureka!
 
Chapter 1 - INTRODUCTION TO PYTHON -MAULIK BORSANIYA
Chapter 1 - INTRODUCTION TO PYTHON -MAULIK BORSANIYAChapter 1 - INTRODUCTION TO PYTHON -MAULIK BORSANIYA
Chapter 1 - INTRODUCTION TO PYTHON -MAULIK BORSANIYAMaulik Borsaniya
 
Python pandas tutorial
Python pandas tutorialPython pandas tutorial
Python pandas tutorialHarikaReddy115
 
Python programming
Python programmingPython programming
Python programmingMegha V
 
INTRODUCTION TO PYTHON.pptx
INTRODUCTION TO PYTHON.pptxINTRODUCTION TO PYTHON.pptx
INTRODUCTION TO PYTHON.pptxNimrahafzal1
 
Introduction To Python | Edureka
Introduction To Python | EdurekaIntroduction To Python | Edureka
Introduction To Python | EdurekaEdureka!
 
Python Programlama Dili
Python Programlama DiliPython Programlama Dili
Python Programlama DiliCihan Özhan
 
Learn Python Programming | Python Programming - Step by Step | Python for Beg...
Learn Python Programming | Python Programming - Step by Step | Python for Beg...Learn Python Programming | Python Programming - Step by Step | Python for Beg...
Learn Python Programming | Python Programming - Step by Step | Python for Beg...Edureka!
 
Hành trình trở thành web đì ve lốp pơ
Hành trình trở thành web đì ve lốp pơHành trình trở thành web đì ve lốp pơ
Hành trình trở thành web đì ve lốp pơHuy Hoàng Phạm
 
Machine learning with scikitlearn
Machine learning with scikitlearnMachine learning with scikitlearn
Machine learning with scikitlearnPratap Dangeti
 
Breadth first search (bfs)
Breadth first search (bfs)Breadth first search (bfs)
Breadth first search (bfs)Bishal Bhandari
 
Machine learning introduction
Machine learning introductionMachine learning introduction
Machine learning introductionAnas Jamil
 
Python Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | EdurekaPython Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | EdurekaEdureka!
 

Was ist angesagt? (20)

Data Mining: Concepts and Techniques (3rd ed.) — Chapter 5
Data Mining:  Concepts and Techniques (3rd ed.)— Chapter 5 Data Mining:  Concepts and Techniques (3rd ed.)— Chapter 5
Data Mining: Concepts and Techniques (3rd ed.) — Chapter 5
 
Python Scipy Numpy
Python Scipy NumpyPython Scipy Numpy
Python Scipy Numpy
 
Phython Programming Language
Phython Programming LanguagePhython Programming Language
Phython Programming Language
 
Python for Data Science | Python Data Science Tutorial | Data Science Certifi...
Python for Data Science | Python Data Science Tutorial | Data Science Certifi...Python for Data Science | Python Data Science Tutorial | Data Science Certifi...
Python for Data Science | Python Data Science Tutorial | Data Science Certifi...
 
Chapter 1 - INTRODUCTION TO PYTHON -MAULIK BORSANIYA
Chapter 1 - INTRODUCTION TO PYTHON -MAULIK BORSANIYAChapter 1 - INTRODUCTION TO PYTHON -MAULIK BORSANIYA
Chapter 1 - INTRODUCTION TO PYTHON -MAULIK BORSANIYA
 
Python pandas tutorial
Python pandas tutorialPython pandas tutorial
Python pandas tutorial
 
Python programming
Python programmingPython programming
Python programming
 
INTRODUCTION TO PYTHON.pptx
INTRODUCTION TO PYTHON.pptxINTRODUCTION TO PYTHON.pptx
INTRODUCTION TO PYTHON.pptx
 
Introduction To Python | Edureka
Introduction To Python | EdurekaIntroduction To Python | Edureka
Introduction To Python | Edureka
 
Data Analysis in Python
Data Analysis in PythonData Analysis in Python
Data Analysis in Python
 
Top 10 python ide
Top 10 python ideTop 10 python ide
Top 10 python ide
 
Go Lang Tutorial
Go Lang TutorialGo Lang Tutorial
Go Lang Tutorial
 
Python Programlama Dili
Python Programlama DiliPython Programlama Dili
Python Programlama Dili
 
Learn Python Programming | Python Programming - Step by Step | Python for Beg...
Learn Python Programming | Python Programming - Step by Step | Python for Beg...Learn Python Programming | Python Programming - Step by Step | Python for Beg...
Learn Python Programming | Python Programming - Step by Step | Python for Beg...
 
Hành trình trở thành web đì ve lốp pơ
Hành trình trở thành web đì ve lốp pơHành trình trở thành web đì ve lốp pơ
Hành trình trở thành web đì ve lốp pơ
 
Machine learning with scikitlearn
Machine learning with scikitlearnMachine learning with scikitlearn
Machine learning with scikitlearn
 
Breadth first search (bfs)
Breadth first search (bfs)Breadth first search (bfs)
Breadth first search (bfs)
 
Python basics
Python basicsPython basics
Python basics
 
Machine learning introduction
Machine learning introductionMachine learning introduction
Machine learning introduction
 
Python Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | EdurekaPython Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | Edureka
 

Andere mochten auch

Facebook Open Graph API
Facebook Open Graph APIFacebook Open Graph API
Facebook Open Graph APIColin Smillie
 
Getting started with Facebook OpenGraph API
Getting started with Facebook OpenGraph APIGetting started with Facebook OpenGraph API
Getting started with Facebook OpenGraph APILynn Langit
 
Facebook Open Graph Overview
Facebook Open Graph OverviewFacebook Open Graph Overview
Facebook Open Graph OverviewCory OBrien
 
Facebook Platform for Developers
Facebook Platform for DevelopersFacebook Platform for Developers
Facebook Platform for DevelopersLidan Hifi
 
Facebook open graph explained
Facebook open graph explainedFacebook open graph explained
Facebook open graph explainedSaint Social
 
Understanding the potential of the Facebook Open Graph and Graph API
Understanding the potential of the Facebook Open Graph and Graph APIUnderstanding the potential of the Facebook Open Graph and Graph API
Understanding the potential of the Facebook Open Graph and Graph APIMeddle
 
Facebook open graph Presentation
Facebook open graph PresentationFacebook open graph Presentation
Facebook open graph PresentationIncheol Baek
 
Introduction to Facebook Graph API and OAuth 2
Introduction to Facebook Graph API and OAuth 2Introduction to Facebook Graph API and OAuth 2
Introduction to Facebook Graph API and OAuth 2Thai Pangsakulyanont
 
Facebook Open Graph Protocol and Graph API (NoVA Code Camp 2010.1)
Facebook Open Graph Protocol and Graph API (NoVA Code Camp 2010.1)Facebook Open Graph Protocol and Graph API (NoVA Code Camp 2010.1)
Facebook Open Graph Protocol and Graph API (NoVA Code Camp 2010.1)Chris Busse
 
Facebook Open Graph meta tags
Facebook Open Graph meta tagsFacebook Open Graph meta tags
Facebook Open Graph meta tagsStudioDeOorzaak
 
Facebook ( Open ) Graph and the Semantic Web
Facebook ( Open ) Graph and the Semantic WebFacebook ( Open ) Graph and the Semantic Web
Facebook ( Open ) Graph and the Semantic WebMatteo Brunati
 
Graph database Use Cases
Graph database Use CasesGraph database Use Cases
Graph database Use CasesMax De Marzi
 
Open tok Android sdk - Droidcon
Open tok Android sdk - DroidconOpen tok Android sdk - Droidcon
Open tok Android sdk - DroidconDroidcon Spain
 
FVCP - Facebook , Twitter and Meetup API / Widgets
FVCP - Facebook , Twitter and Meetup API / WidgetsFVCP - Facebook , Twitter and Meetup API / Widgets
FVCP - Facebook , Twitter and Meetup API / WidgetsPete DuMelle
 
Documenting APIs (with many pictures of cats) - APIStrat
Documenting APIs (with many pictures of cats) - APIStratDocumenting APIs (with many pictures of cats) - APIStrat
Documenting APIs (with many pictures of cats) - APIStratAnya Stettler
 
Introduction to Facebook Javascript SDK (NEW)
Introduction to Facebook Javascript SDK (NEW)Introduction to Facebook Javascript SDK (NEW)
Introduction to Facebook Javascript SDK (NEW)Colin Su
 
Implementasi Aplikasi Video Call Menggunakan WebRTC
Implementasi Aplikasi Video Call Menggunakan WebRTCImplementasi Aplikasi Video Call Menggunakan WebRTC
Implementasi Aplikasi Video Call Menggunakan WebRTCFitra Aditya
 
Comment viraliser les contenus de votre site grâce à l'open graph facebook
Comment viraliser les contenus de votre site grâce à l'open graph facebookComment viraliser les contenus de votre site grâce à l'open graph facebook
Comment viraliser les contenus de votre site grâce à l'open graph facebookPlayApp
 
How to Leverage the Social Graph with Facebook Platform
How to Leverage the Social Graph with Facebook PlatformHow to Leverage the Social Graph with Facebook Platform
How to Leverage the Social Graph with Facebook PlatformDave Olsen
 

Andere mochten auch (20)

Facebook Open Graph API
Facebook Open Graph APIFacebook Open Graph API
Facebook Open Graph API
 
Getting started with Facebook OpenGraph API
Getting started with Facebook OpenGraph APIGetting started with Facebook OpenGraph API
Getting started with Facebook OpenGraph API
 
Facebook Open Graph Overview
Facebook Open Graph OverviewFacebook Open Graph Overview
Facebook Open Graph Overview
 
Facebook Platform for Developers
Facebook Platform for DevelopersFacebook Platform for Developers
Facebook Platform for Developers
 
Facebook open graph explained
Facebook open graph explainedFacebook open graph explained
Facebook open graph explained
 
Understanding the potential of the Facebook Open Graph and Graph API
Understanding the potential of the Facebook Open Graph and Graph APIUnderstanding the potential of the Facebook Open Graph and Graph API
Understanding the potential of the Facebook Open Graph and Graph API
 
Facebook open graph Presentation
Facebook open graph PresentationFacebook open graph Presentation
Facebook open graph Presentation
 
Introduction to Facebook Graph API and OAuth 2
Introduction to Facebook Graph API and OAuth 2Introduction to Facebook Graph API and OAuth 2
Introduction to Facebook Graph API and OAuth 2
 
Facebook Open Graph Protocol and Graph API (NoVA Code Camp 2010.1)
Facebook Open Graph Protocol and Graph API (NoVA Code Camp 2010.1)Facebook Open Graph Protocol and Graph API (NoVA Code Camp 2010.1)
Facebook Open Graph Protocol and Graph API (NoVA Code Camp 2010.1)
 
Facebook Open Graph meta tags
Facebook Open Graph meta tagsFacebook Open Graph meta tags
Facebook Open Graph meta tags
 
Facebook ( Open ) Graph and the Semantic Web
Facebook ( Open ) Graph and the Semantic WebFacebook ( Open ) Graph and the Semantic Web
Facebook ( Open ) Graph and the Semantic Web
 
Graph database Use Cases
Graph database Use CasesGraph database Use Cases
Graph database Use Cases
 
Open tok Android sdk - Droidcon
Open tok Android sdk - DroidconOpen tok Android sdk - Droidcon
Open tok Android sdk - Droidcon
 
FVCP - Facebook , Twitter and Meetup API / Widgets
FVCP - Facebook , Twitter and Meetup API / WidgetsFVCP - Facebook , Twitter and Meetup API / Widgets
FVCP - Facebook , Twitter and Meetup API / Widgets
 
Documenting APIs (with many pictures of cats) - APIStrat
Documenting APIs (with many pictures of cats) - APIStratDocumenting APIs (with many pictures of cats) - APIStrat
Documenting APIs (with many pictures of cats) - APIStrat
 
Introduction to Facebook Javascript SDK (NEW)
Introduction to Facebook Javascript SDK (NEW)Introduction to Facebook Javascript SDK (NEW)
Introduction to Facebook Javascript SDK (NEW)
 
Implementasi Aplikasi Video Call Menggunakan WebRTC
Implementasi Aplikasi Video Call Menggunakan WebRTCImplementasi Aplikasi Video Call Menggunakan WebRTC
Implementasi Aplikasi Video Call Menggunakan WebRTC
 
Facebook & Twitter API
Facebook & Twitter APIFacebook & Twitter API
Facebook & Twitter API
 
Comment viraliser les contenus de votre site grâce à l'open graph facebook
Comment viraliser les contenus de votre site grâce à l'open graph facebookComment viraliser les contenus de votre site grâce à l'open graph facebook
Comment viraliser les contenus de votre site grâce à l'open graph facebook
 
How to Leverage the Social Graph with Facebook Platform
How to Leverage the Social Graph with Facebook PlatformHow to Leverage the Social Graph with Facebook Platform
How to Leverage the Social Graph with Facebook Platform
 

Ähnlich wie Facebook Open Graph API and How To Use It

Open Graph API And How To Use It : Facebook Developers Circle Meetup 2017
Open Graph API And How To Use It : Facebook Developers Circle Meetup 2017Open Graph API And How To Use It : Facebook Developers Circle Meetup 2017
Open Graph API And How To Use It : Facebook Developers Circle Meetup 2017Aayush Shrestha
 
Facebook Open Graph Tech Requirements
Facebook Open Graph Tech RequirementsFacebook Open Graph Tech Requirements
Facebook Open Graph Tech RequirementsAffinitive
 
What's New on the Facebook Platform, July 2011
What's New on the Facebook Platform, July 2011What's New on the Facebook Platform, July 2011
What's New on the Facebook Platform, July 2011Iskandar Najmuddin
 
Facebook Apps: Ein Entwicklungsleitfaden - WMMRN
Facebook Apps: Ein Entwicklungsleitfaden - WMMRNFacebook Apps: Ein Entwicklungsleitfaden - WMMRN
Facebook Apps: Ein Entwicklungsleitfaden - WMMRNStephan Hochdörfer
 
Optimizing WordPress sites for SEO and social media by Miriam Schwab
Optimizing WordPress sites for SEO and social media by Miriam SchwabOptimizing WordPress sites for SEO and social media by Miriam Schwab
Optimizing WordPress sites for SEO and social media by Miriam SchwabMiriam Schwab
 
Microsoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Tech Community
 
Microsoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Tech Community
 
Shiny Agency's Facebook Development Guidelines
Shiny Agency's Facebook Development GuidelinesShiny Agency's Facebook Development Guidelines
Shiny Agency's Facebook Development GuidelinesRoy Pereira
 
How NOT to Suck at App Distribution - Quick Start Guide - Appsocially's Growt...
How NOT to Suck at App Distribution - Quick Start Guide - Appsocially's Growt...How NOT to Suck at App Distribution - Quick Start Guide - Appsocially's Growt...
How NOT to Suck at App Distribution - Quick Start Guide - Appsocially's Growt...Yusuke Takahashi, PhD
 
How to Setup App Indexation
How to Setup App IndexationHow to Setup App Indexation
How to Setup App IndexationJustin Briggs
 
Sunnyside Up: Facebook Mobile, Follow, and Like Updates and Google +1 Updates
Sunnyside Up: Facebook Mobile, Follow, and Like Updates and Google +1 UpdatesSunnyside Up: Facebook Mobile, Follow, and Like Updates and Google +1 Updates
Sunnyside Up: Facebook Mobile, Follow, and Like Updates and Google +1 UpdatesProfero New York
 
Lets create awesome social experiences
Lets create awesome social experiencesLets create awesome social experiences
Lets create awesome social experiencesKaran Singh Bir
 
Facebook Apps Development 101 (Java)
Facebook Apps Development 101 (Java)Facebook Apps Development 101 (Java)
Facebook Apps Development 101 (Java)Damon Widjaja
 
WordCamp Netherlands Keynote
WordCamp Netherlands KeynoteWordCamp Netherlands Keynote
WordCamp Netherlands KeynoteFrederick Townes
 
Introduction to facebook java script sdk
Introduction to facebook java script sdk Introduction to facebook java script sdk
Introduction to facebook java script sdk Yi-Fan Chu
 
Happy facebook developer
Happy facebook developerHappy facebook developer
Happy facebook developerYu-Wei Chuang
 
Iskandar Najmuddin
Iskandar NajmuddinIskandar Najmuddin
Iskandar NajmuddiniPlatform
 

Ähnlich wie Facebook Open Graph API and How To Use It (20)

Open Graph API And How To Use It : Facebook Developers Circle Meetup 2017
Open Graph API And How To Use It : Facebook Developers Circle Meetup 2017Open Graph API And How To Use It : Facebook Developers Circle Meetup 2017
Open Graph API And How To Use It : Facebook Developers Circle Meetup 2017
 
Facebook Open Graph Tech Requirements
Facebook Open Graph Tech RequirementsFacebook Open Graph Tech Requirements
Facebook Open Graph Tech Requirements
 
What's New on the Facebook Platform, July 2011
What's New on the Facebook Platform, July 2011What's New on the Facebook Platform, July 2011
What's New on the Facebook Platform, July 2011
 
Facebook Apps: Ein Entwicklungsleitfaden - WMMRN
Facebook Apps: Ein Entwicklungsleitfaden - WMMRNFacebook Apps: Ein Entwicklungsleitfaden - WMMRN
Facebook Apps: Ein Entwicklungsleitfaden - WMMRN
 
Optimizing WordPress sites for SEO and social media by Miriam Schwab
Optimizing WordPress sites for SEO and social media by Miriam SchwabOptimizing WordPress sites for SEO and social media by Miriam Schwab
Optimizing WordPress sites for SEO and social media by Miriam Schwab
 
Microsoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needs
 
Microsoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needs
 
Shiny Agency's Facebook Development Guidelines
Shiny Agency's Facebook Development GuidelinesShiny Agency's Facebook Development Guidelines
Shiny Agency's Facebook Development Guidelines
 
How NOT to Suck at App Distribution - Quick Start Guide - Appsocially's Growt...
How NOT to Suck at App Distribution - Quick Start Guide - Appsocially's Growt...How NOT to Suck at App Distribution - Quick Start Guide - Appsocially's Growt...
How NOT to Suck at App Distribution - Quick Start Guide - Appsocially's Growt...
 
Meteor.js for DOers
Meteor.js for DOersMeteor.js for DOers
Meteor.js for DOers
 
How to Setup App Indexation
How to Setup App IndexationHow to Setup App Indexation
How to Setup App Indexation
 
Sunnyside Up: Facebook Mobile, Follow, and Like Updates and Google +1 Updates
Sunnyside Up: Facebook Mobile, Follow, and Like Updates and Google +1 UpdatesSunnyside Up: Facebook Mobile, Follow, and Like Updates and Google +1 Updates
Sunnyside Up: Facebook Mobile, Follow, and Like Updates and Google +1 Updates
 
Lets create awesome social experiences
Lets create awesome social experiencesLets create awesome social experiences
Lets create awesome social experiences
 
Facebook Apps Development 101 (Java)
Facebook Apps Development 101 (Java)Facebook Apps Development 101 (Java)
Facebook Apps Development 101 (Java)
 
The social media developer
The social media developer The social media developer
The social media developer
 
WordCamp Netherlands Keynote
WordCamp Netherlands KeynoteWordCamp Netherlands Keynote
WordCamp Netherlands Keynote
 
Facebook Platform
Facebook PlatformFacebook Platform
Facebook Platform
 
Introduction to facebook java script sdk
Introduction to facebook java script sdk Introduction to facebook java script sdk
Introduction to facebook java script sdk
 
Happy facebook developer
Happy facebook developerHappy facebook developer
Happy facebook developer
 
Iskandar Najmuddin
Iskandar NajmuddinIskandar Najmuddin
Iskandar Najmuddin
 

Mehr von Aayush Shrestha

Design and UX. An Introduction
Design and UX. An IntroductionDesign and UX. An Introduction
Design and UX. An IntroductionAayush Shrestha
 
Workshop on Hybrid App Development with Ionic Framework
Workshop on Hybrid App Development with Ionic FrameworkWorkshop on Hybrid App Development with Ionic Framework
Workshop on Hybrid App Development with Ionic FrameworkAayush Shrestha
 
Power of Elastic Search - nLocate
Power of Elastic Search - nLocatePower of Elastic Search - nLocate
Power of Elastic Search - nLocateAayush Shrestha
 
JavaScript : What is it really? AND Some new features in ES6
JavaScript : What is it really? AND Some new features in ES6JavaScript : What is it really? AND Some new features in ES6
JavaScript : What is it really? AND Some new features in ES6Aayush Shrestha
 
Understanding angular js
Understanding angular jsUnderstanding angular js
Understanding angular jsAayush Shrestha
 
A Half Day Workshop on Building Accessible Websites For People With Disabilities
A Half Day Workshop on Building Accessible Websites For People With DisabilitiesA Half Day Workshop on Building Accessible Websites For People With Disabilities
A Half Day Workshop on Building Accessible Websites For People With DisabilitiesAayush Shrestha
 
XBRL Implementation for Financial Reporting | NCASA
XBRL Implementation for Financial Reporting | NCASAXBRL Implementation for Financial Reporting | NCASA
XBRL Implementation for Financial Reporting | NCASAAayush Shrestha
 
XBRL Implementation for Financial Reporting
XBRL Implementation for Financial ReportingXBRL Implementation for Financial Reporting
XBRL Implementation for Financial ReportingAayush Shrestha
 

Mehr von Aayush Shrestha (8)

Design and UX. An Introduction
Design and UX. An IntroductionDesign and UX. An Introduction
Design and UX. An Introduction
 
Workshop on Hybrid App Development with Ionic Framework
Workshop on Hybrid App Development with Ionic FrameworkWorkshop on Hybrid App Development with Ionic Framework
Workshop on Hybrid App Development with Ionic Framework
 
Power of Elastic Search - nLocate
Power of Elastic Search - nLocatePower of Elastic Search - nLocate
Power of Elastic Search - nLocate
 
JavaScript : What is it really? AND Some new features in ES6
JavaScript : What is it really? AND Some new features in ES6JavaScript : What is it really? AND Some new features in ES6
JavaScript : What is it really? AND Some new features in ES6
 
Understanding angular js
Understanding angular jsUnderstanding angular js
Understanding angular js
 
A Half Day Workshop on Building Accessible Websites For People With Disabilities
A Half Day Workshop on Building Accessible Websites For People With DisabilitiesA Half Day Workshop on Building Accessible Websites For People With Disabilities
A Half Day Workshop on Building Accessible Websites For People With Disabilities
 
XBRL Implementation for Financial Reporting | NCASA
XBRL Implementation for Financial Reporting | NCASAXBRL Implementation for Financial Reporting | NCASA
XBRL Implementation for Financial Reporting | NCASA
 
XBRL Implementation for Financial Reporting
XBRL Implementation for Financial ReportingXBRL Implementation for Financial Reporting
XBRL Implementation for Financial Reporting
 

Facebook Open Graph API and How To Use It

  • 1. OPEN GRAPH API AND HOW TO USE IT. FACEBOOK DEVELOPERS MEETUP
  • 2. AAYUSH SHRESTHA FIND ME AT : FB.COM/SHRESTHAAAYUSH @AAYUSHSHRESTHA AAYUSHONWEB@GMAIL.COM HEAD OF EXPERIENCE DESIGN AND ARCHITECTURE - VIVEKA HEALTH CO-FOUNDER - LISHN.COM
  • 3. INTRODUCTION GRAPH API ▸ Primary way for apps to get data in and out of the 
 Facebook Social Graph ▸ HTTP Based REST API ▸ You can : ▸ query data ▸ post status and stories ▸ upload pictures and videos and more … ▸ V2.5
  • 4. INTRODUCTION SOCIAL GRAPH ▸ Representation of the information on Facebook ▸ NODES ▸ EDGES ▸ FIELDS
  • 5. INTRODUCTION SOCIAL GRAPH - NODES ▸ Every “thing”, such as a user, a photo, a comment, a page is a node. ▸ User ▸ Photo ▸ Album ▸ Event ▸ Group ▸ Page ▸ Comment ▸ Story ▸ Video ▸ Link ▸ Note
  • 6. INTRODUCTION SOCIAL GRAPH - EDGES ▸ The connection between these “things” are edges. ▸ Feed ▸ Tagged ▸ Posts ▸ Picture ▸ Friends ▸ Activities ▸ Interests ▸ Likes ▸ Photos ▸ Statuses
  • 7. ▸ The information about these “things” are fields. ▸ User has : name, age, birthday, etc. ▸ Page has : name, description, category, etc INTRODUCTION SOCIAL GRAPH - FIELDS
  • 10. LET’S USE GRAPH API BEFORE JUMPING IN ▸ Making Graph API calls require an Access Token ▸ Get your Access Token using Facebook Login or one of the SDK’s ▸ Get familiar with the Graph API Explorer
 http://developers.facebook.com/tools/explorer
  • 11. LET’S USE GRAPH API TRAVERSING THROUGH THE GRAPH ▸ Authentication : OAuth 2.0 ▸ Selection (or Query) ▸ Basic Operations (Publishing, Updating and Deleting) ▸ Searching ▸ Introspection
  • 12. LET’S USE GRAPH API SELECTION - SELECTING NODES ▸ graph.facebook.com/{node_id} ▸ graph.facebook.com/{node_username} ▸ graph.facebook.com/{node_id}?fields=id,name ▸ TRY THESE 1./me?field=id,name 2./me?field=album.limit(10){name,likes,count},photos 3./album_id 4./page_id
  • 13. LET’S USE GRAPH API SELECTION - SELECTING CONNECTIONS ▸ graph.facebook.com/{node_id}?fields={connection_name} ▸ graph.facebook.com/{node_id}/{connection_name} ▸ graph.facebook.com/{node_id}/{connection_name}? fields=id,name ▸ TRY THESE 1./me/friends 2./me/friends/friend_id 3./albums 4./photos?type=uploaded
  • 14. LET’S USE GRAPH API PUBLISHING ▸ Publishing is done in edges ▸ graph.facebook.com/{node_id}/{connection_name} - POST Request ▸ TRY THESE 1./me/feed - Fields : message=Hello World! 2./me/feed - Fields : message=Hello World!, privacy = {value : ‘SELF’}
  • 15. LET’S USE GRAPH API UPDATING ▸ Make POST Requests, now on nodes ▸ graph.facebook.com/{node_id} - POST Request ▸ TRY THESE 1. /{node_id} - Fields : message=Hello World Again!!
  • 16. LET’S USE GRAPH API DELETING ▸ Make DELETE Request on the node ▸ graph.facebook.com/{node_id} - DELETE Request ▸ TRY THESE 1./{story_id}
  • 17. LET’S USE GRAPH API SEARCHING ▸ graph.facebook.com/search ▸ TRY THESE 1./search?q=john&type=user 2./search?q=facebook+meetup&type=event 3./search?q=coffee&type=place&center={lat},{lon}&distance=1000
  • 18. LET’S USE GRAPH API INTROSPECTION ▸ graph.facebook.com/{node_id}?metadata=1 ▸ JSON comes with the metadata of the node ▸ What type of node is this? ▸ What are its fields and what do they represent? ▸ What connections does this node possess? ▸ TRY THESE 1./me?metadata=1
  • 20. THANK YOU!! FIND ME AT : FB.COM/SHRESTHAAAYUSH @AAYUSHSHRESTHA AAYUSHONWEB@GMAIL.COM