Table of Contents

Class WebhookConfig

Namespace
Google.GenAI.Types
Assembly
Google.GenAI.dll

Configuration for webhook notifications. Used to configure webhook endpoints that will receive notifications when long-running operations (e.g., batch jobs, video generation) complete.

public record WebhookConfig : IEquatable<WebhookConfig>
Inheritance
WebhookConfig
Implements
Inherited Members

Properties

Uris

The webhook URIs to receive notifications. If set, these webhook URIs will be used instead of the registered webhooks.

[JsonPropertyName("uris")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public List<string>? Uris { get; set; }

Property Value

List<string>

UserMetadata

User metadata that will be included in each webhook event notification. Use this to attach custom key-value data to correlate webhook events with your internal systems.

[JsonPropertyName("userMetadata")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public Dictionary<string, object>? UserMetadata { get; set; }

Property Value

Dictionary<string, object>

Methods

FromJson(string, JsonSerializerOptions?)

Deserializes a JSON string to a WebhookConfig object.

public static WebhookConfig? FromJson(string jsonString, JsonSerializerOptions? options = null)

Parameters

jsonString string

The JSON string to deserialize.

options JsonSerializerOptions

Optional JsonSerializerOptions.

Returns

WebhookConfig

The deserialized WebhookConfig object, or null if deserialization fails.