Files
swift-sdk/Sources/Hanzo/Models/O11yWebhookConfig.swift
zeekay 1df3ddf6bd Regenerate against the document the deployment answers for
The projection these were generated from predated the compute migration, so
they described /v1/visor — which the API serves at zero paths now.

No /v1/visor path survives here.
2026-09-05 18:55:38 -07:00

52 lines
1.9 KiB
Swift

//
// O11yWebhookConfig.swift
//
// Generated by openapi-generator
// https://openapi-generator.tech
//
import Foundation
public struct O11yWebhookConfig: Sendable, Codable, ParameterConvertible, Hashable {
public var notifierConfig: O11yNotifierConfig?
public var httpConfig: O11yHTTPClientConfig?
/** MaxAlerts is the maximum number of alerts to be sent per webhook message. Alerts exceeding this threshold will be truncated. Setting this to 0 allows an unlimited number of alerts. */
public var maxAlerts: Int?
/** Timeout is the maximum time allowed to invoke the webhook. Setting this to 0 does not impose a timeout. */
public var timeout: Int64?
public var url: JSONValue?
public var urlFile: String?
public init(notifierConfig: O11yNotifierConfig? = nil, httpConfig: O11yHTTPClientConfig? = nil, maxAlerts: Int? = nil, timeout: Int64? = nil, url: JSONValue? = nil, urlFile: String? = nil) {
self.notifierConfig = notifierConfig
self.httpConfig = httpConfig
self.maxAlerts = maxAlerts
self.timeout = timeout
self.url = url
self.urlFile = urlFile
}
public enum CodingKeys: String, CodingKey, CaseIterable {
case notifierConfig = "NotifierConfig"
case httpConfig = "http_config"
case maxAlerts = "max_alerts"
case timeout
case url
case urlFile = "url_file"
}
// Encodable protocol methods
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(notifierConfig, forKey: .notifierConfig)
try container.encodeIfPresent(httpConfig, forKey: .httpConfig)
try container.encodeIfPresent(maxAlerts, forKey: .maxAlerts)
try container.encodeIfPresent(timeout, forKey: .timeout)
try container.encodeIfPresent(url, forKey: .url)
try container.encodeIfPresent(urlFile, forKey: .urlFile)
}
}