Unable to fetch complete details from Azure API

Kaki Sai Sudharshan (iCORE-CIS) 41 Reputation points
2021-12-01T13:05:14.033+00:00

Hi,

I am using the below API ("**https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.Compute/virtualMachines?api-version=2021-07-01**") to fetch the details of VM Name, VM Size and its Corresponding details. I am getting only few records. For example, in my subscription i am having 72VMs ( Cross verified from Azure Portal), i am getting only 50VMs when i am calling this API in PowerBI. I tried to apply additional parameters on the API, but its throwing an error and it is not running. Can anyone please help me on this.

Reference taken from: https://learn.microsoft.com/en-us/rest/api/compute/virtual-machines/list-all

Thanks,
Sudharshan.

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
9,013 questions
0 comments No comments
{count} votes

Accepted answer
  1. vipullag-MSFT 26,487 Reputation points Moderator
    2021-12-02T08:24:28.98+00:00

    @Kaki Sai Sudharshan (iCORE-CIS)

    You are trying to fetch details from PowerBI through API, and the list you are seeing is only limited to 50.
    This is because your nextLink response parameter might not be processed correctly which might be resulting in incorrect results.

    Incase you are not using the nextLink property please check this document this is the cause and you can fix this issue.

    154367-image.png

    Here is a similar issue on stackoverflow for your reference.

    Hope it helps.
    If the suggested response helped you resolve your issue, please 'Accept as answer', so that it can help others in the community looking for help on similar topics.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.