Skip to content

AgentPrismWebhookOptions

Namespace AgentPrism · Assembly AgentPrism.Core.dll

Event publishing (webhook) settings.

public sealed class AgentPrismWebhookOptions

objectAgentPrismWebhookOptions

object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Read from the AgentPrism:Webhooks configuration section.

public AgentPrismWebhookOptions()

The configuration section name.

public const string SectionName = "AgentPrism:Webhooks"

string

Whether unencrypted http targets are allowed. Even when allowed, only loopback addresses are accepted.

public bool AllowInsecureHttp { get; set; }

bool

Needed to test a listener in local development. The loopback restriction is not lifted: sending an unencrypted event to a publicly reachable address would expose the event’s content to the network.

Whether delivery to private network addresses is allowed. Disabled by default.

public bool AllowPrivateNetworkTargets { get; set; }

bool

Enabling this opens up an SSRF surface: the server becomes able to send requests to any service on the internal network, and to the cloud metadata endpoint (169.254.169.254). It should only be enabled deliberately, on a closed network.

Gets or sets the only prefix under which a configuration key may be referenced as a subscription’s signing secret. Default is "AgentPrism:WebhookSecrets:".

public string AllowedConfigurationPrefix { get; set; }

string

A security boundary, not a convenience default — the same reason as AgentPrismTenantProviderOptions.AllowedConfigurationPrefix. Without it, a subscription could name an unrelated configuration key as its “signing secret” and AgentPrism would sign deliveries with a value that was never meant to leave the process.

If a subscription fails this many times in a row, it is automatically disabled and the event is written to the audit trail.

public int DisableAfterConsecutiveFailures { get; set; }

int

Whether event publishing is enabled. While disabled, a subscription can be registered, but no event is written to the queue.

public bool Enabled { get; set; }

bool

Gets or sets how many extra headers a subscription may add to a delivery. Default 20.

public int MaxExtraHeaders { get; set; }

int

Extra headers are administrator input and travel on every delivery. Headers whose name AgentPrism sets itself are always dropped, whatever this limit is.

The maximum bytes read from the recipient’s response body.

public int MaxResponseBytes { get; set; }

int

The response body is kept only for diagnostics. Reading it without a limit would let a malicious recipient exhaust memory.

The retry ladder. The list’s length is also the maximum number of attempts.

public IList<TimeSpan> RetryDelays { get; }

IList<TimeSpan>

This ladder is handed to the queue through ReleaseForRetryAsync(retryAfter); a second queue or scheduler is not written.

The signature timestamp tolerance the recipient should accept. This is the value recommended to the recipient in the README; AgentPrism only documents it.

public TimeSpan SignatureTolerance { get; set; }

TimeSpan

The timeout for a single delivery attempt.

public TimeSpan Timeout { get; set; }

TimeSpan