Documentation Index
Fetch the complete documentation index at: https://docs.prism.byescaleira.com/llms.txt
Use this file to discover all available pages before exploring further.
Platform Services
PrismCapabilities wraps Apple’s platform frameworks into type-safe,Sendable APIs. Manage in-app purchases, sync data to iCloud, build widgets, schedule notifications, and integrate with Siri Shortcuts.
StoreKit — In-App Purchases
PrismStoreKit wraps StoreKit 2 for managing products, purchases, and subscriptions:
Fetch Products
Purchase Flow
Purchase a Product
Product Types
| Type | Description |
|---|---|
.consumable | Can be purchased multiple times (credits, coins) |
.nonConsumable | One-time purchase (remove ads, unlock feature) |
.autoRenewable | Subscription that renews automatically |
.nonRenewable | Subscription that does not auto-renew |
Transaction Monitoring
Listen for Transactions
CloudKit
PrismCloudKit provides CRUD operations on CloudKit records:
CloudKit CRUD
Cloud Value Types
| Type | Swift Mapping |
|---|---|
.string(String) | Text fields |
.int(Int) | Integer fields |
.double(Double) | Decimal fields |
.data(Data) | Binary data |
.date(Date) | Timestamps |
.reference(String) | Record references |
.stringArray([String]) | List of strings |
Query Records
Query CloudKit
Databases
| Database | Description |
|---|---|
.publicDB | Shared across all users |
.privateDB | Private to the signed-in iCloud user |
.sharedDB | Shared via CloudKit Sharing |
WidgetKit
PrismWidgetKit manages widget timeline reloads and configuration:
Reload Widgets
Widget Families
| Family | Description |
|---|---|
.systemSmall | Small home screen widget |
.systemMedium | Medium home screen widget |
.systemLarge | Large home screen widget |
.systemExtraLarge | Extra large (iPad) |
.accessoryCircular | Lock screen circular |
.accessoryRectangular | Lock screen rectangular |
.accessoryInline | Lock screen inline text |
Timeline Entries
Widget Timeline Entry
Reload Policies
| Policy | Behavior |
|---|---|
.atEnd | Reload after the last entry |
.afterMinutes(Int) | Reload after N minutes |
.never | Manual reload only |
Push Notifications
PrismPushNotifications manages notification permissions, scheduling, and content:
Request Notification Permission
Schedule a Local Notification
Schedule Notification
Permission Status
| Status | Description |
|---|---|
.notDetermined | User hasn’t been asked yet |
.denied | User denied notifications |
.authorized | Full notification access |
.provisional | Quiet notifications (no prompt) |
.ephemeral | App Clip temporary access |
Sounds
| Sound | Usage |
|---|---|
.default_ | System default notification sound |
.named(String) | Custom sound file from bundle |
.critical | Critical alert (bypasses Do Not Disturb) |
App Intents
PrismAppIntentClient integrates with App Intents for Siri Shortcuts and the Shortcuts app:
App Intent
App Clips
PrismAppClip handles App Clip lifecycle and invocation:
App Clip