Definition

Why does SnapAction use SwiftData?

SwiftData is Apple's Swift-native persistence framework. SnapAction uses it to store analyzed screenshot resources locally on iPhone.

Reviewed by SnapAction team · Last updated May 9, 2026

Short answer

SwiftData is Apple’s Swift-native persistence framework for storing app models locally in iOS apps. SnapAction uses SwiftData as the on-device resource library after cloud-assisted screenshot analysis, keeping analyzed cards, tags, scan records, screenshot references, read state, and favorite state available on iPhone.

How SwiftData works

SwiftData was introduced with iOS 17 as a modern persistence layer for Swift apps. Developers define models with the @Model macro, and SwiftData handles local storage, querying, relationships, and UI updates.

For a productivity app, SwiftData is useful because saved items can load instantly without waiting for a network request. The app can filter, sort, and update resource cards directly from local storage.

SwiftData can be used with CloudKit in Apple apps, but this page only describes what is verified in SnapAction’s current implementation: a local resource library backed by SwiftData.

Example: a SnapAction resource model

A resource can include:

@Model
class Resource {
    var title: String
    var url: String?
    var type: ResourceType
    var resourceDescription: String?
    var tags: [String]
    var metadata: [String: String]
    var screenshotAssetIds: [String]
    var isRead: Bool
    var isFavorite: Bool
    var createdAt: Date
}

Result: The app can show a card, connect it to original screenshots, and power actions based on type-specific metadata.

How SnapAction uses SwiftData

SnapAction uses SwiftData as the local library that stores what the AI analysis returns after a screenshot scan.

  1. Fast browsing: Resource cards are available locally after they are saved.
  2. Typed actions: The stored type and metadata decide whether a card can open a URL, call a contact, show directions, add an event, or copy a booking reference.
  3. Screenshot linkage: Resource records can link back to one or more PhotoKit asset IDs, including grouped screenshots.
  4. Daily recall: Rewind can use local resource records to build a daily digest of what you saved.

SwiftData is the local memory layer. The screenshot analysis itself is handled by the Convex-backed AI pipeline.

Related pages

Stop letting screenshots disappear

Join the TestFlight beta and turn a few screenshots into saved cards with links, events, places, repos, receipts, flights, contacts, and next actions.

Try 30 free scans

Requires iOS 17.0 or later.