Get-VPASDPAPolicyDetails


Supported Environments:
SelfHosted
SharedServices
PCloudStandard


Synopsis:

GET DPA POLICY DETAILS


Description:

USE THIS FUNCTION TO RETRIEVE POLICY DETAILS FROM DPA


Syntax:

Get-VPASDPAPolicyDetails [[-PolicyID] <String>] [[-PolicyName] <String>] [[-token] <Hashtable>] [<CommonParameters>]


Parameters:

-PolicyID <String>
UniqueID of the target policy in DPA

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

-PolicyName <String>
Unique name of the target policy in DPA

Required: false
Position: 2
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: 3
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:

$PolicyDetails = Get-VPASDPAPolicyDetails -PolicyID {POLICY ID VALUE}

$PolicyDetails = Get-VPASDPAPolicyDetails -PolicyName {POLICY NAME VALUE}


Outputs:

If successful:
{
         "policyId": "lkjsdhf897-zxcv-asdf-7634-lksjd438754",
         "policyName": "Vman Access Policy",
         "status": "Enabled",
         "description": "",
         "providersData": {
                 "OnPrem": {
                         "fqdnRules": "",
                         "logicalNames": null,
                         "ipRules": ""
                 }
         },
         "startDate": null,
         "endDate": null,
         "userAccessRules": [
                 {
                         "ruleName": "Test Rule",
         "userData": "@{roles=System.Object[]; groups=System.Object[]; users=System.Object[]}",
         "connectionInformation": "@{connectAs=; grantAccess=2; idleTime=15; daysOfWeek=System.Object[]; fullDays=True; hoursFrom=; hoursTo=; timeZone=America/Chicago}"
                 }
         ],
         "updatedOn": null,
         "updatedBy": null,
         "createdOn": null,
         "createdBy": null
}

$false if failed