获取绑定频道
使用其原始ID或文章URL,查找绑定到微信公众号的微信视频号账号。用于将公众号与其视频号身份关联起来。
参数
| 参数 | 必填 | 类型 | 说明 | 示例 | 可选值 |
|---|---|---|---|---|---|
ghid |
可选 | string | 用于查找绑定视频号账号的微信公众号原始 ID。使用 ghid 或 url。 | — | — |
url |
可选 | string | 用于查找绑定视频号账号的微信公众号文章 URL。使用 ghid 或 url。 | — | — |
代码示例
curl "https://api.mofa-ai.com/v1/weixin_channels/get_bound_channel_v1" \
-H "Authorization: Bearer $MOFA_API_KEY"
import os
import requests
resp = requests.get(
"https://api.mofa-ai.com/v1/weixin_channels/get_bound_channel_v1",
headers={"Authorization": f"Bearer {os.environ['MOFA_API_KEY']}"},
timeout=60,
)
body = resp.json()
if body["success"]:
print(body["cost_usd"], body["data"])
else:
print(body["error"], body["message"])
const url = new URL("https://api.mofa-ai.com/v1/weixin_channels/get_bound_channel_v1");
const resp = await fetch(url, {
headers: { Authorization: `Bearer ${process.env.MOFA_API_KEY}` },
});
const body = await resp.json();
if (body.success) console.log(body.cost_usd, body.data);
else console.error(body.error, body.message);
在线试用
登录后可以在这里直接调用此接口,按价格从余额扣费,失败不收费。新账户赠送 $0.50 试用额度。
响应示例
这个接口暂无响应示例。