WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
    • VMware Cloud Foundation 9
  • VKS
  • Homelab
    • Hardware Options
    • Hardware Reviews
    • Lab Deployment Scripts
    • Nested Virtualization
    • Homelab Podcasts
  • VMware Nostalgia
  • Apple
You are here: Home / Private AI Foundation with NVIDIA / Using vSphere 9.0 API to retrieve vGPU & DirectPath Profiles

Using vSphere 9.0 API to retrieve vGPU & DirectPath Profiles

09.16.2025 by William Lam // Leave a Comment

VMware Cloud Foundation (VCF) 9.0 has introduced a number of enhancements when consuming vGPU and DirectPath Profiles, which are available in both the vSphere UI and vSphere API for automation purposes. While answering some vSphere API questions from a colleague regarding vGPU and DirectPath Profiles, I figured it would be useful to share the vSphere API specifics in how to use the API to retrieve these resources and better yet, some code that you can use immediately!

vGPU Profiles

When adding a PCI device to a VM using the vSphere UI, a list of available vGPU Profiles will be displayed for users to select from as shown in the screenshot below.


To get the list of available vGPU Profiles, we will be using the QueryConfigTarget() API which can be scoped at either the vSphere Cluster or an individual ESXi host level. Once you have identified your resource scope level, we will need to get a reference to the EnvironmentBrowser manager which provides the actual API functionality.  The result of the API is ConfigTarget object which will return a number of attributes on what the scoped resource can support and for our specific use case, we will be focusing on following properties:

  • DynamicPassthrough - DirectPath Enabled Devices
  • VgpuProfileInfo - vGPU Enabled Devices
  • VendorDeviceGroupInfo - Device Group Enabled Devices

To demonstrate the use of this vSphere API, I have created the following PowerCLI sample get_vgpu_profiles.ps1 which will output the following simliar to the vSphere UI:


Note: vGPU Profiles can be accessed pre-9.0 with following requirements: DynamicPassthrough requires vSphere 7.0, VgpuProfileInfo requires 7.0 Update 3 and VendorDeviceGroupInfo requires 8.0

DirectPath Profiles

If you have created DirectPath Profiles, they will appear under Policies and Profiles->DirectPath Profiles as shown in the screenshot below.


A new DirectPathProfileManager object is what we will used to interact with DirectPath profiles and specifically the DirectPathProfileManagerList() API method.

To demonstrate the use of this vSphere API, I have created the following PowerCLI sample get_directpath_profiles.ps1 which will output the following simliar to the vSphere UI:

DirectPath Profile Utilization

To view the utilizations of all your DirectPath Profiles, select your vSphere Cluster and navigate to Monitor->DirectPath Profiles Utilizations as shown in the screenshot below.


Simliar to listing all DirectPath Profiles, we will be using the DirectPathProfileManager object but this time we will use the DirectPathProfileManagerQueryCapacity() API to return overall usage information.

To demonstrate the use of this vSphere API, I have created the following PowerCLI sample get_directpath_profile_usage.ps1 which will output the following simliar to the vSphere UI:

Categories // Private AI Foundation with NVIDIA, Private AI Services, vSphere 9.0 Tags // DirectPath, VCF 9.0, vGPU

Thanks for the comment!Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Search

Thank Author

Author

William is Distinguished Platform Engineering Architect in the VMware Cloud Foundation (VCF) Division at Broadcom. His primary focus is helping customers and partners build, run and operate a modern Private Cloud using the VMware Cloud Foundation (VCF) platform.

Connect

  • Bluesky
  • Email
  • GitHub
  • LinkedIn
  • Mastodon
  • Reddit
  • RSS
  • Twitter
  • Vimeo

Recent

  • Cross vCenter vMotion workloads from vSphere 7.0 to vSphere 9.0 02/09/2026
  • Installing Realtek Network Driver Fling using Free ESXi 8.0 Update 3e ISO 02/05/2026
  • Modern Kubernetes Visualization using Radar 02/01/2026
  • Bypassing the ESX Tunnel Endpoint (TEP) 1600 MTU Check in the VCF Installer 01/29/2026
  • Quick Tip - NSX Edge fails DNS pre-check as part of VCF 9.0.2 Upgrade 01/23/2026

Advertisment

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.

To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2026

 

Loading Comments...