Hanzo Cloud SDK for Swift — the full /v1 cloud surface (AI, agents, compute,
data, network, security, platform, observe, web3, apps) as an idiomatic
async/await SwiftPM package. Generated from the Hanzo OpenAPI spec, so it never drifts from the API.
Swift Package Manager — add to your Package.swift:
dependencies: [
.package(url: "https://github.com/hanzo-swift/sdk", from: "8.0.0")
]or in Xcode: File → Add Packages… and enter https://github.com/hanzo-swift/sdk.
import Hanzo
// The client talks to the Hanzo Gateway at https://api.hanzo.ai/v1.
// Authenticate with your Hanzo API key.
HanzoAPI.customHeaders = ["Authorization": "Bearer \(ProcessInfo.processInfo.environment["HANZO_API_KEY"] ?? "")"]
// Every service is an API type (AiAPI, AgentsAPI, NexusAPI, ComputeAPI, …).
// Async/await throughout:
let agents = try await AgentsAPI.chatGetAgents()
print(agents)Every endpoint and model is documented under docs/ and in
GENERATED.md (the generator's full API index). Base URL,
auth, and per-API method signatures live there.
- Full Cloud SDK (this package) — the entire
/v1surface, generated from OpenAPI. - AI + agents — the hand-crafted flagship library; see the sibling-language SDKs.
Open source · every language · on-chain settlement. hanzo.ai · docs.hanzo.ai
SDKs in every language — Python (flagship) · TypeScript · Go · Rust · C++ · Swift · Kotlin · umbrella
Apache-2.0.