Webhooks

Webhooks allow you to receive real-time notifications about events in your Linka account.

Setting Up Webhooks

  1. Go to your Linka Dashboard
  2. Navigate to Settings > Webhooks
  3. Add your webhook URL
  4. Select the events you want to receive

Webhook Events

Payment Events

  • payment.created - A new payment was created
  • payment.completed - A payment was completed
  • payment.failed - A payment failed

Purchase Events

  • purchase.created - A new purchase was created
  • purchase.completed - A purchase was completed
  • purchase.failed - A purchase failed

Webhook Payload

All webhooks include the following structure:

{
  "event": "payment.completed",
  "data": {
    "id": "pay_123",
    "amount": "100.00",
    "currency": "USDC",
    "status": "completed"
  },
  "timestamp": "2024-01-01T00:00:00Z"
}

Verifying Webhooks

Webhooks include a signature header that you can use to verify the request:

X-Linka-Signature: sha256=...

Security

  • Always verify webhook signatures
  • Use HTTPS for webhook endpoints
  • Implement idempotency to handle duplicate events

Was this page helpful?

Help us improve our documentation