获取 Agent 列表
curl --request GET \
--url https://api.senseaudio.cn/v1/realtime/agents \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: <content-type>'import requests
url = "https://api.senseaudio.cn/v1/realtime/agents"
headers = {
"Content-Type": "<content-type>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'Content-Type': '<content-type>', Authorization: 'Bearer <token>'}
};
fetch('https://api.senseaudio.cn/v1/realtime/agents', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.senseaudio.cn/v1/realtime/agents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.senseaudio.cn/v1/realtime/agents"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.senseaudio.cn/v1/realtime/agents")
.header("Content-Type", "<content-type>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.senseaudio.cn/v1/realtime/agents")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"total": 10,
"list": [
{
"id": "690f53770e9d9d60d98ba7a8",
"title": "今天天气怎么样",
"avatar": "https://example.com/avatar1.jpg",
"intro": "今天天气怎么样"
},
{
"id": "8bb494d52b152690f2ff6c58",
"title": "今天天气怎么样",
"avatar": "https://example.com/avatar2.jpg",
"intro": "今天天气怎么样"
}
]
}
实时智能体
获取 Agent 列表
获取平台提供的所有可用语音Agent列表,包括语音Agent的基本信息、角色介绍和适用场景。支持分页查询。
GET
/
v1
/
realtime
/
agents
获取 Agent 列表
curl --request GET \
--url https://api.senseaudio.cn/v1/realtime/agents \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: <content-type>'import requests
url = "https://api.senseaudio.cn/v1/realtime/agents"
headers = {
"Content-Type": "<content-type>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'Content-Type': '<content-type>', Authorization: 'Bearer <token>'}
};
fetch('https://api.senseaudio.cn/v1/realtime/agents', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.senseaudio.cn/v1/realtime/agents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.senseaudio.cn/v1/realtime/agents"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.senseaudio.cn/v1/realtime/agents")
.header("Content-Type", "<content-type>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.senseaudio.cn/v1/realtime/agents")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"total": 10,
"list": [
{
"id": "690f53770e9d9d60d98ba7a8",
"title": "今天天气怎么样",
"avatar": "https://example.com/avatar1.jpg",
"intro": "今天天气怎么样"
},
{
"id": "8bb494d52b152690f2ff6c58",
"title": "今天天气怎么样",
"avatar": "https://example.com/avatar2.jpg",
"intro": "今天天气怎么样"
}
]
}
⌘I