Share via


Windows Phone API reference

July 21, 2014

Applies to: Windows Phone 8 and Windows Phone Silverlight 8.1 only

This topic provides an overview of the Windows Phone API.

The Windows Phone SDK lets you build apps using a variety of languages and tools. You can build your app using XAML and your choice of managed language, which allows you to maintain your investments from existing apps. To provide greater flexibility and performance, Windows Phone 8 introduces the ability to use C++ within your XAML app and in games written using Direct3D. The Windows Phone API Reference node encompasses the complete set of API available on Windows Phone 8. The following diagram illustrates the set of APIs that make up the Windows Phone API.

Important Note:

Windows Phone provides a capabilities-driven security model where a user must opt-in to certain functionality within the app. When using the Windows Phone API, you should determine what capabilities are required by your app and enable them in the app manifest file. For more information on capabilities and hardware requirements, see App manifest file for Windows Phone 8.

This topic contains the following sections.

.NET API for Windows Phone

The .NET API represents the managed API on Windows Phone 8. This will be familiar to you if you have built apps for Windows Phone OS 7.1. The .NET API contains classes and types from the System and Microsoft.Phone namespaces. We’ve added functionality for Windows Phone 8, including Microsoft.Phone.Wallet, the ShareMediaTask, Lock screen for Windows Phone 8 enhancements and lots, lots more.

For more information, see .NET API for Windows Phone.

Windows Phone Runtime API

Windows Phone Runtime is a subset of native API that is built into the operating system. It is implemented in C++ and projected into C#, VB.NET, and C++, making it easy for you to consume naturally in the language of your choice. Developers that are familiar with the Windows Runtime will find the Windows Phone Runtime easy to learn. The frameworks are very similar. The following diagram shows the relationship between Windows Phone Runtime and Windows Runtime in terms of the API surface area it implements.

The diagram has three distinct areas and these are described as follows:

  1. The set of Windows Runtime API not supported on Windows Phone 8. The API surface area of Windows Runtime is very large, with over 11,000 members. We’ve adopted a subset for Windows Phone 8 that allows you to build compelling phone scenarios. Area 1 in the diagram above represents the APIs that are not available on Windows Phone 8.

  2. The set of Windows Runtime API adopted for Windows Phone 8. This is represented by area 2 in the above diagram and consists of approximately 2,800 members. For some types, we have not implemented certain members. For others we have added additional members to support phone-only features. In both cases, these differences are noted in the API reference documentation.

  3. We’ve added key APIs needed to build great apps for the phone. These are represented by area 3 in the diagram and total about 600 members. For example, we have brand-new APIs for speech synthesis and recognition, VOIP, and other features. Creating these as Windows Runtime style APIs means you can use them regardless of the programming language you use for your app.

The Windows Phone Runtime API consists of areas 2 and 3 in the above diagram. For more information, see Windows Phone Runtime API.

Win32 and COM API for Windows Phone

In addition to these APIs, you have access to some Win32 APIs that give you access to low-level features of the platform. This includes Winsock API for low-level networking. For more information, see Win32 and COM API for Windows Phone 8.

Supported languages

The following table shows what programming languages are supported in Windows Phone compared toWindows 8. Whether your development background is with native or managed code, you can build great apps for Windows Phone using your language of choice. JavaScript is not supported on Windows Phone 8.

See Also

Other Resources

Windows Phone API QuickStart Poster (PDF)