-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathProgram.cs
More file actions
25 lines (21 loc) · 804 Bytes
/
Program.cs
File metadata and controls
25 lines (21 loc) · 804 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
using System;
using System.Net.Sockets;
using System.Net.WebSockets;
using Microsoft.Extensions.Configuration;
public class Program
{
public static void Main()
{
var config = new ConfigurationBuilder()
.AddJsonFile("appsettings.json", optional: false, reloadOnChange: true)
.Build();
string? endpoint = config["OpenAIEndpoint"];
Console.WriteLine($"Endpoint: {endpoint}");
string? botName = config["BotName"];
string? channelName = config["ChannelName"];
string? redisConnectionString = config["RedisConnectionString"];
RedisConnection redisConnection = new RedisConnection(redisConnectionString);
Bot bot = new Bot(endpoint, botName, channelName, redisConnection);
Console.ReadLine();
}
}