New
23enum
InsightError
NewiOSpublic enum InsightError : String, Error
Error values that can be returned for specific requested insights within the overall evaluation
Declaration
@nonexhaustive public enum InsightError : String, Error {
/// Rate limit reached for the particular assessment type.
case rateLimitError
/// The requested assessment version is not available. This will be used when the specific version is not
/// availble but other versions are available.
case insightVersionUnavailable
/// The requested version is not available on this device/OS version.
case insightVersionIncompatible
/// There was a failure in generating the insight. A retry may succeed.
case insightEvaluationFailed
/// The requested insight is not available. Potentially withdrawn or no longer supported on the active OS.
case insightUnavailable
/// Creates a new instance with the specified raw value.
///
/// If there is no value of the type that corresponds with the specified raw
/// value, this initializer returns `nil`. For example:
///
/// enum PaperSize: String {
/// case A4, A5, Letter, Legal
/// }
///
/// print(PaperSize(rawValue: "Legal"))
/// // Prints "Optional(PaperSize.Legal)"
///
/// print(PaperSize(rawValue: "Tabloid"))
/// // Prints "nil"
///
/// - Parameter rawValue: The raw value to use for the new instance.
public init?(rawValue: String)
/// The raw type that can be used to represent all values of the conforming
/// type.
///
/// Every distinct value of the conforming type has a corresponding unique
/// value of the `RawValue` type, but there may be values of the `RawValue`
/// type that don't have a corresponding value of the conforming type.
@available(iOS 27.0, *)
@available(macCatalyst, unavailable)
public typealias RawValue = String
/// The corresponding value of the raw type.
///
/// A new instance initialized with `rawValue` will be equivalent to this
/// instance. For example:
///
/// enum PaperSize: String {
/// case A4, A5, Letter, Legal
/// }
///
/// let selectedSize = PaperSize.Letter
/// print(selectedSize.rawValue)
/// // Prints "Letter"
///
/// print(selectedSize == PaperSize(rawValue: selectedSize.rawValue)!)
/// // Prints "true"
public var rawValue: String { get }
}
extension
InsightError
NewiOSextension InsightError : Equatable
Declaration
extension InsightError : Equatable {
}
extension
InsightError
NewiOSextension InsightError : Hashable
Declaration
extension InsightError : Hashable {
}
extension
InsightError
NewiOSextension InsightError : RawRepresentable
Declaration
extension InsightError : RawRepresentable {
}
enum
InsightEvaluationConsumptionStatus
NewiOSpublic enum InsightEvaluationConsumptionStatus : String, Codable, Sendable
Values describing the usage of InsightEvaluation
Declaration
@nonexhaustive public enum InsightEvaluationConsumptionStatus : String, Codable, Sendable {
/// Insights not used e.g. operation was cancelled so no decision required
case notUsedNotNeeded
/// Insights were evaluated but did not have any impact on the decision or user flow
case usedUnchangedFriction
/// Insights were evaluated and were a factor in making the operation easier for the user
case usedReducedFriction
/// Insights were evaluated and were a factor in adding checks or blocking the action
case usedIncreasedFriction
/// The insights could not be used because of a technical failure, they arrived too late
/// to be of use or other issue.
case notUsedError
/// Insights used for evaluation of their usefulness or for model training with no impact on
/// a decision process
case usedEvaluationOnly
/// Creates a new instance with the specified raw value.
///
/// If there is no value of the type that corresponds with the specified raw
/// value, this initializer returns `nil`. For example:
///
/// enum PaperSize: String {
/// case A4, A5, Letter, Legal
/// }
///
/// print(PaperSize(rawValue: "Legal"))
/// // Prints "Optional(PaperSize.Legal)"
///
/// print(PaperSize(rawValue: "Tabloid"))
/// // Prints "nil"
///
/// - Parameter rawValue: The raw value to use for the new instance.
public init?(rawValue: String)
/// The raw type that can be used to represent all values of the conforming
/// type.
///
/// Every distinct value of the conforming type has a corresponding unique
/// value of the `RawValue` type, but there may be values of the `RawValue`
/// type that don't have a corresponding value of the conforming type.
@available(iOS 27.0, *)
@available(macCatalyst, unavailable)
public typealias RawValue = String
/// The corresponding value of the raw type.
///
/// A new instance initialized with `rawValue` will be equivalent to this
/// instance. For example:
///
/// enum PaperSize: String {
/// case A4, A5, Letter, Legal
/// }
///
/// let selectedSize = PaperSize.Letter
/// print(selectedSize.rawValue)
/// // Prints "Letter"
///
/// print(selectedSize == PaperSize(rawValue: selectedSize.rawValue)!)
/// // Prints "true"
public var rawValue: String { get }
}
extension
InsightEvaluationConsumptionStatus
NewiOSextension InsightEvaluationConsumptionStatus : Equatable
Declaration
extension InsightEvaluationConsumptionStatus : Equatable {
}
extension
InsightEvaluationConsumptionStatus
NewiOSextension InsightEvaluationConsumptionStatus : Hashable
Declaration
extension InsightEvaluationConsumptionStatus : Hashable {
}
extension
InsightEvaluationConsumptionStatus
NewiOSextension InsightEvaluationConsumptionStatus : RawRepresentable
Declaration
extension InsightEvaluationConsumptionStatus : RawRepresentable {
}
extension
InsightEvaluator.AuthorizationStatus
NewiOSextension InsightEvaluator.AuthorizationStatus : Equatable
Declaration
extension InsightEvaluator.AuthorizationStatus : Equatable {
}
extension
InsightEvaluator.AuthorizationStatus
NewiOSextension InsightEvaluator.AuthorizationStatus : Hashable
Declaration
extension InsightEvaluator.AuthorizationStatus : Hashable {
}
extension
InsightEvaluator.OperationCategory
NewiOSextension InsightEvaluator.OperationCategory : Equatable
Declaration
extension InsightEvaluator.OperationCategory : Equatable {
}
extension
InsightEvaluator.OperationCategory
NewiOSextension InsightEvaluator.OperationCategory : Hashable
Declaration
extension InsightEvaluator.OperationCategory : Hashable {
}
struct
IsLikelyBeingCoachedInsight
NewiOSpublic struct IsLikelyBeingCoachedInsight : TrustInsight
Insight to request indications that the user may be actively being coached to perform actions it could be useful to consider this in operations where it is possible that the user may be being defrauded (e.g. transfers to new counterparties) and whether step ups or blocks may be appropriate. Be aware that coaching may not necessarily be malicious.
Declaration
public struct IsLikelyBeingCoachedInsight : TrustInsight {
/// Format version of the result that is required
@nonexhaustive public enum SchemaVersion : Sendable {
/// Values available in schema version1 ``unknown``, ``medium``, ``high``
case version1
/// Returns a Boolean value indicating whether two values are equal.
///
/// Equality is the inverse of inequality. For any values `a` and `b`,
/// `a == b` implies that `a != b` is `false`.
///
/// - Parameters:
/// - lhs: A value to compare.
/// - rhs: Another value to compare.
public static func == (a: IsLikelyBeingCoachedInsight.SchemaVersion, b: IsLikelyBeingCoachedInsight.SchemaVersion) -> Bool
/// Hashes the essential components of this value by feeding them into the
/// given hasher.
///
/// Implement this method to conform to the `Hashable` protocol. The
/// components used for hashing must be the same as the components compared
/// in your type's `==` operator implementation. Call `hasher.combine(_:)`
/// with each of these components.
///
/// - Important: In your implementation of `hash(into:)`,
/// don't call `finalize()` on the `hasher` instance provided,
/// or replace it with a different instance.
/// Doing so may become a compile-time error in the future.
///
/// - Parameter hasher: The hasher to use when combining the components
/// of this instance.
public func hash(into hasher: inout Hasher)
/// The hash value.
///
/// Hash values are not guaranteed to be equal across different executions of
/// your program. Do not save hash values to use during a future execution.
///
/// - Important: `hashValue` is deprecated as a `Hashable` requirement. To
/// conform to `Hashable`, implement the `hash(into:)` requirement instead.
/// The compiler provides an implementation for `hashValue` for you.
public var hashValue: Int { get }
}
/// Levels of trust that can be offered for the isLikelyBeingCoached insight.
/// Any additional result values will only be returned when requesting a schema
/// version introduced alongside the new value
@nonexhaustive public enum Value : String, Sendable {
/// Lack of evidence as to whether coaching is occuring.
case unknown
/// There is a medium chance that the user is being coached in some form.
case medium
/// There is a high risk that the user is being coached in some form.
case high
/// Creates a new instance with the specified raw value.
///
/// If there is no value of the type that corresponds with the specified raw
/// value, this initializer returns `nil`. For example:
///
/// enum PaperSize: String {
/// case A4, A5, Letter, Legal
/// }
///
/// print(PaperSize(rawValue: "Legal"))
/// // Prints "Optional(PaperSize.Legal)"
///
/// print(PaperSize(rawValue: "Tabloid"))
/// // Prints "nil"
///
/// - Parameter rawValue: The raw value to use for the new instance.
public init?(rawValue: String)
/// The raw type that can be used to represent all values of the conforming
/// type.
Truncated.
extension
IsLikelyBeingCoachedInsight.SchemaVersion
NewiOSextension IsLikelyBeingCoachedInsight.SchemaVersion : Equatable
Declaration
extension IsLikelyBeingCoachedInsight.SchemaVersion : Equatable {
}
extension
IsLikelyBeingCoachedInsight.SchemaVersion
NewiOSextension IsLikelyBeingCoachedInsight.SchemaVersion : Hashable
Declaration
extension IsLikelyBeingCoachedInsight.SchemaVersion : Hashable {
}
extension
IsLikelyBeingCoachedInsight.Value
NewiOSextension IsLikelyBeingCoachedInsight.Value : Equatable
Declaration
extension IsLikelyBeingCoachedInsight.Value : Equatable {
}
extension
IsLikelyBeingCoachedInsight.Value
NewiOSextension IsLikelyBeingCoachedInsight.Value : Hashable
Declaration
extension IsLikelyBeingCoachedInsight.Value : Hashable {
}
extension
IsLikelyBeingCoachedInsight.Value
NewiOSextension IsLikelyBeingCoachedInsight.Value : RawRepresentable
Declaration
extension IsLikelyBeingCoachedInsight.Value : RawRepresentable {
}
protocol
TrustInsight
NewiOSpublic protocol TrustInsight : Sendable
Declaration
public protocol TrustInsight : Sendable {
/// Typically an enum of the available schema versions for the particular Insight
associatedtype SchemaVersion : Sendable
/// The result type for this particular Insight which will typically be an enum
associatedtype Value
/// Identifier string for the type of Insight this represents
static var typeIdentifier: String { get }
/// Identifier for this particular result
var insightID: String { get }
/// Model version used for this particular insight
var modelVersion: String? { get }
/// The newest model that could be requested
var newestModelVersion: String? { get }
/// The result of an evaluation
var outcome: Result<Self.Value, InsightError> { get }
}
extension
TrustInsight
NewiOSextension TrustInsight
Declaration
extension TrustInsight {
/// Returns true if the Insight was created with the newest available modelVersion
public var isUsingCurrentModel: Bool { get }
/// Convenience method to create insight request for the given insight type
/// - Parameters:
/// - schema: Schema version required
/// - modelVersion: modelVersion required
/// - Returns: InsightRequest for incorporation in an InsightContext to make an evaluation request
public static func request(schema: Self.SchemaVersion, modelVersion: InsightEvaluator.ModelVersion = .current) -> InsightEvaluator.InsightRequest<Self>
}
typealias
InsightError.RawValue
NewiOSpublic typealias RawValue = String
The raw type that can be used to represent all values of the conforming type.
Every distinct value of the conforming type has a corresponding unique value of the RawValue type, but there may be values of the RawValue type that don't have a corresponding value of the conforming type.
typealias
InsightEvaluationConsumptionStatus.RawValue
NewiOSpublic typealias RawValue = String
The raw type that can be used to represent all values of the conforming type.
Every distinct value of the conforming type has a corresponding unique value of the RawValue type, but there may be values of the RawValue type that don't have a corresponding value of the conforming type.
typealias
IsLikelyBeingCoachedInsight.Value.RawValue
NewiOSpublic typealias RawValue = String
The raw type that can be used to represent all values of the conforming type.
Every distinct value of the conforming type has a corresponding unique value of the RawValue type, but there may be values of the RawValue type that don't have a corresponding value of the conforming type.
No APIs match your filter.