> ## Documentation Index
> Fetch the complete documentation index at: https://koreai-agentplatform-dev.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Inbuilt tool - deflect_to_chat

<Badge icon="arrow-left" color="gray">[Back to Inbuilt tools](/agent-platform/inbuilt-tools/index#available-tools)</Badge>

The `deflect_to_chat` tool moves a voice conversation to a chat channel. The caller continues with an automated dialog or with a human agent over chat.

## When to use

Use `deflect_to_chat` when a task is better handled in chat than by voice, for example when the caller needs to receive a link, fill in a form, or type a long value. The tool speaks an optional message to the caller and starts the switch to chat.

## Declare the tool

```yaml theme={null}
TOOLS:
  deflect_to_chat(
      deflectionType: string,
      message?: string,
      triggerType?: string,
      language?: string
  ) -> object
```

## Parameters

| Parameter | Required | Description |
| - | - | - |
| `deflectionType` | Yes | `automation` to continue with the automated dialog in chat, or `agentTransfer` to continue with a human agent in chat. |
| `message` | No | Message spoken to the caller before the switch. |
| `triggerType` | No | What triggered the deflection: `userSelection` or `automationContext`. If omitted, `automation` uses `automationContext`, and `agentTransfer` uses `userSelection`. |
| `language` | No | Language code for text-to-speech. |

## Returns

The deflection branch that was taken: `DEFLECT_AUTOMATION` or `DEFLECT_AGENT_TRANSFER`.

## Example

```yaml theme={null}
TOOLS:
  deflect_to_chat(deflectionType: string, message?: string) -> object

FLOW:
  move_to_chat:
    CALL:
      deflect_to_chat(
        deflectionType: "automation",
        message: "I'll continue with you over chat. You'll receive a message shortly."
      )
    THEN: COMPLETE
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.