logo
On this page

Query AI Agent Details


Description

By calling this API, you can obtain the details of specified AI agents.

Request prototype

  • Request method: POST
  • Request body format: JSON
  • Request URL: https://aigc-aiagent-api.zegotech.cn?Action=QueryAgents
  • Transmission protocol: HTTPS
  • QPS limit: 10 times/second

Request Parameters

Listed below are the parameters specific to this request and part of the common request parameters. For the complete list of common request parameters, see Accessing Server APIs - Common request parameters.

ParameterTypeRequiredDescription
AgentIdsArray of StringYesList of registered AI agent IDs, including no more than 10 IDs.

Sample Request

  • Request URL:

    Untitled
    https://aigc-aiagent-api.zegotech.cn?Action=QueryAgents
    &<Common request parameters>
    
    1
    Copied!
  • Request body:

    Untitled
    {
        "AgentIds": ["xiaozhi"]
    }
    
    1
    Copied!

Response Parameters

ParameterTypeDescription
CodeNumberReturn code. 0 indicates success, other values indicate failure. For more information on error codes and response handling recommendations, please refer to Return Codes.
MessageStringExplanation of the request result.
RequestIdStringRequest ID.
DataObjectReturned data.
└AgentsArray of ObjectList of AI agents. For the structure of this parameter, please refer to Frequently Used Parameters - Agents.

Sample Response

Untitled
{
    "Code": 0,
    "Message": "success",
    "RequestId": "8825223157230377926",
    "Data": {
        "Agents": [
            {
                "AgentId": "xiaozhi",
                "Name": "Xiao Zhi",
                "LLM": {
                    "Url": "https://ark.cn-beijing.volces.com/api/v3/chat/completions",
                    "ApiKey": "eexxxxxxxxxxxxxxx",
                    "Model": "ep-xxxxxxxxxx",
                    "SystemPrompt": "You are Xiaozhi, an adult woman, a companion assistant **created by ZEGO**. knowledgeable in both astronomy and geography, intelligent, wise, enthusiastic, and friendly. \nDialogue requirements: 1. Dialogue with users according to the requirements of the persona. \n2.No more than 100 words."
                },
                "TTS": {
                    "Vendor": "Bytedance",
                    "Params": {
                        "app": {
                            "appid": "your_appid",
                            "cluster": "volcano_tts",
                            "token": "your_token"
                        },
                        "audio": {
                            "emotion": "your_emotion",
                            "enable_emotion": true,
                            "speed_ratio": 1,
                            "voice_type": "your_voice_type"
                        }
                    }
                },
                "ASR": {}
            }
        ],
    }
}
1
Copied!

Previous

List Agents

Next

Create Agent Instance