0
votes

When I try to list azure VMs on my account from their python API, I get the following error: Message: The client 'xxxxxxxxxxxxxxxxxxx' with object id 'xxxxxxxxxxxxxxxxx' does not have authorization to perform action 'Microsoft.Compute/virtualMachines/read' over scope '/subscriptions/xxxxxxxxxxxx/resourceGroups/xxxxxxxxx/providers/Microsoft.Compute/virtualMachines/xxxxxx'.

Does this type of API access require paid access or did I set up my authentication incorrectly?

1

1 Answers

0
votes

You authentication is correct, but you just need proper permissions on the Azure side. So you need to grant yourself (the client you are acting from) a Virtual Machine Contributor or Contributor role to the resource group the VM is in (or to the subscription).

Take a look at this link.