Hatırlatıcılar API'si
Hatırlatıcıları listeleme API'si
Çalışma alanınızdaki hatırlatıcıları, en yeniden başlayarak 50'şer adet alın. Hatırlatıcı ID'lerini bulmak, otomasyonlarınızı denetlemek veya yedeklemek için kullanın.
https://wbiztool.com/api/v1/reminder/list/Gövde: JSON veya form alanları
Bu endpoint yalnızca POST kabul eder. Bir GET isteği, sorgu dizesiyle bile, Invalid JSON format: Expecting value… ile HTTP 400 döndürür.
Liste, API üzerinden veya Hatırlatıcılar sayfasından oluşturulmuş olmalarına bakılmaksızın tüm çalışma alanındaki etkin ve duraklatılmış hatırlatıcıları içerir. İptal edilen hatırlatıcılar dahil değildir.
Hızlı örnek#
curl -X POST https://wbiztool.com/api/v1/reminder/list/ \
-H "Content-Type: application/json" \
-d '{
"client_id": 12345,
"api_key": "YOUR_API_KEY",
"page": 1
}'import requests
response = requests.post(
"https://wbiztool.com/api/v1/reminder/list/",
json={"client_id": 12345, "api_key": "YOUR_API_KEY", "page": 1},
timeout=60,
)
try:
result = response.json() # read the body even when the HTTP code is 400
except ValueError:
raise SystemExit(f"HTTP {response.status_code}: not JSON. Check that your api_key exists.")
if result["status"] == 1:
print(f"{result['total']} reminders in total")
for reminder in result["reminders"]:
print(reminder["id"], reminder["name"], reminder["cron_expression"], reminder["is_active"])
else:
print("Failed:", result["message"])// Node.js 18+ (built-in fetch). Save as .mjs to use top-level await.
const response = await fetch("https://wbiztool.com/api/v1/reminder/list/", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ client_id: 12345, api_key: "YOUR_API_KEY", page: 1 }),
});
// Read the body even when the HTTP code is 400. A non-JSON reply means the api_key wasn't found.
const text = await response.text();
let result;
try {
result = JSON.parse(text);
} catch {
throw new Error(`HTTP ${response.status}: not JSON. Check that your api_key exists.`);
}
if (result.status === 1) {
console.log(`${result.total} reminders in total`);
for (const reminder of result.reminders) {
console.log(reminder.id, reminder.name, reminder.cron_expression, reminder.is_active);
}
} else {
console.error("Failed:", result.message);
}<?php
$ch = curl_init('https://wbiztool.com/api/v1/reminder/list/');
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => ['Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'client_id' => 12345,
'api_key' => 'YOUR_API_KEY',
'page' => 1,
]),
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 60,
]);
$result = json_decode(curl_exec($ch), true);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($result === null) {
echo "HTTP $httpCode: not JSON. Check that your api_key exists.";
} elseif ($result['status'] === 1) {
foreach ($result['reminders'] as $reminder) {
echo $reminder['id'] . ' ' . $reminder['name'] . ' ' . $reminder['cron_expression'] . "\n";
}
} else {
echo 'Failed: ' . $result['message'];
}12345 ve YOUR_API_KEY değerlerini kendi değerlerinizle değiştirin. Bunları nerede bulacağınız için Kimlik doğrulama bölümüne bakın.
İstek parametreleri#
client_idintegerzorunluAyarlar → API anahtarları sayfasındaki API Client ID'niz.
api_keystringzorunluAynı sayfadaki API anahtarınız.
pageintegeristeğe bağlıSayfa numarası,
1(varsayılan) ile başlar. Her sayfa 50 hatırlatıcı içerir ve sayfa boyutu değiştirilemez. 1 veya daha büyük bir tam sayı olmayan değer1olarak değerlendirilir.
Yanıt#
Başarılı bir istek HTTP 200 döndürür:
{
"reminders": [
{
"id": 3187,
"name": "Monthly rent reminder",
"to_number": "919876543210",
"message_template": "Hi Aman, a reminder that your rent is due on {current_date_formatted}.",
"msg_type": 0,
"msg_type_display": "Text",
"img_url": "",
"file_name": "",
"cron_expression": "0 10 1 * *",
"next_run": "2026-10-01 10:00:00 UTC",
"is_active": true,
"whatsapp_client_id": 678,
"created_at": "2026-09-16 04:45:12"
}
],
"total": 1,
"page": 1,
"page_size": 50,
"message": "Success",
"status": 1
}
| Alan | Tür | Açıklama |
|---|---|---|
status | integer | Başarıda 1, istek başarısız olduysa 0. |
message | string | Success, aksi halde hata mesajı. |
reminders | dizi | Bu sayfadaki hatırlatıcılar, en yeniden başlayarak. Sayfa sonun ötesindeyse boştur. |
total | integer | Tüm sayfalarda, çalışma alanındaki hatırlatıcılar. |
page | integer | Döndürülen sayfa. |
page_size | integer | Her zaman 50. |
Hatırlatıcı alanları#
| Alan | Tür | Açıklama |
|---|---|---|
id | integer | Hatırlatıcı ID'si. Hatırlatıcı iptal etme ile kullanın. |
name | string | Hatırlatıcının adı; adı yoksa Unnamed Reminder. |
to_number | string | Hatırlatıcının gönderildiği telefon numarası veya grup adı. |
message_template | string | Şablon değişkenleri henüz doldurulmamış mesaj. |
msg_type | integer | 0 metin, 1 görsel, 2 dosya. |
msg_type_display | string | Text, Image veya File. |
img_url | string veya null | Görsel hatırlatıcılarda görsel URL'si veya API üzerinden oluşturulan dosya hatırlatıcılarında dosya URL'si. Diğer durumlarda boş veya null olabilir. |
file_name | string veya null | Dosya hatırlatıcılarında: dosya URL'si (panelde oluşturulan hatırlatıcılar) veya dosya adı (URL'si img_url içinde olan, API üzerinden oluşturulan hatırlatıcılar). Diğer durumlarda boş veya null olabilir. |
cron_expression | string | Zamanlama. Bkz. Cron ifadeleri. |
next_run | string | Zamanlamanın bir sonraki eşleşme zamanı, YYYY-MM-DD HH:MM:SS UTC biçiminde; ifade okunamıyorsa Invalid cron. Aşağıdaki uyarıya bakın. |
is_active | boolean | Hatırlatıcı çalışıyorsa true, duraklatılmışsa false. |
whatsapp_client_id | integer veya null | Gönderimin yapıldığı WhatsApp numarası; ilk bağlı numarayı kullanıyorsa null. |
created_at | string | Hatırlatıcının oluşturulduğu zaman, UTC'de, YYYY-MM-DD HH:MM:SS biçiminde. |
Hatalar#
Aksi belirtilmedikçe hatalar, status değeri 0 olarak HTTP 400 döndürür:
{ "status": 0, "message": "Upgrade your plan to use reminders feature" }
| Mesaj | Nasıl düzeltilir |
|---|---|
Invalid JSON format: … | JSON gövdesi geçerli değil. Bunu bir GET isteğinde veya client_id olmayan bir form isteğinde de alırsınız. |
Auth Error - Please send correct API key and Client id | client_id ve api_key değerlerinin ikisini de gönderin. |
Invalid client id | client_id değerini sayı olarak gönderin. |
Auth Error: invalid api key | Anahtar farklı bir client_id değerine ait. |
Auth Error: please check client id | Anahtar bir çalışma alanına bağlı değil. Kullanmak istediğiniz çalışma alanında yeni bir anahtar oluşturun. |
Demo Account cannot access APIs | Normal bir hesap kullanın. |
Upgrade your plan to use reminders feature | Planınız hatırlatıcıları içermiyor. Planınızı yükseltin. Mevcut hatırlatıcılar plan düşürüldükten sonra çalışmaya ve kredi harcamaya devam eder; planınızı yükseltene kadar listelenemez, iptal edilemez veya duraklatılamazlar. |
Error fetching reminders: … (HTTP 500) | Bizim tarafımızda bir sorun oluştu. Tekrar deneyin. |
api_key mevcut değilse veya silinmişse, yanıt JSON yerine HTTP 500 ile bir HTML hata sayfasıdır. Anahtarınızı Kimlik bilgilerini kontrol etme ile test edin.
Her sayfayı okuma#
Bir sayfa 50'den az hatırlatıcı içerene kadar sonraki sayfayı istemeye devam edin.
import requests
reminders, page = [], 1
while True:
response = requests.post(
"https://wbiztool.com/api/v1/reminder/list/",
json={"client_id": 12345, "api_key": "YOUR_API_KEY", "page": page},
timeout=60,
)
try:
result = response.json()
except ValueError:
raise SystemExit(f"HTTP {response.status_code}: not JSON. Check that your api_key exists.")
if result["status"] != 1:
raise RuntimeError(result["message"])
reminders += result["reminders"]
if len(result["reminders"]) < result["page_size"]:
break
page += 1
print(len(reminders), "reminders")// Node.js 18+ (built-in fetch). Save as .mjs to use top-level await.
const reminders = [];
let page = 1;
while (true) {
const response = await fetch("https://wbiztool.com/api/v1/reminder/list/", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ client_id: 12345, api_key: "YOUR_API_KEY", page }),
});
const text = await response.text();
let result;
try {
result = JSON.parse(text);
} catch {
throw new Error(`HTTP ${response.status}: not JSON. Check that your api_key exists.`);
}
if (result.status !== 1) throw new Error(result.message);
reminders.push(...result.reminders);
if (result.reminders.length < result.page_size) break;
page += 1;
}
console.log(reminders.length, "reminders");İpuçları#
- Kendi kopyanızı saklayın: bu endpoint döndürmediği için, her hatırlatıcıyı oluştururken
timezonedeğerini kendiniz kaydedin. - Duraklatılmış hatırlatıcıları bulun:
is_activedeğerifalseolanları filtreleyin. Onları Hatırlatıcılar sayfasında devam ettirin. - Eski otomasyonları temizleyin: önce iptal etmek istediğiniz ID'leri tüm sayfalardan toplayın, ardından her biri için Hatırlatıcı iptal etme endpoint'ini çağırın. Sayfalarken iptal etmek, sonraki hatırlatıcıları önceki sayfalara kaydırır ve bazıları atlanır.
