C# / .NET

.NET 6, 7, or 8.

Install

dotnet add package GeckoGuard

Quick start

using GeckoGuard;

using var client = new GeckoGuardClient("gg_live_...", "your-product-uuid");

try
{
    var auth = await client.AuthorizeAsync("LICENSE-KEY-123");
    Console.WriteLine($"Allowed: {auth.Allow}");
}
catch (LicenseDeniedException ex)
{
    Console.WriteLine($"Denied: {ex.Response.ReasonCode}");
    return;
}

GeckoGuardClient implements IDisposable — wrap in using to release the underlying HttpClient.

Configuration

new GeckoGuardClient(
    apiKey: "gg_live_...",
    productId: "your-product-uuid",
    baseUrl: "https://api.geckoguard.net",
    signingSecret: null);  // enable HMAC request signing

For the full method list and endpoint reference, see the API Reference.