Files
zeekay 0c2f028a8c Generate the Swift client, which this copy did not carry
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.
2026-08-23 10:04:41 -07:00

76 lines
3.3 KiB
Swift

//
// RiskCause.swift
//
// Generated by openapi-generator
// https://openapi-generator.tech
//
import Foundation
public struct RiskCause: Sendable, Codable, ParameterConvertible, Hashable {
/** Baseline is the number it was measured against — always this organisation's own history, never a fixed limit and never another organisation's. */
public var baseline: Double?
/** Citation is where those words come from, so the claim is checkable rather than asserted — which is what a chargeback network or a regulator asks for. */
public var citation: String?
/** Feature is the dimension that contributed. */
public var feature: String?
/** Indicator is the supervisor's own words for the thing being looked for. */
public var indicator: String?
/** Observed is the raw number the coordinate was computed from. */
public var observed: Double?
/** Severity is how much weight this dimension carries. */
public var severity: String?
/** Share is this feature's part of the score, in [0,1]. Zero across every cause means no single feature accounts for the alert and the combination does; the causes are then ordered by how far each sits from unremarkable. */
public var share: Double?
/** Typology is the laundering or abuse pattern this dimension detects. */
public var typology: String?
/** Unit is how to read Observed, which is what turns a coordinate into a sentence. */
public var unit: String?
/** Without is the score the same event would have received with this coordinate at its neutral value — the counterfactual itself. */
public var without: Double?
public init(baseline: Double? = nil, citation: String? = nil, feature: String? = nil, indicator: String? = nil, observed: Double? = nil, severity: String? = nil, share: Double? = nil, typology: String? = nil, unit: String? = nil, without: Double? = nil) {
self.baseline = baseline
self.citation = citation
self.feature = feature
self.indicator = indicator
self.observed = observed
self.severity = severity
self.share = share
self.typology = typology
self.unit = unit
self.without = without
}
public enum CodingKeys: String, CodingKey, CaseIterable {
case baseline
case citation
case feature
case indicator
case observed
case severity
case share
case typology
case unit
case without
}
// Encodable protocol methods
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(baseline, forKey: .baseline)
try container.encodeIfPresent(citation, forKey: .citation)
try container.encodeIfPresent(feature, forKey: .feature)
try container.encodeIfPresent(indicator, forKey: .indicator)
try container.encodeIfPresent(observed, forKey: .observed)
try container.encodeIfPresent(severity, forKey: .severity)
try container.encodeIfPresent(share, forKey: .share)
try container.encodeIfPresent(typology, forKey: .typology)
try container.encodeIfPresent(unit, forKey: .unit)
try container.encodeIfPresent(without, forKey: .without)
}
}