Created
September 16, 2016 14:51
-
-
Save chelnak/5c11b61c10c3dc56af2130a0d66ef873 to your computer and use it in GitHub Desktop.
Escape URI String with PowerShell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$URI = "/catalog-service/api/consumer/resourceViews/?withExtendedData=$($WithExtendedData)&withOperations=$($WithOperations)&managedOnly=$($ManagedOnly)&`$orderby=name asc&limit=$($Limit)&page=$($page)&`$filter=resourceType/id eq 'Infrastructure.Machine' or resourceType/id eq 'Infrastructure.Virtual' or resourceType/id eq 'Infrastructure.Cloud' or resourceType/id eq 'Infrastructure.Physical'" | |
$EscapedURI = [uri]::EscapeUriString($URI) | |
$Response = Invoke-vRARestMethod -Method GET -URI $EscapedURI -Verbose:$VerbosePreference |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment