Building PowerShell Arrays and Hashtables for JSON Payloads – Wahl Network
Building PowerShell Arrays and Hashtables for…
While tinkering around with Slack’s Incoming Webhooks feature, I came upon the ability to add message attachments. This seemed like a nifty way to condense a few different pieces of information into a rich formatted Slack message with a bit of PowerShell code. The challenge is converting the syntax for arrays and key-value pairs (hashtables) from native JSON to native PowerShell.