BotSharp/tests/BotSharp.Plugin.PizzaBot/PizzaBotPlugin.cs
2023-09-19 07:17:50 -05:00

21 lines
705 B
C#

using BotSharp.Abstraction.Agents;
using BotSharp.Plugin.PizzaBot.Hooks;
namespace BotSharp.Plugin.PizzaBot;
public class PizzaBotPlugin : IBotSharpPlugin
{
public void RegisterDI(IServiceCollection services, IConfiguration config)
{
// Register callback function
services.AddScoped<IFunctionCallback, GetPizzaTypesFn>();
services.AddScoped<IFunctionCallback, GetPizzaPricesFn>();
services.AddScoped<IFunctionCallback, PlaceOrderFn>();
services.AddScoped<IFunctionCallback, OrderFoundFn>();
services.AddScoped<IFunctionCallback, GetDeliveryTimeFn>();
// Register hooks
services.AddScoped<IAgentHook, PizzaBotAgentHook>();
}
}