Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

New to using Partner Center to pull information #402

Open
sockshrimp opened this issue Dec 1, 2022 · 0 comments
Open

New to using Partner Center to pull information #402

sockshrimp opened this issue Dec 1, 2022 · 0 comments

Comments

@sockshrimp
Copy link

sockshrimp commented Dec 1, 2022

I've started a script to assist resellers get information from Partner Centers. Gotten this far and will not pretend I'm a pro with PS. I just want the SKUs, number licenses used but I do not think (Get-PartnerCustomerSubscribedSku -CustomerId $CustomerID) works

`#Install PartnerCenter Module
Install-Module -Name PartnerCenter -AllowClobber -Scope CurrentUser

#Log into Partner Center (REQUIRES MFA OR IT WILL FAIL)
Connect-PartnerCenter

#Getting Partner Customer Count
$Customers = Get-PartnerCustomer
Write-Host "Found $($Customers.Count) customers" -ForegroundColor DarkGreen

$Csvpath = C:\temp\Export_$ResellerName.csv

$Customers = Get-PartnerCustomer
$CustomerID = Get-PartnerCustomer | Select-object CustomerID

foreach ($Customer in $Customers) {
Write-Host "Retrieving license info for $($customer.name)" -ForegroundColor Green
$CustomerUserSKUs = (Get-PartnerCustomerSubscribedSku -CustomerId $CustomerID)
} `

@sockshrimp sockshrimp reopened this Dec 1, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant