API リファレンス

Receiving Events

call.ended

call.ended は通話の終了を示し、data.call.id、reason、duration_seconds を含みます。発信イベントを受け取るには subscribed_events に call.ended を指定します。

Event payload

{
  "id": "evt_call_example",
  "type": "call.ended",
  "provider": "whatsapp",
  "account_id": "acc_example",
  "occurred_at": "2026-10-10T12:00:42Z",
  "data": {
    "call": {
      "id": "call_example",
      "direction": "outbound",
      "media_type": "voice",
      "state": "ended"
    },
    "reason": "remote_hangup",
    "duration_seconds": 42
  }
}

注記

  • call.ended は通話の終了を示し、data.call.id、reason、duration_seconds を含みます。発信イベントを受け取るには subscribed_events に call.ended を指定します。
  • 通常のワークスペースでは、発信の call.answered と call.ended を受け取るには subscribed_events に明示します。ベータのワークスペースでは *、空リスト、省略も利用できます。配信、再試行、デッドレターの再処理では最新の資格と購読を確認します。message.* の通話記録は別扱いです。
  • duration_seconds は接続時間の秒未満切り捨てです。0 だけで未接続とは判断できず、call.answered も記録してください。作成時の同期エラーでは call.ended がない場合があります。チャットのシステムメッセージとは別です。