// // CreateCustomProviderRequest.swift // // Generated by openapi-generator // https://openapi-generator.tech // import Foundation #if canImport(AnyCodable) import AnyCodable #endif public struct CreateCustomProviderRequest: Codable, JSONEncodable, Hashable { public var apiKey: String public var apiUrl: String public var displayName: String public var models: [String] public var providerType: String public var supportsStreaming: Bool? public init(apiKey: String, apiUrl: String, displayName: String, models: [String], providerType: String, supportsStreaming: Bool? = nil) { self.apiKey = apiKey self.apiUrl = apiUrl self.displayName = displayName self.models = models self.providerType = providerType self.supportsStreaming = supportsStreaming } public enum CodingKeys: String, CodingKey, CaseIterable { case apiKey = "api_key" case apiUrl = "api_url" case displayName = "display_name" case models case providerType = "provider_type" case supportsStreaming = "supports_streaming" } // Encodable protocol methods public func encode(to encoder: Encoder) throws { var container = encoder.container(keyedBy: CodingKeys.self) try container.encode(apiKey, forKey: .apiKey) try container.encode(apiUrl, forKey: .apiUrl) try container.encode(displayName, forKey: .displayName) try container.encode(models, forKey: .models) try container.encode(providerType, forKey: .providerType) try container.encodeIfPresent(supportsStreaming, forKey: .supportsStreaming) } }