PowerShell hack to reformat webhook payload from GitHub to MS Teams. I run it as an Azure Function. This same concept will also work for other applications that send complex payloads via webhook.
Github Webhook -> Azure Function -> MS Teams Webhook.
# Accept the data from the incoming webhook.
param (
[object]$WebhookData
)