microsoft/teams.net

Public

mirrored fromhttps://github.com/microsoft/teams.netAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
next/core-claude-agents

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

core/samples/CustomHosting/Program.cs

17lines · modecode

1// Copyright (c) Microsoft Corporation.
2// Licensed under the MIT License.
3
4using CustomHosting;
5using Microsoft.Teams.Bot.Apps;
6using Microsoft.Teams.Bot.Core.Hosting;
7
8WebApplicationBuilder webAppBuilder = WebApplication.CreateSlimBuilder(args);
9
10// TODO: Show how to setup multiple Teams Bot applications (like how it was done in PABot)
11webAppBuilder.Services.AddTeamsBotApplication<MyTeamsBotApp>();
12WebApplication webApp = webAppBuilder.Build();
13
14webApp.MapGet("/", () => $"Teams Bot App is running {TeamsBotApplication.Version}.");
15webApp.UseBotApplication<MyTeamsBotApp>();
16
17webApp.Run();
18