The web's reading platform.

New Developer Tools in Readability for iOS

Readability 1.2.2 for iOS is available now. Along with minor bug fixes, it introduces new developer tools to easily invoke actions from third-party apps. Using one of the options below, you can launch the Readability app and prompt the user to add an article to their reading list.

Option 1: URL Scheme

Readability now includes the readability:// URL scheme, which can launch the app from a browser link or using the UIApplication:openURL: method. Use it without parameters to simply launch the app, or use the following format with a URL string to prompt the user to add an article to their reading list:

readability://add/{url}

Option 2: iOS 6 UIActivity

iOS 6 introduced the “share sheet”—a simple native interface to launch actions. We’ve created a custom UIActivity that you can integrate into your app. Simply import the ReadabilityActivity class and icons to your project and wire it up:

// init Readability activity
ReadabilityActivity *rdb = [[ReadabilityActivity alloc] init];


// set up activity item / action. url is a NSURL
NSArray *activityItems = @[ReadabilityActivityAdd, url];


// init share sheet with app-specific activity
UIActivityViewController *shareSheet = [[UIActivityViewController alloc] initWithActivityItems:activityItems applicationActivities:@[rdb]];


// present the view controller, animated.
[self presentViewController:shareSheet
animated:YES
completion:^{
}];

The ReadabilityActivity class also includes an easy way to check that Readability is installed on a device. This method returns YES if the user is running Readability 1.2.2 or newer:

[ReadabilityActivity canPerformActivity]

A more comfortable developer experience

The Readability API has been integrated by thousands of developers into their projects. Now it’s even easier to add Readability actions to your iOS app. Enjoy!

Brendan is an associate at Teehan+Lax and the lead developer of Readability for iOS. You can follow him on Twitter, or see what else he's up to via BrendanLynch.com.

2 Responses »

  1. Thanks for bringing that to our attention. We’ll look into it.