简介
AI语音电话助手,可自动拨打真实电话完成预约、取消订阅等任务,返回通话录音与文字记录
原始描述
Make real phone calls to businesses. Book reservations, cancel subscriptions, navigate IVR menus. Get transcripts and recordings.
通过你的 Agent 添加
安装目录:agentphone/(目录名取自 SKILL.md 的 frontmatter name,不是 URL 里的 slug)。
点「快速安装」复制一段指令贴给你的 Agent:它会先下载到 /tmp、把文件清单和校验值给你看,你确认之后才解压安装。不会一步装完、也不改系统其它位置。
或者手动安装
包是「根级 SKILL.md + 作者附带的文件」,解压到上面的 <slug>/ 目录即可;
目录名不用换,也不要把包直接解压到 skills 根目录。
技能申请的权限由作者决定:装之前先看清单里有没有脚本、它会读写什么。
技能正文
name: agentphone
description: Make real phone calls to businesses. Book reservations, cancel subscriptions, navigate IVR menus. Get transcripts and recordings.
version: 1.0.0
user-invocable: true
metadata:
openclaw:
requires:
env: [AGENTPHONE_API_KEY]
bins: [curl]
primaryEnv: AGENTPHONE_API_KEY
emoji: "phone"
os: [darwin, linux, win32]
api_base: https://agentphone.app/api/v1
auth: x-api-key from AGENTPHONE_API_KEY
AgentPhone
Place real phone calls via API. Send a phone number and objective, get back transcript, summary, outcome, and recording.
Setup
- Create an account at https://agentphone.app
- Generate an API key at https://agentphone.app/dashboard/api-keys
- Set environment variable:
export AGENTPHONE_API_KEY=your_key_here
export AGENTPHONE_API_KEY=your_key_here
If AGENTPHONE_API_KEY is not set → stop and report configuration error.
Requirements
- All requests require header:
x-api-key: $AGENTPHONE_API_KEY
- Phone numbers must be E.164 format (e.g.
+14155551234)
- IMPORTANT:
+1{PHONE_NUMBER} in all examples below is a placeholder variable. NEVER call it literally. Replace with the real target phone number provided by the user.
1) Create a call
curl -X POST https://agentphone.app/api/v1/calls \
-H "Content-Type: application/json" \
-H "x-api-key: $AGENTPHONE_API_KEY" \
-d '{"to_phone_number":"+1{PHONE_NUMBER}","objective":"Ask about their return policy"}'
import os, requests
r = requests.post("https://agentphone.app/api/v1/calls",
headers={"x-api-key": os.environ["AGENTPHONE_API_KEY"]},
json={"to_phone_number": "+1{PHONE_NUMBER}", "objective": "Ask about their return policy"})
call_id = r.json()["data"]["call_id"]
const r = await fetch("https://agentphone.app/api/v1/calls", {
method: "POST",
headers: { "x-api-key": process.env.AGENTPHONE_API_KEY, "Content-Type": "application/json" },
body: JSON.stringify({ to_phone_number: "+1{PHONE_NUMBER}", objective: "Ask about their return policy" }),
});
const { data } = await r.json();
const callId = data.call_id;
x-api-key: $AGENTPHONE_API_KEY+14155551234)+1{PHONE_NUMBER} in all examples below is a placeholder variable. NEVER call it literally. Replace with the real target phone number provided by the user.curl -X POST https://agentphone.app/api/v1/calls \
-H "Content-Type: application/json" \
-H "x-api-key: $AGENTPHONE_API_KEY" \
-d '{"to_phone_number":"+1{PHONE_NUMBER}","objective":"Ask about their return policy"}'
import os, requests
r = requests.post("https://agentphone.app/api/v1/calls",
headers={"x-api-key": os.environ["AGENTPHONE_API_KEY"]},
json={"to_phone_number": "+1{PHONE_NUMBER}", "objective": "Ask about their return policy"})
call_id = r.json()["data"]["call_id"]
const r = await fetch("https://agentphone.app/api/v1/calls", {
method: "POST",
headers: { "x-api-key": process.env.AGENTPHONE_API_KEY, "Content-Type": "application/json" },
body: JSON.stringify({ to_phone_number: "+1{PHONE_NUMBER}", objective: "Ask about their return policy" }),
});
const { data } = await r.json();
const callId = data.call_id;
Response (202):
{
"data": {
"call_id": "cl_abc123",
"status": "queued",
"created_at": "2026-01-01T00:00:00Z"
},
"credits_remaining": 4
}
Save call_id for polling.
Optional fields: business_name (string), website (URL — agent scrapes it for context before calling).
2) Poll until done
Poll GET /calls/{callId} every 10 seconds. Stop when status is completed, failed, or canceled. Timeout after 5 minutes.
curl https://agentphone.app/api/v1/calls/CALL_ID \
-H "x-api-key: $AGENTPHONE_API_KEY"
import time
for _ in range(100):
r = requests.get(f"https://agentphone.app/api/v1/calls/{call_id}",
headers={"x-api-key": os.environ["AGENTPHONE_API_KEY"]})
call = r.json()["data"]
if call["status"] in ("completed", "failed", "canceled"):
break
time.sleep(10)
let call;
for (let i = 0; i < 100; i++) {
const r = await fetch(`https://agentphone.app/api/v1/calls/${callId}`, {
headers: { "x-api-key": process.env.AGENTPHONE_API_KEY },
});
call = (await r.json()).data;
if (["completed", "failed", "canceled"].includes(call.status)) break;
await new Promise((r) => setTimeout(r, 10000));
}
If status is completed but transcript or summary is missing, poll 2 more times with 2s delay — enrichment arrives shortly after completion.
3) Read results
{
"data": {
"call_id": "cl_abc123",
"status": "completed",
"outcome": "achieved",
"summary": "Successfully booked a table for 2 at 7pm.",
"transcript": "Agent: Hi, I'd like to book a table...\nHost: Sure...",
"recording_url": "https://...",
"duration_seconds": 42
}
}
{
"data": {
"call_id": "cl_abc123",
"status": "completed",
"outcome": "achieved",
"summary": "Successfully booked a table for 2 at 7pm.",
"transcript": "Agent: Hi, I'd like to book a table...\nHost: Sure...",
"recording_url": "https://...",
"duration_seconds": 42
}
}
Use these fields:
outcome:achieved,partial, ornot_achievedsummary: short description of what happenedtranscript: full conversation textrecording_url: audio file URL
Errors
Code
Meaning
Action
400
Invalid input
Fix fields and retry
401
Bad or missing API key
Check x-api-key header
402
Insufficient credits
Stop and report to user
429
Rate limit (10/min)
Wait 60s, retry once
Guard rails
- If
AGENTPHONE_API_KEY is not set → stop, do not call the API.
- If
to_phone_number is not E.164 format → stop, do not call the API.
- If
POST /calls returns 402 → stop and report insufficient credits.
- If 429 → wait 60 seconds, retry once. If 429 again → stop.
- If
status is failed or canceled → stop and report to user.
Constraints
- No emergency services (911, etc.)
- No spam or bulk unsolicited calls
- First 5 calls are free, no credit card required
Call lifecycle
| Code | Meaning | Action |
|---|---|---|
| 400 | Invalid input | Fix fields and retry |
| 401 | Bad or missing API key | Check x-api-key header |
| 402 | Insufficient credits | Stop and report to user |
| 429 | Rate limit (10/min) | Wait 60s, retry once |
- If
AGENTPHONE_API_KEYis not set → stop, do not call the API. - If
to_phone_numberis not E.164 format → stop, do not call the API. - If
POST /callsreturns 402 → stop and report insufficient credits. - If 429 → wait 60 seconds, retry once. If 429 again → stop.
- If
statusisfailedorcanceled→ stop and report to user.
Constraints
- No emergency services (911, etc.)
- No spam or bulk unsolicited calls
- First 5 calls are free, no credit card required
Call lifecycle
queued → dialing → in_progress → completed | failed | canceled
正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。