• Save
Better Genealogy Through APIs
Upcoming SlideShare
Loading in...5
×
 

Better Genealogy Through APIs

on

  • 2,165 views

RootsTech 2012 - Better Genealogy Through APIs

RootsTech 2012 - Better Genealogy Through APIs

Statistics

Views

Total Views
2,165
Views on SlideShare
1,953
Embed Views
212

Actions

Likes
4
Downloads
0
Comments
0

3 Embeds 212

http://www.geni.com 187
http://feeds.feedburner.com 24
http://www.netvibes.com 1

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Better Genealogy Through APIs Better Genealogy Through APIs Presentation Transcript

  • Better Genealogy Through APIs Michael Berkovich Platform Tech Lead, Geni.com michael@geni.com February 2, 2012Thursday, February 2, 12
  • The Brief History of The Web Web 1.0 1990-2004 Static Content Publishing, Sharing, Surfing, Email, Chat, CMS, Personal Websites, Screen Scraping Delivered Through HTTP, HTML, URL, DialupThursday, February 2, 12
  • The Brief History of The Web Web 2.0 2004-2008 Social Web and User Provided Content Community, Collaboration, Interaction, Participation, Blogging, Wikis, Tagging, Syndication, SEO Delivered Through DHTML, CSS, JavaScript, AJAX, JSON, XML, XSLT, XHTML, XMLHttpRequest, Prototype, jQuery, RSSThursday, February 2, 12
  • The Brief History of The Web Web 2.0 ++ 2008 - now Integrated Data Web Services, Platforms, Mashups, Cloud, SaaS, Mobile Apps Delivered Through API, SOA, REST, SOAP, OAuth, RSSThursday, February 2, 12
  • What is an API? n Application Programming Interface n Set of protocols that provide building blocks for developers to build applications n Previously were associated with computer operating systems and native applications n Today mostly refer to web servicesThursday, February 2, 12
  • What is a Web Service API? Client Applications (Web, Mobile, Desktop) n Request messages along with a definition of the structure of response messages HTTP HTTPS Client-Side SDKs n Data formats - JSON, XML JS, iOS, Android, Java XML JSON n Paradigms - REST, SOAP Web Services Layer n Protocols - HTTP, HTTPS Family Tree Records Media API API API Core Platform and DataThursday, February 2, 12
  • Total API Over Time Programmable Web Statistics Source: http://net.tutsplus.com/articles/news/the-increasing-importance-of-apis-in-web-development/Thursday, February 2, 12
  • Consumer API Categories Programmable Web Statistics Source: http://net.tutsplus.com/articles/news/the-increasing-importance-of-apis-in-web-development/Thursday, February 2, 12
  • Mashups Created in the Last 6 Months Programmable Web Statistics Source: http://www.programmableweb.comThursday, February 2, 12
  • Benefits of Web APIs End Users n Provides users with application choices and better tools Application Developers n Allows unique and creative integration to provide the best value to the end users API Providers n Increases interest in the products and services n Increases web traffic n Outsources a task that is not part of your core businessThursday, February 2, 12
  • Genealogy Applications Today Documents & Records Maps Biographies Family Tree Family Photos DNA Services ChartsThursday, February 2, 12
  • Genealogy Applications with API Documents & Records Biographies Maps Family Photos Genealogy Platform DNA Services ChartsThursday, February 2, 12
  • Why Genealogy API? n Save users time n Provides access to the best tools n Allows for data aggregation n Makes collaboration easy n Enables integrated experienceThursday, February 2, 12
  • APIs in Genealogy Geni API http://dev.geni.com MyHeritage Family Graph API http://www.familygraph.com FamilySearch API https://devnet.familysearch.org/docs/api-overviewThursday, February 2, 12
  • Geni Platform Features n Free public open API that provides access to Geni users and data n Application security and permissions n API management and documentation n Developer tools, SDKs and metrics n Application directoryThursday, February 2, 12
  • What Can You Do With Geni Platform? n Geni Connect and Web Widgets n Web, Mobile and Desktop applications n Embedded apps within GeniThursday, February 2, 12
  • Geni Platform Implementation n Authorization - OAuth 2.0 n RESTful Paradigm n Data Formats - JSON, XML n Protocols - HTTP, HTTPS n Encoding - UTF8Thursday, February 2, 12
  • What is OAuth? An open protocol to allow secure API authorization in a simple and standard method from desktop and web applications. Source: http://oauth.netThursday, February 2, 12
  • Who is Using OAuth? Source: http://oauthx.comThursday, February 2, 12
  • OAuth 2.0 n Consumers n Desktop and mobile applications n Dashboard widgets and gadgets n Javascript browser-based apps n Providers (platform) n Web applications and server-side APIThursday, February 2, 12
  • OAuth 2.0 - High Level User Web Authorization Browser Server Shared Authorization Store Client Resource Application ServerThursday, February 2, 12
  • OAuth 2.0 - Authorization Flow Source: http://petermcintyre.com/2011/10/30/web-svc-security-principles-oauth/Thursday, February 2, 12
  • OAuth 2.0 - Subsequent Requests Source: http://petermcintyre.com/2011/10/30/web-svc-security-principles-oauth/Thursday, February 2, 12
  • Geni Supported OAuth Flows n Server-side (Authentication Code) n Client-side (Implicit Grant) n Desktop Apps (Implicit Grant) n Mobile Apps (Implicit Grant) n Trusted Apps (Resource Owners) n App Login (Client Credentials)Thursday, February 2, 12
  • API Access Scope & Permissions User Family Tree user_basic family_basic tree_basic user_email X X user_location family_location tree_location user_about_me family_about_me tree_about_me user_occupation family_occupation tree_occupation user_events family_events tree_events user_contact_info family_contact_info X user_media family_media tree_media update_user X update_profiles publish_media upload tag commentThursday, February 2, 12
  • RESTFul Paradigm http://www.geni.com/api/user http://www.geni.com/api/profile/12345 http://www.geni.com/api/profile/12345/immediate-family n REpresentational State Transfer n Stateless client-server architecture n Web services are resources and can be identified by their URLs n API is defined as set of remote methods that describe the action to be performed on the resource n HTTP methods such as GET and POST are used to describe the necessary CRUD actions to be performedThursday, February 2, 12
  • JSON Data Format { “first_name”: “Michael”, “last_name”: “Berkovich”, “gender”: “male”, “email”: “michael@geni.com” } n JavaScript Object Notation n Lightweight data-interchange format n Easy for humans to read and write n Easy for machines to parse and generate n Based on a subset of the JavaScript Programming Language n Completely language independentThursday, February 2, 12
  • Geni Platform Client SDKs n JavaScript SDK n http://geni.com/jsdk.js n iOS SDK n https://github.com/geni/geni-ios-sdk n Android SDK (work in progress) n Java SDK (work in progress) n PHP SDK (work in progress)Thursday, February 2, 12
  • Geni APIThursday, February 2, 12
  • Profile API Example http://www.geni.com/api/profile-23642470Thursday, February 2, 12
  • Immediate Family API Example http://www.geni.com/api/profile-23642470/immediate-familyThursday, February 2, 12
  • Profiles and Unions http://www.geni.com/api/profile-23642470/immediate-familyThursday, February 2, 12
  • Profile Documents API Example http://www.geni.com/api/profile-23642470/documentsThursday, February 2, 12
  • Geni JavaScript SDK Example Include Geni JS Client SDK Script <script src="http://geni.com/jsdk.js"></script> Initialize Geni Client Geni.init({ app_id: YOUR_APP_KEY, cookie: true, // enables saving the access token to a cookie logging:true // enable log messages to help in debugging }); Connect with Geni Geni.connect(function(response) { if(response.status == authorized) { // User is logged in and has authorized your application. // You can now make authorized calls to the API. } else { // User is either logged out, has not authorized the app or both. } }); Call Geni API Geni.api(/profile-23642470, function(response) { alert(response.name) });Thursday, February 2, 12
  • Geni iOS SDK Example Import Geni Client Library #import "GeniSDK.h" Initialize Geni Client Geni *geni = [[Geni alloc] initWithAppId:@”YOUR_APP_ID”]; Authorize Your App Using OAuth <GeniSessionDelegate> [geni authorize:self]; - (void) geniDidLogin { } - (void) geniDidNotLogin: (BOOL)cancelled { } Call Geni API [geni requestWithPath:@"user/max-family" andDelegate:self]; - (void)request:(GeniRequest *)request didLoadResponse:(GeniResponse *)response { }Thursday, February 2, 12
  • Let’s write some code !!!Thursday, February 2, 12
  • Geni Developer Community Over 200 developers are working on more than 70 Geni AppsThursday, February 2, 12
  • Why Develop with Geni Platform? n Instant access to our Free Public Open API n Reach over 7 million users n Get access to over 115 million profiles n Access public content including historical profiles, family trees, genealogy projects and surnamesThursday, February 2, 12
  • Getting Started with Geni Platform http://dev.geni.com n Register as a developer n Create a new application n Use key and secret to get an access token n Use Geni’s API to create an amazing user experience n Publish your application in the application directoryThursday, February 2, 12
  • And One More Thing Geni platform is Open-Sourced! http://github.com/berk/platformThursday, February 2, 12
  • Thursday, February 2, 12