Create a basic agent and publish it to Microsoft Teams.

Note :

This article applies only to content creators who have a Teams plan, available in certain Microsoft 365 subscriptions . Content creators with a Teams plan can only create agents using the classic orchestration method in Copilot Studio and can only publish these agents to Microsoft Teams . If you have a standalone Copilot Studio subscription, see the guide on creating and deploying agents .

After June 2026, it will no longer be possible to use the Copilot Studio for Teams application to create classic chatbots. The application will redirect you to the Copilot Studio web application.

Content creators with a Teams plan can use Copilot Studio to build basic agents for Microsoft Teams. These agents have built-in natural language processing (NLP) capabilities and a graphical interface that requires no programming. With a Teams plan, you can create, edit, test, and publish your agents to Teams directly from the Copilot Studio interface.

When creating a classic agent, consider the following:

  • Types of questions someone might ask
  • Different ways to ask a question
  • Expected answers
  • Do users have any further questions or concerns?

To help you get started creating an HR agent, this quick guide will show you how:

  • Outline your scenario and needs to match what an agent can do.
  • Create an agent in Copilot Studio
  • Develop and improve topics for answering frequently asked questions in the HR field.
  • Test, publish, and share the agent with your organization.

The HR Support Bot is a friendly Q&A agent that connects HR support experts when HR staff are unable to assist. Employees can ask the agent a question, and the agent will answer if the information provided matches the question.

If the agent doesn't have an answer, the employee can submit a request. The request is sent to a pre-defined team of experts, who will respond to the request messages.

Script

You work in the Human Resources (HR) department at Contoso and need to build an HR support agent in Microsoft Teams. The agent will answer common HR questions, such as employee leave requests, with relevant information from the company's internal knowledge base. The agent will contact HR specialists and inform them that an employee needs support in uncommon situations.

Once the agent is set up, Contoso employees can access personnel information within Teams without having to search the company's intranet.

Create a new agent in a group.

1. Access Copilot Studio . The first time you use Copilot Studio, you may be asked to select a Teams group for your agent.

2. If prompted, select the group you want to manage the agent in, then select Continue . You can create a new group if needed.

3. Select Create blank agent .

4. Enter a name for your agent - for example: "HR Support bot".

5. Select Create . The agent is created and the Overview page appears.

6. Replace the default icon with a more suitable one, if desired.

7. Add prompt suggestions, if desired.

Develop themes for frequently asked questions about leave of absence.

The agent comes with a set of topics that define how it interacts with users. Let's build a topic to answer employee questions about leave requests.

1. Access the agent's Topics page .

2. Select Add a topic > From blank .

3. On the Trigger node , select Edit . The Phrases panel will appear.

4. Use the text box below Add phrases to add trigger phrases for this theme. For example, enter the following phrases:

  • Information about leave is needed.
  • I need help with leave of absence.
  • How many paid leave days do I have?
  • What are national holidays?
  • I need extended leave.

The trigger phrases for a topic determine how users will ask questions about that topic. This is how we expect employees to ask about leave.

Copilot Studio has built-in natural language processing capabilities. You simply define a few trigger phrases about leave requests, and the agent can accurately trigger the topic based on employee input.

5. Close the Phrases panel when you're finished. Node Trigger will display the phrases.

6. Select Details from the toolbar. The Topic details panel will appear.

7. Name the subject "Employee time off" and enter a suitable description.

8. Close the Details table .

9. Select Save .

Identify how agents support interaction.

1. Select the Add node icon below the Trigger node , then select Send a message . A Message node will appear.

2. Enter the following text: "I can help with questions related to time-off".

3. Select the Add node icon below the Message node , then select Ask a question . A Question node will appear.

4. Enter the following questions: "What information are you looking for?"

5. In the Options for user section , select New option , then enter "Paid vacation".

6. Select the New option again, and enter "National holidays".

Your theme will branch based on the options the user selects.

7. Select the default variable name in the "Save user response as" section to open the Variable properties panel and change the name to something meaningful, such as TimeOffType. The changes will be reflected in the editor.

You can add different responses for each option. For "Paid vacation," the agent can direct the employee to the internal HR website to look up the paid leave policy.

8. Add a Message node to the Paid vacation branch with the following message for employees: "For paid vacation time-off, go to www.contoso.com/HR/PaidTimeOffto submit time-off requests".

9. On the National holidays path , add a Message node with the following text:

National holidays for 2020: - New Year's Day: January 1st - Memorial Day: May 25th - Independence day: July 4th - Labor Day: September 7th - Thanksgiving: November 26th - 27th - Christmas Eve and Christmas Day: December 24th - 25th

10. Select the Add node icon below the set of conditional branches, point to Topic management > Go to another topic , and then select End of Conversation . Ending the conversation in this way will cause the agent to display the customer satisfaction survey.

11. Select Save .

Check your agent

Copilot Studio includes a built-in test suite that you can use to test the agent in real time.

1. To open the test case, select Test from the toolbar.

2. Enter "I need time off information".

Although "I need time off information" doesn't exactly match any trigger phrase, the system will process the user input and trigger the Employee time off topic .

When chatting with the system, you'll see the conversation's position in real time by monitoring the checkmarks next to each running node.

3. Select Paid vacation

The topic will branch based on user feedback. You open the Variables panel to track the TimeOffType variable. However, what happens if the user is looking for information about national holidays in their request? The user might get frustrated if the system asks them to repeat themselves. Let's see.

4. At the top of the test panel, select the Start new test session icon to restart the conversation.

5. Enter "Need information on national holidays".

The agent will skip the question about the type of leave and directly provide information about national holidays. This behavior occurs because Copilot Studio supports proactive data entry and can identify that the user is asking about national holidays.

Elevate the topic to handle more complex queries by forwarding them to an HR specialist.

After completing the basic steps, add the more complex Extended leave option to the theme.

1. Let's go back to the topic of Employee time off .

2. On the Question node, add the Extended leave option .

Because each employee's individual circumstances are different, questions about extended leave should be discussed with HR professionals. You can build an agent to connect HR professionals with your employees.

3. Add a Message node that says "Extended leave needs HR expert approval. Let me connect you with them".

In this example, you add a tool to notify HR professionals. This tool sends a tag to the HR professional channel in Teams to let professionals know that an employee needs their contact. You create the tool to send the message to a Teams channel and then call it with the appropriate input.

4. Add a Question node that asks for a description of the problem: "How would you describe the issue?"

5. In the Identify section , select User's entire response .

6. Replace the default name of the variable containing the answer with "Description".

7. Select the Add node icon below the Question node , point to Add a tool , and then select Create a flow . Power Automate will open.

8. In Power Automate, add the following Teams step: Post message in a chat or channel . A new flow, based on the template, will open.

a. If Power Automate asks you to authenticate your connection to Teams, select Sign in under This flow will connect to .

b. Select the first node of the flow, " When Copilot Studio calls a flow ," to add the inputs you want your agent to pass to this flow: the title for the message and the question to post to the channel.

  • Select Add an input , choose Text , replace the default input name "Text" with "Subject", and leave the remaining field blank.
  • Select Add an input again, choose Text , replace the default input field name with "Question", and leave the other field blank.

c. Select the "Post message in a chat or channel" node and fill in the parameters for the Teams step.

  • For Post as , select User .
  • For Post in , select Channel .
  • For Teams and Channels , select or enter the groups and channels you want to post messages to for HR professionals.
  • For Message , insert the input parameter Question.
  • In the Advanced parameters section , select Subject , and then insert the input parameter Subject.

d. Replace the default template name with a name that represents your flow—for example, "Post an HR question to an expert"—and save it.

9. Return to Copilot Studio, save your theme, and reload the page to refresh the list of available flows.

10. Select the Add node icon again below the Question node , point to Add a tool , and then select your new flow.

  • For the Subject parameter , enter "Extended leave question".
  • For Message , select the Description variable ; this variable is collected during the conversation with the employee.

Tip:

Your Agent Copilot Studio integrates directly with Teams, so it knows which agent you're chatting with. This allows you to build personalized and customized responses for the agent.

To use the name of the person chatting with the agent, there is a predefined variable called `name` bot.UserDisplayNamethat you can use like any other variable.

You can let the staff know that their request has been forwarded to the specialists.

11. Add a message node with the content "We notified the expert. They'll reach out shortly".

12. Save the topic.

You can add more topics so that the HR Support Bot can answer more questions from Contoso employees.

Tip : Always test your agent to ensure it's working as expected to provide the best experience for your employees. You'll see a message posted to the Teams channel when the flow is executed from the test chat.

Publish your agent and allow other agents to use it.

1. Select Publish at the top of the page.

Tip : If you are in a chat with the agent, you can type "restart" after publishing the changes. This command will restart the chat with the latest version of the agent.

To enable the agent to be used by employees, follow these steps:

2. Access the Channels page .

3. Select the Microsoft 365 and Microsoft Teams channels .

a. Select Add channel .

b. Options to customize the agent's interface.

c. Share the agent with your team.

Checking the agent in the Built with Power Platform section of the Teams app store is one way to test it, as it doesn't require administrator approval and avoids sending spam to the admin.

4. Once you are completely satisfied, share the agent with your organization. This step requires administrator approval.

Find your agent in the Teams app store.

An employee named Melissa can find the agent you created in the Teams app store.

Depending on how you share the agent, Melissa may find it in the Copilot extensions section or the Built for your org section in the Teams app store. For an agent to appear in the Built for your org section , an administrator must approve it first.

Melissa selects the agent application and chooses Add for me . The agent appears in the Teams application bar.

The Greeting theme automatically welcomes Melissa.

Tip : You can edit the Greeting theme to create a customized welcome message.

Melissa needed time off in July and August for personal reasons and entered "need information about time off". Melissa selected Paid vacation and a website appeared where she could learn more about paid time off.

The agent then collects data on customer satisfaction and concludes the conversation.

Melissa checked the HR department's website regarding paid leave and realized she needed extended leave. Melissa went back to her manager and typed "I need extended leave."

The manager informed Melissa that a human resources specialist was needed to handle her request for extended leave and asked her to describe the issue in detail.

The agent notified a specialist, who then contacted Melissa.

In the HR team's channel, you can see that the agent ran the flow and posted Melissa's request to the channel.

You've just finished reading the article "Create a basic agent and publish it to Microsoft Teams." edited by the TipsMake team. We hope this article has provided you with many useful tech tips and tricks. You can search for similar articles on tips and guides. Thank you for reading and for following us regularly.

Close
Category

System

Windows XP

Windows Server 2012

Windows 8

Windows 7

Windows 10

Wifi tips

Virus Removal - Spyware

Speed ​​up the computer

Server

Security solution

Mail Server

LAN - WAN

Ghost - Install Win

Fix computer error

Configure Router Switch

Computer wallpaper

Computer security

Mac OS X

Mac OS System software

Mac OS Security

Mac OS Office application

Mac OS Email Management

Mac OS Data - File

Mac hardware

Hardware

USB - Flash Drive

Speaker headset

Printer

PC hardware

Network equipment

Laptop hardware

Computer components

Advice Computer

Game

PC game

Online game

Mobile Game

Pokemon GO

information

Technology story

Technology comments

Quiz technology

New technology

British talent technology

Attack the network

Artificial intelligence

Technology

Smart watches

Raspberry Pi

Linux

Camera

Basic knowledge

Banking services

SEO tips

Science

Strange story

Space Science

Scientific invention

Science Story

Science photo

Science and technology

Medicine

Health Care

Fun science

Environment

Discover science

Discover nature

Archeology

Life

Travel Experience

Tips

Raise up child

Make up

Life skills

Home Care

Entertainment

DIY Handmade

Cuisine

Christmas

Application

Web Email

Website - Blog

Web browser

Support Download - Upload

Software conversion

Social Network

Simulator software

Online payment

Office information

Music Software

Map and Positioning

Installation - Uninstall

Graphic design

Free - Discount

Email reader

Edit video

Edit photo

Compress and Decompress

Chat, Text, Call

Archive - Share

Electric

Water heater

Washing machine

Television

Machine tool

Fridge

Fans

Air conditioning

Program

Unix and Linux

SQL Server

SQL

Python

Programming C

PHP

NodeJS

MongoDB

jQuery

JavaScript

HTTP

HTML

Git

Database

Data structure and algorithm

CSS and CSS3

C ++

C #

AngularJS

Mobile

Wallpapers and Ringtones

Tricks application

Take and process photos

Storage - Sync

Security and Virus Removal

Personalized

Online Social Network

Map

Manage and edit Video

Data

Chat - Call - Text

Browser and Add-on

Basic setup