Public/MT4/Invoke-MT4DailySyncRead.ps1
|
function Invoke-MT4DailySyncRead { <# .SYNOPSIS Read daily-report sync #> [CmdletBinding(SupportsShouldProcess)] param( [Parameter()][string] $TradePlatform, [Parameter()][object] $Body, [Parameter()][Nullable[guid]] $CacheId, [Parameter()][int] $CacheTimeout, [Parameter()][string] $IdempotencyKey ) if (-not $PSCmdlet.ShouldProcess('MT4/DailySyncRead')) { return } $reqArgs = @{ Method = 'Post'; Path = "/api/v2/MT4/{tradePlatform}/DailySyncRead"; TradePlatform = $TradePlatform; Body = $Body } if ($PSBoundParameters.ContainsKey('CacheId')) { $reqArgs.CacheId = $CacheId } if ($PSBoundParameters.ContainsKey('CacheTimeout')) { $reqArgs.CacheTimeout = $CacheTimeout } if ($PSBoundParameters.ContainsKey('IdempotencyKey')) { $reqArgs.IdempotencyKey = $IdempotencyKey } Invoke-MyWebApiRequest @reqArgs } |