Microsoft Subscription Reconciliation

Quickly reconcile Pax8 and Microsoft subscription quantities. This guide details a workaround to map Pax8 company and product identifiers to their Microsoft Tenant and Graph API SKU counterparts, addressing the current lack of direct Microsoft subscription ID exposure in the Pax8 Subscription API.

References:


Prerequisites

  • Pax8 API access.
  • Microsoft Graph API access with necessary permissions (e.g., Organization.Read.All).
  • Familiarity with REST APIs (Pax8 & Microsoft Graph).
  • The Microsoft Product Reference CSV (downloadable from the "Microsoft SKU Info" link above).

Reconciliation Steps

Step 1: Map Pax8 Company to Microsoft Tenant ID

  1. Fetch Pax8 Company Details:
    Use GET /v1/companies/{companyId} (Pax8 API).
  2. Identify Tenant ID:
    The externalId field in the response can be used to map to the Microsoft Tenant ID.

Step 2: Map Pax8 Product to Microsoft Graph API SKU

  1. Get Pax8 Product Name:
    From the Pax8 Product API (GET /v1/products or /v1/products/{productId}), note the product name (e.g., "Microsoft 365 Business Standard").
  2. Use Microsoft's Reference CSV:
    • Download the CSV from the "Microsoft SKU Info" link.
    • Find the Pax8 product name in the CSV's Product_Display_Name column.
    • From that matching row, retrieve the GUID. This GUID is the skuId used by the Graph API.

Step 3: Reconcile Subscription Quantities

  1. Get Pax8 Quantity:
    Note the subscription quantity from Pax8 for the specific product and company. You can use the Pax8 subscriptions endpoint to pull subscription quantities.

  2. Query Microsoft Graph API:
    Call GET https://graph.microsoft.com/v1.0/organization/{tenantId}/subscribedSkus (replace {tenantId} with the ID from Step 1).

  3. Compare Quantities:

    • In the Graph API response, find the SKU where its skuId matches the GUID obtained in Step 2.
    • Compare the consumedUnits value from this SKU with the quantity from Pax8.

    Example Graph API subscribedSku field for quantity:

    {
        // ... other fields
        "skuId": "05e9a617-0261-457d-9994-2f7e80c53611", // Matches GUID from CSV
        "consumedUnits": 3, // Compare this value
        // ... other fields
    }
    

Key Considerations

  • CSV Updates: Regularly download the latest Microsoft product reference CSV.
  • Product Naming: Be mindful of potential minor differences in product names between Pax8 and the CSV.
  • Workaround Status: This is an interim solution. Monitor Pax8 developer channels for API enhancements.
  • Troubleshooting: Log your mapping process to help identify any discrepancies.