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.
1113 lines
65 KiB
Swift
1113 lines
65 KiB
Swift
//
|
|
// PricingAPI.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
open class PricingAPI {
|
|
|
|
/**
|
|
Returns the whole pricing catalog in one document: Zen and third-party models, providers, model families, the free-model list, plan and infrastructure pricing.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: [String: JSONValue]
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricing(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> [String: JSONValue] {
|
|
return try await getPricingWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the whole pricing catalog in one document: Zen and third-party models, providers, model families, the free-model list, plan and infrastructure pricing.
|
|
- GET /v1/pricing
|
|
- Returns the whole pricing catalog in one document: Zen and third-party models, providers, model families, the free-model list, plan and infrastructure pricing. Every model and provider it names is filtered to what the caller's org may see — the same gate the leaf routes apply, so this can never be an un-gated second source for what they hide.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<[String: JSONValue]>
|
|
*/
|
|
open class func getPricingWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<[String: JSONValue]> {
|
|
let localVariablePath = "/v1/pricing"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<[String: JSONValue]>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the Hanzo Base plans — the managed-instance tiers, each with its monthly and annual price, storage and request allowances and feature list.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingPlanList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingBase(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingPlanList {
|
|
return try await getPricingBaseWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the Hanzo Base plans — the managed-instance tiers, each with its monthly and annual price, storage and request allowances and feature list.
|
|
- GET /v1/pricing/base
|
|
- Returns the Hanzo Base plans — the managed-instance tiers, each with its monthly and annual price, storage and request allowances and feature list.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingPlanList>
|
|
*/
|
|
open class func getPricingBaseWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingPlanList> {
|
|
let localVariablePath = "/v1/pricing/base"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingPlanList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the blockchain access plans — the RPC and node tiers, each with its monthly price, compute-unit allowance and feature list.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingPlanList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingBlockchain(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingPlanList {
|
|
return try await getPricingBlockchainWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the blockchain access plans — the RPC and node tiers, each with its monthly price, compute-unit allowance and feature list.
|
|
- GET /v1/pricing/blockchain
|
|
- Returns the blockchain access plans — the RPC and node tiers, each with its monthly price, compute-unit allowance and feature list.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingPlanList>
|
|
*/
|
|
open class func getPricingBlockchainWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingPlanList> {
|
|
let localVariablePath = "/v1/pricing/blockchain"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingPlanList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the public cloud section of the catalog in one document: its instance plans, its regions and its block-storage prices.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: [String: JSONValue]
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingCloud(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> [String: JSONValue] {
|
|
return try await getPricingCloudWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the public cloud section of the catalog in one document: its instance plans, its regions and its block-storage prices.
|
|
- GET /v1/pricing/cloud
|
|
- Returns the public cloud section of the catalog in one document: its instance plans, its regions and its block-storage prices. The section's internal half — the provider costs Hanzo pays and the plan-to- provider routing table — is stripped before it is served, so this is what a customer may see and nothing more.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<[String: JSONValue]>
|
|
*/
|
|
open class func getPricingCloudWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<[String: JSONValue]> {
|
|
let localVariablePath = "/v1/pricing/cloud"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<[String: JSONValue]>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns just the cloud instance plans — each with its vCPU, memory, disk, CPU type, VM allowance, feature list and monthly and hourly price.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingPlanList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingCloudPlans(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingPlanList {
|
|
return try await getPricingCloudPlansWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns just the cloud instance plans — each with its vCPU, memory, disk, CPU type, VM allowance, feature list and monthly and hourly price.
|
|
- GET /v1/pricing/cloud/plans
|
|
- Returns just the cloud instance plans — each with its vCPU, memory, disk, CPU type, VM allowance, feature list and monthly and hourly price. It is the plans of the cloud section on their own.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingPlanList>
|
|
*/
|
|
open class func getPricingCloudPlansWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingPlanList> {
|
|
let localVariablePath = "/v1/pricing/cloud/plans"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingPlanList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the regions a cloud instance can be placed in, each with its id, display name and physical location.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingRegionList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingCloudRegions(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingRegionList {
|
|
return try await getPricingCloudRegionsWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the regions a cloud instance can be placed in, each with its id, display name and physical location.
|
|
- GET /v1/pricing/cloud/regions
|
|
- Returns the regions a cloud instance can be placed in, each with its id, display name and physical location. It is the regions of the cloud section on their own.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingRegionList>
|
|
*/
|
|
open class func getPricingCloudRegionsWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingRegionList> {
|
|
let localVariablePath = "/v1/pricing/cloud/regions"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingRegionList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the block-storage prices of the cloud section: the per-GB monthly rate and the volume size bounds a caller may ask for.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: [String: JSONValue]
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingCloudStorage(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> [String: JSONValue] {
|
|
return try await getPricingCloudStorageWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the block-storage prices of the cloud section: the per-GB monthly rate and the volume size bounds a caller may ask for.
|
|
- GET /v1/pricing/cloud/storage
|
|
- Returns the block-storage prices of the cloud section: the per-GB monthly rate and the volume size bounds a caller may ask for.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<[String: JSONValue]>
|
|
*/
|
|
open class func getPricingCloudStorageWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<[String: JSONValue]> {
|
|
let localVariablePath = "/v1/pricing/cloud/storage"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<[String: JSONValue]>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the compute section of the catalog: the cloud provider and region the prices are quoted for, the monthly markup applied to them, the full instance-size tier list and the named presets.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: [String: JSONValue]
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingCompute(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> [String: JSONValue] {
|
|
return try await getPricingComputeWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the compute section of the catalog: the cloud provider and region the prices are quoted for, the monthly markup applied to them, the full instance-size tier list and the named presets.
|
|
- GET /v1/pricing/compute
|
|
- Returns the compute section of the catalog: the cloud provider and region the prices are quoted for, the monthly markup applied to them, the full instance-size tier list and the named presets. It is the whole section as the pricing source records it, un-gated — no model or provider identity appears in it.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<[String: JSONValue]>
|
|
*/
|
|
open class func getPricingComputeWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<[String: JSONValue]> {
|
|
let localVariablePath = "/v1/pricing/compute"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<[String: JSONValue]>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns just the named compute sizes — the short, human-labelled list (\"Starter\", \"Pro\") a size picker renders, each carrying its provider slug, vCPU, memory, disk and price.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingPresetList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingComputePresets(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingPresetList {
|
|
return try await getPricingComputePresetsWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns just the named compute sizes — the short, human-labelled list (\"Starter\", \"Pro\") a size picker renders, each carrying its provider slug, vCPU, memory, disk and price.
|
|
- GET /v1/pricing/compute/presets
|
|
- Returns just the named compute sizes — the short, human-labelled list (\"Starter\", \"Pro\") a size picker renders, each carrying its provider slug, vCPU, memory, disk and price. It is the presets of the compute section on their own, for a caller that does not need the full tier table.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingPresetList>
|
|
*/
|
|
open class func getPricingComputePresetsWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingPresetList> {
|
|
let localVariablePath = "/v1/pricing/compute/presets"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingPresetList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the Hanzo Datastore rate card: the tier list, the per-GB storage and egress usage rates, the annual discount and the trial.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: [String: JSONValue]
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingDatastore(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> [String: JSONValue] {
|
|
return try await getPricingDatastoreWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the Hanzo Datastore rate card: the tier list, the per-GB storage and egress usage rates, the annual discount and the trial.
|
|
- GET /v1/pricing/datastore
|
|
- Returns the Hanzo Datastore rate card: the tier list, the per-GB storage and egress usage rates, the annual discount and the trial. It is the section as authored, un-gated — no provider identity appears in it. The route was missing while the data existed, so this 404d and every visitor to hanzo.ai's Infrastructure tab was told pricing was \"temporarily unavailable\".
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<[String: JSONValue]>
|
|
*/
|
|
open class func getPricingDatastoreWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<[String: JSONValue]> {
|
|
let localVariablePath = "/v1/pricing/datastore"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<[String: JSONValue]>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns what the caller's org can actually use: every managed item with its global state, whether it is effective here, whether this org is already opted into its beta, and whether it may still opt in.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: EnablementBoard
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingEnablement(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> EnablementBoard {
|
|
return try await getPricingEnablementWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns what the caller's org can actually use: every managed item with its global state, whether it is effective here, whether this org is already opted into its beta, and whether it may still opt in.
|
|
- GET /v1/pricing/enablement
|
|
- Returns what the caller's org can actually use: every managed item with its global state, whether it is effective here, whether this org is already opted into its beta, and whether it may still opt in. Read-only and safe for any caller — one without a validated principal simply sees the generally-available items and no opt-in affordance, never another org's state.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<EnablementBoard>
|
|
*/
|
|
open class func getPricingEnablementWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<EnablementBoard> {
|
|
let localVariablePath = "/v1/pricing/enablement"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<EnablementBoard>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the models the catalog highlights, filtered to what the caller's org may see.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingModelList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingFeatured(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingModelList {
|
|
return try await getPricingFeaturedWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the models the catalog highlights, filtered to what the caller's org may see.
|
|
- GET /v1/pricing/featured
|
|
- Returns the models the catalog highlights, filtered to what the caller's org may see. It is the same catalog as ListModels narrowed to entries the pricing source marks featured.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingModelList>
|
|
*/
|
|
open class func getPricingFeaturedWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingModelList> {
|
|
let localVariablePath = "/v1/pricing/featured"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingModelList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the models that cost nothing to call, filtered to what the caller's org may see.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingModelList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingFree(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingModelList {
|
|
return try await getPricingFreeWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the models that cost nothing to call, filtered to what the caller's org may see.
|
|
- GET /v1/pricing/free
|
|
- Returns the models that cost nothing to call, filtered to what the caller's org may see. It is the same catalog as ListModels narrowed to entries the pricing source marks free.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingModelList>
|
|
*/
|
|
open class func getPricingFreeWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingModelList> {
|
|
let localVariablePath = "/v1/pricing/free"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingModelList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
ListGPUTiers returns the rentable GPU configurations, each with its accelerator count and model, VRAM, vCPU, host memory and hourly price.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingTierList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingGpu(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingTierList {
|
|
return try await getPricingGpuWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
ListGPUTiers returns the rentable GPU configurations, each with its accelerator count and model, VRAM, vCPU, host memory and hourly price.
|
|
- GET /v1/pricing/gpu
|
|
- ListGPUTiers returns the rentable GPU configurations, each with its accelerator count and model, VRAM, vCPU, host memory and hourly price.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingTierList>
|
|
*/
|
|
open class func getPricingGpuWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingTierList> {
|
|
let localVariablePath = "/v1/pricing/gpu"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingTierList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Health reports that the pricing subsystem is mounted and serving.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingHealth
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingHealth(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingHealth {
|
|
return try await getPricingHealthWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Health reports that the pricing subsystem is mounted and serving.
|
|
- GET /v1/pricing/health
|
|
- Health reports that the pricing subsystem is mounted and serving. It answers from the process itself and consults neither the catalog bundle nor the enablement store, so it stays \"ok\" while either is degraded.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingHealth>
|
|
*/
|
|
open class func getPricingHealthWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingHealth> {
|
|
let localVariablePath = "/v1/pricing/health"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingHealth>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
ListIAMPlans returns the identity plans — the Hanzo IAM tiers, each with its monthly and annual price, monthly-active-user allowance and feature list.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingPlanList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingIam(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingPlanList {
|
|
return try await getPricingIamWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
ListIAMPlans returns the identity plans — the Hanzo IAM tiers, each with its monthly and annual price, monthly-active-user allowance and feature list.
|
|
- GET /v1/pricing/iam
|
|
- ListIAMPlans returns the identity plans — the Hanzo IAM tiers, each with its monthly and annual price, monthly-active-user allowance and feature list.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingPlanList>
|
|
*/
|
|
open class func getPricingIamWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingPlanList> {
|
|
let localVariablePath = "/v1/pricing/iam"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingPlanList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns one model's catalog entry — its pricing, context window and capabilities as the pricing source records them.
|
|
|
|
- parameter name: (path) Name is the model's name or its slugged id (\"zen4\", \"acme/some-model-1\"), matched case-insensitively. It comes from the path: the URL is the addressing authority.
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: [String: JSONValue]
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingModelByName(name: String, apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> [String: JSONValue] {
|
|
return try await getPricingModelByNameWithRequestBuilder(name: name, apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns one model's catalog entry — its pricing, context window and capabilities as the pricing source records them.
|
|
- GET /v1/pricing/model/{name}
|
|
- Returns one model's catalog entry — its pricing, context window and capabilities as the pricing source records them. A model hidden for the caller's org answers the same 404 an unknown name does, so a disabled model gets no existence oracle.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter name: (path) Name is the model's name or its slugged id (\"zen4\", \"acme/some-model-1\"), matched case-insensitively. It comes from the path: the URL is the addressing authority.
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<[String: JSONValue]>
|
|
*/
|
|
open class func getPricingModelByNameWithRequestBuilder(name: String, apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<[String: JSONValue]> {
|
|
var localVariablePath = "/v1/pricing/model/{name}"
|
|
let namePreEscape = "\(APIHelper.mapValueToPathItem(name))"
|
|
let namePostEscape = namePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? ""
|
|
localVariablePath = localVariablePath.replacingOccurrences(of: "{name}", with: namePostEscape, options: .literal, range: nil)
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<[String: JSONValue]>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the whole model catalog — every model the gateway serves, Zen and third-party alike — filtered to what the caller's org may see.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingModelList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingModels(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingModelList {
|
|
return try await getPricingModelsWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the whole model catalog — every model the gateway serves, Zen and third-party alike — filtered to what the caller's org may see.
|
|
- GET /v1/pricing/models
|
|
- Returns the whole model catalog — every model the gateway serves, Zen and third-party alike — filtered to what the caller's org may see. A model an admin has disabled is absent; one in beta appears only for an org granted it. A SuperAdmin sees every model, each annotated with its enablement state.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingModelList>
|
|
*/
|
|
open class func getPricingModelsWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingModelList> {
|
|
let localVariablePath = "/v1/pricing/models"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingModelList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
ListPaaSPlans returns the application-hosting plans — the deploy-and-host tiers, each with its monthly and annual price, app and memory allowances and feature list.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingPlanList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingPaas(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingPlanList {
|
|
return try await getPricingPaasWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
ListPaaSPlans returns the application-hosting plans — the deploy-and-host tiers, each with its monthly and annual price, app and memory allowances and feature list.
|
|
- GET /v1/pricing/paas
|
|
- ListPaaSPlans returns the application-hosting plans — the deploy-and-host tiers, each with its monthly and annual price, app and memory allowances and feature list.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingPlanList>
|
|
*/
|
|
open class func getPricingPaasWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingPlanList> {
|
|
let localVariablePath = "/v1/pricing/paas"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingPlanList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the pricing policy document: the revenue-sharing terms (the idle-resale share and the open-source share, each with its percentage and who is eligible) and the commitments Hanzo makes about how it bills — no hidden fees, no egress charges, no surprise bills.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: [String: JSONValue]
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingPolicy(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> [String: JSONValue] {
|
|
return try await getPricingPolicyWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the pricing policy document: the revenue-sharing terms (the idle-resale share and the open-source share, each with its percentage and who is eligible) and the commitments Hanzo makes about how it bills — no hidden fees, no egress charges, no surprise bills.
|
|
- GET /v1/pricing/policy
|
|
- Returns the pricing policy document: the revenue-sharing terms (the idle-resale share and the open-source share, each with its percentage and who is eligible) and the commitments Hanzo makes about how it bills — no hidden fees, no egress charges, no surprise bills.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<[String: JSONValue]>
|
|
*/
|
|
open class func getPricingPolicyWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<[String: JSONValue]> {
|
|
let localVariablePath = "/v1/pricing/policy"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<[String: JSONValue]>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the model providers the catalog knows, each with its info object, filtered to what the caller's org may see.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingProviderList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingProviders(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingProviderList {
|
|
return try await getPricingProvidersWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the model providers the catalog knows, each with its info object, filtered to what the caller's org may see.
|
|
- GET /v1/pricing/providers
|
|
- Returns the model providers the catalog knows, each with its info object, filtered to what the caller's org may see. A provider an admin has disabled is absent — and so are its models everywhere else on this surface, because a provider's state cascades to what it serves.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingProviderList>
|
|
*/
|
|
open class func getPricingProvidersWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingProviderList> {
|
|
let localVariablePath = "/v1/pricing/providers"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingProviderList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the managed-service rate cards — Search, Crawl, Vector, Console and Managed Services — each with its own tiers, and some with usage rates or a comparison table.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: [String: JSONValue]
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingServices(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> [String: JSONValue] {
|
|
return try await getPricingServicesWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the managed-service rate cards — Search, Crawl, Vector, Console and Managed Services — each with its own tiers, and some with usage rates or a comparison table.
|
|
- GET /v1/pricing/services
|
|
- Returns the managed-service rate cards — Search, Crawl, Vector, Console and Managed Services — each with its own tiers, and some with usage rates or a comparison table. It is the section as authored, un-gated. These are DISPLAY rate cards: what a product costs, not what a plan grants. No entitlement or limit fields ride here, so nothing can bill off them.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<[String: JSONValue]>
|
|
*/
|
|
open class func getPricingServicesWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<[String: JSONValue]> {
|
|
let localVariablePath = "/v1/pricing/services"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<[String: JSONValue]>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the API subscription plans — the account-level tiers a customer subscribes to, each with its monthly and annual price, included credit, rate limits and feature list.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingPlanList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingSubscriptions(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingPlanList {
|
|
return try await getPricingSubscriptionsWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the API subscription plans — the account-level tiers a customer subscribes to, each with its monthly and annual price, included credit, rate limits and feature list.
|
|
- GET /v1/pricing/subscriptions
|
|
- Returns the API subscription plans — the account-level tiers a customer subscribes to, each with its monthly and annual price, included credit, rate limits and feature list.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingPlanList>
|
|
*/
|
|
open class func getPricingSubscriptionsWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingPlanList> {
|
|
let localVariablePath = "/v1/pricing/subscriptions"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingPlanList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the catalog's headline statistics — model counts by family and the provider directory.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: [String: JSONValue]
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingSummary(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> [String: JSONValue] {
|
|
return try await getPricingSummaryWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the catalog's headline statistics — model counts by family and the provider directory.
|
|
- GET /v1/pricing/summary
|
|
- Returns the catalog's headline statistics — model counts by family and the provider directory. The provider sub-object is filtered to what the caller's org may see, so a disabled provider's name never leaks; the aggregate counts are the catalog's own, over everything it holds.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<[String: JSONValue]>
|
|
*/
|
|
open class func getPricingSummaryWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<[String: JSONValue]> {
|
|
let localVariablePath = "/v1/pricing/summary"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<[String: JSONValue]>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Returns the per-use tool prices — web search, code interpreter, file storage, image generation, speech-to-text and text-to-speech — each with the unit it is billed by and its price in that unit.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingToolList
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func getPricingTools(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingToolList {
|
|
return try await getPricingToolsWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Returns the per-use tool prices — web search, code interpreter, file storage, image generation, speech-to-text and text-to-speech — each with the unit it is billed by and its price in that unit.
|
|
- GET /v1/pricing/tools
|
|
- Returns the per-use tool prices — web search, code interpreter, file storage, image generation, speech-to-text and text-to-speech — each with the unit it is billed by and its price in that unit.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingToolList>
|
|
*/
|
|
open class func getPricingToolsWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingToolList> {
|
|
let localVariablePath = "/v1/pricing/tools"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingToolList>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Opts the caller's OWN org into a beta item.
|
|
|
|
- parameter enablementOptRef: (body)
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: UserEnablementItem
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func postPricingEnablementOptin(enablementOptRef: EnablementOptRef, apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> UserEnablementItem {
|
|
return try await postPricingEnablementOptinWithRequestBuilder(enablementOptRef: enablementOptRef, apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Opts the caller's OWN org into a beta item.
|
|
- POST /v1/pricing/enablement/optin
|
|
- Opts the caller's OWN org into a beta item. The org is the caller's validated one, so this can never target another org, and the registry refuses anything not in beta — so it can neither re-open an item an operator turned off nor touch one that is already generally available. Requires a signed-in caller with an org.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter enablementOptRef: (body)
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<UserEnablementItem>
|
|
*/
|
|
open class func postPricingEnablementOptinWithRequestBuilder(enablementOptRef: EnablementOptRef, apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<UserEnablementItem> {
|
|
let localVariablePath = "/v1/pricing/enablement/optin"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters = JSONEncodingHelper.encodingParameters(forEncodableObject: enablementOptRef, codableHelper: apiConfiguration.codableHelper)
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
"Content-Type": "application/json",
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<UserEnablementItem>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "POST", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Removes the caller's OWN org from a beta item's grant list, the reverse of OptIntoBeta and idempotent.
|
|
|
|
- parameter enablementOptRef: (body)
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: UserEnablementItem
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func postPricingEnablementOptout(enablementOptRef: EnablementOptRef, apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> UserEnablementItem {
|
|
return try await postPricingEnablementOptoutWithRequestBuilder(enablementOptRef: enablementOptRef, apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Removes the caller's OWN org from a beta item's grant list, the reverse of OptIntoBeta and idempotent.
|
|
- POST /v1/pricing/enablement/optout
|
|
- Removes the caller's OWN org from a beta item's grant list, the reverse of OptIntoBeta and idempotent. The org is the caller's validated one, so this can never revoke another org's grant. Requires a signed-in caller with an org.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter enablementOptRef: (body)
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<UserEnablementItem>
|
|
*/
|
|
open class func postPricingEnablementOptoutWithRequestBuilder(enablementOptRef: EnablementOptRef, apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<UserEnablementItem> {
|
|
let localVariablePath = "/v1/pricing/enablement/optout"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters = JSONEncodingHelper.encodingParameters(forEncodableObject: enablementOptRef, codableHelper: apiConfiguration.codableHelper)
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
"Content-Type": "application/json",
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<UserEnablementItem>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "POST", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
|
|
/**
|
|
Refreshes the third-party section of the catalog from its upstream listings and returns the time the refreshed catalog was stamped with.
|
|
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: PricingSyncOut
|
|
*/
|
|
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
|
|
open class func postPricingSync(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) async throws(ErrorResponse) -> PricingSyncOut {
|
|
return try await postPricingSyncWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
|
|
}
|
|
|
|
/**
|
|
Refreshes the third-party section of the catalog from its upstream listings and returns the time the refreshed catalog was stamped with.
|
|
- POST /v1/pricing/sync
|
|
- Refreshes the third-party section of the catalog from its upstream listings and returns the time the refreshed catalog was stamped with. The fetch runs in Go and the markup transform in the pricing bundle. SuperAdmin only; every other caller is refused.
|
|
- Bearer Token:
|
|
- type: http
|
|
- name: bearer
|
|
- parameter apiConfiguration: The configuration for the http request.
|
|
- returns: RequestBuilder<PricingSyncOut>
|
|
*/
|
|
open class func postPricingSyncWithRequestBuilder(apiConfiguration: HanzoAPIConfiguration = HanzoAPIConfiguration.shared) -> RequestBuilder<PricingSyncOut> {
|
|
let localVariablePath = "/v1/pricing/sync"
|
|
let localVariableURLString = apiConfiguration.basePath + localVariablePath
|
|
let localVariableParameters: [String: any Sendable]? = nil
|
|
|
|
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
|
|
|
|
let localVariableNillableHeaders: [String: (any Sendable)?] = [
|
|
:
|
|
]
|
|
|
|
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
|
|
|
|
let localVariableRequestBuilder: RequestBuilder<PricingSyncOut>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
|
|
|
|
return localVariableRequestBuilder.init(method: "POST", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
|
|
}
|
|
}
|