Member Junction
    Preparing search index...

    Fired once per agent turn, BEFORE any reply row exists: the person's message is saved and the chat area has picked the agent that will answer it, on whichever route chose it (a tagged agent, the last agent that answered, a pinned or host default agent, or the conversation manager). A message that starts no turn (see AgentReplyMode) fires nothing.

    A listener can:

    • cancel the turn (Cancel = true). Nothing more is written: no placeholder, no reply row, and AfterAgentTurn does not fire. CancelReason is logged, not shown.
    • send the turn to a different agent by setting RedirectAgentId. The agent must be one the chat allows (AllowedAgentIDs); otherwise the turn is refused with a notice.

    Listeners run synchronously: the chat area reads Cancel and RedirectAgentId as soon as emit() returns.

    Earlier releases fired this event only on the conversation-manager route, after that route's placeholder row was saved, so a cancel left the row behind marked "Turn canceled".

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    AgentId: string | null

    The agent the turn resolved to. Null only when the args were built without turn details.

    AgentName: string | null

    The agent's name, when known.

    ApplicationId: string | null = null
    Cancel: boolean = false
    CancelReason?: string
    ConversationId: string
    MessageText: string
    RedirectAgentId: string | null = null

    Set to send the turn to a different agent instead. Null (the default) keeps AgentId. The turn then runs with Route 'Redirect'.

    Route: AgentTurnRoute | null

    How the agent was chosen.

    UserMessageId: string | null

    The person's saved message the turn answers.