Chapter 9. Service Integration Using URL Protocols


  • Make phone calls and send SMS messages

  • Send e-mails

  • Use GoogleMaps in your apps

Certainly, one of the most potentially exciting aspects of an application that is written specifically for Android or iPhone is the ability to integrate your app with mobile services, such as phone, e-mail, and Google Maps. After all, if you can do so, you break out of the solo application silo and extend its reach across mobile devices.

There's two types of integration that's possible: through AIR API and through URL protocols. Using the AIR API, you can directly access Camera, Camera Roll, and Microphone for Android devices. I'll cover that in Chapter 10. (As of the time of writing, iOS devices do not provide support for Camera, CameraRoll, and Microphone.)

Other Android and iOS services don't have direct API access through AS3. As a result, you need to use a special set of URLs to integrate with these services. I'll cover how to do this in this chapter.

This chapter shows you how to integrate your app with Android and iOS services using URL protocols for the following services:

  • Phone

  • SMS

  • Mail

  • Google Maps

At the same time, it demonstrates how to add an ActionScript wrapper around these protocols to provide your own custom-made AS3 API for Android and iPhone Services.


Rather than work directly with URL protocols in my application code, I decided that I'd rather create a set of classes that can be called. What's more, ...

Get Professional Flash® Mobile Development: Creating Android™ and iPhone® Applications now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.