Introducing the vCAC VMPS SOAP ProvisionService

Besides the well used ManagementContext vCAC also has some SOAP services for basic infrastructure communication and provisioning. With the ProvisionService, VMPS for short, you get a wrapper around some basic vCAC workflows and helper functions that abstract data manipulation of the MangementContext and others. Using this service with PowerShell is pretty straightforward with the help of the ‘New-WebServiceProxy’ Cmdlet. For short I show you how to initialise the SOAP service and list some SOAP actions you can execute. To further dive into it you can have a look at some of my other blog posts like machine import and Approval/Reject of requested machines. Here is a list of all actions (excluding all async actions):

PS > $VMPS = New-WebServiceProxy -Uri https://vcac52.sharedop.org/VMPS -Class VMPS -Namespace VMPS
PS > $VMPS;
SoapVersion                          : Default
AllowAutoRedirect                    : False
CookieContainer                      :
ClientCertificates                   : {}
EnableDecompression                  : False
UserAgent                            : Mozilla/4.0 (compatible; MSIE 6.0; MS Web Services Client Protocol 4.0.30319.18063)
Proxy                                :
UnsafeAuthenticatedConnectionSharing : False
Credentials                          :
UseDefaultCredentials                : False
ConnectionGroupName                  :
PreAuthenticate                      : False
Url                                  : https://vcac52.sharedop.org/VMPS
RequestEncoding                      :
Timeout                              : 100000
Site                                 :
Container                            :

PS > $idTkn = New-Object VMPS.IdentityToken;
PS > $idTkn.User = '{0}\{1}' -f $ENV:USERDOMAIN, $ENV:USERNAME;
PS > ((($vmps | gm -Type Method).Name
  -notmatch '^Begin' )
  -notmatch '^End')
  -notmatch 'Async$';
Abort
AcceptLeaseExtensionRequests
AcceptVirtualMachineRequest
CreateObjRef
Discover
Dispose
Equals
FireReclamationRequestEvent
FireVirtualMachineEvent
GetHashCode
GetLifetimeService
GetType
InitializeLifetimeService
NotifyGroupAdminOfLeaseExtensionRequest
RegisterExistingVirtualMachine
RejectLeaseExtensionRequests
RejectVirtualMachineRequest
RequestVirtualMachine2
SubmitReclamationRequest
SubmitVirtualMachineRequests
ToString
TriggerUpdateMachineNotesEvents
TriggerUpdateMachineOwnerEvents

When you execute actions you often have to use an IdentityToken that I always set to the username of the current user. You certainly can choose something else.

Trackbacks

  1. […] virtual machines I came across the ‘RegisterExistingVirtualMachine()’ SOAP action the VMPS ProvisionService in vCAC. As it turns out that same method also allows for changing a reservation of machine during […]

  2. […] In order to achieve this we set up a resource account and added that resource to the approver group. Then we installed a script that periodically checked machines for being in an ‘AwaitingApproval’ state and checked their ‘VMCreationDate’. Calculating the timespan from [datetime]::UtcNow and that date we determined what to do with the machine and issued the corresponding request via the VMPS soap interface: […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: