Skip to content

Webhook API ​

POST /v1/jobs/{job_id}/webhook

Internal endpoint used by Modal GPU workers to push render completion results back to the API. Not intended for external use.

Authentication ​

Webhooks are authenticated using HMAC-SHA256 signatures with replay protection:

  1. The request body is signed with the shared WEBHOOK_SECRET
  2. The signature is sent in the X-Signature header
  3. A timestamp and nonce prevent replay attacks (5-minute window)

Request ​

Content-Type: application/json

json
{
  "success": true,
  "video_key": "videos/550e8400-....mp4",
  "thumb_key": "thumbnails/550e8400-....jpg",
  "log_key": "logs/550e8400-....log",
  "error": "",
  "pp": 425.8,
  "timestamp": 1717848000,
  "nonce": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}

Fields ​

FieldTypeDescription
successboolWhether the render succeeded
video_keystringS3 key of the rendered video
thumb_keystringS3 key of the thumbnail
log_keystringS3 key of the render log
errorstringError message if success is false
ppfloatPP value parsed from danser output
timestampintUnix timestamp (replay protection)
noncestringUnique nonce (replay protection)

Verification Flow ​

Error Responses ​

StatusCondition
401Missing or invalid X-Signature header
400Payload expired (timestamp > 5 min old)
404Job not found
422Invalid JSON body
500WEBHOOK_SECRET not configured on server

Built with VitePress