1

I have to get the last bills from my azure account via CLI or python SDK. In both cases, I have a message telling me that my subscription type is not supported:

CLI :

# az billing invoice show
UnsupportedSubscriptionType - Offer id MS-AZR-0017P is not supported.

Python-SDK :

from azure.mgmt.billing import BillingManagementClient
bil_client = BillingManagementClient(credentials, subscription_id)
for item in bil_client.invoices.list():
    print(item)

azure.mgmt.billing.models.error_response.ErrorResponseException:     (UnsupportedSubscriptionType) Offer id MS-AZR-0017P is not supported.

Does anyone have a solution ?

Best regards,

PierreD
  • 13
  • 2
  • I'm voting to close this question as off-topic because it's about billing – CSharpRocks Jul 02 '19 at 14:43
  • 2
    Why ? For example this question is discussed here: [link](http://ninocrudele.com/azure-billing-warning-offer-id-ms-azr-0017p-is-not-supported-solved) and [link](https://github.com/Azure/azure-powershell/issues/7389) and for the moment no solution has been found. – PierreD Jul 02 '19 at 15:29

1 Answers1

0

I would suggest you to give a try by using latest versioned CLI / python-sdk. However, if the issue still persists then follow this (currently open) GitHub issue for any future updates regarding the similar issue.

Cheers!!

KrishnaG
  • 3,340
  • 2
  • 6
  • 16
  • Hello Krishna-MSFT, thank you for your reply. I did not specify it in my message, but I checked to have the last version of AZure CLI: `az --version` azure-cli 2.0.67 billing 0.2.2 Latest version : [link](https://pypi.org/project/azure-cli-billing/) and of Phyton SDK : `# pip show azure` Name: azure Version: 4.0.0 Latest version : [link](https://pypi.org/project/azure/) Yes, there is an issue open on Github, I quote in my comment, but I know that asking the question on stackoverflow can always be a good thing :) – PierreD Jul 03 '19 at 07:18