PowerCLI Reference



This cmdlet creates a new entry in the credential store.


New-VICredentialStoreItem [-Host] <String> [-User] <String> [[-Password] <String>] [[-File] <String>] [<CommonParameters>]

Related Commands

Online Version

Detailed Description

This cmdlet creates a new entry in the credential store. If there is an existing entry for the specified host and user, it is overwritten. If the credential store file does not exist, it is created (along with its directory if needed). If no file is specified, the item is created in the default credential store file %APPDATA%\VMware\credstore\vicredentials.xml. Credential store items for vCloud Director servers must contain user name and organization in the following format: user_name:organization_name, where both names are lower-cased.


NameTypeDescriptionRequired?Pipeline InputDefault Value
HostStringSpecifies the host for which you want to create the new credentials item.trueFalse
UserStringSpecifies a user name.trueFalse
PasswordStringSpecifies a password.falseFalse
FileStringSpecifies a file path where you want to store the new credentials.falseFalse

Return Type

The newly created VICredentialStoreItem object


This cmdlet is not supported on the Core edition of PowerShell.


-------------------------- Example 1 --------------------------

New-VICredentialStoreItem -Host -User Admin -Password pass

Adds a new item in the default credential store file.

Copyright © VMware, Inc. All rights reserved.