A new perspective on mobile app development: Building cognitive mobile apps with Realm and Watson

By Adam Fish and contributed by Prashant Khanal

Most companies today are looking for new ways to engage customers, partners or employees where they are most active: on mobile. They recruit highly specialized mobile app development professionals to build modern apps that are performant, snappy and deliver great user experiences. As they mobilize the business, app developers use APIs to transfer data between core legacy systems and the apps. However, they end up spending way too much time writing code that handles complexity around data transfer and API communications. This detracts from focusing their talent on what they do best: developing a user interface/user experience users will love.

Realm takes a fundamentally different approach to APIs. The Realm Mobile Platform enables API mobilization that simplifies the mobile app stack and shifts the burden of API communication from the app to the Realm platform. This essentially abstracts away all API handling for the mobile developer, who instead works with always-up-to-date data as “live objects” — genuine data objects that Realm seamlessly and automatically synchronizes in real-time on the server and across all devices.

Sign up for our newsletter
Stay on top of the latest mobile news and insights.

To showcase API mobilization, IBM recently collaborated with Realm to build a cognitive demo app with the Realm Mobile Platform. The Scanner app enables users to take a photo of any item, send it to the Watson service and return a response that identifies the item. Rather than have the client device directly call the Watson API, the photo is stored on devices in the Realm Mobile Database and then automatically synced with the Realm Object Server. The server handles API management on behalf of the app by using event handling to call IBM Watson’s Visual Recognition API. The Watson service on the back end processes and classifies the image and returns a result. This entire pattern moves the complexity of API management to the server and automates the synchronization between device and server.

The Realm Object Server makes transferring data between apps and legacy systems much more reliable. It removes API failure opportunities by handling API calls on the server side rather than across unpredictable mobile networks. Mobile developers no longer have to worry about building resilience for multiple clients or managing latency issues. Realm liberates the developer from having to write massive amounts of code to handle API integration, failure scenarios, JSON decoding and other tasks that are ancillary to the mobile experience. This allows mobile app development teams to focus on building a great app experience.

To explore the Scanner application, its code (Swift and Android) and a tutorial are available for free as an open-source project.

Written By

Adam Fish

Senior Director of Product at Realm

Adam is the Senior Director of Product at Realm, where he manages the product development for all mobile platforms with Realm Mobile Database and server development with Realm Object Server. He has a deep background in entrepreneurship and software development, having previously co-founded…