Share
Embed
Sticky Social Apps
Best practices and strategies for keeping people engaged in your application
beardouglas
May 29, 2013
Transcript
105 slides
-
developers Making Sticky Social Apps Bear Douglas and Christine Abernathy
github: beardouglas, caabernathy @beardigsit @caabernathy Wednesday, May 29, 13 -
The Lifecycle of a Sticky App What can I find
here? Contribute content Add friends Discover / Engage Wednesday, May 29, 13 -
Solving the empty room problem What can I find here?
Contribute content Add friends Discover / Engage Wednesday, May 29, 13 -
Code: Fetching a person’s list of friends using app String
fqlQuery = "SELECT uid, name FROM user WHERE uid IN " + "(SELECT uid2 FROM friend WHERE uid1 = me() LIMIT 25) AND is_app_user = 1"; Bundle params = new Bundle(); params.putString("q", fqlQuery); Request request = new Request(Session.getActiveSession(), "/fql", params, HttpMethod.GET, new Request.Callback() { Wednesday, May 29, 13 -
Code: Fetching a person’s list of friends using app String
fqlQuery = "SELECT uid, name FROM user WHERE uid IN " + "(SELECT uid2 FROM friend WHERE uid1 = me() LIMIT 25) AND is_app_user = 1"; Bundle params = new Bundle(); params.putString("q", fqlQuery); Request request = new Request(Session.getActiveSession(), "/fql", params, HttpMethod.GET, new Request.Callback() { @Override public void onCompleted(Response response) { // Get the array of data returned JSONArray dataArray = (JSONArray) response.getGraphObject().getProperty("data"); if (dataArray.length() > 0) { // Cast this into a defined interface representing the response GraphObjectList<MyResult> result = GraphObject.Factory.createList(dataArray, MyResult.class); requestOpenGraphData(result); } } }); Wednesday, May 29, 13 -
Code: Fetching a person’s list of friends using app request.executeAsync();
String fqlQuery = "SELECT uid, name FROM user WHERE uid IN " + "(SELECT uid2 FROM friend WHERE uid1 = me() LIMIT 25) AND is_app_user = 1"; Bundle params = new Bundle(); params.putString("q", fqlQuery); Request request = new Request(Session.getActiveSession(), "/fql", params, HttpMethod.GET, new Request.Callback() { @Override public void onCompleted(Response response) { // Get the array of data returned JSONArray dataArray = (JSONArray) response.getGraphObject().getProperty("data"); if (dataArray.length() > 0) { // Cast this into a defined interface representing the response GraphObjectList<MyResult> result = GraphObject.Factory.createList(dataArray, MyResult.class); requestOpenGraphData(result); } } }); Wednesday, May 29, 13 -
Code: Reading Open Graph Data from a list of friends
Wednesday, May 29, 13 -
Code: Reading Open Graph Data from a list of friends
private void requestOpenGraphData(GraphObjectList<MyResult> friends) { RequestBatch requestBatch = new RequestBatch(); for (MyResult friend : friends) { Wednesday, May 29, 13 -
Code: Reading Open Graph Data from a list of friends
private void requestOpenGraphData(GraphObjectList<MyResult> friends) { RequestBatch requestBatch = new RequestBatch(); for (MyResult friend : friends) { Request ogDataRequest = Request.newGraphPathRequest( Session.getActiveSession(), friend.getUid()+"/resourcebrowser:browse", new Request.Callback() { public void onCompleted(Response response) { FacebookRequestError error = response.getError(); if (error == null) { // Process the data for display } } }); requestBatch.add(ogDataRequest); Wednesday, May 29, 13 -
Code: Reading Open Graph Data from a list of friends
} requestBatch.executeAsync(); } private void requestOpenGraphData(GraphObjectList<MyResult> friends) { RequestBatch requestBatch = new RequestBatch(); for (MyResult friend : friends) { Request ogDataRequest = Request.newGraphPathRequest( Session.getActiveSession(), friend.getUid()+"/resourcebrowser:browse", new Request.Callback() { public void onCompleted(Response response) { FacebookRequestError error = response.getError(); if (error == null) { // Process the data for display } } }); requestBatch.add(ogDataRequest); Wednesday, May 29, 13 -
Pro Tips ▪Personalize around friends and interests ▪Consider building up
your own graph Wednesday, May 29, 13 -
Pro Tips ▪Personalize around friends and interests ▪Consider building up
your own graph ▪Put aggregation data logic on a server Wednesday, May 29, 13 -
Contributing content What can I find here? Contribute content Add
friends Discover / Engage Wednesday, May 29, 13 -
Case study: TripAdvisor Average user engagement increased Users who connect
through Facebook are x as likely to contribute content “Cities I’ve Visited” app saw x increase in monthly active users after adding Open Graph Wednesday, May 29, 13 -
________ + ________ + ________ Christine ate a meal =
Story Wednesday, May 29, 13 -
Open Graph and Sharing Share Dialog User Owned Objects Object
API Wednesday, May 29, 13 -
Code: Creating the Story // Create a batch request RequestBatch
requestBatch = new RequestBatch(); Wednesday, May 29, 13 -
Code: Creating the Story // Create a batch request RequestBatch
requestBatch = new RequestBatch(); // Create object creation request Bundle objectParams = new Bundle(); JSONObject book = new JSONObject(); book.put("title", "A Game of Thrones"); // ... objectParams.putString("object", book.toString()); Request objectRequest = new Request(session,"me/objects/books.book", objectParams, HttpMethod.POST, null); objectRequest.setBatchEntryName("objectCreate"); requestBatch.add(objectRequest); Wednesday, May 29, 13 -
Code: Creating the Story // Create a batch request RequestBatch
requestBatch = new RequestBatch(); // Create the publish action request Bundle actionParams = new Bundle(); actionParams.putString("book", "{result=objectCreate:$.id}"); Request actionRequest = new Request(session,"me/books.reads", actionParams, HttpMethod.POST, null); requestBatch.add(actionRequest); // Create object creation request Bundle objectParams = new Bundle(); JSONObject book = new JSONObject(); book.put("title", "A Game of Thrones"); // ... objectParams.putString("object", book.toString()); Request objectRequest = new Request(session,"me/objects/books.book", objectParams, HttpMethod.POST, null); objectRequest.setBatchEntryName("objectCreate"); requestBatch.add(objectRequest); Wednesday, May 29, 13 -
Code: Creating the Story // Execute the batch request requestBatch.executeAsync();
// Create a batch request RequestBatch requestBatch = new RequestBatch(); // Create the publish action request Bundle actionParams = new Bundle(); actionParams.putString("book", "{result=objectCreate:$.id}"); Request actionRequest = new Request(session,"me/books.reads", actionParams, HttpMethod.POST, null); requestBatch.add(actionRequest); // Create object creation request Bundle objectParams = new Bundle(); JSONObject book = new JSONObject(); book.put("title", "A Game of Thrones"); // ... objectParams.putString("object", book.toString()); Request objectRequest = new Request(session,"me/objects/books.book", objectParams, HttpMethod.POST, null); objectRequest.setBatchEntryName("objectCreate"); requestBatch.add(objectRequest); Wednesday, May 29, 13 -
Creating a Custom Story ▪ Model your data create a
collage Wednesday, May 29, 13 -
Creating a Custom Story ▪ Model your data ▪ Set
up your custom story create a collage Wednesday, May 29, 13 -
Creating a Custom Story ▪ Model your data ▪ Set
up your custom story ▪ Create test objects create a collage Wednesday, May 29, 13 -
Creating a Custom Story ▪ Model your data ▪ Set
up your custom story ▪ Create test objects ▪ Publish test actions create a collage Wednesday, May 29, 13 -
Building Your App Database REST API REST Z Z Z
Server + + + users + security Caching Networking + + The fun stuff! Wednesday, May 29, 13 -
Parse Lets You Focus on the Fun Stuff Database REST
API REST Z Z Server + + + users + security Caching Networking + + The fun stuff! Wednesday, May 29, 13 -
Parse Lets You Focus on the Fun Stuff no no
no no no yes! Database REST API REST Z Z Server + + + users + security Caching Networking + + The fun stuff! Z Wednesday, May 29, 13 -
ParseUser user = new ParseUser(); user.setUsername("my name"); user.setPassword("my pass"); user.setEmail("[email protected]");
user.signUpInBackground(new SignUpCallback() { }); Creating and Managing Users PFUser *user = [PFUser user]; user.username = @"my name"; user.password = @"my pass"; user.email = @"[email protected]"; [user signUpInBackgroundWithBlock:^(BOOL succeeded, NSError *error) { }]; var user = new Parse.User(); user.set("username", "my name"); user.set("password", "my pass"); user.set("email", "[email protected]"); user.signUp(null, { success: function(user) { }, error: function(user, error) {} }); Wednesday, May 29, 13 -
Saving Data ParseObject gameScore = new ParseObject("Score"); gameScore.put("points", 1337); gameScore.put("playerName",
"Christine Abernathy"); gameScore.saveInBackground(); Wednesday, May 29, 13 -
Querying Data ParseQuery query = new ParseQuery("Score");; query.whereEqualTo("playerName", "Christine Abernathy"];
query.whereGreaterThan("points", 10000]; query.findInBackground(new FindCallback() { public void done(List<ParseObject> pointList, ParseException e) { // Process the result } }); Wednesday, May 29, 13 -
Pro Tips ▪Track content performance through Insights ▪Generate image rich
stories Wednesday, May 29, 13 -
Pro Tips ▪Track content performance through Insights ▪Generate image rich
stories ▪Use proper Open Graph tags for great previews Wednesday, May 29, 13 -
Pro Tips ▪Track content performance through Insights ▪Generate image rich
stories ▪Use proper Open Graph tags for great previews ▪Consider adding Internationalization support Wednesday, May 29, 13 -
Add friends What can I find here? Contribute content Add
friends Discover / Engage Wednesday, May 29, 13 -
Case study: Waze Wazers who use Facebook drive more miles
Users who connect through Facebook use Waze . x as often as other users User growth doubled after adding Facebook Login How can a mapping app be social? Enable friends to carpool and share directions to events Wednesday, May 29, 13 -
Discover / Engage What can I find here? Contribute content
Add friends Discover / Engage Wednesday, May 29, 13 -
Your Cross-Platform Checklist Use the same Facebook App ID everywhere
Wednesday, May 29, 13 -
Your Cross-Platform Checklist Use the same Facebook App ID everywhere
Implement Facebook Login on every platform Wednesday, May 29, 13 -
Your Cross-Platform Checklist Use the same Facebook App ID everywhere
Enable Deep Linking for Android and iOS Implement Facebook Login on every platform Wednesday, May 29, 13 -
Your Cross-Platform Checklist Use the same Facebook App ID everywhere
Enable Deep Linking for Android and iOS Make it easy to share from every platform Implement Facebook Login on every platform Wednesday, May 29, 13 -
Promote What can I find here? Contribute content Add friends
Discover / Engage Wednesday, May 29, 13 -
Promote What can I find here? Contribute content Add friends
Discover / Engage But how do you even get someone here? Wednesday, May 29, 13 -
Best Practices ▪ Real People. Real Things. ▪ Strong Call
to Action Wednesday, May 29, 13 -
Best Practices ▪ Real People. Real Things. ▪ Strong Call
to Action ▪ Include Mobile Devices Wednesday, May 29, 13 -
Best Practices ▪ Real People. Real Things. ▪ Strong Call
to Action ▪ Include Mobile Devices ▪ App Screenshots Wednesday, May 29, 13 -
Best Practices ▪ Real People. Real Things. ▪ Strong Call
to Action ▪ Include Mobile Devices ▪ App Screenshots ▪ Test. Test. Test. Wednesday, May 29, 13 -
Sponsoring Open Graph Stories Friends engage with story Sponsor story
Wednesday, May 29, 13 -
Key Takeaways ▪Pay attention to your user’s lifecycle ▪Show engaging
content first Wednesday, May 29, 13 -
Key Takeaways ▪Pay attention to your user’s lifecycle ▪Show engaging
content first ▪Use Open Graph to tell rich stories Wednesday, May 29, 13 -
Key Takeaways ▪Pay attention to your user’s lifecycle ▪Show engaging
content first ▪Use Open Graph to tell rich stories ▪Add cross-platform support Wednesday, May 29, 13 -
Key Takeaways ▪Pay attention to your user’s lifecycle ▪Show engaging
content first ▪Use Open Graph to tell rich stories ▪Add cross-platform support ▪A/B test content and ads to find the most effective ways to get users Wednesday, May 29, 13