BotSharp/src/Plugins/BotSharp.Plugin.WebDriver/WebDriverPlugin.cs

22 lines
849 B
C#
Raw Normal View History

2024-01-03 19:40:41 +00:00
using BotSharp.Plugin.WebDriver.Drivers.PlaywrightDriver;
2024-01-03 04:43:37 +00:00
using BotSharp.Plugin.WebDriver.Services;
2023-11-15 13:33:46 +00:00
using Microsoft.Extensions.Configuration;
2024-01-03 04:43:37 +00:00
namespace BotSharp.Plugin.Playwrights;
2023-11-15 13:33:46 +00:00
public class WebDriverPlugin : IBotSharpPlugin
{
2024-01-12 22:20:22 +00:00
public string Id => "f0e26bc3-cfde-4b63-845c-c9c542abea44";
2023-11-15 13:33:46 +00:00
public string Name => "Web Driver";
2024-01-06 22:24:22 +00:00
public string Description => "Empower agent to manipulate web browser in automation tools.";
public string IconUrl => "https://cdn-icons-png.flaticon.com/512/8576/8576378.png";
2024-01-13 00:31:25 +00:00
public string[] AgentIds => new[] { "f3ae2a0f-e6ba-4ee1-a0b9-75d7431ff32b" };
2024-01-03 04:43:37 +00:00
2023-11-15 13:33:46 +00:00
public void RegisterDI(IServiceCollection services, IConfiguration config)
{
2024-01-03 04:43:37 +00:00
services.AddScoped<PlaywrightWebDriver>();
services.AddSingleton<PlaywrightInstance>();
services.AddScoped<WebDriverService>();
2023-11-15 13:33:46 +00:00
}
}