For the complete documentation index, see llms.txt. This page is also available as Markdown.

Regenerate webhook secret

Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.

Regenerate webhook secret

post

Regenerate the secret of a webhook. The previous secret is immediately invalidated. The new secret is returned only in this response and is sent as a bearer token with every delivery.

Authorizations
AuthorizationstringRequired

API Token authentication

Path parameters
webhookIdstringRequired

Webhook ID (returned when the webhook was created)

Example: 019683f8-1234-7abc-8def-0123456789ab
Responses
200

Success response

application/json
idstringOptional

Unique webhook identifier

Example: 019683f8-1234-7abc-8def-0123456789ab
namestringOptional

Human-readable name for this webhook

Example: New message notifier
descriptionstring · nullableOptional

Optional description of the webhook's purpose

Example: Notifies our CRM when a new email arrives
statusstring · enumOptional

Current status of the webhook

Example: activePossible values:
urlstringOptional

URL that receives webhook POST requests

Example: https://example.com/webhooks/incoming
secretstringOptional

New webhook secret, sent as Authorization: Bearer <secret> with every delivery. The previous secret is immediately invalidated and the new one is not returned again.

Example: 4a6f8b2d1e9c3f7a0b5d8e2c4f1a7b3d9e6c2f8a1b4d7e0c3f6a9b2d5e8c1f4
created_atstring · date-timeOptionalExample: 2026-07-23T12:00:00Z
updated_atstring · date-timeOptionalExample: 2026-07-23T12:00:00Z
post/api/mail/v1/webhooks/{webhookId}/regenerate-secret
POST /api/mail/v1/webhooks/{webhookId}/regenerate-secret HTTP/1.1
Host: developers.hostinger.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "id": "019683f8-1234-7abc-8def-0123456789ab",
  "mailbox": {
    "id": "AC1a2b3c4d5e6f7g",
    "address": "user@example.com"
  },
  "name": "New message notifier",
  "description": "Notifies our CRM when a new email arrives",
  "events": [
    "message.received"
  ],
  "status": "active",
  "url": "https://example.com/webhooks/incoming",
  "secret": "4a6f8b2d1e9c3f7a0b5d8e2c4f1a7b3d9e6c2f8a1b4d7e0c3f6a9b2d5e8c1f4",
  "created_at": "2026-07-23T12:00:00Z",
  "updated_at": "2026-07-23T12:00:00Z"
}

Last updated

Was this helpful?