latestOpenAPI 3.1.02026-08-223871,4712.0 MB

b96b80bcbb83

Agents Insights
Agents Platform

Get Agent Conversation Topics

Returns the latest topic discovery run results for a given agent.

get/v1/convai/agents/{agent_id}/topics

Path parameters

agent_idstring required

ID of the agent

ID of the agent

Query parameters

page_sizeinteger nullable

Number of top-level topic groups to return.

Number of top-level topic groups to return.

sort_by'conversations' | 'sentiment' | 'success_rate' | 'frustration'

Column to rank topics by. Use conversations for volume, sentiment with sort_direction=asc for the most negative topics, and frustration with sort_direction=desc for the most frustrated ones. Topics with no score are always ranked last.

sort_direction'asc' | 'desc'

Direction to sort topics.

from_unix_secsinteger nullable

Start of the window to view topics for. When set with to_unix_secs, the completed daily topic-discovery runs in the range are aggregated together, so the window scopes the metrics as well as the topic set. Floored to the start of its UTC day because runs cover whole UTC days; aggregated_run_count reports how many runs were summed. Omit both bounds to get the single latest run.

Start of the window to view topics for. When set with to_unix_secs, the completed daily topic-discovery runs in the range are aggregated together, so the window scopes the metrics as well as the topic set. Floored to the start of its UTC day because runs cover whole UTC days; aggregated_run_count reports how many runs were summed. Omit both bounds to get the single latest run.

to_unix_secsinteger nullable

End of the window to view topics for.

End of the window to view topics for.

include_evaluation_criteriaboolean

Include the per-criteria evaluation breakdown on each topic's metrics. Pass false to drop it: it dominates the payload and the weighted success_rate is returned either way.

Include the per-criteria evaluation breakdown on each topic's metrics. Pass false to drop it: it dominates the payload and the weighted success_rate is returned either way.

cursorstring nullable

Used for fetching next page. Cursor is returned in the response.

Used for fetching next page. Cursor is returned in the response.

Headers

xi-api-keystring nullable

Your API key. This is required by most endpoints to access our API programmatically. You can view your xi-api-key using the 'Profile' tab on the website.

Your API key. This is required by most endpoints to access our API programmatically. You can view your xi-api-key using the 'Profile' tab on the website.

Response

Successful Response

window_start_unix_secsinteger required
window_end_unix_secsinteger required
aggregated_run_countinteger

Number of daily topic-discovery runs the returned metrics were summed over.

has_moreboolean
next_cursorstring nullable