Set up Privy webhooks from the terminal
You need an HTTPS endpoint you control. Webhooks can contain user data, so don’t point them at a public test receiver.
Add the endpoint
Section titled “Add the endpoint”privy --app APP_ID webhooks create --url https://api.example.com/privy --dry-runprivy --app APP_ID webhooks create --url https://api.example.com/privy --yesprivy --app APP_ID webhooks listAn app can have up to five endpoints.
Save the signing key
Section titled “Save the signing key”Creating an endpoint doesn’t fetch its signing key. This saves it straight to your OS keychain without printing it:
privy --app APP_ID webhooks signing-key save ENDPOINT_ID --yesYour server uses that key to verify each webhook’s signature.
Choose events
Section titled “Choose events”Subscriptions apply to every endpoint in the app, and the list you pass replaces the current one, so include everything you want to keep:
privy --app APP_ID webhooks subscriptions getprivy --app APP_ID webhooks subscriptions update --subscriptions '["user.created"]' --diffprivy --app APP_ID webhooks subscriptions update --subscriptions '["user.created"]' --yesPrivy validates the event names.
Test and check delivery
Section titled “Test and check delivery”privy --app APP_ID webhooks test ENDPOINT_ID --confirm-url https://api.example.com/privy --yesprivy --app APP_ID webhooks history list --endpoint-id ENDPOINT_IDA successful test only means Privy accepted the request. Check the history and your server’s logs to confirm the webhook arrived and its signature verified. The CLI never resends on its own, so look at the history before sending again.
More in the Webhooks guide.
Privy CLI is an unofficial, community project by Samarth Saxena. Not affiliated with or endorsed by Privy. The Privy name and wordmark belong to Privy. It uses undocumented dashboard APIs that can change.