-2

Whether it is possible to list above questions by api using Python script

I am not getting exactly what I need

0

1 Answer 1

0

See the API here:
https://learn.microsoft.com/en-us/rest/api/compute/virtual-machines/list-all?tabs=HTTP GET https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.Compute/virtualMachines?api-version=2022-11-01

Use PostMan or similar application to do this.

You need a header Authorization Bearer access-token.
headers = {'Authorization': 'Bearer ' + token['accessToken'], 'Content-Type': 'application/json'}

Also see:

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.