Webhooks
Overview
Creating Webhooks
Via API
const webhook = await mppfi.webhooks.create({
url: 'https://api.yourcompany.com/webhooks/mppfi',
events: [
'payment.created',
'payment.completed',
'payment.failed',
'policy.violation',
'balance.low'
],
description: 'Production webhook endpoint',
secret: 'whsec_your_generated_secret_key'
});
console.log(`Webhook ID: ${webhook.id}`);
console.log(`Secret: ${webhook.secret}`); // Store securelyVia Dashboard
Event Types
Payment Events
Event
Description
Includes Blockchain Data
Agent Events
Event
Description
Policy Events
Event
Description
Account Events
Event
Description
Blockchain Events
Event
Description
Webhook Payload
Verifying Signatures
TypeScript/Node.js
Using SDK
Python
Rust
Event Examples
Payment Completed
Policy Violation
Balance Low Warning
Best Practices
1. Respond Quickly
2. Handle Idempotency
3. Use HTTPS
4. Monitor Webhook Health
5. Implement Retry Logic
Retry Logic
Attempt
Delay
Testing Webhooks
Send Test Events
Local Development
Webhook Inspector
Example Integrations
Slack Notifications
Database Sync
Email Alerts
Webhook Security
IP Allowlist
Rate Limiting
Timeout
Managing Webhooks
Update Webhook
Disable Webhook
Delete Webhook
List Webhooks
Webhook Limits
Plan
Max Webhooks
Max Retries
Event Retention
Troubleshooting
Webhook Not Receiving Events
Signature Verification Failing
High Failure Rate
Next Steps
Last updated
Was this helpful?
