You can specify username and password credentials to establish a session with a vCenter Server. The following steps describe how a client application specifies username and password credentials for access to a vCenter Server.

Procedure

  1. Create a connection to the vSphere server Web service.
  2. Instantiate a local proxy object for reference to ServiceInstance. Use this local proxy object to retrieve the ServiceContent object from the server. ServiceContent contains a reference to the root folder for the inventory and references to the managed objects that provide the vSphere services.
  3. Instantiate a local proxy object for access to vSphere API methods.
  4. Log in to the server using appropriate credentials (user account, password, and optionally the locale).
  5. Access server-side objects to retrieve data and perform management operations.
  6. Close the connection.