Mixi and Nohana Bring Photos to Life With Parse

Nohana

As Japan’s go-to destination for all things people and social, Mixi has its hands in a variety of creative outlets for bringing people together. With its roots as a social networking site, Mixi’s recent foray into gaming with Monster Strike has proven to be highly successful. Now, Mixi has developed a subsidiary named Nohana, a photobook creation app powered by Parse.

The Nohana app allows you to upload photos from your smartphone, assembling them into 20-page photo-booklets or albums that are then printed and sent straight to your door. The first book ordered in a month is free plus shipping, and users can invite family members to a secured group to share photos and make collaborative photobooks.

To date, over 100,000 photobooks have been published by over 200,000 people, uploading more than 4 million photos. For a time, Nohana was not only the number one free iOS app in Japan with over 1 million downloads, but it was also featured on national television.

With so many photos and memories flowing through the service each day, Nohana turned to Parse products for a stable and scalable way to develop a strong backend for its app. Photo data, purchase history, and user information are all stored in Parse. Cloud Code is utilized for validation of a user’s value input and for connecting with Twilio for SMS authentication.

For Kazuki Tanaka and Kenta Tsuji, developers on the Nohana team, the Parse experience has been key for the app’s development and the startup’s growth:

The biggest merit of using Parse was shortening development of server-side infrastructure. To be a successful startup, we need to maximize output by minimizing cost and time, so it was perfect to use Parse.

Additionally, Nohana uses Parse Push to engage with its users, guiding them to photobook purchases and updates within the app. In the future, Nohana plans to use Parse Push to notify users of their shipment status. Of the features used, Parse has been especially useful for three elements of Nohana’s development:

1. Administration of users are really useful—including being able to set access control for each set of data, authentication via email, password reset function;

2. Implementation of server-side is easy;

3. 3rd party integration is easy, too! (e.g. Twilio, Underscore.js)

The Nohana app is available on the App Store and the Google Play Store. Bring your memories to life in a flash!

Nancy Xiao
September 18, 2014

Parse SDK for iOS 8, Performance, and Security

Parse SDK for iOS 8

We’re excited that the big day is finally here — iOS 8 is finally available to everyone! We spent the last few weeks waiting patiently and getting ready. Today we’re rolling out a new version of the Parse SDK for iOS with support for iOS 8 as well as a bunch of other performance and security improvements.

Parse and iOS 8

We updated our SDK to make sure it runs smoothly on iOS 8 and benefits from all the new APIs available. Just to name a couple, we’ve updated how [PFGeoPoint geoPointForCurrentLocationInBackground:] works to be smarter about requesting the appropriate permissions depending on the state of the app, and we’ve updated our push notification integration everywhere to use the new permissions style and support the category key.

Performance Improvements for Parse Files

Parse Files let you easily store application files in the cloud that would otherwise be too large or cumbersome to fit into a regular database-style Parse Object. This release of the iOS (and OS X) SDK brings greatly improved performance for Parse Files. Uploading is now up to 3 times faster and downloading is up to 35% faster. We’re also using fewer system resources which leads to better battery usage for file-heavy apps.

Improved Security for Account Data

The Parse SDK now uses the System Keychain on both iOS and OS X to store sensitive user information tied to PFUser. All of this happens automatically and under the hood so you don’t need to make any changes on your end.

Try It Out

The latest iOS SDK is now available for download here. Send us your feedback! We hope you’re as excited as we are about the new features and possibilities that iOS 8 brings.

Nikita Lutsenko
September 18, 2014

Ready for iOS 8? So is Parse Push

In this year’s WWDC, Apple announced some great changes to iOS Notifications. First, Apple has increased the maximum payload size to two kilobytes rather than 256 bytes. This new limit is retroactive and works with all existing devices! The more subtle changes to push notifications involve security and interaction with notifications.

“Silent” pushes are push notifications that don’t create UI; they instead tell your app to fetch or react to new content available online. In iOS 8, Apple has separated out the permissions for UI and push. The push permission is auto-accepted by default too! This means your iOS 8 apps will be able to much more reliably depend on the ability to receive silent notifications in iOS 8. To migrate your app, change the following code:

// Before iOS 8:
[[UIApplication sharedApplication] registerForRemoteNotificationTypes:UIRemoteNotificationTypeAlert |
                                                                      UIRemoteNotificationTypeBadge |
                                                                      UIRemoteNotificationTypeSound];

to

// For iOS 8:
UIUserNotificationSettings *settings =
    [UIUserNotificationSettings settingsForTypes:UIUserNotificationTypeAlert |
                                                 UIUserNotificationTypeBadge |
                                                 UIUserNotificationTypeSound
                                      categories:nil];
[[UIApplication sharedApplication] registerUserNotificationSettings:settings];
[[UIApplication sharedApplication] registerForRemoteNotifications];
Even if the user declines permission for creating UI, the permission to send (silent) pushes is auto-accepted for most users.

Notice the nil param for categories above? Categories unlock a whole new dimension to push notifications in iOS 8. Categories describe “actions” that should be presented in your notification in various views. Actions provide custom buttons your users can use when interacting with your push notification; your action can launch the app into the foreground or even trigger a background action, such as accepting or declining a calendar invite. To enable this feature, you must define a UIUserNotificationCategory. These categories have an identifier string and a map of UIUserNotificationActionContext to many UIUserNotificationActions. A UIUserNotificationActionContext comes in two flavors: default and minimal. The default context specifies which actions should be presented when the notification has an alert UI and supports a maximum of four actions; the minimal context specifies which actions should be presented when the notification has a banner UI or is on the lock screen and supports a maximum of two actions.  Once you’ve registered notification categories with your application, sending them via Parse Push is easy: simply pass the category identifier as the category option in your push. This feature is supported retroactively on all Parse SDKs, you don’t even need to upgrade! You may, however, want to check out the new UIApplicationDelegate method application:handleActionWithIdentifier:forRemoteNotification:completionHandler:

iOS 8 allows developers to define actions an end user can take when responding to a notification.

We look forward to seeing the great things you build with Parse and iOS 8!

Thomas Bouldin
September 15, 2014

Quip Goes Global With Parse Push

QuipIn many workplaces, collaborative word processing is a key activity on a day-to-day basis. However, the tools we use to write collaboratively have remained relatively unchanged in the past thirty years. With Quip, this experience has become much more dynamic, and much more accessible. Quip is a mobile, collaborative word processor that works across smartphones, tablets, and the desktop.

Started in 2012 by Kevin Gibbs and Bret Taylor, the former Chief Technology Officer of Facebook and co-creator of Google Maps, Quip tackles a unique opportunity in high global demand. Having seen tremendous growth in mobile devices, Quip took to redefining the product experience for productivity apps for the era of smartphones and tablets. The Quip app works seamlessly across desktop, iOS, and Android.

Quip turned to Parse Push to handle its push notifications on Android. This was a very strategic move, given that Android has such a large, rapidly growing user base—particularly outside of the U.S. However, much of this growth has been taking place in places like China, where the Play Store and Google Services are not present. Using Parse Push, Quip was able to reach those users without having to reproduce Google’s infrastructure, and now are present on virtually all Android devices around the world. China is Quip’s third biggest country, and growing quickly. This has also proved useful for users in Russia, and on devices like the Kindle Fire in the U.S. According to Bret Taylor, CEO of Quip:

Our favorite aspects of using Parse were the great APIs and great documentation. Thanks to using Parse for notifications on Android devices without Google services, we have a much bigger presence in China.

Head on over to Quip’s desktop product to find out more, or download now straight from the App Store or on Google Play.

Nancy Xiao
September 11, 2014

Announcing Parse Config

Parse Config

We at the Parse London office are happy to announce Parse Config: the simplest way to store your app’s parameters for updating on the fly. Keeping configurations out of your app’s binary means config changes do not require a fresh app release.

Say you have a background image in your game, and you would like to change it on the fly during the Christmas season. All you would have to do is swap the image on the Parse Config dashboard. Or, for example, you have this shiny new feature that you haven’t released yet, and would like to have a few people dogfood it. You could trickle out these by specifying a “dogfooding” array of user IDs.

Parse Config Dashboard

In the past, some Parse developers have built their own configuration management using a Parse Object, and then modified its columns in the Data Browser. This approach required manually caching this object on mobile devices to avoid waiting for a query to run on every app restart. Parse is all about abstracting away common tasks so we wanted to build something for this use case.

Parse Config makes the experience of handling configuration much smoother than ever before. We updated our iOS, Android, JS, .NET and Unity SDKs to provide intuitive method calls to help sync configurations in the Parse Cloud. Our SDKs automatically cache the last-fetched configuration, so you don’t have to re-fetch it after an app restart.

Here is an example snippet of what the Parse Config API looks like. Alternatively, you can have a look at the Anywall source code, which has now been updated to use Parse Config.

[PFConfig getConfigInBackgroundWithBlock:^(PFConfig *config, NSError *error) {
  NSArray *distanceOptions = config[@"searchDistanceOptions"];
  if (!distanceOptions) {
    // No config for distance options - fallback to the default ones
    distanceOptions = @[ @250.0, @1000.0, @2000.0, @5000.0 ];
  }
  self.distanceOptions = distanceOptions;
  [self.tableView reloadData];
}];

Our simple yet flexible API gives you precise control over when to fetch a new configuration and when to use the last-known configuration.The PFConfig is an immutable dictionary that can be used to retrieve configuration parameters. Our SDKs automatically persist the last-known PFConfig instance, and can be retrieved with [PFConfig currentConfig] so you don’t have to worry about losing the last-known configuration if a user decides to close your app.

As you may expect, the fetching of the configuration from the server is an asynchronous call. While the fetch occurs in the background, you can keep using the last-held PFConfig instance, without worrying about it suddenly changing underneath you. After the fetch completes, you can decide to switch to the latest PFConfig anytime.

We are always looking to improve our products and would love to hear your feedback. Check out our guides, try it out and let us know what you think!


  
Karan Gajwani
September 8, 2014

Meety Makes File Sharing Easy With Parse

Meety

For businesses across the globe, file sharing has become a ubiquitous, of-the-minute tool that is constantly utilized in all kinds of work settings. Sensing an opportunity and reimagining the way files are shared, Japan’s NEOS Corporation has tackled file sharing with a fresh new take with the release of Meety. In Japan, email communication has been replaced with chat. Simultaneously, file sharing tools such as Dropbox and Evernote have drastically grown in usage. Thus, Meety sought to find a common ground between the two, developing a comprehensive chat application with file sharing features.

By using Meety’s integration with Dropbox, Google Drive, and Box, users can easily transfer files to each other—from music to movie files to PowerPoints, Word Docs, Excel spreadsheets, PDFs, and more. Files are stored and managed in every chat room, allowing for simple search functionality if a user needs to return to the file in the future.

For execution of the app, the Meety team at NEOS Corporation turned to Parse. NEOS Corporation has a wide array of resources, including investor backing from NTT Docomo, Sharp Corporation, and KDDI Corporation. Upon coming across Parse on an external blog, the team decided to give it a try. According to Meety’s software development manager:

By using Parse, we were able to launch the service without incurring large infrastructure costs. We saved about three crucial months in developing our app, which also brought down our development costs.

Meety is now available for download on the App Store, and is coming soon to the Google Play Store.

Nancy Xiao
September 6, 2014

The Dangerous World of Client Push

Push Notifications are one of the most effective ways for apps to increase user engagement and retention, notify customers of important information like sales and new products, or allow users communicate with each other. A messaging app, for example, could use push notifications to alert users to an incoming message from their friend in the app. But be careful, because the most obvious way to do this can expose you to a security risk.

One easy way to send push notifications to particular users from within an app is to send the pushes directly from the client code, for example by using PFPush on iOS. This is tempting, because you have all the information you need to send the push straight from within iOS, and the code to send the push is very simple. But as Bryan mentioned in his security series, clients can’t be trusted to send push notifications directly. Some nefarious hacker could modify the client code, changing the Objective-C or Java code to modify the push’s alert text, or to send pushes to people they shouldn’t be able to. The hacker could steal your app’s keys and send pushes himself without even using the app.

Sounds scary! Luckily, there is a simple way around this security vulnerability. In your app’s settings, under “Push Notifications”, there is a toggle that lets you disable “Client Push.” We highly recommend that you set this switch to “OFF,” and instead of sending the push notifications from the client, you should write Cloud Code functions that validate the user and the data to be pushed before sending them. Client Push is disabled by default, but this feature can still be useful for initial prototyping if you want to hook up push notifications without diving into Cloud Code as you iterate. But as you scale to a production app, you really should not have Client Push enabled.

Here is one example of how to port your pushes from the client into Cloud Code, starting with an example Client Push to a single user, stored in userObject. Here’s the old iOS code:

// WRONG WAY TO SEND PUSH - INSECURE!
PFQuery *pushQuery = [PFInstallation query];
[pushQuery whereKey:@"user" equalTo:userObject];
PFUser *user = [PFUser currentUser];
NSString *message = [NSString stringWithFormat:@"%@ says Hi!", user[@"name"]];

PFPush *push = [[PFPush alloc] init];
[push setQuery:pushQuery]; // Set our Installation query
[push setMessage:message];
[push sendPushInBackground];

And on Android:

// WRONG WAY TO SEND PUSH - INSECURE!
ParseQuery pushQuery = ParseInstallation.getQuery();
pushQuery.whereEqualTo("user", userObject);
ParseUser currentUser = ParseUser.getCurrentUser();
String message = currentUser.getString("name") + " says Hi!";

ParsePush push = new ParsePush();
push.setQuery(pushQuery); // Set our Installation query
push.setMessage(message);
push.sendInBackground();

To move these push calls to Cloud Code, first we would write a Cloud function, sendPushToUser, to verify that the user sending the push is allowed to send it and that the alert text is what it should be.

Parse.Cloud.define("sendPushToUser", function(request, response) {
  var senderUser = request.user;
  var recipientUserId = request.params.recipientId;
  var message = request.params.message;

  // Validate that the sender is allowed to send to the recipient.
  // For example each user has an array of objectIds of friends
  if (senderUser.get("friendIds").indexOf(recipientUserId) === -1) {
    response.error("The recipient is not the sender's friend, cannot send push.");
  }

  // Validate the message text.
  // For example make sure it is under 140 characters
  if (message.length > 140) {
  // Truncate and add a ...
    message = message.substring(0, 137) + "...";
  }

  // Send the push.
  // Find devices associated with the recipient user
  var recipientUser = new Parse.User();
  recipientUser.id = recipientUserId;
  var pushQuery = new Parse.Query(Parse.Installation);
  pushQuery.equalTo("user", recipientUser);
 
  // Send the push notification to results of the query
  Parse.Push.send({
    where: pushQuery,
    data: {
      alert: message
    }
  }).then(function() {
      response.success("Push was sent successfully.")
  }, function(error) {
      response.error("Push failed to send with error: " + error.message);
  });
});

 After you deploy this Cloud function, you can call the code from iOS like this:

[PFCloud callFunctionInBackground:@"sendPushToUser"
                   withParameters:@{@"recipientId": userObject.id, @"message": message}
                            block:^(NSString *success, NSError *error) {
  if (!error) {
     // Push sent successfully
  }
}];

And on Android:

HashMap<String, Object> params = new HashMap<String, Object>();
params.put("recipientId", userObject.getObjectId());
params.put("message", message);
ParseCloud.callFunctionInBackground("sendPushToUser", params, new FunctionCallback<String>() {
   void done(String success, ParseException e) {
       if (e == null) {
          // Push sent successfully
       }
   }
});

Now that you have moved the Push logic into Cloud Code, you can disable Client Push in your app settings, and spoil the hacker’s evil plan! We hope you learned how to use Cloud Code to secure your app’s push notifications, and that you will think twice before enabling Client Push for your app. As always, feel free to ask questions or let us know what you think on our new Help page.

Jamie
September 3, 2014

Open Sourcing the f8 Conference Apps

f8 App

 

As part of the f8 conference experience, we launched iOS and Android apps built entirely on Parse. The app enabled conference attendees to stay up-to-date with upcoming talks, get to know the speakers, and receive push notifications on talks they had marked as favorites.

This app grew out of the Parse Developer Day apps, and was thoroughly customized to match the f8 experience. Using Parse to build these apps was a fun experience, and it took one iOS and Android developer around two weeks to deliver the apps. Parse Data was used to store all the conference data and much of the User Interface (UI) customizations and assets, enabling quick iteration on design changes across iOS and Android. Even after the app was shipped, last minute updates were possible without touching code, simply by using the Data Browser. And, as talks were in session, the Push Console was used for ad hoc messaging to conference attendees–it’s vitally important to know when to pick up those T-shirts.

Today, we are releasing the source code for these apps so you can peek under the hood and see how they were built. The source code is available on GitHub. We hope they will serve as good guidance for how to build apps on Parse. We also hope others find them useful as a starting point for their own conference apps. We can’t wait to see what you do with them!

Christine Abernathy
August 28, 2014

Elex’s Age of Warring Empire Finds A Key Ally in Parse

Age of Warring Empire
As a long-standing player in China’s gaming and internet industries, Elex was founded in 2008 with a focus on developing mobile games. With partners including Baidu, Tencent, Alibaba, 7Road, and Giant Interactive, Elex has grown rapidly, rising to the forefront of game development in both Asian and Western markets.

The latest to Elex’s gaming family, Age of Warring Empire, has soared to the top of the charts, with over 20 million downloads to date. It has also charted as one of the top 30 grossing apps on Android for several consecutive months. Age of Warring Empire is supported by Parse Push, and the game is popular on both the Android and iOS platforms.

While strategy and war games are popular no matter the hemisphere, Elex decided to add yet another element of complexity to Age of Warring Empire. Beyond the basics of a strategy game, the team explored RPG elements and a top-notch player vs. player system to craft a unique experience found only in Age of Warring Empire.

These layers of complexity have attracted a strong user base, and in order to communicate directly with players, Age of Warring Empire uses Parse Push. These push notifications prove to be pivotal in gameplay, as notifications are sent when important events occur in a player’s Empire. Additionally, Age of Warring Empire is able to retain their players’ attention with a daily check-in award powered by a push notification. Competitions and flash sales are regular occurrences in the app as well, and key drivers of traffic and retention. Particular attention is paid to these events with the help of Parse Push.

As Evan Wan, producer of Age of Warring Empire, notes:

Parse is beneficial in its convenience, ease-of-use, and efficiency. Normally, it takes us more than 48 hours to acquire good data, and Parse requires less than half that time. Additionally, Parse provides us with statistical accuracy and a range of analyses.

As empires continue to flourish, and with it, the crucial importance of consistent player engagement, Age of Warring Empire can efficiently and directly communicate to players with the help of Parse Push. Age of Warring Empire is available on the App Store and the Google Play Store.

Nancy Xiao
August 22, 2014

Announcing Parse Analytics Integration with App Links

After the initial release of App Links support in the Bolts SDK, we’ve been looking for ways to enhance this support and easily provide actionable data to developers. With that in mind, we are pleased to announce Parse support for the App Links analytics hooks that are now available in the Bolts framework.

This Parse support takes App Links events and translates them into Parse Analytics custom events. You can then go to your app’s Analytics dashboard to view detailed App Links data–for example, how often an outbound App Links has been clicked or how many times your app has been opened from another App Links-enabled app.

This new open source, lightweight library is available for iOS and Android. You can simply download the jar or framework file and drop it into your project that’s already using the Bolts SDK. You can also download the source directly from GitHub. Then you can start measuring App Links events on Android as follows:

ParseAppLinksAnalytics.enableTracking(context);

To measure App Links events in iOS, add the following:

[PAAnalytics enableTracking];

You can then check out the custom events area in the Analytics dashboard and look for the following data related to your App Links usage:

AppLinksInbound: whenever traffic resulting from your App Links integration opens up your app.
AppLinksOutbound: whenever your app opens another app via an App Links integration.
AppLinksReturning: (iOS only) whenever an App Links integrated app returns the user back to your app after a previous outbound link.

Note that these events are only triggered if the App Links are constructed using the Bolts SDK.

For more information, please see the platform-specific README files on GitHub. We’d love to hear your feedback as you use the power of Parse Analytics to help fine tune your app’s integration with App Links and Bolts.

Christine Abernathy
August 21, 2014

Archives

Categories

RSS Feed Follow us Like us