Skip to main content
Version: Current

Fill Form Field

Description​

Requests that the page hosting a Web Chat widget fill a named form field. The activity sends a fillFormField client action; the host page's handler decides whether to accept the request and how to update the field.

Tool only: Available under Web Automation in the Conversational Agent Tools picker. It is hidden from the canvas toolbox and cannot be added as an ordinary workflow step. Supported only in Web Chat.

Prerequisites​

Configure a Web Chat Trigger and Conversational Agent, embed the widget in the target page, and implement the host page's client-action handler. See Web Chat Page Actions for setup and shared tool settings.

Inputs​

Both inputs are required strings and support Literal, an expression, or FromAI in the tool editor.

PropertyTypeDescription
Field NamestringName of the field to update. Sent as Field, with surrounding whitespace trimmed. Use the exact name declared by the host page.
Field ValuestringValue to send. Sent as Value; surrounding whitespace is trimmed on the FromAI path. The host handler converts the string to the field's expected type and validates it.

Use strings for dates, checkbox values, and selection values too. This activity does not perform field-type conversion or validation on behalf of the page.

Outputs​

OutputTypeDescription
Client ActionstringAlways fillFormField. Serialized as ClientAction.
FieldstringThe field name that was sent.
ValuestringThe value that was sent.
StatusstringAlways Sent to the form. Continue the conversation.
Error MessagestringStandard error output for a failed run.

Example successful client-action payload:

{
"ClientAction": "fillFormField",
"Field": "firstName",
"Value": "Alex",
"Status": "Sent to the form. Continue the conversation."
}

The widget delivers this payload unchanged as a.payload, with a.action set to fillFormField.

Example​

  1. On the Conversational Agent's Tools connector, select Web Automation > Fill Form Field.
  2. Set Field Name and Field Value to FromAI.
  3. Describe the tool's purpose and instruct the agent to use the page's declared field names.
  4. When the user says “My first name is Alex,” the agent can call the tool with Field set to firstName and Value set to Alex.
  5. The host handler validates the name and value, then updates the form and its application state.

Delivery and limitations​

When both inputs are FromAI, the pipeline builds the result JSON without resuming the workflow. A blank or missing argument returns an error such as {"error":"Missing argument Field"} or {"error":"Missing argument Value"} and is not relayed to the page. Literal or expression inputs use the normal tool lane and emit the same client-action JSON shape.

Each call requests an update to one field. Delivery is fire-and-forget: the host's acceptance or rejection is not returned to the agent. Status describes dispatch, not successful validation or a completed field update. Client-action calls do not speak a tool acknowledgement, even when one is configured.