The example is based on the code in the PlatformServiceController.cs sample file. This file is located in the following vCloud Suite SDK for .NET directory: client/samples/src/Samples/vmware/vcloud/suite/samples/common/PlatformServicesController.cs.
This example uses the steps that are described in the Retrieve a SAML Token procedure.
using System; using System.Linq; using vmware.vapi.util.security; // Create a connection object to communicate with the vCenter Single Sign-On service. var ssoUrl = FindSsoUrl(); SsoConnection = new SsoConnection(ssoUrl); // Request a SAML token. SsoConnection.AcquireSamlToken(ssoUserName, ssoPassword, SamlTokenConfirmationType.BEARER);