Create Microsoft Store apps via Graph API
Published: March 02, 2023 | Author: René Laas
The purpose of this blog post is to inform you how to create Microsoft Store apps (new method) via Graph API.
Intune is a service that allows organizations easily distribute and manage apps for their Windows devices. Previously, with Microsoft Store for Business and Education, IT administrators can purchase apps and other digital content in bulk and distribute them to managed devices using Microsoft Intune. With the new Store method in Intune and the upcoming deprecation of the Microsoft Store for business, you as an Intune admin must add the Microsoft Store app now via a different method in Intune.
I will explain in this blog how to create Microsoft store apps via Graph API to automate the creation of the apps.
Requirements:
New Microsoft Store integration within Intune
As of December 2, 2022, it is possible to search, browse, configure, and deploy Microsoft Store apps within Intune. The new Microsoft Store app type is implemented using the Windows Package Manager (WinGet). This app type features an expanded catalog of apps, which includes both UWP apps and Win32 apps.
For more information about the new Microsoft Store apps, see Add Microsoft Store apps to Microsoft Intune.
Microsoft Store for Business deprecation
As of June 30, 2020, Microsoft announced the deprecation of the Microsoft Store for Business and Education, and at the end of Q1 2023, the service will be fully retired. This means that any existing apps, app licenses, and app installers that have been acquired through the service will no longer be available for download, and any devices that are enrolled in the service will no longer be able to install or update apps.
The decision to deprecate the Microsoft Store for Business and Education is due to Microsoft’s focus on modern management and app deployment models, such as Microsoft Endpoint Manager and the Microsoft Store for Business and Education APIs. Microsoft recommends that organizations migrate to these newer solutions to continue managing their Microsoft apps.
Graph API
The Microsoft Graph API provides a set of RESTful endpoints that enable developers to access and manipulate data in Microsoft Intune, a cloud-based service that enables organizations to manage and secure their mobile devices and apps. With the Graph API, administrators can get, create, update, and delete Intune resources such as devices, apps, policies, and profiles.
Administrators can use the Graph API to perform their tasks in Intune, such as retrieving device inventory information, deploying apps and profiles to devices, configuring device compliance policies, and managing device actions like wiping or locking a device. In summary, the Microsoft Graph API provides a powerful and flexible tool for administrators.
Commonly used Microsoft Store Apps
Displayname | Package Identifier |
---|---|
3D viewer | 9NBLGGH42THS |
Company Portal | 9WZDNCRFJ3PZ |
Feedback Hub | 9NBLGGH4R32N |
Kiosk Browser | 9NGB5S5XG2KP |
Mail and Calendar | 9WZDNCRFHVQM |
Microsoft 365 (Office) | 9WZDNCRD29V9 |
Microsoft Authenticator | 9NBLGGGZMCJ6 |
Microsoft Messaging | 9WZDNCRFJBQ6 |
Microsoft News | 9WZDNCRFHVFW |
Microsoft People | 9NBLGGH10PG8 |
Microsoft Photos | 9WZDNCRFJBH4 |
Microsoft Sticky Notes | 9NBLGGH4QGHW |
Microsoft Tips | 9WZDNCRDTBJJ |
Microsoft To Do | 9NBLGGH5R558 |
Microsoft Whiteboard | 9MSPC6MP8FM4 |
Mixed Reality Portal | 9NG1H8B3ZC7M |
Mobile Plans | 9NBLGGH5PNB1 |
Movies & TV | 9WZDNCRFJ3P2 |
MSN Money | 9WZDNCRFHV4V |
MSN Weather | 9WZDNCRFJ3Q2 |
Network Speed Test | 9WZDNCRFHX52 |
OneDrive | 9WZDNCRFJ1P3 |
OneNote for Windows 10 | 9WZDNCRFHVJL |
Paint 3D | 9NBLGGH5FV99 |
Phone Link | 9NMPJ99VJBWV |
Power Apps | 9MVC8P1Q3B29 |
Power Automate | 9NFTCH6J7FHV |
Power BI Desktop | 9NTXR16HNW1T |
Quick Assist | 9P7BP5VNWKX5 |
Skype | 9WZDNCRFJ364 |
Snipping Tool | 9MZ95KL8MR0L |
Surface | 9WZDNCRFJB8P |
Sway | 9WZDNCRD2G0J |
Windows Maps | 9WZDNCRDTBVB |
Windows Media Player | 9WZDNCRFJ3PT |
Windows Sound Recorder | 9WZDNCRFHWKN |
Windows Terminal | 9N0DX20HK701 |
Xbox Console Companion | 9WZDNCRFJBD8 |
Xbox Game Bar | 9NZKPSTSNW4P |
How to get Microsoft Store apps via Graph API
- Open Graph Explorer
- Click on the user icon at the top of the page
- Login with your admin account
- In the middle of the screen, you will find the Graph URL bar with the following URL
https://graph.microsoft.com/v1.0/me
- Replace the above URL with the following URL
https://graph.microsoft.com/beta/deviceAppManagement/mobileApps?$filter=(isof('microsoft.graph.winGetApp')
- Click on Run query, you will get all the new Windows Store Apps back when you have already added a new Microsoft Store App. If you have not added a new Microsoft Store App, then your returning array is empty.
How to create Microsoft Store apps via Graph API
- Open Graph Explorer
- Click on the user icon at the top of the page
- Login with your admin account
- In the middle of the screen, you will find the Graph URL bar with the following URL
https://graph.microsoft.com/v1.0/me
- Replace the above URL with the following URL
https://graph.microsoft.com/beta/deviceAppManagement/mobileApps
- Change the dropdown before the URL from GET to POST
- Add the following code to the request body
{
"@odata.type": "#microsoft.graph.winGetApp",
"displayName": "Microsoft To Do: Lists, Tasks & Reminders",
"packageIdentifier": "9WZDNCRD2G0J",
"installExperience": {
"runAsAccount": "user"
}
}
- Click on Run query, You will get a created 201 response action from the Graph API.
- The new Microsoft Store App is created and available in the app overview in Intune
Note. Check my blog post about multiple GRAPH API requests in one HTTP Call to add multiple Microsoft Store apps to Intune
Leave a Reply
Want to join the discussion?Feel free to contribute!