Skip to content

Commit 61b89ac

Browse files
Kbridge/main/device capabilities update for wasdk (#6474)
* Freshness update: enable-device-capabilities.md for Windows App SDK - Update title and description to be platform-neutral ('Windows app' vs 'UWP app') - Add keywords for windows 11, winui, windows app sdk - Add Windows App SDK note explaining shared capability model for packaged apps - Add new 'Windows App SDK considerations' section covering packaged, unpackaged, and WinRT API usage - Replace 'your UWP app' with 'your app' in Bluetooth RFCOMM description - Update ms.date to 03/18/2026 Co-authored-by: Copilot <[email protected]> * more ai suggestions and human refinements --------- Co-authored-by: Copilot <[email protected]>
1 parent f821e24 commit 61b89ac

1 file changed

Lines changed: 19 additions & 27 deletions

File tree

Lines changed: 19 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,33 @@
11
---
22

33
title: Enable device capabilities
4-
description: This topic explains how to declare device capabilities in Microsoft Visual Studio to use cameras, microphones, location sensors, and other devices for a UWP app.
5-
ms.date: 05/04/2023
4+
description: This topic explains how to declare device capabilities in Microsoft Visual Studio to use cameras, microphones, location sensors, and other devices in a Windows app.
5+
ms.date: 03/18/2026
66
ms.topic: article
7-
7+
keywords: windows 10, windows 11, uwp, winui, windows app sdk, device capabilities
88
ms.localizationpriority: medium
99
---
1010

11-
# Enable device capabilities for a Universal Windows Platform app
11+
# Enable device capabilities for a Windows app
12+
13+
This topic explains how to declare device capabilities in Microsoft Visual Studio when using cameras, microphones, location sensors, and other devices in a Windows app.
1214

13-
This topic explains how to declare device capabilities in Microsoft Visual Studio to use cameras, microphones, location sensors, and other devices for a Universal Windows Platform (UWP) app.
15+
> [!NOTE]
16+
> Not all devices (such as printers and scanners) need to be declared in the app package manifest.
1417
1518
## Specify the device capabilities your app will use
1619

17-
Windows apps require you to specify in the app package manifest when you use certain types of devices. In Visual Studio, you can declare most capabilities by using [Manifest Designer](/visualstudio/extensibility/vsix-manifest-designer) or you can add them manually as described in [How to specify device capabilities in a package manifest (manually)](/uwp/schemas/appxpackage/how-to-specify-device-capabilities-in-a-package-manifest). This tutorial assumes you're using Manifest Designer.
20+
You must declare in the app package manifest specific types of devices being used by your app. In Visual Studio, you can declare most using the [Manifest Designer](/visualstudio/extensibility/vsix-manifest-designer) or you can add them manually as described in [How to specify device capabilities in a package manifest (manually)](/uwp/schemas/appxpackage/how-to-specify-device-capabilities-in-a-package-manifest). This tutorial uses the Manifest Designer.
1821

1922
> [!NOTE]
20-
> Some types of devices, such as printers, scanners, and sensors, don't need to be declared in the app package manifest.
23+
> For Windows App SDK (WinUI 3) packaged apps, device capabilities are declared in the same **Package.appxmanifest** file using the same capability elements as UWP apps. The device capability model is shared across both platforms.
2124
2225
- In Visual Studio Solution Explorer, double-click the package manifest file, **Package.appxmanifest**.
2326
- Open the **Capabilities** tab.
2427
- Select the device capabilities that your app uses. If you don't see the capability you're looking for in Manifest Designer, add it manually. For more info, see [How to specify device capabilities in a package manifest](/uwp/schemas/appxpackage/how-to-specify-device-capabilities-in-a-package-manifest).
2528

2629
| Device Capability | Manifest Designer | Description |
2730
|-------------------|-------------------|-------------|
28-
| AllJoyn | ![Available in Manifest Designer](images/ap-tools.png) | Allows AllJoyn-enabled apps and devices on a network to discover and interact with each other. App apps that access APIs in the [**Windows.Devices.AllJoyn**](/uwp/api/Windows.Devices.AllJoyn) namespace must use this capability. |
2931
| Blocked Chat Messages | ![Available in Manifest Designer](images/ap-tools.png) | Allows apps to read SMS and MMS messages that have been blocked by the Spam Filter app. |
3032
| Chat Message Access | ![Available in Manifest Designer](images/ap-tools.png) | Allows apps to read and delete Text Messages. It also allows apps to store chat messages in the system data store. |
3133
| Code Generation | ![Available in Manifest Designer](images/ap-tools.png) | Allows apps to generate code dynamically. |
@@ -38,34 +40,24 @@ Windows apps require you to specify in the app package manifest when you use cer
3840
| Objects 3D | ![Available in Manifest Designer](images/ap-tools.png) | Provides programmatic access to the user's **3D Objects**, allowing the app to enumerate and access all files in the library without user interaction. This capability is typically used in 3D apps and games that need to access the entire **3D Objects** library. |
3941
| Phone Call | ![Available in Manifest Designer](images/ap-tools.png) | Allows apps to access all of the phone lines on the device and perform the following functions: place a call on the phone and show the system dialer without prompting the user; access line-related metadata; access line-related triggers. Allows the user-selected spam filter app to set and check the block list and call origin information. |
4042
| Pictures Library | ![Available in Manifest Designer](images/ap-tools.png) | Provides the capability to add, change, or delete files in the **Pictures Library** for the local PC and **HomeGroup** PCs. |
41-
| Point of Service | ![Available in Manifest Designer](images/ap-tools.png) | Provides access to Point of Service peripherals. This capability is required to access APIs in the [**Windows.Devices.PointOfService**](/uwp/api/Windows.Devices.PointOfService) namespace. |
43+
| Point of Service | ![Available in Manifest Designer](images/ap-tools.png) | Provides access to Point of Service peripherals. |
4244
| Private Networks (Client &amp; Server) | ![Available in Manifest Designer](images/ap-tools.png) | Provides inbound and outbound access to Intranet networks that have an authenticated domain controller, or that the user has designated as either home or work networks. Inbound access to critical ports is always blocked. |
4345
| Proximity | ![Available in Manifest Designer](images/ap-tools.png) | Provides the capability to connect to devices in close proximity to the PC via near-field communication (NFC). Near-field proximity may be used to send files or communicate with an app on the nearby device. |
4446
| Removable Storage | ![Available in Manifest Designer](images/ap-tools.png) | Provides the capability to add, change, or delete files on removable storage devices. The app can only access the file types on removable storage that are defined in the manifest using the **File Type Associations** declaration. The app can't access removable storage on **HomeGroup** PCs. |
4547
| Shared User Certificates | ![Available in Manifest Designer](images/ap-tools.png) | This capability is subject to the Microsoft Store policy. It provides the capability to access software and hardware certificates, such as smart card certificates, for validating a user's identity. When related APIs are invoked at runtime, the user must take action (insert card, select certificate, etc.). This capability is not necessary if your app includes a private certificate via a **Certificates** declaration. |
46-
| User Account Information | ![Available in Manifest Designer](images/ap-tools.png) | Gives apps the ability to access the user's name and picture. This capability is required to access some APIs in the [**Windows.System.UserProfile**](/uwp/api/Windows.System.UserProfile) namespace. |
48+
| User Account Information | ![Available in Manifest Designer](images/ap-tools.png) | Gives apps the ability to access the user's name and picture. |
4749
| Videos Library | ![Available in Manifest Designer](images/ap-tools.png) | Provides the capability to add, change, or delete files in the **Videos Library** for the local PC and **HomeGroup** PCs. |
48-
| VOIP Calling | ![Available in Manifest Designer](images/ap-tools.png) | Allows apps to access the VOIP calling APIs in the [**Windows.ApplicationModel.Calls**](/uwp/api/Windows.ApplicationModel.Calls) namespace. |
50+
| VOIP Calling | ![Available in Manifest Designer](images/ap-tools.png) | Allows apps to access the VOIP calling APIs. |
4951
| Webcam | ![Available in Manifest Designer](images/ap-tools.png) | Provides access to the built-in camera or attached webcam's video feed. This allows the app to capture snapshots and movies. |
5052
| USB | | Provides access to custom USB devices. This capability requires child elements. This feature is not supported on Windows Phone. |
5153
| Human Interface Device (HID) | | Provides access to Human Interface Devices (HID). This capability requires child elements. For more info, see [How to specify device capabilities for HID](/uwp/schemas/appxpackage/how-to-specify-device-capabilities-for-hid). |
5254
| Bluetooth GATT | | Provides access to Bluetooth LE devices through a collection of primary services, included services, characteristics, and descriptors. This capability requires child elements. For more info, see [How to specify device capabilities for Bluetooth](/uwp/schemas/appxpackage/how-to-specify-device-capabilities-for-bluetooth). |
53-
| Bluetooth RFCOMM | | Provides access to APIs that support the Basic Rate/Extended Data Rate (BR/EDR) transport and also lets your UWP app access a device that implements Serial Port Profile (SPP). This capability requires child elements. For more info, see [How to specify device capabilities for Bluetooth](/uwp/schemas/appxpackage/how-to-specify-device-capabilities-for-bluetooth). |
55+
| Bluetooth RFCOMM | | Provides access to APIs that support the Basic Rate/Extended Data Rate (BR/EDR) transport and also lets your app access a device that implements Serial Port Profile (SPP). This capability requires child elements. For more info, see [How to specify device capabilities for Bluetooth](/uwp/schemas/appxpackage/how-to-specify-device-capabilities-for-bluetooth). |
5456

55-
## Use the Windows Runtime API for communicating with your device
57+
## Windows App SDK considerations
5658

57-
The following table connects some of the capabilities to Windows Runtime APIs.
59+
When using the Windows App SDK, keep the following in mind regarding device capabilities:
5860

59-
| Device Capability | API |
60-
|--------------------------|-----------------|
61-
| AllJoyn | [**Windows.Devices.AllJoyn**](/uwp/api/Windows.Devices.AllJoyn) |
62-
| Blocked Chat Messages | [**Windows.ApplicationModel.CommunicationBlocking**](/uwp/api/Windows.ApplicationModel.CommunicationBlocking) |
63-
| Location | See [Maps and location overview](../maps-and-location/index.md) for more information. |
64-
| Phone Call | [**Windows.ApplicationModel.Calls**](/uwp/api/Windows.ApplicationModel.Calls) |
65-
| User Account Information | [**Windows.System.UserProfile**](/uwp/api/Windows.System.UserProfile) |
66-
| VOIP Calling | [**Windows.ApplicationModel.Calls**](/uwp/api/Windows.ApplicationModel.Calls) |
67-
| USB | [**Windows.Devices.Usb**](/uwp/api/Windows.Devices.Usb) |
68-
| HID | [**Windows.Devices.HumanInterfaceDevice**](/uwp/api/Windows.Devices.HumanInterfaceDevice) |
69-
| Bluetooth GATT | [**Windows.Devices.Bluetooth.GenericAttributeProfile**](/uwp/api/Windows.Devices.Bluetooth.GenericAttributeProfile) |
70-
| Bluetooth RFCOMM | [**Windows.Devices.Bluetooth.Rfcomm**](/uwp/api/Windows.Devices.Bluetooth.Rfcomm) |
71-
| Point of Service | [**Windows.Devices.PointOfService**](/uwp/api/Windows.Devices.PointOfService) |
61+
- **Packaged apps**: Device capabilities are declared in `Package.appxmanifest` the same way as UWP apps. The capability names and XML elements are identical.
62+
- **Unpackaged apps**: Unpackaged Windows App SDK apps do not use an app package manifest. Instead, device access is governed by OS-level permissions and user consent prompts at runtime. No capability declarations are needed, but users may still be prompted to grant access (for example, for camera or microphone).
63+
- **Windows Runtime APIs**: The Windows Runtime device APIs (such as `Windows.Devices.Bluetooth`, `Windows.Devices.Usb`, and `Windows.Media.Capture`) are available to both UWP and Windows App SDK apps. You can call these APIs directly from WinUI 3 projects.

0 commit comments

Comments
 (0)