#author("2019-09-21T15:14:25+09:00","default:ryuichi","ryuichi")
#author("2019-09-21T15:21:32+09:00","default:ryuichi","ryuichi")
* ConvertFrom-Json - curlからのJSONをパースする [#ac5868b9]
PS> $response = Invoke-WebRequest -Uri "https://swapi.co/api/people/1/"
PS> ConvertFrom-Json $response.Content
name : Luke Skywalker
height : 172
mass : 77
hair_color : blond
- ここではcurlはInvoke-WebRequestコマンドレットを使っているが、curl.exeを使う場合はいったんファイルにしてからJSONファイルをパースする
** 参考 [#w2ebea55]
- https://stackoverflow.com/questions/37762615/how-to-parse-json-from-the-invoke-webrequest-in-powershell
- スターウォーズAPI: https://swapi.co/