mirror of
https://github.com/hanzoai/swift-sdk.git
synced 2026-10-30 18:20:19 +00:00
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.
64 lines
2.5 KiB
Swift
64 lines
2.5 KiB
Swift
//
|
|
// ProviderView.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
public struct ProviderView: Sendable, Codable, ParameterConvertible, Hashable {
|
|
|
|
/** Available is whether THIS DEPLOYMENT has the provider's app credentials, so connect can succeed. False renders the card without a working Connect button. */
|
|
public var available: Bool?
|
|
/** Category groups the card (\"Communication\", \"Developer\", \"Marketing\"). */
|
|
public var category: String?
|
|
/** Connected is whether this org has a live connection to the provider. */
|
|
public var connected: Bool?
|
|
/** Connection is the connected account's non-secret detail. Absent when the org has no connection; tokens NEVER appear here (they live only in KMS). */
|
|
public var connection: ConnectionView?
|
|
/** Description is the one-line pitch the console card shows. */
|
|
public var description: String?
|
|
/** ID is the provider's registry id and the :provider path segment (\"slack\"). */
|
|
public var id: String?
|
|
/** Name is the provider's display name (\"Slack\"). */
|
|
public var name: String?
|
|
|
|
public init(available: Bool? = nil, category: String? = nil, connected: Bool? = nil, connection: ConnectionView? = nil, description: String? = nil, id: String? = nil, name: String? = nil) {
|
|
self.available = available
|
|
self.category = category
|
|
self.connected = connected
|
|
self.connection = connection
|
|
self.description = description
|
|
self.id = id
|
|
self.name = name
|
|
}
|
|
|
|
public enum CodingKeys: String, CodingKey, CaseIterable {
|
|
case available
|
|
case category
|
|
case connected
|
|
case connection
|
|
case description
|
|
case id
|
|
case name
|
|
}
|
|
|
|
// Encodable protocol methods
|
|
|
|
public func encode(to encoder: Encoder) throws {
|
|
var container = encoder.container(keyedBy: CodingKeys.self)
|
|
try container.encodeIfPresent(available, forKey: .available)
|
|
try container.encodeIfPresent(category, forKey: .category)
|
|
try container.encodeIfPresent(connected, forKey: .connected)
|
|
try container.encodeIfPresent(connection, forKey: .connection)
|
|
try container.encodeIfPresent(description, forKey: .description)
|
|
try container.encodeIfPresent(id, forKey: .id)
|
|
try container.encodeIfPresent(name, forKey: .name)
|
|
}
|
|
}
|
|
|
|
|
|
@available(iOS 13, tvOS 13, watchOS 6, macOS 10.15, *)
|
|
extension ProviderView: Identifiable {}
|