AgentStack Docs

Custom Button

Render a contextual link button in widget chat without making an external request from the action itself.

Use Custom Button to make the agent show a contextual link in widget chat. Set a Button Label and an absolute HTTP or HTTPS Button URL. Set whether the button opens in a new tab. Also write a clear When to show this button instruction. This instruction tells the model when to show the button. Without it, the button can appear inconsistently.

Labels and URLs can contain {{variable}} placeholders. The conversation's tool context resolves these placeholders. The preview uses example values to show the shape of the button. These values do not prove that every variable is available in every real conversation. The action renders a link. It does not fetch the target URL or call an external API for the visitor.

Custom Button carries low risk. It works only in the widget, not in other channels. The system strips this action from channels that cannot render interactive UI, including email, Slack, and REST flows. MCP does not filter out this action yet, so an MCP client can still receive it. Test the button on your live widget. Verify the generated URL and the new-tab behavior. Write a label that tells visitors exactly what happens when they select the button.