リマインダーAPI
リマインダー一覧API
ワークスペース内のリマインダーを、50件ずつ新しい順に取得します。リマインダーIDの確認、自動化の点検、バックアップなどに利用できます。
POST
https://wbiztool.com/api/v1/reminder/list/リクエストボディ: JSONまたはフォームフィールド
このエンドポイントはPOSTのみを受け付けます。GETリクエストは、クエリ文字列を付けても、HTTP 400でInvalid JSON format: Expecting value…を返します。
一覧には、API経由で作成したかリマインダーページで作成したかにかかわらず、ワークスペース全体の有効なリマインダーと一時停止中のリマインダーが含まれます。キャンセルされたリマインダーは含まれません。
クイック例#
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とYOUR_API_KEYはご自身の値に置き換えてください。値の確認場所は認証をご覧ください。
リクエストパラメータ#
client_idinteger必須設定 → APIキーに表示されるAPIクライアントIDです。
api_keystring必須同じページにあるAPIキーです。
pageinteger任意ページ番号で、
1(デフォルト)から始まります。1ページには50件のリマインダーが含まれ、ページサイズは変更できません。1以上の整数でない値は1として扱われます。
レスポンス#
リクエストが成功すると、HTTP 200が返ります。
{
"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
}
| フィールド | 型 | 説明 |
|---|---|---|
status | integer | 成功時は1、リクエストが失敗した場合は0。 |
message | string | Success、それ以外はエラー内容。 |
reminders | array | このページのリマインダー(新しい順)。ページが末尾を超えている場合は空です。 |
total | integer | 全ページを通じた、ワークスペース内のリマインダーの数。 |
page | integer | 返されたページ。 |
page_size | integer | 常に50。 |
リマインダーのフィールド#
| フィールド | 型 | 説明 |
|---|---|---|
id | integer | リマインダーID。リマインダーのキャンセルで使用します。 |
name | string | リマインダーの名前。名前がない場合はUnnamed Reminder。 |
to_number | string | リマインダーの送信先の電話番号またはグループ名。 |
message_template | string | テンプレート変数に値が入る前のメッセージ。 |
msg_type | integer | 0テキスト、1画像、2ファイル。 |
msg_type_display | string | Text、Image、Fileのいずれか。 |
img_url | string or null | 画像リマインダーの画像URL、またはAPIで作成したファイルリマインダーのファイルURL。それ以外の場合は空またはnullになることがあります。 |
file_name | string or null | ファイルリマインダーの場合:ファイルURL(ダッシュボードで作成したリマインダー)またはファイル名(APIで作成したリマインダー。URLはimg_urlに入ります)。それ以外の場合は空またはnullになることがあります。 |
cron_expression | string | スケジュール。cron式を参照してください。 |
next_run | string | 次にスケジュールが一致する日時で、YYYY-MM-DD HH:MM:SS UTC形式。式を読み取れない場合はInvalid cron。下の注意事項を参照してください。 |
is_active | boolean | リマインダーが実行中の場合はtrue、一時停止中の場合はfalse。 |
whatsapp_client_id | integer or null | 送信に使うWhatsApp番号。最初の接続済み番号を使う場合はnull。 |
created_at | string | リマインダーが作成された日時(UTC)で、YYYY-MM-DD HH:MM:SS形式。 |
エラー#
特に記載がない限り、エラーはHTTP 400で返り、statusは0になります。
{ "status": 0, "message": "Upgrade your plan to use reminders feature" }
| メッセージ | 対処方法 |
|---|---|
Invalid JSON format: … | JSONボディが無効です。GETリクエストや、client_idなしのフォームリクエストでもこのエラーになります。 |
Auth Error - Please send correct API key and Client id | client_idとapi_keyの両方を送信してください。 |
Invalid client id | client_idを数値で送信してください。 |
Auth Error: invalid api key | キーが別のclient_idに属しています。 |
Auth Error: please check client id | キーがワークスペースに紐付いていません。使用したいワークスペースで新しいキーを作成してください。 |
Demo Account cannot access APIs | 通常のアカウントを使用してください。 |
Upgrade your plan to use reminders feature | ご利用のプランにはリマインダーが含まれていません。プランをアップグレードしてください。ダウングレード後も、既存のリマインダーは実行され続けてクレジットを消費しますが、アップグレードするまで一覧の取得、キャンセル、一時停止はできません。 |
Error fetching reminders: …(HTTP 500) | サーバー側で問題が発生しました。もう一度お試しください。 |
api_keyが存在しないか削除されている場合、レスポンスはJSONではなく、HTTP 500のHTMLエラーページになります。認証情報の確認でキーをテストしてください。
すべてのページを読み取る#
リマインダーが50件未満のページが返るまで、次のページをリクエストし続けてください。
すべてのリマインダーを取得する
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");ヒント#
- 自分でコピーを保存する:このエンドポイントは
timezoneを返さないため、作成時に各リマインダーのtimezoneを保存しておいてください。 - 一時停止中のリマインダーを見つける:
is_activeがfalseのものを絞り込みます。再開はリマインダーページで行ってください。 - 古い自動化を整理する:まずすべてのページからキャンセルしたいIDを集め、その後それぞれに対してリマインダーのキャンセルを呼び出してください。ページを読み進めながらキャンセルすると、後のリマインダーが前のページにずれるため、一部が読み飛ばされます。
