frm/Get-FRMService.ps1
function Get-FRMService { Param( [Parameter(Mandatory=$true)] [string] $ServiceID, [Parameter(Mandatory=$false)] [string] $EdgeRCFile = '~\.edgerc', [Parameter(Mandatory=$false)] [string] $Section = 'firewall', [Parameter(Mandatory=$false)] [string] $AccountSwitchKey ) $Path = "/firewall-rules-manager/v1/services/$ServiceID`?accountSwitchKey=$AccountSwitchKey" try { $Result = Invoke-AkamaiRestMethod -Method GET -Path $Path -EdgeRCFile $EdgeRCFile -Section $Section return $Result } catch { throw $_.Exception } } |