mirror of
https://github.com/hanzoai/swift-sdk.git
synced 2026-10-30 18:20:19 +00:00
The projection these were generated from predated the compute migration, so they described /v1/visor — which the API serves at zero paths now. No /v1/visor path survives here.
114 lines
5.4 KiB
Swift
114 lines
5.4 KiB
Swift
//
|
|
// MCPListing.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
public struct MCPListing: Sendable, Codable, ParameterConvertible, Hashable {
|
|
|
|
/** Description is the publisher's one-line summary. */
|
|
public var description: String?
|
|
/** Featured puts the listing on the front of the shelf. Curation. */
|
|
public var featured: Bool?
|
|
/** Hidden keeps the listing out of the org-visible catalog. Curation: a sync never changes it. Only a SuperAdmin sets it, and only a SuperAdmin sees a hidden entry listed. */
|
|
public var hidden: Bool?
|
|
/** ID addresses the listing in a URL. It is the reverse-DNS NAME with its one slash written as an underscore — reversible, because a namespace never contains an underscore — so the id is readable and stable rather than a hash that means nothing to whoever reads a link. */
|
|
public var id: String?
|
|
/** Logo is the brand mark to render for the listing — the publisher's icon when the entry carries one, or the one an admin set. Curation. */
|
|
public var logo: String?
|
|
/** Name is the publisher's reverse-DNS name, e.g. \"com.stripe/mcp\". */
|
|
public var name: String?
|
|
/** Official is whether this is the vendor's OWN server rather than someone else's copy of it. Derived on every sync (see isOfficial) until a SuperAdmin sets it explicitly, after which the admin's answer stands. */
|
|
public var official: Bool?
|
|
/** Packages are the runnable package forms — npm, pypi, oci — each with the runtime that launches it and the transport it then speaks. */
|
|
public var packages: [MCPPackage]?
|
|
/** Registry is the upstream this row was synced from. */
|
|
public var registry: String?
|
|
/** Remotes are the hosted endpoints the publisher serves the server at. */
|
|
public var remotes: [MCPRemote]?
|
|
/** Repo is the source repository URL, when the entry names one. */
|
|
public var repo: String?
|
|
/** Site is the project's homepage, when the entry names one. */
|
|
public var site: String?
|
|
/** Synced is when this row was last confirmed against upstream, Unix seconds. */
|
|
public var synced: Int64?
|
|
/** Title is the human-readable display name, when the entry carries one. */
|
|
public var title: String?
|
|
/** Transports are the distinct transports this server can be reached over, sorted: some of \"stdio\", \"streamable-http\", \"sse\". A listing with \"streamable-http\" is one an org can enable here and now; a listing that is only \"stdio\" needs a process to run it. */
|
|
public var transports: [String]?
|
|
/** Vendor is the namespace half of Name — the publisher, e.g. \"com.stripe\". */
|
|
public var vendor: String?
|
|
/** Version is the published version of this listing. */
|
|
public var version: String?
|
|
|
|
public init(description: String? = nil, featured: Bool? = nil, hidden: Bool? = nil, id: String? = nil, logo: String? = nil, name: String? = nil, official: Bool? = nil, packages: [MCPPackage]? = nil, registry: String? = nil, remotes: [MCPRemote]? = nil, repo: String? = nil, site: String? = nil, synced: Int64? = nil, title: String? = nil, transports: [String]? = nil, vendor: String? = nil, version: String? = nil) {
|
|
self.description = description
|
|
self.featured = featured
|
|
self.hidden = hidden
|
|
self.id = id
|
|
self.logo = logo
|
|
self.name = name
|
|
self.official = official
|
|
self.packages = packages
|
|
self.registry = registry
|
|
self.remotes = remotes
|
|
self.repo = repo
|
|
self.site = site
|
|
self.synced = synced
|
|
self.title = title
|
|
self.transports = transports
|
|
self.vendor = vendor
|
|
self.version = version
|
|
}
|
|
|
|
public enum CodingKeys: String, CodingKey, CaseIterable {
|
|
case description
|
|
case featured
|
|
case hidden
|
|
case id
|
|
case logo
|
|
case name
|
|
case official
|
|
case packages
|
|
case registry
|
|
case remotes
|
|
case repo
|
|
case site
|
|
case synced
|
|
case title
|
|
case transports
|
|
case vendor
|
|
case version
|
|
}
|
|
|
|
// Encodable protocol methods
|
|
|
|
public func encode(to encoder: Encoder) throws {
|
|
var container = encoder.container(keyedBy: CodingKeys.self)
|
|
try container.encodeIfPresent(description, forKey: .description)
|
|
try container.encodeIfPresent(featured, forKey: .featured)
|
|
try container.encodeIfPresent(hidden, forKey: .hidden)
|
|
try container.encodeIfPresent(id, forKey: .id)
|
|
try container.encodeIfPresent(logo, forKey: .logo)
|
|
try container.encodeIfPresent(name, forKey: .name)
|
|
try container.encodeIfPresent(official, forKey: .official)
|
|
try container.encodeIfPresent(packages, forKey: .packages)
|
|
try container.encodeIfPresent(registry, forKey: .registry)
|
|
try container.encodeIfPresent(remotes, forKey: .remotes)
|
|
try container.encodeIfPresent(repo, forKey: .repo)
|
|
try container.encodeIfPresent(site, forKey: .site)
|
|
try container.encodeIfPresent(synced, forKey: .synced)
|
|
try container.encodeIfPresent(title, forKey: .title)
|
|
try container.encodeIfPresent(transports, forKey: .transports)
|
|
try container.encodeIfPresent(vendor, forKey: .vendor)
|
|
try container.encodeIfPresent(version, forKey: .version)
|
|
}
|
|
}
|
|
|
|
|
|
@available(iOS 13, tvOS 13, watchOS 6, macOS 10.15, *)
|
|
extension MCPListing: Identifiable {}
|