دستگیرندگان اعلان
GET https://firstuptime.ir/api/notification-handlers/
curl --request GET \
--url 'https://firstuptime.ir/api/notification-handlers/' \
--header 'Authorization: Bearer {api_key}' \
--url 'https://firstuptime.ir/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-12-06 06:04:35"
}
],
"meta": {
"page": 1,
"results_per_page": 25,
"total": 1,
"total_pages": 1
},
"links": {
"first": "https://firstuptime.ir/api/notification-handlers?&page=1",
"last": "https://firstuptime.ir/api/notification-handlers?&page=1",
"next": null,
"prev": null,
"self": "https://firstuptime.ir/api/notification-handlers?&page=1"
}
}
GET https://firstuptime.ir/api/notification-handlers/{notification_handler_id}
curl --request GET \
--url 'https://firstuptime.ir/api/notification-handlers/{notification_handler_id}' \
--header 'Authorization: Bearer {api_key}' \
--url 'https://firstuptime.ir/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-12-06 06:04:35"
}
}
POST https://firstuptime.ir/api/notification-handlers
| پارامترها | جزئیات | توضیحات |
|---|---|---|
| name | الزام رشته | - |
| type | الزام رشته | مقادیر مجاز: email , webhook , slack , discord , telegram , microsoft_teams |
| اختیاری رشته | در دسترس است زمانی که: type = email ایمیل | |
| webhook | اختیاری رشته | در دسترس است زمانی که: type = webhook URL Webhook |
| slack | اختیاری رشته | در دسترس است زمانی که: type = slack URL Webhook Slack |
| discord | اختیاری رشته | در دسترس است زمانی که: type = discord آدرس وب هوک دیسکورد |
| telegram | اختیاری رشته | در دسترس است زمانی که: type = telegram نشانه API تلگرام |
| telegram_chat_id | اختیاری رشته | در دسترس است زمانی که: type = telegram شناسه چت تلگرام |
| x_consumer_key | اختیاری رشته | در دسترس است زمانی که: type = x نشانه API تلگرام |
| x_consumer_secret | اختیاری رشته | در دسترس است زمانی که: type = x نشانه API تلگرام |
| x_access_token | اختیاری رشته | در دسترس است زمانی که: type = x نشانه API تلگرام |
| x_access_token_secret | اختیاری رشته | در دسترس است زمانی که: type = x نشانه API تلگرام |
curl --request POST \
--url 'https://firstuptime.ir/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://firstuptime.ir/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://firstuptime.ir/api/notification-handlers/{notification_handler_id}
| پارامترها | جزئیات | توضیحات |
|---|---|---|
| name | اختیاری رشته | - |
| type | اختیاری رشته | مقادیر مجاز: email , webhook , slack , discord , telegram , microsoft_teams |
| اختیاری رشته | در دسترس است زمانی که: type = email ایمیل | |
| webhook | اختیاری رشته | در دسترس است زمانی که: type = webhook URL Webhook |
| slack | اختیاری رشته | در دسترس است زمانی که: type = slack URL Webhook Slack |
| discord | اختیاری رشته | در دسترس است زمانی که: type = discord آدرس وب هوک دیسکورد |
| telegram | اختیاری رشته | در دسترس است زمانی که: type = telegram نشانه API تلگرام |
| telegram_chat_id | اختیاری رشته | در دسترس است زمانی که: type = telegram شناسه چت تلگرام |
| x_consumer_key | اختیاری رشته | در دسترس است زمانی که: type = x نشانه API تلگرام |
| x_consumer_secret | اختیاری رشته | در دسترس است زمانی که: type = x نشانه API تلگرام |
| x_access_token | اختیاری رشته | در دسترس است زمانی که: type = x نشانه API تلگرام |
| x_access_token_secret | اختیاری رشته | در دسترس است زمانی که: type = x نشانه API تلگرام |
| is_enabled | اختیاری بولی | - |
curl --request POST \
--url 'https://firstuptime.ir/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://firstuptime.ir/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://firstuptime.ir/api/notification-handlers/{notification_handler_id}
curl --request DELETE \
--url 'https://firstuptime.ir/api/notification-handlers/{notification_handler_id}' \
--header 'Authorization: Bearer {api_key}' \
--url 'https://firstuptime.ir/api/notification-handlers/{notification_handler_id}' \
--header 'Authorization: Bearer {api_key}' \