Discover location and CSP tenants

This article describes how to retrieve the Partner Local Accounts (PLAs) and Cloud Solution Provider (CSP) tenant accounts associated with a Partner Global Account (PGA).

Prerequisites

Before you call the API:

  • You must be an Account admin of the PGA.
  • You must have the PGA's Microsoft Entra tenant ID.
  • You must have the PGA's Partner ID (also known as MPN ID).
  • You must register and authorize your application for the API.

The Account admin role requirement is effective May 7, 2026.

Get PLAs and CSP tenants associated with a PGA

Use the following request to retrieve the PGA, its associated PLAs, and its CSP tenant accounts:

GET {base-url}/accountenrollments/v1/pgatocspmapping?tenantId={tenant-id}&mpnId={mpn-id}
Authorization: Bearer {access-token}

URI parameters

Parameter Required Type Description
tenantId Yes GUID Microsoft Entra tenant ID of the PGA.
mpnId Yes String Partner ID of the PGA.

The tenantId and mpnId values must resolve to the same valid PGA.

Example request

GET {base-url}/accountenrollments/v1/pgatocspmapping?tenantId=aaaabbbb-0000-cccc-1111-dddd2222eeee&mpnId=7654321
Authorization: Bearer eyJ...
Accept: application/json

Response

A successful request returns 200 OK.

{
  "partnerGlobalAccount": {
    "accountId": "pga-account-456",
    "mpnId": "7654321",
    "accountName": "Partner Global Account",
    "status": "Active",
    "tenantId": "aaaabbbb-0000-cccc-1111-dddd2222eeee",
    "legalEntityCid": "legal-entity-789"
  },
  "partnerLocalAccounts": [
    {
      "accountId": "pla-account-101",
      "mpnId": "1111111",
      "accountName": "Partner Local Account 1",
      "status": "Active",
      "tenantId": "11111111-1111-1111-1111-111111111111",
      "legalEntityCid": "legal-entity-101"
    }
  ],
  "cspAccounts": [
    {
      "accountId": "csp-account-123",
      "tenantId": "12345678-1234-1234-1234-123456789012",
      "baId": "01234567-89ab-cdef-93ce-43cf48240123:89abcdef-162e-4c31-b715-1405de6d0123_2019-05-31",
      "baName": "Contoso CSP Billing Account",
      "programId": "a437af94-b2fa-4350-bca7-b5691825fbee",
      "programType": "Reseller",
      "status": "Active",
      "mpnId": "1111111"
    }
  ]
}

Response properties

partnerGlobalAccount

Property Type Description
accountId String PGA account identifier.
mpnId String Partner ID of the PGA.
accountName String or null Name of the PGA account.
status String Enrollment status.
tenantId GUID Microsoft Entra tenant ID of the PGA.
legalEntityCid String Legal-entity identifier.

partnerLocalAccounts

An array of PLA accounts associated with the PGA.

Property Type Description
accountId String PLA account identifier.
mpnId String Partner ID of the PLA.
accountName String Name of the PLA account.
status String Enrollment status.
tenantId GUID Microsoft Entra tenant ID associated with the PLA.
legalEntityCid String Legal-entity identifier.

cspAccounts

An array of CSP tenant accounts associated with the PGA.

Property Type Description
accountId String CSP account identifier.
tenantId GUID Microsoft Entra tenant ID of the CSP account.
baId String Billing account identifier.
baName String Billing account name.
programId GUID Identifier of the CSP enrollment program.
programType String CSP enrollment type.
status String Enrollment status.
mpnId String Associated partner MPN ID.

CSP program identifiers

Program ID Program name
DC50B011-5400-415A-BE11-F17F8423B3F4 Direct provider/Distributor
811534CF-5C2E-42B5-8161-8493A8777147 ResellerChina
112CEEB7-AD19-49B3-86D1-2B04287004BF ResellerNationalCloud
A437AF94-B2FA-4350-BCA7-B5691825FBEE Indirect reseller
1E65FD75-FEA1-40D4-AFC3-16D0D0DFE1C7 ValueAddedResellerPartnerNetwork

Error handling

The service returns errors using the following shape:

{
  "code": "<error-code>",
  "description": "<human-readable message>",
  "data": [],
  "source": "PartnerAccountEnrollmentApi"
}
HTTP status Error Description
400 MissingInput A required query parameter is missing.
400 InvalidInput A parameter has an invalid format, or tenantId and mpnId resolve to different PGAs.
401 Unauthorized The Microsoft Entra access token is missing or invalid.
403 Forbidden The calling application isn't authorized.
404 NotFound The supplied identifiers don't resolve to a valid PGA.
500 InternalServerError An unexpected service failure occurred.

See also