Get a list of messages for a specific chat.
curl --request GET \
--url https://api.useinvent.com/chats/{chat_id}/messages[
{
"id": "<string>",
"role": "user",
"model": "<string>",
"status": "RUNNING",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"messages": [
{
"role": "system",
"parts": [
{
"type": "text",
"text": "<string>",
"audio": {
"id": "<string>",
"file_path": "<string>",
"file_filename": "document.pdf",
"file_size": 1024,
"file_mimetype": "application/pdf",
"file_url": "<string>",
"created_at": "2023-11-07T05:31:56Z"
},
"start_timestamp": 123,
"end_timestamp": 123
}
]
}
],
"tools": [
{
"name": "<string>",
"display_name": "<string>",
"action_name": "<string>",
"description": "<string>",
"icon": "StepFormIcon",
"icon_url": "<string>",
"connection_id": "<string>",
"parameters": {},
"enabled_by_default": true,
"callback": "<string>"
}
],
"features": {
"web_search": {},
"reasoning": {
"effort": "low"
}
},
"member": {
"id": "<string>",
"role": "ADMIN",
"user": {
"id": "<string>",
"name": "<string>",
"avatar": "<string>"
},
"session": {
"id": "<string>"
},
"contact_channel": {
"id": "<string>",
"type": "internal",
"user_id": "<string>",
"avatar": "<string>",
"name": "<string>",
"username": "<string>",
"email": "[email protected]",
"phone": "<string>",
"country": "<string>",
"agent": "<string>",
"ip": "<string>",
"language": "<string>",
"contact": {
"id": "<string>",
"name": "<string>",
"blocked": true,
"is_admin": true
},
"link": "<string>"
}
},
"error": "<string>",
"usage": {
"input_tokens": 123,
"output_tokens": 123,
"total_tokens": 123,
"reasoning_tokens": 123,
"input_tokens_cache_read": 123,
"input_tokens_cache_write": 123
}
}
]Chat ID
The date to start fetching messages from
Page number
Number of items to take
Next page token (Only used on special endpoints)
The role of the message
user, assistant, system, tool, event, note The model used for the message
The chat status
RUNNING, COMPLETED, FAILED, CANCELED The message content
System message
Show child attributes
The tools used in the message
10Show child attributes
Enabled features for the model
Show child attributes
The member of the chat
Show child attributes
Error message if the message failed
The usage information for the message
Show child attributes
Was this page helpful?
curl --request GET \
--url https://api.useinvent.com/chats/{chat_id}/messages[
{
"id": "<string>",
"role": "user",
"model": "<string>",
"status": "RUNNING",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"messages": [
{
"role": "system",
"parts": [
{
"type": "text",
"text": "<string>",
"audio": {
"id": "<string>",
"file_path": "<string>",
"file_filename": "document.pdf",
"file_size": 1024,
"file_mimetype": "application/pdf",
"file_url": "<string>",
"created_at": "2023-11-07T05:31:56Z"
},
"start_timestamp": 123,
"end_timestamp": 123
}
]
}
],
"tools": [
{
"name": "<string>",
"display_name": "<string>",
"action_name": "<string>",
"description": "<string>",
"icon": "StepFormIcon",
"icon_url": "<string>",
"connection_id": "<string>",
"parameters": {},
"enabled_by_default": true,
"callback": "<string>"
}
],
"features": {
"web_search": {},
"reasoning": {
"effort": "low"
}
},
"member": {
"id": "<string>",
"role": "ADMIN",
"user": {
"id": "<string>",
"name": "<string>",
"avatar": "<string>"
},
"session": {
"id": "<string>"
},
"contact_channel": {
"id": "<string>",
"type": "internal",
"user_id": "<string>",
"avatar": "<string>",
"name": "<string>",
"username": "<string>",
"email": "[email protected]",
"phone": "<string>",
"country": "<string>",
"agent": "<string>",
"ip": "<string>",
"language": "<string>",
"contact": {
"id": "<string>",
"name": "<string>",
"blocked": true,
"is_admin": true
},
"link": "<string>"
}
},
"error": "<string>",
"usage": {
"input_tokens": 123,
"output_tokens": 123,
"total_tokens": 123,
"reasoning_tokens": 123,
"input_tokens_cache_read": 123,
"input_tokens_cache_write": 123
}
}
]