Add-VPASAccount


Supported Environments:
SelfHosted
SharedServices
PCloudStandard


Synopsis:

CREATE ACCOUNT


Description:

USE THIS FUNCTION TO CREATE A NEW ACCOUNT IN CYBERARK


Syntax:

Add-VPASAccount [-platformID] <String> [-safeName] <String> [[-accessRestrictedToRemoteMachines] <String>] [[-remoteMachines] <String>] [[-automaticManagementEnabled] <String>] [[-manualManagementReason] <String>] [[-extraProps] <Hashtable>] [[-secretType] <String>] [[-name] <String>] [-address] <String> [-username] <String> [[-secret] <String>] [[-token] <Hashtable>] [<CommonParameters>]


Parameters:

-platformID <String>
PlatformID that will be assigned to the new account

Required: true
Position: 1
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-safeName <String>
SafeName that will be assigned to the new account

Required: true
Position: 2
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-accessRestrictedToRemoteMachines <String>
Limit if the new account can only connect to specific remote machines
Possible values: TRUE, FALSE

Required: false
Position: 3
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-remoteMachines <String>
Specific remote machines that the new account can connect to

Required: false
Position: 4
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-automaticManagementEnabled <String>
Enable for the account to be automatically managed by the CPM depending on platform settings and configurations
Possible values: TRUE, FALSE

Required: false
Position: 5
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-manualManagementReason <String>
Specify a reason for automatic management to be disabled

Required: false
Position: 6
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-extraProps <Hashtable>
Include extra properties that can be defined based on platform settings and configurations
Pass extra properties in a hashtable following this pattern: @{ OptionalProperty1Tag = "OptionalProperty1Value" }
Oracle Example: -extraProps @{ Database = "VmanDB" }

Required: false
Position: 7
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-secretType <String>
Type of secret that will be assigned to the new account
Possible values: Password, Key

Required: false
Position: 8
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-name <String>
ObjectName that will be assigned to the new account

Required: false
Position: 9
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-address <String>
Address that will be assigned to the new account

Required: true
Position: 10
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-username <String>
Username that will be assigned to the new account

Required: true
Position: 11
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-secret <String>
Secret that will be assigned to the new account

Required: false
Position: 12
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-token <Hashtable>
HashTable of data containing various pieces of login information (PVWA, LoginToken, HeaderType, etc).
If -token is not passed, function will use last known hashtable generated by New-VPASToken

Required: false
Position: 13
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug
ErrorAction, ErrorVariable, WarningAction, WarningVariable
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216)


Examples:

$CreateAccountJSON = Add-VPASAccount -platformID {PLATFORMID VALUE} -safeName {SAFENAME VALUE} -address {ADDRESS VALUE} -username {USERNAME VALUE}

$CreateAccountJSON = Add-VPASAccount -platformID {PLATFORMID VALUE} -safeName {SAFENAME VALUE} -address {ADDRESS VALUE} -username {USERNAME VALUE} -extraProps @{Database = "DatabaseName"; Port = "1234"}


Outputs:

If successful:
{
         "categoryModificationTime": 1723780054,
         "platformId": "WinDomain",
         "safeName": "TestSafe",
         "id": "121_5",
         "name": "Operating System-WinDomain-vman.com-testdomainuser02",
         "address": "vman.com",
         "userName": "testdomainuser02",
         "secretType": "password",
         "secretManagement": {
                 "automaticManagementEnabled": true,
                 "lastModifiedTime": 1723780054
         },
         "createdTime": 1723780054
}

$false if failed