You could replace Invoke-WebRequest
with Invoke-RestMethod
which auto-converts json response to a psobject
so you can use:
$response = Invoke-RestMethod -Uri "https://yadayada:8080/bla"
$response.flag
More Related Contents:
- Unexpected ConvertTo-Json results? Answer: it has a default -Depth of 2
- Iterating through a JSON file PowerShell
- Convert nested JSON array into separate columns in CSV file
- PowerShell 2.0 ConvertFrom-Json and ConvertTo-Json implementation
- Proper formating of JSON using powershell
- PowerShell : retrieve JSON object by field value
- Why does powershell give different result in one-liner than two-liner when converting JSON?
- Cannot convert PSCustomObjects within array back to JSON correctly
- Powershell ConvertTo-JSON missing nested level
- Merge two json objects
- ConvertFrom-Json max length
- Prettify json in powershell 3
- Can JSON start with “[“?
- What JSON library to use in Scala? [closed]
- Parse JSON with R
- How to decode a property with type of JSON dictionary in Swift [45] decodable protocol
- Reading in a JSON File Using Swift
- How to rename JSON key
- How to query a json column for empty objects?
- Angular 2: Get Values of Multiple Checked Checkboxes
- JSON or XML? Which is better? [closed]
- What is the JSON format? [closed]
- ASP JSON: Object not a collection
- What is the difference between resource and resource representation in REST?
- How to decode JSON in Flutter?
- Error parsing JSON file with the jsonlite package
- Node.js -Firebase Service Account Private Key won’t parse
- deserialize a datatable with a missing first column
- Can Server Sent Events (SSE) with EventSource pass parameter by POST
- Typescript `enum` from JSON string