user
object that is the same structure as what the user REST API returns. For webhook events that involve an account change, we will include an account
object that represents the changed account. For example, in a user.unlinked_account
event, the account
value will be the account that was just removed, so it will no longer exist on the user
.
Example payload for different webhook events:
Verifying a webhook payload
svix
for webhooks infrastructure.@privy-io/server-auth
PrivyClient
’s verifyWebhook
method to verify an incoming webhook. Pass in the request body, headers, and signing key (from the Privy Dashboard). As an example, for a NextJS API request, you can verify a webhook using the code below: