Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Models

Reference for OnsideKit's public value types: transactions, payments, products, prices and periods.

OnsideKit's public models are value types (Sendable, safe to pass across actors).

OnsidePaymentTransaction

A snapshot of a transaction in the payment queue.

Property
Description

id: UUID

Stable local identifier for this transaction.

transactionIdentifier: String?

Server-side transaction id (may be absent while .purchasing).

originalTransactionIdentifier: String?

Id of the original transaction (for restored/renewed cases).

payment: OnsidePayment

The payment that produced this transaction.

transactionState: OnsidePaymentTransactionState

Current state.

storefront: OnsideStorefront

The storefront the transaction belongs to.

error: OnsidePaymentTransactionError?

Set only for .failed transactions.

func isSame(as another: OnsidePaymentTransaction) -> Bool — compares by id. Use it to correlate updates for the same transaction across state changes.

OnsidePaymentTransactionState

enum OnsidePaymentTransactionState {
    case purchasing   // in flight
    case purchased    // bought successfully
    case restored     // surfaced by restoreCompletedTransactions
    case failed       // failed; see transaction.error
}

OnsidePayment

appAccountToken correlates the purchase with your account system. The only initializer is init(product:); set the token by mutating the value.

OnsideProduct

Property
Description

productIdentifier: String

The Onside identifier (slug) you requested.

localizedTitle: String

Display title.

localizedDescription: String

Display description.

iconUrl: URL?

Icon URL, if available.

price: OnsidePrice

Price.

subscriptionPeriod: OnsidePeriod?

Recurring period (subscriptions only).

subscriptionGroupIdentifier: String?

Localized display name of the subscription group — not a stable identifier (subscriptions only).

See Subscriptions for the subscription fields.

Pricing types

OnsideStorefront

OnsideProductsResponse

For external profiles, subscriptions and non-consumables appear in unsupportedProductIdentifiers instead of products. See Fetching Products.

OnsideLoginMethod

Selects the regular login route through OnsideDelegate.onsideLoginMethod(). External login, when configured, takes priority.

OnsideSignedInAppsHistory

OnsideAttributionMetadata

Last updated

Was this helpful?