Overview
Instead of polling the status endpoint, you can provide acallback_url in your interactive notification request. NextKS will POST the results to your URL when the request finishes.
When callbacks fire
A callback is triggered when:onUserActionmode: All users have respondedonTimeoutmode: The timeout is reached- Either mode: The timeout is reached and some users haven’t responded
status: "finished"). It is never sent for partial or intermediate individual responses — the payload always reflects the completed request.
Signature verification
Every callback request is signed with HMAC-SHA256 so you can verify it came from NextKS. When you send an interactive notification with acallback_url, the API response includes a callback_secret. Store this secret securely — you’ll use it to verify incoming callbacks.
Verification headers
Verification example
Callback payload
NextKS sends aPOST request with Content-Type: application/json:
Callback URL requirements
Your callback URL is validated when you submit the notification:
If validation fails, the notification request is rejected with a
400 error.
Retries
If a callback delivery fails (network error or non-2xx response), NextKS retries automatically with exponential backoff:- Up to 6 total attempts (1 initial + 5 retries)
- Each attempt is logged with the error message
- Once successful, no further retries are attempted
Handling callbacks
Your endpoint should:- Return a
2xxstatus code to acknowledge receipt - Process the payload asynchronously if needed — NextKS has a 10-second timeout
- Be idempotent — in rare cases, a callback may be delivered more than once