Creating and managing structured message templates for AI agents

<body>
<p id="docs-hc-snippet" style="display: none;">You can create structured message templates and insert them in conversation flows for AI agents. There are three types of structured message templates, which can be used to do the following:</p>
<div class="article-banners">
<div id="docs-wmp-link">
<a href="https://support.zendesk.com/hc/en-us/articles/5411234991258-plan" rel="noopener" target="_blank">What's my plan?</a>
</div>

<div class="article-banner" id="suite_all">
<table>
<tbody>
<tr>
<td>
<strong>All Suites</strong>
</td>
<td>Team, Growth, Professional, Enterprise, or Enterprise Plus</td>
</tr>
</tbody>
</table>
</div>

<div class="article-banner" id="support_all">
<table>
<tbody>
<tr>
<td>
<strong>Support</strong>
</td>
<td>Team, Professional, or Enterprise</td>
</tr>
</tbody>
</table>
</div>

</div>

<div class="body">

<div class="note attention" id="adv_templates_rich_messaging__note_dnl_ndj_jhc">
<span class="attentiontitle"></span> This article applies only to AI agents <a class="xref" href="https://support.zendesk.com/hc/en-us/articles/8357720504858" target="_blank">connected to a messaging channel</a>.</div>
<p class="p">You can create structured message templates and insert them in conversation flows for AI
agents. There are three types of structured message templates, which can be used to do
the following: </p>
<ul class="ul" id="adv_templates_rich_messaging__ul_f4b_rcj_jhc">
<li class="li">
<strong class="ph b">Forms</strong>: Collect a predefined set of information from a customer. </li>
<li class="li">
<strong class="ph b">Webviews</strong>: Present an external website to the customer within the Web Widget. </li>
<li class="li">
<strong class="ph b">Custom</strong>: Templates that are designed to meet your business needs. </li>
</ul>
<div class="p">
<div class="note" id="adv_templates_rich_messaging__note_wwy_1cj_vjc">
<span class="notetitle">Note:</span> Structured message templates are distinct from <a class="xref" href="https://support.zendesk.com/hc/en-us/articles/8357756562330" target="_blank">templates</a>, which are used to centralized replies that
you can link to from multiple generative procedures or dialogues.</div>
This article
contains the following topics:</div>
<ul class="ul" id="adv_templates_rich_messaging__ul_sww_rcj_jhc">
<li class="li"><a class="xref" href="#topic_lfw_hcj_jhc">Creating a structured message template</a></li>
<li class="li"><a class="xref" href="#topic_mgl_3cj_jhc">Adding a structured message template in a dialogue</a></li>
<li class="li"><a class="xref" href="#topic_ahy_3cj_jhc">Viewing all structured message templates</a></li>
<li class="li"><a class="xref" href="#topic_c54_jcj_jhc">Editing a structured message template</a></li>
<li class="li"><a class="xref" href="#topic_i2j_kcj_jhc">Deleting a structured message template</a></li>
</ul>
<p class="p">Related article: </p>
<ul class="ul" id="adv_templates_rich_messaging__ul_thm_pcj_jhc">
<li class="li">
<a class="xref" href="https://support.zendesk.com/hc/en-us/articles/8357756562330" target="_blank">Using templates to create conversation flows for
AI agents</a>
</li>
</ul>
</div>
<div aria-labelledby="ariaid-title2" class="topic nested1" id="topic_lfw_hcj_jhc">
<h2 class="title topictitle2" id="ariaid-title2">Creating a structured message template</h2>
<div class="body">
<p class="p">You can create three types of structured message templates:</p>
<ul class="ul" id="topic_lfw_hcj_jhc__ul_vqt_vpx_qhc">
<li class="li"><a class="xref" href="#topic_gzn_zdj_jhc">Form templates</a></li>
<li class="li"><a class="xref" href="#topic_rnb_12j_jhc">Webview templates</a></li>
<li class="li"><a class="xref" href="#topic_c2p_12j_jhc">Custom (JSON)
templates</a></li>
</ul>
</div>
<div aria-labelledby="ariaid-title3" class="topic nested2" id="topic_gzn_zdj_jhc">
<h3 class="title topictitle3" id="ariaid-title3">Creating a form template</h3>
<div class="body">
<p class="p">Form templates are useful for presenting a customer with a set of predefined
fields that you want them to fill out, such as their contact information. </p>
<p class="p"><strong class="ph b">To create a form template</strong></p>
<div class="p">
<ol class="ol" id="topic_gzn_zdj_jhc__ol_lyz_k2j_jhc">
<li class="li"><span class="ph">In the AI agents workspace, <a class="xref" href="https://support.zendesk.com/hc/en-us/articles/8357756913178#topic_t25_qvj_tdc" target="_blank">select the AI agent</a> you want to work
with.</span></li>
<li class="li"><span class="ph">Click <img class="image" id="topic_gzn_zdj_jhc__d8e404" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/ai_agents_settings_icon.png">
<strong class="ph b">Settings</strong> in the sidebar, then select <strong class="ph b">CRM integration</strong>.</span></li>
<li class="li">Select the <strong class="ph b">Templates</strong> tab. </li>
<li class="li">Click <strong class="ph b">Create your first template</strong> or, if you’ve created a template
before, <strong class="ph b">Create template</strong>.</li>
<li class="li">Select <strong class="ph b">Forms</strong>.<p class="p">The form template configuration page
appears.</p>
<p class="p"><img class="image" id="topic_gzn_zdj_jhc__image_bx5_2hj_jhc" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/aiaa_rich_messaging_form_template.png" width="600"></p>
</li>
<li class="li">In <strong class="ph b">Template name</strong>, enter a name for the template.<p class="p">The name can't
have spaces or any special characters other than hyphens (-) and
underscores (_). This name appears in the list of structured message
templates and is the shorthand you’ll use to <a class="xref" href="#topic_mgl_3cj_jhc">add the template in a
dialogue</a>.</p>
</li>
<li class="li">(Optional) In <strong class="ph b">Description</strong>, enter a brief description of the
template, such as its intended purpose. </li>
<li class="li">Select <strong class="ph b">Block messaging input</strong> if you want to prevent the customer
from continuing the conversation until they’ve filled out the form. </li>
<li class="li">Under Input Field, in <strong class="ph b">Message type</strong>, select the type of
information you want to collect from the user: <strong class="ph b">Email</strong>,
<strong class="ph b">Text</strong>, or <strong class="ph b">Select</strong> (which allows customers to select from
options you define).<p class="p">All fields in this section are limited to 128
characters.</p>
</li>
<li class="li">In <strong class="ph b">Name</strong>, enter the name of the variable that will be created
based on this input field.</li>
<li class="li">In <strong class="ph b">Label</strong>, enter the name of the field that will be shown to the
customer in the widget.</li>
<li class="li">If you selected a message type of Select, click <strong class="ph b">Add option</strong> and
fill out the following fields: <ul class="ul" id="topic_gzn_zdj_jhc__ol_urb_t2j_jhc">
<li class="li">
<strong class="ph b">Option name</strong>: Enter the name of the variable that will be
created based on this option selection.</li>
<li class="li">
<strong class="ph b">Option label</strong>: Enter the name of the option that will be
shown to the customer in the form. Repeat this step for any
additional options you want to present to the customer.</li>
</ul>
</li>
<li class="li">(Optional) Click <strong class="ph b">Add field</strong> to add additional fields to the
form.<p class="p">For the best user experience, keep the number of fields to
five or fewer.
</p>
</li>
<li class="li">Click <strong class="ph b">Create</strong>. </li>
</ol>
</div>
</div>
</div>
<div aria-labelledby="ariaid-title4" class="topic nested2" id="topic_rnb_12j_jhc">
<h3 class="title topictitle3" id="ariaid-title4">Creating a webview template</h3>
<div class="body">
<div class="p">Webview templates are useful for presenting an external website to the customer
within the Web Widget so that they don’t have to leave the conversation.<div class="note" id="topic_rnb_12j_jhc__note_byq_v2j_jhc">
<span class="notetitle">Note:</span> Webview templates can be used to direct customers to a
single website, with one fallback website available. To create a dynamic
webview where the website the customer is directed to is based on collected
parameters, use the <a class="xref" href="https://support.zendesk.com/hc/en-us/articles/8357734565402#h_01GWKHG1ZJ40C0D3HW289PY990" target="_blank">Add a webview</a> CRM action instead.
</div>
</div>
<p class="p"><strong class="ph b">To create a webview template</strong></p>
<div class="p">
<ol class="ol" id="topic_rnb_12j_jhc__ol_ut3_x2j_jhc">
<li class="li"><span class="ph">In the AI agents workspace, <a class="xref" href="https://support.zendesk.com/hc/en-us/articles/8357756913178#topic_t25_qvj_tdc" target="_blank">select the AI agent</a> you want to work
with.</span></li>
<li class="li"><span class="ph">Click <img class="image" id="topic_rnb_12j_jhc__d8e404" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/ai_agents_settings_icon.png">
<strong class="ph b">Settings</strong> in the sidebar, then select <strong class="ph b">CRM integration</strong>.</span></li>
<li class="li">Select the <strong class="ph b">Templates</strong> tab. </li>
<li class="li">Click <strong class="ph b">Create your first template</strong> or, if you’ve created a template
before, <strong class="ph b">Create template</strong>.</li>
<li class="li">Select <strong class="ph b">Webview</strong>.<p class="p">The webview template configuration page
appears.</p>
<p class="p"><img class="image" id="topic_rnb_12j_jhc__image_enj_fhj_jhc" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/aiaa_rich_messaging_webview_template.png" width="600"></p>
</li>
<li class="li">In <strong class="ph b">Template name</strong>, enter a name for the template. <p class="p">The name
cannot have spaces or any special characters other than hyphens (-)
and underscores (_). This name appears in the list of structured
message templates and is the shorthand you’ll use to <a class="xref" href="#topic_mgl_3cj_jhc">add the template in a
dialogue</a>. </p>
</li>
<li class="li">(Optional) In <strong class="ph b">Description</strong>, enter a brief description of the
template, such as its intended purpose. </li>
<li class="li">In <strong class="ph b">Message text</strong>, enter the message your AI agent will show above
the button. <p class="p">For example, if you're creating a webview to present
product information to the customer from your website, the message
text might say, "You can check out our product page to learn more
about this camera model."</p>
</li>
<li class="li">In <strong class="ph b">Button text</strong>, enter the text that appears as the label on the
button. <p class="p">For example: "View product details"</p>
</li>
<li class="li">In <strong class="ph b">URL</strong>, enter the URL that opens when the customer clicks the
button.<p class="p">This URL must allow loading in an iframe.</p>
</li>
<li class="li">In <strong class="ph b">Fallback URL</strong>, enter a backup URL.<p class="p">Channels that don’t
support webviews open the fallback URL instead. </p>
</li>
<li class="li">(Optional) Click <strong class="ph b">Optional fields</strong> to show the following additional
configuration options: <ul class="ul" id="topic_rnb_12j_jhc__ol_oks_jfj_jhc">
<li class="li">
<strong class="ph b">Size</strong>: Select the size of the displayed webpage within the
Web Widget. Available options are <strong class="ph b">Compact</strong>, <strong class="ph b">Tall</strong>,
or <strong class="ph b">Full</strong>. </li>
<li class="li">
<strong class="ph b">Default</strong>: Select this toggle to make this the default
action. </li>
<li class="li">
<strong class="ph b">Automatically open webview</strong>: Select this toggle to
automatically open the webview when this template is triggered. </li>
<li class="li">
<strong class="ph b">Add field</strong>: Click to add field to capture metadata based
on this template. Fill out the <strong class="ph b">Metadata</strong> and <strong class="ph b">Value</strong>
fields. Repeat as needed to add additional fields. </li>
</ul>
</li>
<li class="li">Click <strong class="ph b">Create</strong>. </li>
</ol>
</div>
</div>
</div>
<div aria-labelledby="ariaid-title5" class="topic nested2" id="topic_c2p_12j_jhc">
<h3 class="title topictitle3" id="ariaid-title5">Creating a custom (JSON) template</h3>
<div class="body">
<p class="p">Custom templates are useful for presenting carousels, lists of content, NPS
ratings, or location-based messages. </p>
<p class="p"><strong class="ph b">To create a custom (JSON) template</strong></p>
<div class="p">
<ol class="ol" id="topic_c2p_12j_jhc__ol_upc_4fj_jhc">
<li class="li"><span class="ph">In the AI agents workspace, <a class="xref" href="https://support.zendesk.com/hc/en-us/articles/8357756913178#topic_t25_qvj_tdc" target="_blank">select the AI agent</a> you want to work
with.</span></li>
<li class="li"><span class="ph">Click <img class="image" id="topic_c2p_12j_jhc__d8e404" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/ai_agents_settings_icon.png">
<strong class="ph b">Settings</strong> in the sidebar, then select <strong class="ph b">CRM integration</strong>.</span></li>
<li class="li">Select the <strong class="ph b">Templates</strong> tab. </li>
<li class="li">Click <strong class="ph b">Create your first template</strong> or, if you’ve created a template
before, <strong class="ph b">Create template</strong>.</li>
<li class="li">Select <strong class="ph b">Custom (JSON)</strong>.<p class="p">The custom template configuration page
appears. </p>
<p class="p"><img class="image" id="topic_c2p_12j_jhc__image_uj3_ghj_jhc" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/aiaa_rich_messaging_custom_template.png" width="600"></p>
</li>
<li class="li">In <strong class="ph b">Template name</strong>, enter a name for the template.<p class="p">The name
cannot have spaces or any special characters other than hyphens (-)
and underscores (_). This name appears in the list of structured
message templates and is the shorthand you’ll use to <a class="xref" href="#topic_mgl_3cj_jhc">add the template in a
dialogue</a>.</p>
</li>
<li class="li">(Optional) In <strong class="ph b">Description</strong>, enter a brief description of the
template, such as its intended purpose. </li>
<li class="li">In the code field, enter the JSON for the custom template you want to
create.<p class="p">For help, see <a class="xref" href="https://developer.zendesk.com/documentation/conversations/messaging-platform/programmable-conversations/template-messages/" target="_blank">Template
messages</a>.</p>
</li>
<li class="li">Click <strong class="ph b">Create</strong>.</li>
</ol>
</div>
</div>
</div>
</div>
<div aria-labelledby="ariaid-title6" class="topic nested1" id="topic_mgl_3cj_jhc">
<h2 class="title topictitle2" id="ariaid-title6">Adding a structured message template in a dialogue</h2>
<div class="body">
<p class="p">After you <a class="xref" href="#topic_lfw_hcj_jhc">create a structured message
template</a>, you have to add it in a dialogue so that it’s presented to a
customer at the appropriate time during a conversation with an AI agent. </p>
<p class="p"><strong class="ph b">To add a structured message template in a dialogue </strong></p>
<div class="p">
<ol class="ol" id="topic_mgl_3cj_jhc__ol_omc_vfj_jhc">
<li class="li"><span class="ph">In the AI agents workspace, <a class="xref" href="https://support.zendesk.com/hc/en-us/articles/8357756913178#topic_t25_qvj_tdc" target="_blank">select the AI agent</a> you want to work
with.</span></li>
<li class="li"><span class="ph">Click <img class="image" id="topic_mgl_3cj_jhc__d8e404" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/ai_agents_settings_icon.png">
<strong class="ph b">Settings</strong> in the sidebar, then select <strong class="ph b">CRM integration</strong>.</span></li>
<li class="li">Select the <strong class="ph b">Templates</strong> tab. </li>
<li class="li">Find the template you want to add and click the entry in the Shorthand
column. <p class="p"><img class="image" id="topic_mgl_3cj_jhc__image_vbz_ghj_jhc" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/aiaa_rich_messaging_shorthand.png" width="500"></p>
The template shorthand is
copied to your clipboard. </li>
<li class="li">
<a class="xref" href="https://support.zendesk.com/hc/en-us/articles/9066753203738#topic_nvb_tzl_52c" target="_blank">Open the dialogue</a> you want to add
the template to. </li>
<li class="li">Select the AI agent message block where you want the AI agent to present the
template to the customer. </li>
<li class="li">Paste the template shorthand you copied earlier.<p class="p"><img class="image" id="topic_mgl_3cj_jhc__image_eyx_hhj_jhc" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/aiaa_rich_messaging_add_in_dialogue.png"></p>
</li>
</ol>
</div>
</div>
</div>
<div aria-labelledby="ariaid-title7" class="topic nested1" id="topic_ahy_3cj_jhc">
<h2 class="title topictitle2" id="ariaid-title7">Viewing all structured message templates</h2>
<div class="body">
<p class="p">You can view a list of all structured message templates you’ve created. </p>
<p class="p"><strong class="ph b">To view all structured message templates</strong>
</p>
<div class="p">
<ol class="ol" id="topic_ahy_3cj_jhc__ol_cx3_bgj_jhc">
<li class="li"><span class="ph">In the AI agents workspace, <a class="xref" href="https://support.zendesk.com/hc/en-us/articles/8357756913178#topic_t25_qvj_tdc" target="_blank">select the AI agent</a> you want to work
with.</span></li>
<li class="li"><span class="ph">Click <img class="image" id="topic_ahy_3cj_jhc__d8e404" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/ai_agents_settings_icon.png">
<strong class="ph b">Settings</strong> in the sidebar, then select <strong class="ph b">CRM integration</strong>.</span></li>
<li class="li">Select the <strong class="ph b">Templates</strong> tab.<p class="p">The Templates page opens.</p>
<p class="p"><img class="image" id="topic_ahy_3cj_jhc__image_qqf_jhj_jhc" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/aiaa_rich_messaging_templates_page.png" width="600"></p>
From this page, you can see
a list of all structured message templates, with information shown in the
following columns: <ul class="ul" id="topic_ahy_3cj_jhc__ul_en5_fgj_jhc">
<li class="li">
<strong class="ph b">Details</strong>: The name of the template. </li>
<li class="li">
<strong class="ph b">Shorthand</strong>: Click to copy the text you should enter when you
<a class="xref" href="#topic_mgl_3cj_jhc">add the template
in a dialogue</a>. </li>
<li class="li">
<strong class="ph b">Type</strong>: The type of structured message template (form, webview,
or custom). </li>
<li class="li">
<strong class="ph b">Created by</strong>: The user who created the template. </li>
<li class="li">
<strong class="ph b">Last modified by</strong>: The date the template was last updated.
</li>
</ul>
</li>
</ol>
</div>
</div>
</div>
<div aria-labelledby="ariaid-title8" class="topic nested1" id="topic_c54_jcj_jhc">
<h2 class="title topictitle2" id="ariaid-title8">Editing a structured message template</h2>
<div class="body">
<p class="p">After you create a structured message template, you can edit it at any time. </p>
<p class="p"><strong class="ph b">To edit a structured message template</strong></p>
<div class="p">
<ol class="ol" id="topic_c54_jcj_jhc__ol_hlz_3gj_jhc">
<li class="li">
<a class="xref" href="#topic_ahy_3cj_jhc">In the list of structured
message templates</a>, find the template you want to edit. </li>
<li class="li">Click the options menu (<img class="image" id="topic_c54_jcj_jhc__image_r4s_ngj_jhc" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/options-menu-icon-small.png">) and select <strong class="ph b">View information</strong>.<p class="p">The
template configuration page opens.</p>
</li>
<li class="li">Edit the template as needed.<p class="p">For help, see <a class="xref" href="#topic_lfw_hcj_jhc">Creating a structured message template</a>.</p>
</li>
<li class="li">Click Save. </li>
</ol>
</div>
</div>
</div>
<div aria-labelledby="ariaid-title9" class="topic nested1" id="topic_i2j_kcj_jhc">
<h2 class="title topictitle2" id="ariaid-title9">Deleting a structured message template</h2>
<div class="body">
<p class="p">If you no longer need a structured message template, you can delete it. </p>
<p class="p"><strong class="ph b">To delete a structured message template</strong></p>
<div class="p">
<ol class="ol" id="topic_i2j_kcj_jhc__ol_bvb_kgj_jhc">
<li class="li">
<a class="xref" href="#topic_ahy_3cj_jhc">In the list of structured
message templates</a>, find the template you want to delete. </li>
<li class="li">Click the options menu (<img class="image" id="topic_i2j_kcj_jhc__image_x3v_ngj_jhc" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/options-menu-icon-small.png">) and select <strong class="ph b">Delete</strong>. <p class="p">A confirmation
dialog appears.</p>
<p class="p"><img class="image" id="topic_i2j_kcj_jhc__image_pkx_1hj_jhc" src="https://zen-marketing-documentation.s3.amazonaws.com/docs/en/aiaa_rich_messaging_delete.png" width="350"></p>
</li>
<li class="li">Click <strong class="ph b">Delete</strong>.</li>
</ol>
</div>
</div>
</div>
<script id="docs-schema-markup" type="application/ld+json">{
"@context": "https://schema.org",
"@type": "TechArticle",
"@id": "https://support.zendesk.com/hc/en-us/articles/8357757976474",
"url": "https://support.zendesk.com/hc/en-us/articles/8357757976474",
"headline": "Creating and managing structured message templates for AI agents",
"description": "You can create, add, view, edit, and delete structured message templates for AI agents, including forms, webviews, and custom JSON templates.",
"articleSection": "Configuring messaging channels for AI agents",
"datePublished": "2024-11-11T22:26:54+00:00",
"dateModified": "2026-07-07T14:37:54.174599+00:00",
"inLanguage": "en",
"mainEntityOfPage": {
"@type": "WebPage",
"@id": "https://support.zendesk.com/hc/en-us/articles/8357757976474"
},
"author": {
"@type": "Organization",
"name": "Zendesk",
"@id": "https://www.zendesk.com"
},
"publisher": {
"@type": "Organization",
"name": "Zendesk",
"@id": "https://www.zendesk.com"
},
"isPartOf": {
"@type": "WebSite",
"name": "Zendesk Help",
"@id": "https://support.zendesk.com/hc/"
},
"about": {
"@type": "SoftwareApplication",
"name": "Zendesk",
"@id": "https://www.zendesk.com",
"softwareAddOn": {
"@type": "SoftwareApplication",
"name": "AI agents",
"@id": "https://support.zendesk.com/hc/en-us/sections/8988994355994"
}
}
}</script>
</body>