Get error reporting data for your desktop application
Use this method in the Microsoft Store analytics API to get aggregate error reporting data for a desktop application that you have added to the Windows Desktop Application program. This method can only retrieve errors that occurred in the last 30 days. This information is also available in the Health report for desktop applications in Partner Center.
Prerequisites
To use this method, you need to first do the following:
- If you have not done so already, complete all the prerequisites for the Microsoft Store analytics API.
- Obtain an Azure AD access token to use in the request header for this method. After you obtain an access token, you have 60 minutes to use it before it expires. After the token expires, you can obtain a new one.
Request
Request syntax
Method | Request URI |
---|---|
GET | https://manage.devcenter.microsoft.com/v1.0/my/analytics/desktop/failurehits |
Request header
Header | Type | Description |
---|---|---|
Authorization | string | Required. The Azure AD access token in the form Bearer <token>. |
Request parameters
Parameter | Type | Description | Required |
---|---|---|---|
applicationId | string | The product ID of the desktop application for which you want to retrieve error reporting data. To get the product ID of a desktop application, open any analytics report for your desktop application in Partner Center (such as the Health report) and retrieve the product ID from the URL. | Yes |
startDate | date | The start date in the date range of error reporting data to retrieve, in the format mm/dd/yyyy . The default is the current date.Note: This method can only retrieve errors that occurred in the last 30 days. |
No |
endDate | date | The end date in the date range of error reporting data to retrieve, in the format mm/dd/yyyy . The default is the current date. |
No |
top | int | The number of rows of data to return in the request. The maximum value and the default value if not specified is 10000. If there are more rows in the query, the response body includes a next link that you can use to request the next page of data. | No |
skip | int | The number of rows to skip in the query. Use this parameter to page through large data sets. For example, top=10000 and skip=0 retrieves the first 10000 rows of data, top=10000 and skip=10000 retrieves the next 10000 rows of data, and so on. | No |
filter | string | One or more statements that filter the rows in the response. Each statement contains a field name from the response body and value that are associated with the eq or ne operators, and statements can be combined using and or or. String values must be surrounded by single quotes in the filter parameter. You can specify the following fields from the response body:
|
No |
aggregationLevel | string | Specifies the time range for which to retrieve aggregate data. Can be one of the following strings: day, week, or month. If unspecified, the default is day. If you specify week or month, the failureName and failureHash values are limited to 1000 buckets. | No |
orderby | string | A statement that orders the result data values. The syntax is orderby=field [order],field [order],.... The field parameter can be one of the following strings:
Here is an example orderby string: orderby=date,market |
No |
groupby | string | A statement that applies data aggregation only to the specified fields. You can specify the following fields:
The returned data rows will contain the fields specified in the groupby parameter as well as the following:
The groupby parameter can be used with the aggregationLevel parameter. For example: &groupby=failureName,market&aggregationLevel=week |
No |
Request example
The following examples demonstrate several requests for getting error reporting data. Replace the applicationId value with the product ID for your desktop application.
GET https://manage.devcenter.microsoft.com/v1.0/my/analytics/desktop/failurehits?applicationId=10238467886765136388&startDate=1/1/2018&endDate=2/1/2018&top=10&skip=0 HTTP/1.1
Authorization: Bearer <your access token>
GET https://manage.devcenter.microsoft.com/v1.0/my/analytics/desktop/failurehits?applicationId=10238467886765136388&startDate=8/1/2017&endDate=8/31/2017&skip=0&filter=market eq 'US' and deviceType eq 'PC' HTTP/1.1
Authorization: Bearer <your access token>
Response
Response body
Value | Type | Description |
---|---|---|
Value | array | An array of objects that contain aggregate error reporting data. For more information about the data in each object, see the error values section below. |
@nextLink | string | If there are additional pages of data, this string contains a URI that you can use to request the next page of data. For example, this value is returned if the top parameter of the request is set to 10000 but there are more than 10000 rows of errors for the query. |
TotalCount | integer | The total number of rows in the data result for the query. |
Error values
Elements in the Value array contain the following values.
Value | Type | Description |
---|---|---|
date | string | The first date in the date range for the error data, in the format yyyy-mm-dd . If the request specifies a single day, this value is that date. If the request specifies a longer date range, this value is the first date in that date range. For requests that specify an aggregationLevel value of hour, this value also includes a time value in the format hh:mm:ss . |
applicationId | string | The product ID of the desktop application for which you retrieved error data. |
productName | string | The display name of the desktop application as derived from the metadata of its associated executable(s). |
appName | string | TBD |
fileName | string | The name of the executable file for the desktop application. |
failureName | string | The name of the failure, which is made up of four parts: one or more problem classes, an exception/bug check code, the name of the image where the failure occurred, and the associated function name. |
failureHash | string | The unique identifier for the error. |
symbol | string | The symbol assigned to this error. |
osBuild | string | The four-part build number of the OS on which the error occurred. |
osVersion | string | One of the following strings that specifies the OS version on which the desktop application is installed:
|
osRelease | string | One of the following strings that specifies the OS release or flighting ring (as a subpopulation within OS version) on which the error occurred. For Windows 11: Version 2110 For Windows 10:
For Windows Server 1709:
For Windows Server 2016:
For Windows 8.1:
For Windows 7:
If the OS release or flighting ring is unknown, this field has the value Unknown. |
eventType | string | One of the following strings that indicates the type of error event:
|
market | string | The ISO 3166 country code of the device market. |
deviceType | string | One of the following strings that specifies the type of device on which the error occurred:
|
applicationVersion | string | The version of the application executable in which the error occurred. |
eventCount | number | The number of events that are attributed to this error for the specified aggregation level. |
Response example
The following example demonstrates an example JSON response body for this request.
{
"Value": [
{
"date": "2018-02-01",
"applicationId": "10238467886765136388",
"productName": "Contoso Demo",
"appName": "Contoso Demo",
"fileName": "contosodemo.exe",
"failureName": "SVCHOSTGROUP_localservice_IN_PAGE_ERROR_c0000006_hardware_disk!Unknown",
"failureHash": "11242ef3-ebd8-d525-838d-b5497b225695",
"symbol": "hardware_disk!Unknown",
"osBuild": "10.0.15063.850",
"osVersion": "Windows 10",
"osRelease": "Version 1703",
"eventType": "crash",
"market": "US",
"deviceType": "PC",
"applicationVersion": "2.2.2.0",
"eventCount": 0.0012422360248447205
}
],
"@nextLink": "desktop/failurehits?applicationId=10238467886765136388&aggregationLevel=week&startDate=2018/02/01&endDate2018/02/08&top=1&skip=1",
"TotalCount": 21
}