Describe the bug
Command Name
az network vnet list-available-ips
Issue:
The command only returns a limited list of available IPs (appears to be first 5 available) without providing the total count of available IPs or indicating that the response is truncated.
Related Issues
This builds on previously closed issues (#25427, #13853) which focused on listing more IPs. However, this request is specifically for metadata (total count) rather than an exhaustive list, which serves different operational use cases.
To Reproduce:
- Create a VNet with a /24 subnet (should have ~248 available IPs after Azure reservations for platform usage)
- Run
az network vnet list-available-ips --ids <vnet-resource-id>
- Observe that only 5 IPs are returned despite many more being available
Expected Behavior
The API response should include:
- Total count of available IPs - essential for capacity planning and monitoring
- Clear indication if the list is truncated - so users know there are more IPs available
- Optional pagination or limit parameters - to control response size
Suggested response format:
{
"totalAvailableIPs": 247,
"availableIPs": ["10.0.0.4", "10.0.0.5", "..."],
"truncated": true
}
Environment Summary
Linux-5.15.167.4-microsoft-standard-WSL2-x86_64-with-glibc2.39, Ubuntu 24.04.2 LTS
Python 3.12.8
Installer: DEB
azure-cli 2.71.0 *
Additional Context
Describe the bug
Command Name
az network vnet list-available-ipsIssue:
The command only returns a limited list of available IPs (appears to be first 5 available) without providing the total count of available IPs or indicating that the response is truncated.
Related Issues
This builds on previously closed issues (#25427, #13853) which focused on listing more IPs. However, this request is specifically for metadata (total count) rather than an exhaustive list, which serves different operational use cases.
To Reproduce:
az network vnet list-available-ips --ids <vnet-resource-id>Expected Behavior
The API response should include:
Suggested response format:
{ "totalAvailableIPs": 247, "availableIPs": ["10.0.0.4", "10.0.0.5", "..."], "truncated": true }Environment Summary
Additional Context