Configure Webhook
- Enter your receiver address. Open Webhook settings in DGrid, enter the address, and save it. Use a public HTTPS address that you or your technical team provides.
- Enable Webhook.
- Get your Signing Secret. Click Rotate Secret, securely copy the generated secret, and add it to your receiver configuration. Keep it private. Each rotation generates a new secret; update your receiver and retain the previous key while queued deliveries finish.
- Choose your events. Enable the notification types you want to receive from the options below.
- Test notifications. Use the page’s test function to confirm that your receiver accepts the notification and verifies its signature.
Available events
All six event types below are available in Webhook settings. Your receiver identifies each event using the top-leveleventType field in the notification JSON. Use these exact identifiers, including their letter case, periods and underscores.
Deposit Balance and subscription balance are separate. Subscription low-balance notifications occur at most once per subscription per UTC month; there is no separate subscription-balance-depleted event. Auto Deposit failure refers to an actual failed attempt, not a funds or authorization warning raised before an attempt exists.
Incoming request
DGrid sends an HTTPPOST request to your saved receiver URL with Content-Type: application/json. Every notification uses the same outer JSON structure:
Event data
Each of the following six snippets replaces onlydata in the common outer structure. The IDs, times and balances are examples, not fixed values.
Deposit Balance low — balance.low
Deposit Balance depleted — balance.depleted
eventType is a string and test is a boolean. balance is a signed decimal string in USD and can be zero or negative. It represents Deposit Balance, excluding subscription allowance. Preserve its precision rather than converting it to floating point or applying email display rounding/truncation rules.
Auto Deposit completed — auto_recharge.succeeded
Auto Deposit failed — auto_recharge.failed
attemptId identifies the automatic deposit attempt, state is fixed to confirmed or failed respectively, and occurredAt is the UTC RFC 3339 event time, possibly with fractional seconds. These payloads contain only the three fields shown: there is no inner eventType or test, amount, transaction hash, wallet or failure reason.
Subscription active — subscription.activated
sourceId is the subscription UUID.
Subscription Balance low — subscription.balance_low
sourceId combines the subscription UUID and UTC month as <subscription UUID>:YYYY-MM. All three subscription fields are strings; occurredAt is a UTC RFC 3339 timestamp. These payloads do not contain the plan name, subscription dates, quota, percentage or wallet. Do not assume they include the details displayed in an email.
Test notifications
Test notifications havetest: true in the outer structure. Every event type uses the same three-field test shape, but data.eventType matches the selected event and the outer eventType. For example, selecting Auto Deposit completed produces this complete test notification:
test field before validating the live event schema or processing business data. Tests do not contain live-event fields such as attemptId or sourceId, and an empty balance does not mean zero. Do not use test notifications to change balances, record deposits or activate subscriptions.
Verify the signature
Each request includes four signature-related headers:
Header names are case-insensitive. There is no separate signing-key version header.
The Signing Secret shown by Rotate Secret is an unpadded base64url encoding of a 32-byte key. Decode it into bytes before computing the HMAC; do not use the displayed secret text directly as the key.
Compute the expected signature using:
DGrid-Signature using a constant-time comparison. Require signature version v1. A five-minute timestamp window is recommended to limit replay; keep your receiver’s clock synchronized. After verification, parse the JSON and check that DGrid-Event-Id matches id.
Respond to deliveries
Durably accept the verified notification, then return any HTTP2xx status in under five seconds. For example, persist it to a queue and return:
200 response whose JSON body describes an error counts as accepted.
Non-2xx responses, network failures and timeouts trigger retries, up to five total attempts, including the first attempt. Redirects are not followed. Perform slower business processing after the request has been durably accepted.
Deliveries can be duplicated, and their order is not guaranteed. Deduplicate using the outer id, which remains stable on retry. Acknowledge an already accepted duplicate with 2xx without repeating its business effects. Retry timestamps, signatures and raw message bytes may change; do not use these or createdAt to deduplicate or establish business event order.

