For the complete documentation index, see llms.txt. This page is also available as Markdown.

Basic Settings

Basic settings for a web chat platform: platform name, the bound Agent, return URL, custom domain, allowed embed domains, public access URL and the three embed methods, plus where to find the Web Chat

Basic Settings is the first category in the "General" group of the chat platform settings page. It determines what the platform is called, which Agent it connects to, and which URL it is served from. This page describes all fields of a web platform. For messaging platforms such as LINE and Microsoft Teams, the basic settings are that platform's credential fields; see the corresponding "Connect a Chat Platform" page. For the overall structure of the settings page and how to open it, see Chat Platform Settings Overview.

Guide navigation: This page is one step in configuring a chat platform. For the complete go-live process for text customer service, see Text Customer Service: From Zero to Launch; for voice customer service, see Voice Customer Service: From Zero to Launch.

1. When You Will Use This

A marketer wants to put the company's AI customer service on the corporate website. She opens the web platform's Basic Settings, changes the name to "Support Helper", confirms the bound Agent is "Product Inquiry Assistant", enters the website's home page in Return URL, and then adds *.my-company.com to Allowed Embed Domains. After saving, she clicks Embed, copies the JavaScript code, and hands it to the website engineer. Once live, only the company's own websites can load this customer service; copying the code elsewhere will not work.

2. Field Descriptions

Basic settings of a web platform: name, Agent, return URL, custom domain, allowed embed domains, public access URL
Basic settings of a web platform
Field
Description

Name

The name shown in the title bar of the chat window, for example "Support Helper"; required

Description

A short introduction to what this Agent can help with (up to 100 characters). It appears on the Agent card in the "Organization-built" tab of the Agent Marketplace and in the share link preview. If left empty, the card shows default text. Website and internal chat platforms have this field; API platforms do not

AI Assistant

The Agent that answers on this platform; the same Agent can be connected to multiple platforms

Return URL

The URL users go to when they click Back in the chat window, usually the website's home page

Custom Domain (CNAME)

Serve the chat page from your own domain; see Section 3

Allowed Embed Domains

The embed allowlist; see Section 4

Public Access URL

The chat page URL generated automatically by the system, which can be shared or embedded directly; see Section 5

Name and Agent

In Name, enter the name you want displayed on your website, and in the AI Assistant dropdown, select the Agent that will answer questions. Switching the Agent takes effect immediately, and the chat window does not need to be re-embedded.

The platform name is displayed in the chat window title bar
The platform name is displayed in the title bar of the chat window

Return URL

After you enter your company website's URL, users who click Back on the full-screen chat page are taken to this URL. The embed preview also uses this URL as its background.

The embed preview uses the return URL's website as its background
After you add a return URL, the embed preview uses that website as its background

3. Custom Domain (CNAME)

The default public access URL is under chat.maiagent.ai. If you want the chat page to use your own domain (for example chat.my-company.com), enter that domain in Custom Domain (CNAME) and save. The system will request a certificate for it and set up routing. After saving, a Domain Status appears next to the field:

Status
Meaning
What to do

Checking

The system is setting up routing and the certificate

Wait a few minutes, then refresh

DNS not ready

Your DNS does not yet point the domain to MaiAgent

Add a CNAME record at your DNS provider

Certificate not ready

DNS points correctly, but the certificate is still being issued

Wait; it usually completes within a few minutes

DNS configuration error

It was active before, but the DNS record has been changed or removed

Check the CNAME record at your DNS provider

Active

The chat page can now be opened with your domain

The public access URL and embed code switch to your domain

The target address the CNAME record should point to depends on the environment. Please ask the Support Center for it. To remove the custom domain, clear the field and save; the chat page returns to the default URL.

4. Allowed Embed Domains

What Is It?

Allowed Embed Domains is an "embed allowlist": once filled in, only the websites on the list can embed this web chat, and embed code placed on other websites stops working.

Situations where enabling it is appropriate:

  • Prevent unauthorized embedding: You are concerned that third-party websites may copy your embed code and embed your customer service bot on their pages, consuming your conversation quota

  • Security compliance: Your company's or customers' security policy requires controlling which websites can load this customer service widget

This is an advanced security setting. If you have no such need, leave the list empty. When the list is empty, any website can embed this web chat.

How It Works

List state
Behavior

Empty (default)

No restriction; any website can embed this web chat

Not empty

Allowlist mode: browsers block embedding from other domains, and the SDK also rejects their setup calls

  • When a blocked domain embeds it: The chat widget on that page does not finish initializing, and visitors cannot start a conversation

  • Visitors who open the public access URL directly: This setting restricts only "embedding"; visitors who open the chat page directly through the public URL are not affected

  • The security mechanism rejects anything it cannot verify: When the list is not empty, any embed that cannot pass origin verification is rejected, including a mistyped domain or an embed page that uses an older embed script that does not support origin verification

Setup Steps

1

Find the Field

In Basic Settings, find Allowed Embed Domains and click + Add.

The "Allowed Embed Domains" field in Basic Settings
The "Allowed Embed Domains" field in Basic Settings
2

Add a Domain

Each entry can be an exact origin (https://example.com) or a wildcard domain (*.example.com, which matches example.com and all of its subdomains).

Format
Description

✅ https://www.example.com

Exact origin: only pages at this address (including the protocol) may embed

✅ *.example.com

Wildcard domain: allows example.com and all its subdomains (www, shop, blog, …) to embed

❌ example.com

An exact origin must include the protocol; without https:// it will not take effect

❌ *.com

Too broad; it opens embedding to every .com website and defeats the purpose of an allowlist

3

Save and Verify

After saving, wait about one minute, then refresh the embed page on a listed website and confirm the chat window can still open a conversation normally.

The "Allowed Embed Domains" field with a filled-in domain list
Example list containing an exact origin and a wildcard domain

Pre-Enablement Checklist

FAQ

Q: How long until the setting takes effect?

It usually takes effect within about one minute after saving; after that, refreshing an already-open embed page applies the new setting.

Q: I have many subdomains. Do I need to list each one?

No. A single *.example.com entry matches example.com and all of its subdomains.

Q: What does this setting protect against, and what does it not?

It is protection at the "embed layer": it prevents other websites from embedding this web chat in their pages. It is not authentication; anyone who knows the public access URL can still open the chat page directly and start a conversation. If you need to control who can chat, use it together with Login Settings.

Q: I configured it wrong and no embed can chat. What should I do?

Clear the Allowed Embed Domains list and save; after about one minute the restriction is lifted, and you can then recheck the domain format.

5. Public Access URL and Embedding

The Public Access URL at the bottom of the page is the chat page URL generated automatically by the system. The action buttons next to it are:

Action
Purpose

Copy

Copy the URL to share directly with users or use in a QR code

Visit

Open the chat page in a new tab to test your settings

Voice Mode

Open the voice chat page in a new tab; it appears only when the bound Agent has Voice Assistant enabled. For the go-live process, see Voice Customer Service: From Zero to Launch

Embed

Get the embed code; see the three embed methods below

Embed Preview

Preview how it looks once embedded, using the return URL's website as the background

Three Embed Methods

After clicking Embed, you can switch between the following at the top of the window:

  • JavaScript: Loaded with <script>; the most common option, and it handles loading and compatibility automatically

  • Iframe: Embedded directly with <iframe>; suitable for environments where scripts cannot be inserted

  • MaiGPT: A ChatGPT-style full chat interface (conversation history on the left plus the main chat area on the right). It can stay permanently on the embedding page, or be expanded to full screen by clicking a floating button in the lower-right corner

After selecting MaiGPT, you can adjust the Embed Container (targetElement), Locale (locale), and Title (maigptTitle) on the left. The Code Preview on the right updates in real time, and clicking Copy lets you paste it into your website. For the full parameter reference, see MaiGPT Window Mode Embedding.

Embed Script Characteristics

The embed.js script provided by the JavaScript embed offers:

  • Duplicate-run protection: Even if the script is loaded multiple times, it initializes only once

  • Clear error messages: When loading fails, an error message is provided to make debugging easier

  • No impact on site load speed: The script is optimized

  • Compatible with various website environments and frameworks

When embedding, we recommend:

  1. Place the embed script before the </body> tag so the main page content loads first

  2. Add the embed script to the page only once to avoid duplication

  3. When using it in a SPA (Single Page Application), refer to the advanced settings in the technical documentation

Embed preview screen
Embed preview

6. Web Chat ID of an API Platform

When an engineer creates a conversation through the API, the required webChat field takes the Web Chat ID of the API platform. It is not on the Agent detail page, but on the API platform's settings page:

  1. Go to Customer Service Conversations → Chat Platforms, find the Agent's API platform (created automatically when the Agent is created), and click Edit.

  2. In the left category navigation, under the "Integration and Login" group, click Webhook Settings.

  3. The API Information card at the bottom of the page shows the Web Chat ID (read-only); click the copy button on its right to copy it.

This card exists only on API platforms; web and internal platforms have no Web Chat ID field. To look up the list of Web Chats and their IDs for the whole organization, engineers can also call GET /api/v1/web-chats/; for details, see the technical manual Creating Conversations and Messages.

7. FAQ

Q: If I change the name or Agent, do I need to re-embed?

No. It takes effect immediately after you click Save, and the embed code does not change.

Q: Can the same Agent be connected to multiple web platforms?

Yes. Each platform has its own name, appearance, and feature toggles, which is suitable when the same Agent should look different on different websites. Go to Customer Service Conversations → Chat Platforms, click Connect Chat Platform, and add one.

Last updated

Was this helpful?