Get partner licenses deployment information

Applies To

  • Partner Center

How to get partner licenses deployment information aggregated to include all customers.

Prerequisites

Credentials as described in Partner Center authentication. This scenario supports authentication with App+User credentials.

C#

To retrieve aggregated data on licenses deployment, first get an interface to partner level analytics collection operations from the IAggregatePartner.Analytics property. Then retrieve an interface to the partner level licenses analytics collection from the Licenses property. Finally, call the Deployment.Get method to get the aggregated data on licenses deployment. If the method succeeds you'll get a collection of PartnerLicensesDeploymentInsights objects.

// IAggregatePartner partnerOperations;

var partnerLicensesDeploymentAnalytics = partnerOperations.Analytics.Licenses.Deployment.Get();

Request

Request syntax

Method Request URI
GET {baseURL}/v1/analytics/licenses/deployment HTTP/1.1

Request headers

Request body

None.

Request example

GET https://api.partnercenter.microsoft.com/v1/analytics/licenses/deployment HTTP/1.1
Authorization: Bearer <token>
Accept: application/json
MS-RequestId: 25b6edd5-1f53-456b-b48c-c64f60ec2dda
MS-CorrelationId: 6492b9d6-5629-429b-934c-040b1946e760
X-Locale: en-US
Host: api.partnercenter.microsoft.com

Response

If successful, the response body contains a collection of PartnerLicensesDeploymentInsights resources that provide information about the licenses deployed.

Response success and error codes

Each response comes with an HTTP status code that indicates success or failure and additional debugging information. Use a network trace tool to read this code, error type, and additional parameters. For the full list, see Partner Center REST error codes.

Response example

HTTP/1.1 200 OK
Content-Length: 487
Content-Type: application/json; charset=utf-8
MS-CorrelationId: 6492b9d6-5629-429b-934c-040b1946e760
MS-RequestId: 25b6edd5-1f53-456b-b48c-c64f60ec2dda
MS-CV: f0trvmq8mEScHcFS.0
MS-ServerId: 102030524
Date: Tue, 14 Mar 2017 17:55:01 GMT

 {
    "totalCount": 2,
    "items": [{
            "proratedDeploymentPercent": 0.0,
            "licensesSold": 343,
            "processedDateTime": "2017-03-10T00:00:00+00:00",
            "serviceName": "crm",
            "channel": "reseller",
            "attributes": {
                "objectType": "PartnerLicensesDeploymentInsights"
            }
        }, {
            "proratedDeploymentPercent": 1.0,
            "licensesSold": 4464,
            "processedDateTime": "2017-03-14T03:25:16.36+00:00",
            "serviceName": "o365",
            "channel": "reseller",
            "attributes": {
                "objectType": "PartnerLicensesDeploymentInsights"
            }
        }
    ],
    "attributes": {
        "objectType": "Collection"
    }
}