Webhooks
Webhooks let you subscribe to events from your LLMTune workspace for automation and monitoring. Receive real-time notifications when training jobs complete, deployments change, or usage thresholds are reached.Supported Events
| Event | Trigger |
|---|---|
training.started | A fine-tuning job enters the running state |
training.completed | A job finishes successfully |
training.failed | A job fails or is cancelled |
model.deployed | A model is promoted to an endpoint |
Register a Webhook
- Navigate to Webhooks in the dashboard.
- Click Create Webhook.
- Provide:
- Target URL (HTTPS recommended)
- Events to subscribe to (select one or more)
- Save. A secret is generated automatically (e.g.
whsec_...). Use it to verify theX-Webhook-Signatureheader. - Test using the Send test event action in the dashboard.
Payload Format
LLMTune sends POST requests to your webhook URL with these headers:Content-Type: application/jsonX-Webhook-Signature– HMAC-SHA256 of the raw JSON body using your webhook secret (hex-encoded)X-Webhook-Event– Event name (e.g.training.completed)
data object may include additional fields depending on the event (e.g. provider for training.started). Use the secret shown in the dashboard to verify the signature.
Training Events
Fortraining.started, training.completed, and training.failed, data includes at least jobId and modelName. Other fields (e.g. metrics, error) may be present.
Deployment Events
Formodel.deployed, data includes deployment details such as modelId and endpoint information.
Signature Verification
LLMTune signs the raw request body (string) with HMAC-SHA256 using your webhook secret. The signature is sent in theX-Webhook-Signature header (hex-encoded). Verify it before processing:
Response Handling
- Respond with
2xxstatus codes to acknowledge receipt quickly; process the event asynchronously if needed - Request timeout: 5 seconds. Slow responses may be treated as failures
Best Practices
- Use unique secrets per webhook endpoint
- Acknowledge quickly – Respond with 200 OK immediately, then process asynchronously
- Log received events for debugging and auditing
- Validate signatures to ensure requests are from LLMTune
- Handle idempotency – Events may be delivered multiple times; use event IDs to deduplicate
- Monitor webhook health – Set up alerts if webhooks fail repeatedly
Testing Webhooks
- Use the Send Test Event button in the webhook configuration
- Test your endpoint locally using tools like ngrok or localtunnel
- Verify your endpoint handles all subscribed event types
Troubleshooting
- Webhook not receiving events: Check that your endpoint is publicly accessible (HTTPS) and returns 2xx responses
- Signature verification fails: Ensure you’re using the correct secret and computing the signature correctly
- Events delayed: Check your endpoint response time; slow responses may cause retries
- Missing events: Review webhook logs in the dashboard to see delivery status
Next Steps
- Learn about Deployment to understand when deployment events fire
- Read the Fine-Tuning Guide to see training event triggers
- Check the API documentation for programmatic webhook management