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.
46 lines
1.6 KiB
Swift
46 lines
1.6 KiB
Swift
//
|
|
// BuildRequest.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
public struct BuildRequest: Sendable, Codable, ParameterConvertible, Hashable {
|
|
|
|
/** Name is the plugin's name: one lowercase path segment (a-z0-9, _ or -), and the id the runtime loads it by. */
|
|
public var name: String?
|
|
/** Provider is the connectors provider whose credential the plugin reads at run time. Empty for a plugin that needs none. */
|
|
public var provider: String?
|
|
/** Source is TypeScript to build as-is. Exactly one of Source or Spec. */
|
|
public var source: String?
|
|
/** Spec is API documentation — an OpenAPI document, or prose describing the endpoints — that the generator turns into Source. The generated source is returned in the response, so a caller can read what will run before it runs. */
|
|
public var spec: String?
|
|
|
|
public init(name: String? = nil, provider: String? = nil, source: String? = nil, spec: String? = nil) {
|
|
self.name = name
|
|
self.provider = provider
|
|
self.source = source
|
|
self.spec = spec
|
|
}
|
|
|
|
public enum CodingKeys: String, CodingKey, CaseIterable {
|
|
case name
|
|
case provider
|
|
case source
|
|
case spec
|
|
}
|
|
|
|
// Encodable protocol methods
|
|
|
|
public func encode(to encoder: Encoder) throws {
|
|
var container = encoder.container(keyedBy: CodingKeys.self)
|
|
try container.encodeIfPresent(name, forKey: .name)
|
|
try container.encodeIfPresent(provider, forKey: .provider)
|
|
try container.encodeIfPresent(source, forKey: .source)
|
|
try container.encodeIfPresent(spec, forKey: .spec)
|
|
}
|
|
}
|
|
|