> For the complete documentation index, see [llms.txt](https://documentation.proto.cx/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://documentation.proto.cx/docs/modules/ai-agents/workflows-and-actions/auto-fill-field.md).

# Auto fill field

`Action` — Uses AI to populate grouped single option custom fields from conversation context. Only the grouped single option field type is supported.

## What it does

Analyses the conversation and automatically sets selected custom fields based on what the person has said — without asking them directly.

## When to use it

To categorise or tag a conversation automatically, such as setting an enquiry type or product category, before a handoff or ticket creation.

## Settings

| Setting           | Description                                                                                                  |
| ----------------- | ------------------------------------------------------------------------------------------------------------ |
| **Select fields** | One or more grouped single option custom fields to auto-fill. If no match is found, the field is left unset. |
| **Variable name** | The chat variable that stores the result of the field assignment.                                            |

Press **Save** to confirm edits.

## Custom field setup

Before using this action, create the custom field in settings:

1. Go to **Settings → Teamspaces → Livechat custom fields**.
2. Select **Create custom field**.
3. Set **Type** to **Single select (grouped)**.
4. Enter a **Name** and optional **Description**.
5. Define groups and options in the **Field options** JSON editor.
6. Set a **Default value** if required.
7. Select **Create**.

## Outcome branches

The action branches into **Success** and **Error**. Nest subsequent actions under each as needed.

## Example

```
Auto fill field
• Select fields: enquiry_type
• Variable name: matched_enquiry
├─ Success
│  └─ Branch on enquiry_type
└─ Error
   └─ Send message: "Could you tell me more about your enquiry?"
```

## Related

{% content-ref url="/pages/WzSbzqdwHIOgSdw0HbCV" %}
[Auto team match](/docs/modules/ai-agents/workflows-and-actions/auto-team-match.md)
{% endcontent-ref %}

{% content-ref url="/pages/rTdnuIG08MgrRXkV3Alv" %}
[Set variable](/docs/modules/ai-agents/workflows-and-actions/set-variable.md)
{% endcontent-ref %}
