using NostrRelay; using NostrServices.Client; using PayForReactions; var builder = WebApplication.CreateBuilder(args); var config = builder.Configuration.GetSection("Config").Get()!; builder.Services.AddSingleton(config); builder.Services.AddHttpClient(); builder.Services.AddTransient(); builder.Services.AddTransient(); builder.Services.AddTransient(); builder.Services.AddTransient(); builder.Services.AddSingleton(svc => { var logger = svc.GetRequiredService>(); return new NostrStore("./data", logger); }); var host = builder.Build(); host.UseWebSockets(); host.MapRelay("/", new RelayDocument() { Name = "wss://reactions.v0l.io", Description = "Zapping server for Kieran's paid reactions", SupportedNips = [1], Software = "PayForReactions (https://git.v0l.io/Kieran/NostrServices)", Limitation = new() { RestrictedWrites = true, AuthRequired = false, PaymentRequired = false } }); host.Run();