How to add a webhook (get notified when accounts change)
A webhook makes the server tell your system what happened, so your system does not have to ask the API again and again. For each event you choose, the server sends a signed JSON POST to your address.
Before you start
- You need the admin panel (
https://<server>:2087). Resellers need the API tokens (billing systems) privilege. - Your system needs an HTTPS address that accepts
POSTrequests, for examplehttps://billing.example.com/hooks/hosting.
Steps
- Open Webhooks in the menu (section Account).
- Under Add webhook, enter the Address.
- Under Events, tick what to send. All
account.*events are ticked to start with. See webhook events. - Click Add webhook.
- The page shows Signing secret: with a Copy button. Store it in your system: you need it to verify the signature of each message.
Test it
Click Send test next to the webhook. A ping message is sent within a few seconds. Recent deliveries shows each message with its event, address and status: sent, pending (waiting for a retry) or failed, with the error and the number of attempts.
How delivery works
- Messages are sent within a few seconds of the event.
- Your address must answer with any
2xxstatus within 10 seconds. Redirects are not followed. - Otherwise the message is sent again after 1, 5, 30 and 120 minutes, then marked failed.
- The same message can arrive twice. Use its
idto ignore duplicates. - Deliveries are kept in the list for 30 days.
Good to know
- The administrator's webhooks hear about every account on the server, and about server events such as failed tasks. A reseller's webhooks hear only about the reseller's own accounts.
- A reseller's address must be on the public internet; addresses of this server or private networks are refused.
- Up to 20 webhooks each. Click Show secret to see a webhook's secret again, or Remove to delete it.
- To change the events of a webhook, add a new one and remove the old one.
Common questions
Why do I get "Enter the full address, starting with https://"?
The address must start with http:// or https:// and have a host name, without a user name or password in it.
Why do I get "The name … does not resolve."?
The host name of your address has no DNS record yet. Create it, or use the IP address.
Thank you — this helps us improve the article.
Still stuck?
Ask the AI about your exact situation — it answers from this knowledge base — or contact us.
Related articles
- Webhook events and JSON payloads reference
Every webhook event the server sends — accounts, domains, mailboxes, disk and bandwidth limits, failed tasks, support tickets — with the JSON body of each.
- How to verify webhook signatures (HMAC-SHA256)
Check the X-Sahaab-Signature header of webhook messages with your signing secret, with code for PHP, Node.js and Python, and skip duplicates.
- REST API overview: authentication, requests and responses
How the REST API v1 works: base URL, Bearer token authentication, JSON or form bodies, the response envelope, HTTP status codes and every endpoint.