Обработчики уведомлений
GET https://linkindrive.com/api/notification-handlers/
curl --request GET \
--url 'https://linkindrive.com/api/notification-handlers/' \
--header 'Authorization: Bearer {api_key}' \
--url 'https://linkindrive.com/api/notification-handlers/' \
--header 'Authorization: Bearer {api_key}' \
Параметры | Подробнее | Описание |
---|---|---|
page | По желанию Целое число | Номер страницы, с которой вы хотите получить результаты. По умолчанию 1 . |
results_per_page | По желанию Целое число | Сколько результатов вы хотите на странице. Допустимые значения: 10 , 25 , 50 , 100 , 250 , 500 , 1000 . По умолчанию 25 . |
{ "data": [ { "id": 1, "type": "email", "name": "Work email", "settings": { "email": "hey@example.com" }, "is_enabled": true, "last_datetime": null, "datetime": "2025-10-21 20:14:42", } ], "meta": { "page": 1, "results_per_page": 25, "total": 1, "total_pages": 1 }, "links": { "first": "https://linkindrive.com/api/notification-handlers?page=1", "last": "https://linkindrive.com/api/notification-handlers?page=1", "next": null, "prev": null, "self": "https://linkindrive.com/api/notification-handlers?page=1" } }
GET https://linkindrive.com/api/notification-handlers/{notification_handler_id}
curl --request GET \
--url 'https://linkindrive.com/api/notification-handlers/{notification_handler_id}' \
--header 'Authorization: Bearer {api_key}' \
--url 'https://linkindrive.com/api/notification-handlers/{notification_handler_id}' \
--header 'Authorization: Bearer {api_key}' \
{ "data": { "id": 1, "type": "email", "name": "Work email", "settings": { "email": "hey@example.com" }, "is_enabled": true, "last_datetime": null, "datetime": "2025-10-21 20:14:42", } }
POST https://linkindrive.com/api/notification-handlers
Параметры | Подробнее | Описание |
---|---|---|
name | Необходимый Нить | - |
type | Необходимый Нить | Допустимые значения: email , webhook , telegram , internal_notification , push_subscriber_id |
По желанию Нить | Доступно, когда: type = email Email | |
webhook | По желанию Нить | Доступно, когда: type = webhook Webhook URL |
telegram | По желанию Нить | Доступно, когда: type = telegram Telegram API Token |
telegram_chat_id | По желанию Нить | Доступно, когда: type = telegram Telegram Chat ID |
push_subscriber_id | По желанию Нить | Доступно, когда: type = push_subscriber_id Подписчик push-уведомлений |
curl --request POST \
--url 'https://linkindrive.com/api/notification-handlers' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: multipart/form-data' \
--form 'name=Example' \
--form 'type=email' \
--form 'email=hello@example.com' \
--url 'https://linkindrive.com/api/notification-handlers' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: multipart/form-data' \
--form 'name=Example' \
--form 'type=email' \
--form 'email=hello@example.com' \
{ "data": { "id": 1 } }
POST https://linkindrive.com/api/notification-handlers/{notification_handler_id}
Параметры | Подробнее | Описание |
---|---|---|
name | По желанию Нить | - |
type | По желанию Нить | Допустимые значения: email , webhook , telegram , internal_notification , push_subscriber_id |
По желанию Нить | Доступно, когда: type = email Email | |
webhook | По желанию Нить | Доступно, когда: type = webhook Webhook URL |
telegram | По желанию Нить | Доступно, когда: type = telegram Telegram API Token |
telegram_chat_id | По желанию Нить | Доступно, когда: type = telegram Telegram Chat ID |
push_subscriber_id | По желанию Нить | Доступно, когда: type = push_subscriber_id Подписчик push-уведомлений |
is_enabled | По желанию Логический | - |
curl --request POST \
--url 'https://linkindrive.com/api/notification-handlers/{notification_handler_id}' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: multipart/form-data' \
--form 'name=Example new name' \
--form 'is_enabled=1' \
--url 'https://linkindrive.com/api/notification-handlers/{notification_handler_id}' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: multipart/form-data' \
--form 'name=Example new name' \
--form 'is_enabled=1' \
{ "data": { "id": 1 } }
DELETE https://linkindrive.com/api/notification-handlers/{notification_handler_id}
curl --request DELETE \
--url 'https://linkindrive.com/api/notification-handlers/{notification_handler_id}' \
--header 'Authorization: Bearer {api_key}' \
--url 'https://linkindrive.com/api/notification-handlers/{notification_handler_id}' \
--header 'Authorization: Bearer {api_key}' \