Files
swift-sdk/Sources/Hanzo/Models/PeriodEarningView.swift
zeekay 1df3ddf6bd Regenerate against the document the deployment answers for
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.
2026-09-05 18:55:38 -07:00

41 lines
1.6 KiB
Swift
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
//
// PeriodEarningView.swift
//
// Generated by openapi-generator
// https://openapi-generator.tech
//
import Foundation
public struct PeriodEarningView: Sendable, Codable, ParameterConvertible, Hashable {
/** CommissionCents is what the caller earned that period, in cents: the sum over each referred org and upline level of margin × that level's rate. Always ≤ marginCents, by construction. */
public var commissionCents: Int64?
/** MarginCents is the margin Hanzo earned in that period on the spend of every org the caller referred, in cents — the base commission is a rate OF. It is the aggregate base, never any one customer's bill. */
public var marginCents: Int64?
/** Period is the accrual bucket: the UTC year-month, \"YYYY-MM\". Commission is latched at most once per referred org per period, so one row is one month. */
public var period: String?
public init(commissionCents: Int64? = nil, marginCents: Int64? = nil, period: String? = nil) {
self.commissionCents = commissionCents
self.marginCents = marginCents
self.period = period
}
public enum CodingKeys: String, CodingKey, CaseIterable {
case commissionCents
case marginCents
case period
}
// Encodable protocol methods
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(commissionCents, forKey: .commissionCents)
try container.encodeIfPresent(marginCents, forKey: .marginCents)
try container.encodeIfPresent(period, forKey: .period)
}
}