OpenSocial Gadget - Using the result
function onLoadFriends(data) {
var viewer = data.get('viewer').getData();
var viewerFriends = data.get('viewerFriends').getData();
html = new Array();
html.push('<ul>');
viewerFriends.each(function(person) {
html.push(
'<li>' + person.getDisplayName() + "</li>"
);
});
html.push('</ul>');
document.getElementById('friends').innerHTML =
html.join('');
}
OpenSocial - OpenSocial Client Libraries
• For Server to Server, use the REST API
• Libraries exist for popular languages:
– http://code.google.com/p/opensocial-php-client/
– http://code.google.com/p/opensocial-java-client/
– http://code.google.com/p/opensocial-ruby-client/
– http://code.google.com/p/opensocial-python-client/
– http://code.google.com/p/opensocial-as3-client/
36
Google Friend Connect
• May 2008 Google Friend Connect preview
– Preview release, for whitelisted sites only
– Make your website social
– Long tail, no technical skills required
– Copy and past javascript
– Add OpenSocial applications
• December 2008 General availability
• February 2009 Social bar
– Easier integration
• March 2009
– Allow deep customized integration through outside of IFrame JS
– Server side integration (REST API’s)
40
Google I/O Social Videos
Find them at:
http://code.google.com/events/io/sessions.htm
• Beyond Cut & Paste: Deep integrations with Google Friend Connect
• Building a Business with Social Apps
• Designing OpenSocial Apps for Speed and Scale
• Google and the Social Web
• Google Friend Connect Gadgets: Best Practices in Code and Interaction Design
• Google Friend Connect In The Real World
• Powering Mobile Apps with Social Data
• The Social Web: An Implementor's Guide