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.
70 lines
3.4 KiB
Swift
70 lines
3.4 KiB
Swift
//
|
|
// ProjectsCreate.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
public struct ProjectsCreate: Sendable, Codable, ParameterConvertible, Hashable {
|
|
|
|
/** Analytics is the opt-OUT for the wired-by-default analytics beacon: absent (nil) ⇒ ON (the default); explicit false ⇒ off. A pointer so \"unset\" is distinguishable from \"false\" — the only way to turn the default off. */
|
|
public var analytics: Bool?
|
|
/** Description is the one-line summary, copied onto anything forked from this project. */
|
|
public var description: String?
|
|
/** Framework is a BUILD HINT from a closed set, defaulting to static. It tells CI how to build a linked repo and never gates a deploy. */
|
|
public var framework: String?
|
|
/** License is the terms that upstream work carries. */
|
|
public var license: String?
|
|
/** Name is the project's display name and the only REQUIRED field. When slug is omitted it is also what the slug is derived from. */
|
|
public var name: String?
|
|
public var repo: ProjectsCreateRepo?
|
|
/** Slug is the handle everything else addresses this project by: the public host `<slug>.hanzo.app`, the object-store key segment, and the path parameter of every later call. Derived from the name when omitted. It is a hostname label, so it is constrained and reserved labels such as `api` or `admin` are refused. */
|
|
public var slug: String?
|
|
/** Upstream credits the third-party work this project was published from. It is accepted from any caller: giving away credit can only cost the publisher, so it needs no gate. */
|
|
public var upstream: String?
|
|
/** Visibility is \"public\" (the default when absent) or \"private\". Publishing publicly is ungated — that is the point of a community. Going PRIVATE is the paid feature, so an unfunded org asking for it is refused rather than silently downgraded (see resolve). */
|
|
public var visibility: String?
|
|
|
|
public init(analytics: Bool? = nil, description: String? = nil, framework: String? = nil, license: String? = nil, name: String? = nil, repo: ProjectsCreateRepo? = nil, slug: String? = nil, upstream: String? = nil, visibility: String? = nil) {
|
|
self.analytics = analytics
|
|
self.description = description
|
|
self.framework = framework
|
|
self.license = license
|
|
self.name = name
|
|
self.repo = repo
|
|
self.slug = slug
|
|
self.upstream = upstream
|
|
self.visibility = visibility
|
|
}
|
|
|
|
public enum CodingKeys: String, CodingKey, CaseIterable {
|
|
case analytics
|
|
case description
|
|
case framework
|
|
case license
|
|
case name
|
|
case repo
|
|
case slug
|
|
case upstream
|
|
case visibility
|
|
}
|
|
|
|
// Encodable protocol methods
|
|
|
|
public func encode(to encoder: Encoder) throws {
|
|
var container = encoder.container(keyedBy: CodingKeys.self)
|
|
try container.encodeIfPresent(analytics, forKey: .analytics)
|
|
try container.encodeIfPresent(description, forKey: .description)
|
|
try container.encodeIfPresent(framework, forKey: .framework)
|
|
try container.encodeIfPresent(license, forKey: .license)
|
|
try container.encodeIfPresent(name, forKey: .name)
|
|
try container.encodeIfPresent(repo, forKey: .repo)
|
|
try container.encodeIfPresent(slug, forKey: .slug)
|
|
try container.encodeIfPresent(upstream, forKey: .upstream)
|
|
try container.encodeIfPresent(visibility, forKey: .visibility)
|
|
}
|
|
}
|
|
|