API & Integration

Setting Up Webhooks

7 min read
Webhooks allow LicenseChain to notify your application in real-time when license events occur. ## What are Webhooks? Webhooks are HTTP callbacks that LicenseChain sends to your server when specific events happen, such as: - License activations - License expirations - Usage limit reached - License violations - Renewal events ## Setting Up Webhooks 1. Navigate to your application settings 2. Go to the "Webhooks" section 3. Click "Add Webhook" 4. Enter your webhook URL 5. Select the events you want to receive 6. Save your webhook configuration ## Webhook URL Requirements Your webhook endpoint must: - Be accessible via HTTPS - Accept POST requests - Return a 200 status code within 5 seconds - Handle JSON payloads ## Webhook Payload Webhooks send JSON payloads with event type, timestamp, and event data. ## Verifying Webhooks Always verify webhook signatures to ensure requests are from LicenseChain using HMAC SHA256. ## Handling Webhooks Set up an endpoint to receive webhook POST requests, verify the signature, and handle different event types appropriately. ## Testing Webhooks Use LicenseChain's webhook testing tool in the dashboard to test your webhook endpoints before going live.