blob: ca2425b573279c97ca769b758daa5590b4dc4048 (
plain)
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
26
27
28
29
30
31
32
33
34
35
36
|
namespace Enmarcha.Backend.Configuration;
public class AppConfiguration
{
public required string OpenTripPlannerBaseUrl { get; set; }
public required string GeoapifyApiKey { get; set; }
public string NominatimBaseUrl { get; set; } = "https://nominatim.openstreetmap.org";
public string[] OtpFeeds { get; set; } = [];
public OpenTelemetryConfiguration? OpenTelemetry { get; set; }
public VapidConfiguration? Vapid { get; set; }
}
public class OpenTelemetryConfiguration
{
public string? Endpoint { get; set; }
public string? Headers { get; set; }
}
public class VapidConfiguration
{
/// <summary>
/// VAPID subject — typically "mailto:admin@yourdomain.com" or a URL.
/// </summary>
public required string Subject { get; set; }
/// <summary>
/// Base64url-encoded VAPID public key. Safe to expose to browsers.
/// </summary>
public required string PublicKey { get; set; }
/// <summary>
/// Base64url-encoded VAPID private key. Store in user secrets or environment variables only.
/// Generate a key pair with: VapidHelper.GenerateVapidKeys() from the WebPush NuGet package.
/// </summary>
public required string PrivateKey { get; set; }
}
|