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.
41 lines
1.6 KiB
Swift
41 lines
1.6 KiB
Swift
//
|
|
// EnvVarJSON.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
public struct EnvVarJSON: Sendable, Codable, ParameterConvertible, Hashable {
|
|
|
|
/** Key is the variable's name in the container, which must match `^[A-Za-z_][A-Za-z0-9_]*$`. For a sealed value it is also the last segment of the KMS ref, so it is what identifies the value across a round trip. */
|
|
public var key: String?
|
|
/** Secret says the value lives in KMS and never in the database. A caller may only ADD secrecy: the server seals a value whose key or shape looks like a credential anyway (secretshape.go), so an entry can come back secret that was not sent that way. */
|
|
public var secret: Bool?
|
|
/** Value is the plaintext, and it is WRITE-ONLY once the entry is secret: a sealed value reads back as \"\", and sending \"\" again KEEPS what is sealed rather than wiping it. Only a non-empty value seals a new one. */
|
|
public var value: String?
|
|
|
|
public init(key: String? = nil, secret: Bool? = nil, value: String? = nil) {
|
|
self.key = key
|
|
self.secret = secret
|
|
self.value = value
|
|
}
|
|
|
|
public enum CodingKeys: String, CodingKey, CaseIterable {
|
|
case key
|
|
case secret
|
|
case value
|
|
}
|
|
|
|
// Encodable protocol methods
|
|
|
|
public func encode(to encoder: Encoder) throws {
|
|
var container = encoder.container(keyedBy: CodingKeys.self)
|
|
try container.encodeIfPresent(key, forKey: .key)
|
|
try container.encodeIfPresent(secret, forKey: .secret)
|
|
try container.encodeIfPresent(value, forKey: .value)
|
|
}
|
|
}
|
|
|