This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# VMware vRealize Automation API sample in PowerSHell | |
# | |
# Submits a catalog item request via the vRA API | |
# | |
# For vRO 7.0+ | |
#set global variables | |
$baseUrl = 'https://vra01a.corp.local' | |
$catalogItemName = 'HVD 7' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// VMware vRealize Orchestrator action sample | |
// | |
// Removes duplicates from an array, with the option to also sort the array | |
// | |
// For vRO 6.0+ | |
// | |
// Action Inputs: | |
// a - Array/Any - Array with potential duplicates | |
// doSort - boolean - Sort the array also? Potentially better performance than unsorted algorithm | |
// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// VMware vRealize Orchestrator action sample | |
// | |
// This sample returns the ID of a vCenter Tag Category given its name | |
// | |
// For vRO/VAPI 7.0+ | |
// | |
// Action Inputs: | |
// endpoint - VAPIEndpoint - VAPI Endpoint | |
// categoryName - string - Name of the vCenter Tag Category | |
// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// VMware vRealize Orchestrator action sample | |
// | |
// This sample retrieves the value of an attribute defined in a configuration element | |
// Note: This calls another action defined in getConfigurationElement.js | |
// | |
// For vRO 6.0+ | |
// | |
// Action Inputs: | |
// configurationCategoryPath - string - Path of the configuration element; e.g., PSO/VAPI/ | |
// configurationName - string - name of the configuration element |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// VMware vRealize Orchestrator action sample | |
// | |
// Get the children of a vRA Catalog Resource. | |
// For example, find the Machine resource(s) of a Deployment. | |
// | |
// For vRO/VRA 7.0+ | |
// | |
// Action Inputs: | |
// cafeHost - vCACCAFE:VCACHost - vRA CAFE Host | |
// parentCatalogResource - vCACCAFE:CatalogResource - parent Catalog Resource for which to get children |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// VMware vRealize Orchestrator action sample | |
// | |
// Use VM-host compatibility checker, which is native to the vCenter plugin, | |
// to determine if a host is compatible with a given VM and resource pool | |
// | |
// For vRO 7.0+/vCenter 6.0+ | |
// | |
// Action Inputs: | |
// host - VC:HostSystem - vCenter host | |
// vm - VC:VirtualMachine - vCenter VM |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// VMware vRealize Orchestrator action sample | |
// | |
// Get the names of all the reservations of a compute resource in a vRA IaaS instance | |
// | |
// For vRO/VRA 7.0+ | |
// | |
// Action Inputs: | |
// host - vCAC:VCACHost - vRA IaaS Host | |
// computeResourceName - string - Compute resource name | |
// onlyEnabledReservations - boolean - Set to true to only return the names of enabled reservations |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// VMware vRealize Orchestrator action sample | |
// | |
// Get the reservation policy IDs of all the reservations of a compute resource in a vRA IaaS instance | |
// | |
// For vRO/VRA 7.0+ | |
// | |
// Action Inputs: | |
// host - vCAC:VCACHost - vRA IaaS Host | |
// computeResourceName - string - Compute resource name | |
// onlyEnabledReservations - boolean - Set to true to only return the reservation policies of enabled reservations |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// VMware vRealize Orchestrator action sample | |
// | |
// Get all the managed VMs in a vRA IaaS instance | |
// | |
// For vRO/VRA 7.0+ | |
// | |
// Action Inputs: | |
// host - vCAC:VCACHost - vRA IaaS Host | |
// | |
// Return type: Array/vCAC:VirtualMachine - all managed VMs in a vRA instance |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// VMware vRealize Orchestrator action sample | |
// | |
// Get a vRA reservation object given its ID | |
// | |
// For vRO/VRA 7.0+ | |
// | |
// Action Inputs: | |
// cafeHost - vCACCAFE:VCACHost - vRA host | |
// reservationId - string - ID of a Reservation | |
// |