logo
On this page

AddAgentInstanceMsg

POST

https://aigc-aiagent-api.zegotech.cn/

Used to insert messages into the agent instance context list. This interface does not trigger LLM callbacks, subtitle updates, does not increase dialogue rounds, and does not store messages in ZIM history.

Request

Query Parameters

    Action stringrequired

    Possible values: [AddAgentInstanceMsg]

    Interface prototype parameter

    https://aigc-aiagent-api.zegotech.cn?Action=AddAgentInstanceMsg

    AppId uint32required

    💡Public parameter. Application ID, assigned by ZEGOCLOUD. Get it from the ZEGOCLOUD Admin Console.

    SignatureNonce stringrequired

    💡Public parameter. A 16-character hexadecimal random string (hex encoding of 8-byte random number). Refer to Signature sample code for how to generate.

    Timestamp int64required

    💡Public parameter. Current Unix timestamp, in seconds. Refer to Signature sample code for how to generate, with a maximum error of 10 minutes.

    Signature stringrequired

    💡Public parameter. Signature, used to verify the legitimacy of the request. Refer to Signing the requests for how to generate an API request signature.

    SignatureVersion stringrequired

    Possible values: [2.0]

    Default value: 2.0

    💡Public parameter. Signature version number.

Body

required
    AgentInstanceId stringrequired

    The unique identifier of the agent instance, globally unique. Obtained from the response parameter of the Create Agent Instance interface.

    Messages object[]
    List of dialogue context messages to be inserted
  • Array[
  • Role stringrequired

    Possible values: [user, assistant]

    The role of the message sender:

    • user: User
    • assistant: AI agent
    Content stringrequired

    Message content

  • ]

Responses​

Added successfully
Schema
    Code integer

    Return code, 0 indicates success, other values indicate failure. For details, please refer to Return Codes.

    Message string

    Request result description

    RequestId string

    Request ID

Previous

Reset Agent Instance Context

Next

Receiving Callback

On this page

Back to top