Files
swift-sdk/Sources/Hanzo/Models/O11yO11yLLMUpdatablePricingRule.swift
zeekay 0c2f028a8c Generate the Swift client, which this copy did not carry
The forge tree held the package scaffolding and none of the generated sources —
2,435 files of APIs, Models and Infrastructure, including BaseAPI, were simply
absent, so anything depending on this copy had a package that compiled to
nothing usable.

Generated from the current API document rather than reconciled with the other
copy: a client is a function of the spec, so regenerating answers "which history
wins" without anyone having to choose. .spec-lock records which document, so the
next reader can tell.
2026-08-23 10:04:41 -07:00

74 lines
2.7 KiB
Swift

//
// O11yO11yLLMUpdatablePricingRule.swift
//
// Generated by openapi-generator
// https://openapi-generator.tech
//
import Foundation
public struct O11yO11yLLMUpdatablePricingRule: Sendable, Codable, ParameterConvertible, Hashable {
/** Enabled turns the rule on. */
public var enabled: Bool?
/** ID matches an existing rule by its id. */
public var id: String?
/** IsOverride pins the rule so the sync job skips it. Omit to leave a matched override untouched. */
public var isOverride: Bool?
/** Model is the model the rule prices. Required. */
public var modelName: String?
/** ModelPattern are the model-name globs the rule matches. Required. */
public var modelPattern: [String]?
/** Pricing is the per-unit cost. Required. */
public var pricing: O11yO11yLLMRulePricing?
/** Provider is the model's provider. Required. */
public var provider: String?
/** SourceID matches an existing rule by its upstream source id. */
public var sourceId: String?
/** Unit is the pricing unit, e.g. per_million_tokens. Required. */
public var unit: String?
public init(enabled: Bool? = nil, id: String? = nil, isOverride: Bool? = nil, modelName: String? = nil, modelPattern: [String]? = nil, pricing: O11yO11yLLMRulePricing? = nil, provider: String? = nil, sourceId: String? = nil, unit: String? = nil) {
self.enabled = enabled
self.id = id
self.isOverride = isOverride
self.modelName = modelName
self.modelPattern = modelPattern
self.pricing = pricing
self.provider = provider
self.sourceId = sourceId
self.unit = unit
}
public enum CodingKeys: String, CodingKey, CaseIterable {
case enabled
case id
case isOverride
case modelName
case modelPattern
case pricing
case provider
case sourceId
case unit
}
// Encodable protocol methods
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(enabled, forKey: .enabled)
try container.encodeIfPresent(id, forKey: .id)
try container.encodeIfPresent(isOverride, forKey: .isOverride)
try container.encodeIfPresent(modelName, forKey: .modelName)
try container.encodeIfPresent(modelPattern, forKey: .modelPattern)
try container.encodeIfPresent(pricing, forKey: .pricing)
try container.encodeIfPresent(provider, forKey: .provider)
try container.encodeIfPresent(sourceId, forKey: .sourceId)
try container.encodeIfPresent(unit, forKey: .unit)
}
}
@available(iOS 13, tvOS 13, watchOS 6, macOS 10.15, *)
extension O11yO11yLLMUpdatablePricingRule: Identifiable {}