One Logo Pool Ball
App Frameworks · IOS API REFERENCE

TrustInsights

Evaluate transactions for potential coercive activity while preserving people’s privacy.

17 types

34 callable entries

10 skipped

77% entry coverage

Generated from iOS SDK 27.1. Availability is shown on each declaration; permissions and entitlements still apply.

Types

Functions and constants

get · iOS 27.0+

operationCategory

TypeScript
get operationCategory(): InsightEvaluator_OperationCategory
Swift declaration
var operationCategory: InsightEvaluator.OperationCategory

Type of operation that the evaluation is being requested for. Information based on this may be presented in the transparency log showing the usage of this system by each app

set · iOS 27.0+

operationCategory

TypeScript
set operationCategory(value: InsightEvaluator_OperationCategory)
Swift declaration
var operationCategory: InsightEvaluator.OperationCategory

Type of operation that the evaluation is being requested for. Information based on this may be presented in the transparency log showing the usage of this system by each app

get · iOS 27.0+

requestID

TypeScript
get requestID(): (string) | null
Swift declaration
var requestID: String?

Optionally provide a unique identifier to strongly tie the assessment to the transaction Recommended to use a server generated identifier and then to verifify that it is included in the evaluation result to have strong evidence that the result was produced in response to the particular request

set · iOS 27.0+

requestID

TypeScript
set requestID(value: (string) | null)
Swift declaration
var requestID: String?

Optionally provide a unique identifier to strongly tie the assessment to the transaction Recommended to use a server generated identifier and then to verifify that it is included in the evaluation result to have strong evidence that the result was produced in response to the particular request

get · iOS 27.0+

modelVersion

TypeScript
get modelVersion(): InsightEvaluator_ModelVersion
Swift declaration
let modelVersion: InsightEvaluator.ModelVersion

Model version requested

get · iOS 27.0+

schemaVersion

TypeScript
get schemaVersion(): IsLikelyBeingCoachedInsight_SchemaVersion
Swift declaration
var schemaVersion: InsightType.SchemaVersion
set · iOS 27.0+

schemaVersion

TypeScript
set schemaVersion(value: IsLikelyBeingCoachedInsight_SchemaVersion)
Swift declaration
var schemaVersion: InsightType.SchemaVersion
get · iOS 27.0+

schemaVersionNumber

TypeScript
get schemaVersionNumber(): number
Swift declaration
var schemaVersionNumber: Int { get }

Schema version requested

get · iOS 27.0+

insightTypeIdentifier

TypeScript
get insightTypeIdentifier(): string
Swift declaration
var insightTypeIdentifier: String { get }

The identifer for the type of insight requested

get · iOS 27.0+

signedPayload

TypeScript
get signedPayload(): ArrayBuffer
Swift declaration
final let signedPayload: Data

Full signed response in [CBOR](https://www.rfc-editor.org/rfc/rfc8152) format. This is intended for server side validation and processing. Details of the format can be found at: URLToBeDefined

get · iOS 27.0+

additionalInfo

TypeScript
get additionalInfo(): Record<string, string>
Swift declaration
final let additionalInfo: [String : String]

Server may provide additional information will be described on the documentation website

get · iOS 27.0+

serverTimestamp

TypeScript
get serverTimestamp(): globalThis.Date
Swift declaration
final let serverTimestamp: Date

Timestamp at which the server validated the result

method · iOS 27.0+

reportConsumption

TypeScript
reportConsumptionInsightsUsed(status: InsightEvaluationConsumptionStatus, insightsUsed?: Array<SDKHandle>): void
Swift declaration
final func reportConsumption(_ status: InsightEvaluationConsumptionStatus, insightsUsed: [any TrustInsight] = [])

Before releasing an ``InsightEvaluation`` this should be called on it to report how the results have been used. This may be presented in the transparency reporting and it also helps with model improvement. - Parameters: - status: Label indicating how the provided insights were consumed in the application context - insightsUsed: Optionally, the specific insights that were used in making the decision Failure to call report consumption before deinit of the InsightEvaluation may lead to fault logs, and will be reported as such; this may lead to rate-limiting the application.

method · iOS 27.0+

reportConsumption

TypeScript
reportConsumptionInsightIDsUsed(status: InsightEvaluationConsumptionStatus, insightIDsUsed: Array<string>): void
Swift declaration
final func reportConsumption(_ status: InsightEvaluationConsumptionStatus, insightIDsUsed: [String])

Before releasing an ``InsightEvaluation`` this should be called on it to report how the results have been used. This may be presented in the transparency reporting and it also helps with model improvement. - Parameters: - status: Label indicating how the provided insights were consumed in the application context - insightIDsUsed: Optionally, the insights IDs that were used in making the decision Failure to call report consumption before deinit of the InsightEvaluation may lead to fault logs, and will be reported as such; this may lead to rate-limiting the application.

get · iOS 27.0+

generationTimestamp

TypeScript
get generationTimestamp(): globalThis.Date
Swift declaration
final let generationTimestamp: Date

Timestamp at which the on device part of the assessment was created

get · iOS 27.0+

eventID

TypeScript
get eventID(): string
Swift declaration
final var eventID: String { get }

Identifier for this evaluation result that can be recorded with other transaction records so that in the event that fraud or abuse is later discovered associated with the transaction it can be reported to Apple as Offline feedback via Apple Business Register

get · iOS 27.0+

requestID

TypeScript
get requestID(): (string) | null
Swift declaration
final var requestID: String? { get }

App defined identifier provided as the ``InsightEvaluator/InsightContext/requestID`` in the ``InsightEvaluator/InsightContext`` for the evaluation request If provided in the context this will be non-nil and should match that included in the context for the request. Any mismatch would indicate that the payload should not be trusted and may have been injected by an attacker in some way. It can also be used by an app to link request or a wider app specific ID for the active operation.

Skipped declarations

10 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.

InsightEvaluation.insight

Swift parameter packs cannot cross the bridge.

InsightEvaluator.requestEvaluation(context:)

Swift parameter packs cannot cross the bridge.

InsightEvaluator.requestAuthorization(for:)

Swift parameter packs cannot cross the bridge.

InsightEvaluator.authorizationStatus(for:)

Swift parameter packs cannot cross the bridge.

InsightEvaluator.InsightContext.requestedInsight

Swift parameter packs cannot cross the bridge.

InsightEvaluator.InsightContext.init(operationCategory:requestedEvaluations:)

Swift parameter packs cannot cross the bridge.

InsightEvaluator.InsightRequest.init(insightType:schema:model:)

Passing a Swift type itself is not supported.

TrustInsight.request(schema:modelVersion:)

This protocol needs associated types that cannot yet cross the bridge.

protocol implementation InsightEvaluator.InsightRequestProtocol

This protocol needs associated types that cannot yet cross the bridge.

protocol implementation TrustInsight

This protocol needs associated types that cannot yet cross the bridge.