Create agent conversation
This endpoint creates a new conversation between a user and the agent.
POST
/Agent/conversationThis endpoint creates a new conversation between a user and the agent.
Authentication
Authentication required. Send your user API key in the X-API-Key header.
Parameters
This operation has no path, query, or header parameters.
Request body
Content type: application/json · Schema: AgentConversationRequestDto
| Property | Type | Required | Description | Constraints |
|---|---|---|---|---|
agentId | integer · int32 | No | — | — |
inputMessage | string | No | — | nullable |
messageType | MessageType | No | — | — |
mediaFileName | string | No | — | nullable |
mediaUrl | string | No | — | nullable |
documentId | integer · int32 | No | — | — |
Example request
curl --request POST \
--url 'https://api.zild.ai/Agent/conversation' \
--header 'X-API-Key: YOUR_USER_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"agentId": 0,
"inputMessage": "string",
"messageType": 0,
"mediaFileName": "string",
"mediaUrl": "string",
"documentId": 0
}'
Responses
| Status | Description | Response body |
|---|---|---|
200 | Conversation created successfully | No response body is defined. |
Data models
AgentConversationRequestDto
| Property | Type | Required | Description | Constraints |
|---|---|---|---|---|
agentId | integer · int32 | No | — | — |
inputMessage | string | No | — | nullable |
messageType | MessageType | No | — | — |
mediaFileName | string | No | — | nullable |
mediaUrl | string | No | — | nullable |
documentId | integer · int32 | No | — | — |
MessageType
0 = Text; 1 = Image; 2 = File; 3 = Audio; 4 = Video; 5 = Internal; 6 = TemplateMarketing; 7 = TemplateUtility; 8 = Location; 9 = Contact
integer