I am trying to get a list of subscriptions in an Azure tenant using the Python SDK.
I want to use this class: https://docs.microsoft.com/en-us/python/api/azure-mgmt-subscription/azure.mgmt.subscription.operations.subscriptionsoperations
and the list
method.
The documentation says "You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute."
What does that mean?
This is what I have:
client = SubscriptionClient(credentials)
test = SubscriptionClient.SubscriptionsOperations(client)
I am getting this:
AttributeError: type object 'SubscriptionClient' has no attribute 'SubscriptionsOperations'
Thanks,
Mick