Test and deploy your AI agent

Learn how to effectively test and deploy your AI agent for optimal performance

Written By Frieda Yip (Super Administrator)

Updated at November 18th, 2026

After configuring your AI agent’s behavior and Knowledge, test how it handles customer conversations before making it available on your messaging channels.

This process has two stages:

  1. Test and improve: Check responses, identify problems, and refine the agent.
  2. Deploy: Choose where, when, and for which conversations the agent should respond.

A deployment controls:

  • What starts the conversation
  • The messaging channels the agent uses
  • The conversations the agent can handle
  • When the agent is active
  • How messages are delivered
  • What happens after the agent exits a conversation

 

Before testing and deploying your agent:

  • Complete the steps in “Set up your AI agent’s behavior and knowledge”.
  • Make sure your agent has “Rules” and at least one data source in the “Knowledge base” section that shows “Ready”. Testing unlocks as soon as one source is Ready and does not wait for the others. Sources that are still adding don’t count yet.
  • Review any actions, Context and response settings, and exit conditions you want to test.
  • Connect the messaging channels you want to use. Only connected channels are available for deployment.

Testing does not send messages to real customers or modify real customer data.

 

Part 1: Test and improve your agent

Test your agent with different customer questions and scenarios before publishing it. Use the results to improve its Playbook, Knowledge, actions, and exit conditions.

The tabs at the top of the agent builder are “Edit”, “Preview”, “Issues” and, once the agent has a deployment, “Deployments”. “Issues” collects the test replies you flag. To learn more, refer to Fix problems found while testing your AI agent.

 

Choose a testing method

You can test the agent in two modes:

Testing method

Use it for

Chat

Testing a conversation one message at a time, including follow-up questions and context across multiple messages

Batch test

Running and reviewing multiple independent questions together

Use Chat to explore how the agent handles a conversation in detail. Use Batch test to evaluate a broader range of common questions, business rules, and edge cases.

Each question in a batch test runs independently as a single-round test. Batch tests do not support multi-message conversations.

 

What to test

Cover scenarios such as:

  • Common customer questions, including variations in wording, tone, and spelling
  • Follow-up questions (Chat only)
  • Unclear requests, or requests with missing information
  • Business-specific rules
  • Questions that depend on assigned Knowledge sources
  • Requests that should trigger an action or integration
  • Requests that should cause the agent to exit or escalate
  • Questions the agent should not answer
  • Questions that previously received an incorrect response

 

Test in Chat mode

Chat mode lets you have a multi-message test conversation with the agent in a sandboxed environment. Test messages are not sent to real customers and do not modify customer data.

The header shows how many assigned Knowledge sources are currently readable by the agent.

If fewer sources are ready than the total, the agent can’t use all of its Knowledge yet, so its test replies may be incomplete. Before you change the Playbook to fix a reply, check whether any sources are still adding or need a retry. See Understand AI Knowledge source statuses and fix issues.

To start a test conversation:

  1. Select the Chat tab.
  2. Choose a suggested question or enter your own in Message your agent
  3. Send the message and review the response
  4. Enter follow-up messages to check how the agent maintains context across the conversation.

Press “Shift + Enter” to add a new line to your message.

Click “Reset” when you want to clear the current conversation and start a new test.

 

Flag a reply

If a reply is wrong, hover over it and click “Flag”. Describe what went wrong, then click “Flag reply”. The reply becomes an issue on the “Issues” tab, where you can see the likely cause and apply a fix. To learn more, refer to Fix problems found while testing your AI agent.

 

AI credits during testing 

Testing uses AI credits in the same way as replies to contacts. Basic replies are included in your plan, and Advanced replies use credits. Test usage appears on the AI Wallet page as "Test chats" and "Batch tests", separate from "Replies to contacts". For details, see Managing your AI Wallet.

It shows the credits used this cycle out of your total. When the current testing session has used credits, the meter also shows how many.

Hover over the meter to see:

  • “AI credits this cycle”
  • How many credits have been used out of your total
  • How many credits this session has used
  • When your credits reset
  • “Only Advanced replies use credits.”

Credit use is also shown per reply:

  • In “Chat”, each reply shows "Advanced · {credits} credits" or "Basic · included" under it. Clicking "Reset" starts a new session count. It does not change your balance or the credits used this cycle.
  • In “Batch test”, the "Credits" column and each question's panel show how many credits the question used. Basic replies show "Included".
  • The downloaded batch test report includes the credits each question used and the total for the test.

If your credits run out:

  • In “Chat”, the agent doesn’t reply, and the chat lets you know that your AI credits ran out. You can continue testing once credits are available.
  • In “Batch test”, you can’t start a run. If credits run out during a run, the questions that didn’t run are marked as out of credits. Run them again once credits are available.

 

Review how the agent answered

When the agent used Knowledge or took a step to answer, click “How it answered” under the reply to see how it produced the reply. Click “Hide” to close it.

  • “What it received” lists the Knowledge the agent used. Click “View relevant chunks” to see the exact parts it used.
  • “What it did” lists the steps the agent took, such as searching the knowledge base, calling an integration, following a procedure step, adding a label, calculating a lead score, or exiting the chat.

The same “How it answered” view appears in each Batch test question’s panel.

If a reply is wrong, flag it. The issue shows the likely cause and a suggested fix. To learn more, refer to Fix problems found while testing your AI agent.

 

Run a batch test

Batch test lets you run multiple questions and review their results together.

To open it, select the “Batch test” tab next to “Chat”.

You can add questions by:

  • Generating suggested questions
  • Writing your own questions
  • Importing questions from a CSV file

 

Generate suggested questions

Click “Generate suggested” to let AgentFlow create questions based on the agent’s current configuration, including its:

  • ProceduresPlaybook
  • Knowledge
  • Rules
  • Persona
  • Enabled integrations

The number of questions may vary depending on the agent’s setup.

Questions appear progressively in the batch test table and run automatically. You can review completed results while AgentFlow continues generating and running other questions.

Generate a new set after making significant changes to the agent so the suggested questions reflect its latest configuration.

 

Stop question generation

While suggested questions are being generated, click Stop to prevent AgentFlow from adding more questions.

Questions that have already been generated remain in the table. Questions that are running or have already been answered are also retained.

Stopping generation does not remove existing questions or results.

 

Write your own questions

Click “Write your own” to add questions based on your business requirements and actual customer scenarios.

Add questions that test:

  • Common customer requests
  • Business-specific rules
  • Unusual or difficult cases
  • Questions that previously received an incorrect response
  • Knowledge-dependent answers
  • Actions and integrations
  • Exit and escalation scenarios

After you add the questions, they appear in the batch test table and run automatically.

 

Import questions from a CSV file

Use “Import CSV” when you already have a set of test questions or want to reuse the same questions across agents.

You can download the sample CSV to review the required structure.

The CSV file must:

  • Include one question per row
  • Place the question in the first column
  • Optionally include a header row

To import questions:

  1. Click “Import CSV”.
  2. Select the CSV file from your device.
  3. Wait for AgentFlow to import the questions.

Questions that are already in the batch test are skipped.

If the file does not contain any valid questions, AgentFlow displays an error.

 

Run questions and set a credit limit

Questions in a batch test only run when you run them. You can:

  • Click “Run all” to run every question.
    • If some questions already have answers, running all clears every existing answer, rating and correction before the run starts. You’ll be asked to confirm first. To keep your ratings, run only the pending or selected questions instead.
  • Click the arrow next to “Run all”, then select “Run pending” to run questions that haven’t been answered yet.
  • Select one or more questions, then click “Run”.

To run a single question straight away, open it and click "Run this case", or "Re-run" if it already has an answer. The question runs with the agent's latest configuration, and the credit limit confirmation below is not shown.

 

Choose a credit limit

On plans with an AI Wallet, you choose whether to limit the credits a run can use before it starts.

  1. Click “Run all”, “Run pending” or “Run”. The confirmation shows how many credits you have left.
  2. Select “No limit” to run all the selected questions, or select “Set a limit” and enter the maximum number of credits the run can use, in whole credits. You need to enter a limit before you can start the run.
  3. Start the run.

When the run reaches your limit, it stops. Questions that were already running still finish, so the run can use slightly more credits than your limit. Questions that didn’t run stay “Pending”.

 

Follow a run

While a run is in progress, Batch test shows how many questions have been answered and how many credits the run has used so far.

To end a run early, click “Stop”. Questions that are already running finish, and the rest go back to “Pending”.

If a run ends early, Batch test shows why. To continue, click “Run pending cases”, or click the arrow next to “Run all” and select “Run pending”.

 

Review and rate responses

The batch test table shows each question’s status and rating. Use the filters to find questions that still need attention:

  • “Status is”: “Answered”, “Pending”, “Running”, or “Failed”
  • “Rating is”: “Good”, “Poor”, or “Unrated”

Click a question to open the Evaluate answer panel. The panel shows:

  • The test question
  • The response time
  • The agent’s response
  • Actions taken
  • Guided Workflow
  • Options for rating the response

Click “How it answered” to see the Knowledge the agent used and the steps it took.

 

Rate a response

Rating Use it when
Good The response is accurate, complete, and follows the expected behavior.
Poor The response is incorrect, incomplete, irrelevant, or does not follow the expected behavior.

There are three ways to rate a response:

  • Under “Rate the response” in the question’s panel
  • With the “Good” and “Poor” buttons on the question’s row
  • On your keyboard: press G for Good and P for Poor

To clear a rating, choose the same rating again.

When you choose “Poor”, you can describe the problem under “What went wrong?”. This field is optional.

When you leave a question rated “Poor”, it becomes an issue on the “Issues” tab. Leaving means closing its panel, opening another question, switching to “Chat”, or leaving “Preview”. The question’s row and panel then show the issue’s state. Click the state to open the issue.

After the question becomes an issue, its rating stays “Poor” until you run the question again. Running it again doesn’t remove the issue. To learn more, refer to Fix problems found while testing your AI agent.

 

Fix Poor-rated responses

Each question you leave rated “Poor” becomes an issue on the “Issues” tab. Replies with the same cause are grouped into one issue.

Open the issue to see the likely cause and a suggested fix. Apply the fix, then retest the same questions. To learn more, refer to Fix problems found while testing your AI agent.

 

Manage batch tests

Click the arrow next to “Run all” to see more options for your batch test.

Option

What it does

When to use it

Reset results

Clears all answers, ratings and notes, and keeps the questions.

When you want to restart the evaluation with the same questions

Download report

Exports the results as a CSV file.

When you want to share or keep the results outside SleekFlow

Compare answers

Shows each answer next to the answer you expected, with a pass or fail result.

When your questions include expected answers

“Reset results” doesn’t remove issues. Issues created from Poor ratings stay on the “Issues” tab.

To add more questions, click “Add cases”. To replace all questions with a new set of suggestions, select “Regenerate suggested”. This removes every question in the list, including ones you wrote or imported, along with their answers and ratings.

The exported report includes the questions, agent responses, statuses, ratings, notes, sources, and response performance.

Batch test questions and results are kept for each agent in the browser you tested in. They’re still there when you come back, until you reset them or clear your browser data.

They aren’t shared with teammates or other browsers. Issues are shared: everyone who edits the agent sees the same issues. Teammates who open an issue created from a Batch test question can see the issue, but not your Batch test list.

To keep or share results, use “Download report”.

 

Check whether the agent is ready

Before deployment, confirm that:

  • Each scenario in “What to test” gets a Good response.
  • Issues on the “Issues” tab have been applied, resolved, or dismissed.
  • Changes have been retested.

 

Manage batch tests

Click the arrow next to “Run all” to see more options for your batch test.

Option

What it does

When to use it

Reset results

Clears all answers, ratings and notes, and keeps the questions.

When you want to restart the evaluation with the same questions

Download report

Exports the results as a CSV file.

When you want to share or keep the results outside SleekFlow

Compare answers

Shows each answer next to the answer you expected, with a pass or fail result.

When your questions include expected answers

To add more questions, click “Add cases”. To replace all questions with a new set of suggestions, select “Regenerate suggested”. This removes every question in the list, including ones you wrote or imported, along with their answers and ratings.

The exported report includes the questions, agent responses, statuses, ratings, notes, sources, and response performance.

Test reports are session-based. Once you reset the test or leave the testing session, you can no longer access the report. If you want to keep a record of the results, download the report after completing the test and any ratings or notes.

 

Check whether the agent is ready

Before deployment, confirm that:

  • Each scenario in “What to test” gets a Good response.
  • Issues on the “Issues” tab have been applied, resolved, or dismissed.
  • Changes have been retested.

 

Part 2: Deploy your agent

Deploy your agent when it is ready to handle customer conversations.

Configure how conversations start, which channels the agent uses, who it can interact with, when it is active, and what happens after it exits a conversation. When the deployment is ready, click “Publish”.

 

Configure the trigger

The “Trigger” section determines what starts a conversation with the agent. Each deployment has one trigger. Both trigger options are available on every plan.

Choose one of the following:

Option

What it does

Incoming message

A customer messages your channel directly. Does not include messages from Click-to-WhatsApp ads.

Click-to-WhatsApp ad

A customer taps Send message on a Facebook or Instagram ad. WhatsApp channels only.

A new deployment uses Incoming message by default.

When you select Click-to-WhatsApp ad, the agent receives information about the ad the customer clicked and can use it to answer questions during the conversation.

Under Ads, choose:

Setting

What it does

All ads

The agent answers conversations from any Click-to-WhatsApp ad on the selected channels. This is the default.

Specific ads

The agent answers only conversations from the ad IDs you enter.

For Specific ads:

  1. Copy the ad ID from Meta Ads Manager. Use the ad ID, not the ad set or campaign ID. An ad ID looks like 120200000000000000.
  2. Paste the ID into the ad ID field.
  3. Click Add ad ID to add another ad. You can enter up to five ad IDs per deployment. Add ad ID is no longer offered after you add five.

Each ad ID row must contain a value. If you try to publish with an empty row, the following message appears: “Enter an ad ID, or select All ads.”

The restriction matches the ad the customer actually clicked. An ad ID included as text in the customer’s message does not count as a match.

If an ad no longer exists in Meta, its ID will not match new conversations. Conversations already running with the agent are not interrupted.

Note: You can select ads by ID only. There is no list of ad names to choose from because SleekFlow does not connect to a Meta ad account.

 

 

What the agent knows about the ad

When a conversation starts from a Click-to-WhatsApp ad, the agent receives the following information separately from the customer’s message:

  • The ad’s headline
  • The ad’s body text
  • The ad ID
  • The link destination

The agent keeps this information throughout the conversation. It is not carried into a later conversation that did not start from an ad.

The agent reads the customer’s message as their question. The ad link and reference attached before the first message are not treated as part of that question.

Use the agent’s Rules to define whether and how it mentions the advertised product. For example, you can instruct it to acknowledge the product in the ad before answering and use the ad’s wording for the product name.

The following limitations apply:

  • The agent receives the ad’s text, but cannot answer questions about its image or video.
  • Ad text provides context for the conversation. It cannot override the agent’s Rules, Procedures, or Knowledge.
  • This behavior applies to Click-to-WhatsApp ads. It does not cover click-to-message ads that open Instagram or Messenger.

The conversation’s appearance in Inbox does not change. Existing automations that identify ads by matching message text continue to work.

 

When the ad isn’t detected

Some ad conversations reach SleekFlow without ad information. WhatsApp on mobile sometimes removes the ad reference before the message arrives. This is outside SleekFlow’s control.

A customer may also start a conversation from an organic Facebook or Instagram post rather than a paid ad. In this case, there is no ad information to provide to the agent.

When no ad information is available:

  • An Incoming message deployment can pick up the conversation if it matches the deployment’s other settings.
  • A Click-to-WhatsApp ad deployment does not pick up the conversation.
  • A Specific ads restriction does not match.
  • If an agent handles the conversation through an Incoming message deployment, it responds normally without ad context.

To cover campaign conversations that arrive without ad information, set up a separate Incoming message deployment as a fallback. A deployment restricted to specific ads may not cover every conversation generated by your campaign.

 

Configure channels

The Channel section determines which messaging channels the agent can use for this deployment.

To add a channel:

  1. Click “Add channel”.
  2. Select a connected messaging channel.
  3. Repeat as needed to add other channels.

If you selected Click-to-WhatsApp ad as the trigger, the Channel section displays: “WhatsApp channels only, because ad clicks arrive on WhatsApp.” Only WhatsApp channels are available for selection. Non-WhatsApp channels are not shown.

You must add a channel before publishing the deployment.

If you switch an existing deployment to Click-to-WhatsApp ad while it has non-WhatsApp channels selected, a confirmation modal appears. It lists the channels that will be removed.

  • Click “Cancel” to keep the current trigger and channels.
  • Click “Switch trigger” to use the ad trigger and remove the listed channels.

Switching back to “Incoming message” does not require confirmation and does not remove any channels.

 

Configure reply delivery

The “Reply delivery” section controls how longer replies are sent to customers.

Turn on “Split replies into separate messages” to send a long reply as several chat bubbles instead of one message.

Turn it off to send the reply as a single message.

 

Configure the target audience

The “Target audience” section determines which incoming conversations the agent can handle.

Choose:

  • All incoming conversations: The agent can respond to all eligible conversations received through the selected channels.
  • Custom audience: The agent only responds to conversations that match your audience rules.

For a custom audience, you can create rules using:

  • Contact labels
  • Phone numbers
  • Keywords

Review the rules carefully to make sure the agent only joins the intended conversations.

Target audience rules use contact details, such as labels and phone numbers, or keywords in the customer’s message. They do not determine where the conversation started. To restrict a deployment to Click-to-WhatsApp ad conversations or specific ads, use the “Trigger” section.

 

Configure active hours

The Active hours section determines when the agent can respond. Active hours are based on your company’s time zone.

The agent is available at all times by default. To limit its availability:

  1. Turn on “Set specific hours”.
  2. Select the active days.
  3. Set the “From” and “To” times for each day.
  4. Review the company time zone displayed in the deployment settings.

Overnight schedules are supported. For example, you can set the agent to respond from 10:00 PM to 6:00 AM.

For more information about company and personal time zone settings, see Personal settings.

 

Configure post-exit actions

The “Post-exit actions” section determines what happens after the agent exits a conversation under each exit condition.

Every exit the agent has appears as its own card, including the default exits “Human agent takes over” and “System error”. Each card shows the trigger and when it applies. A Timeout card also shows its duration, and a Lead score card shows its threshold.

To configure a post-exit action:

  1. Find the exit condition you want to configure.
  2. Click “Add action”
    .
  3. Select an action.
  4. Complete the action settings.
  5. Add another action if needed.
  6. Review the actions before publishing.

Available post-exit actions include:

Action

What it does

Send message

Sends a message after the agent exits. You can also attach media.

Assign to

Assigns the conversation to a teammate or team.

Add label

Adds a label to the conversation or contact.

Add to list

Adds the contact to a contact list.

Add internal note

Adds an internal note to the conversation for your teammates.

For example, when a customer requests a human:

  1. Use Send message to tell the customer that a teammate will continue the conversation.
  2. Use Assign to to assign the conversation to the Support team.

Post-exit actions are optional. If you do not configure one, the agent stops handling the conversation without performing another action.

The two-action limit applies to post-exit actions configured on this deployment page. Advanced workflows created in Flow Builder are not limited by this deployment-page setting.

 

Review and publish

Before publishing, review:

  • Trigger. If you selected Click-to-WhatsApp ad, check whether the deployment covers All ads or Specific ads. For Specific ads, make sure every ad ID row is filled in.
  • Selected channels
  • Target audience
  • Active hours
  • Reply delivery
  • Post-exit actions

Click “Publish” when the deployment is ready.

If auto top-up is disabled, you may see a notice when you publish. It explains that some of the agent’s replies use credits, and that these conversations go to a human agent when credits run out. To avoid this, set up auto top-up so credits are added automatically. If you can’t manage the AI Wallet, ask your workspace admin to set it up.

The notice is for information only and doesn’t stop you from publishing.

If a required field is incomplete, AgentFlow prevents publishing until you resolve the validation issue.

After publication, the agent can respond to new conversations that match the deployment’s trigger, channels, audience settings, and active hours.

Changes made after publication do not affect the live deployment until you publish them.

 

Manage deployments

The “Deployments” page shows every deployment configured for the agent. Once you have deployed the AI agent, you will find the “Deployments” tab in the “Edit agent page”

Each deployment card displays:

  • The deployment name
  • Its current status
  • Its trigger: Incoming message, Ad clicks, or a label such as Ad clicks · 3 ads when specific ads are selected
  • The connected messaging channel
  • The agent’s availability
  • A toggle for enabling or disabling the deployment

A deployment managed in Flow Builder is marked Managed in Flow Builder and does not display a trigger label. It may use a trigger that cannot be configured on the deployment page.

 

Create a deployment

Click “Create deployment” to configure another deployment for the agent.

Use separate deployments when the agent needs different channels, audiences, schedules, or post-exit actions.

 

Duplicate a deployment

Each deployment has one trigger. To handle both Click-to-WhatsApp ad conversations and direct messages, create two deployments. You can duplicate an existing deployment to reuse its settings.

To duplicate a deployment:

  1. Click on the icon on a deployment card.
  2. Click “Duplicate”
  3. The copy opens with its name field ready to edit. Enter a name that describes the conversations it will handle.
  4. Review the copied settings. Change the trigger, channel, or target audience as needed to avoid overlap.
  5. Review any warnings and configure missing post-exit actions.
  6. Click “Publish” when the copy is ready.

The copy includes the original deployment’s trigger and ad settings, channel, target audience, active hours, and post-exit actions. Exit steps managed in Flow Builder are not copied.

 

Edit a deployment

Click a deployment card to review or update its settings. Publish the changes before they take effect.

 

Enable or disable a deployment

Use the toggle on the deployment card to control whether the deployment is active.

Disabling a deployment prevents the agent from joining new matching conversations through that deployment.

 

Avoid overlapping deployments

A Click-to-WhatsApp ad deployment and an Incoming message deployment on the same WhatsApp channel do not overlap. They handle different conversation sources, and Incoming message excludes detected Click-to-WhatsApp ad conversations.

Two Incoming message deployments on the same channel, or two ad deployments with overlapping ad selections, can match the same conversation and enroll the contact more than once if their other settings also match.

Review audience rules before enabling multiple deployments or automations for the same channels and conversations.

If more than one matching flow or deployment is triggered, the same contact may be enrolled with the agent more than once. Use distinct channels, audience rules, labels, or other routing conditions to prevent unintended overlap.

 

Use Flow Builder for advanced deployments

Use the “Open Flow Builder” when you need advanced triggers, conditional routing, longer workflows, or more complex post-exit behavior.

You can also place an AI agent after the “Customer messages you from a Click-to-WhatsApp ad” trigger on the Flow Builder canvas to configure routing beyond the options available on the deployment page.

 

Manage live AI conversations in Inbox

After deployment, your team can use Human-AI Conversation Control to view and manage live AI sessions in Inbox. Depending on the session state, teammates can take over, pause, resume, or end the AI session.

For setup instructions and session behavior, see Manage AI agent sessions in Inbox with Human-AI Conversation Control.