Class WebhookTarget

Namespace
Cratis.Chronicle.Webhooks
Assembly
Cratis.Chronicle.dll

Represents the target of a webhook.

public record WebhookTarget : IEquatable<WebhookTarget>
Inheritance
WebhookTarget
Implements
Inherited Members
Extension Methods

Constructors

WebhookTarget(WebhookTarget)

protected WebhookTarget(WebhookTarget original)

Parameters

original WebhookTarget

WebhookTarget(WebhookTargetUrl, OneOf<BasicAuthorization, BearerTokenAuthorization, OAuthAuthorization, None>, IReadOnlyDictionary<string, string>)

Represents the target of a webhook.

public WebhookTarget(WebhookTargetUrl Url, OneOf<BasicAuthorization, BearerTokenAuthorization, OAuthAuthorization, None> Authorization, IReadOnlyDictionary<string, string> Headers)

Parameters

Url WebhookTargetUrl

The WebhookTargetUrl.

Authorization OneOf<BasicAuthorization, BearerTokenAuthorization, OAuthAuthorization, None>

The authorization method.

Headers IReadOnlyDictionary<string, string>

The headers.

Properties

Authorization

The authorization method.

public OneOf<BasicAuthorization, BearerTokenAuthorization, OAuthAuthorization, None> Authorization { get; init; }

Property Value

OneOf<BasicAuthorization, BearerTokenAuthorization, OAuthAuthorization, None>

EqualityContract

protected virtual Type EqualityContract { get; }

Property Value

Type

Headers

The headers.

public IReadOnlyDictionary<string, string> Headers { get; init; }

Property Value

IReadOnlyDictionary<string, string>

Url

public WebhookTargetUrl Url { get; init; }

Property Value

WebhookTargetUrl

Methods

Deconstruct(out WebhookTargetUrl, out OneOf<BasicAuthorization, BearerTokenAuthorization, OAuthAuthorization, None>, out IReadOnlyDictionary<string, string>)

public void Deconstruct(out WebhookTargetUrl Url, out OneOf<BasicAuthorization, BearerTokenAuthorization, OAuthAuthorization, None> Authorization, out IReadOnlyDictionary<string, string> Headers)

Parameters

Url WebhookTargetUrl
Authorization OneOf<BasicAuthorization, BearerTokenAuthorization, OAuthAuthorization, None>
Headers IReadOnlyDictionary<string, string>

Equals(WebhookTarget?)

public virtual bool Equals(WebhookTarget? other)

Parameters

other WebhookTarget

Returns

bool

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object

Returns

bool

GetHashCode()

public override int GetHashCode()

Returns

int

PrintMembers(StringBuilder)

protected virtual bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

ToString()

public override string ToString()

Returns

string

Operators

operator ==(WebhookTarget?, WebhookTarget?)

public static bool operator ==(WebhookTarget? left, WebhookTarget? right)

Parameters

left WebhookTarget
right WebhookTarget

Returns

bool

operator !=(WebhookTarget?, WebhookTarget?)

public static bool operator !=(WebhookTarget? left, WebhookTarget? right)

Parameters

left WebhookTarget
right WebhookTarget

Returns

bool