Перейти к основному содержанию
WEBHOOK

Авторизации

Authorization
string
header
обязательно

API token from the Zenedu dashboard

Заголовки

Signature
string
обязательно

HMAC-SHA256 of the raw request body, hex. The key is the API token of the account

X-Event-Type
string
обязательно

Event type, the same as event in the body

X-Webhook-ID
string
обязательно

Delivery ID, the same as _id in the body

Тело

application/json

Body of every webhook delivery

_id
string
обязательно

Unique delivery ID (ULID), the same as the X-Webhook-ID header. Retries of a delivery keep it, use it to skip duplicates

Пример:

"01JCQ8Z5W3K7X2M4N6P8R0T2V4"

event
string
обязательно

Event type, the same as the X-Event-Type header

Allowed value: "product.access.expired"
description
string | null
обязательно

Description of the webhook subscription

timestamp
string<date-time>
обязательно

When the event happened (ISO 8601)

data
object
обязательно

Event object, its shape depends on event

Ответ

2XX

Return any 2xx status within 3 seconds to confirm the delivery. Any other status, a connection error or a timeout is retried