コメントありがとうございます。 申し訳ございません。 10年近い前の記事と言うこ…
PowerShellでAPIを叩いてみた
$headers = @{}
$headers.FOO = $foo
$headers.bar = $bar
try{
$objApiRes = Invoke-RestMethod -Method Get -Uri https://www.hogehoge.com/xyzzy/ -Headers $headers
}catch{
}
Write-Output ("res(key): " + $objApiRes.key )
Write-Output ("res(val): " + $objApiRes.value )
Write-Output ("res(hoge): " + $objApiRes.hoge )
検索

コメントを残す