Installation
RakomiSDK ships exclusively via Swift Package Manager — there is no CocoaPods podspec and no
Carthage support.
Add the package in Xcode
Section titled “Add the package in Xcode”-
File → Add Package Dependencies…
-
Enter the repository URL:
https://github.com/rakomidev/rakomi-swift -
Choose a version rule (Xcode defaults to “Up to Next Major Version”).
-
Add the
RakomiSDKlibrary product to your app target.
Add the package in Package.swift
Section titled “Add the package in Package.swift”If your app is itself a Swift package, or you prefer to edit the manifest directly:
import PackageDescription
let package = Package( name: "YourApp", dependencies: [ .package(url: "https://github.com/rakomidev/rakomi-swift", from: "0.1.0"), ], targets: [ .target( name: "YourApp", dependencies: [ .product(name: "RakomiSDK", package: "rakomi-swift"), ] ), ])Tagged releases use the namespace sdk-swift/vX.Y.Z.
Requirements
Section titled “Requirements”- Swift tools version 5.10 or later.
- Deployment target: iOS 16 / macOS 13 / watchOS 9 / tvOS 16 / visionOS 1 at minimum — see Platform support for what each platform can actually do (watchOS links the package but has no interactive sign-in). The pre-built SwiftUI views need a higher floor (iOS 17 / macOS 14 / watchOS 10 / tvOS 17 / visionOS 1).
- Zero transitive runtime dependencies — nothing else is pulled into your app’s dependency graph. (Test-only dependencies used by the SDK’s own test suite are not part of your app’s build.)
Provisioning & code signing
Section titled “Provisioning & code signing”iOS / macOS / visionOS — register your redirect URL scheme
Section titled “iOS / macOS / visionOS — register your redirect URL scheme”The OAuth callback on iOS, macOS, and visionOS is delivered through a custom URL scheme, so your
app must declare one. In Info.plist:
<key>CFBundleURLTypes</key><array> <dict> <key>CFBundleURLSchemes</key> <array><string>myapp</string></array> </dict></array>Use a scheme unique to your app’s bundle identifier — a colliding scheme on a device with multiple
apps installed is a scheme-hijack risk. Pass the matching redirectURI when constructing
RakomiAuthConfiguration. Universal Links / Associated Domains support
is planned and not available yet — until then, the custom-scheme approach above is what to use.
Sign in with Apple
Section titled “Sign in with Apple”Enable the com.apple.developer.applesignin capability for your target in your Apple Developer
account, then add the corresponding entitlement in Xcode’s Signing & Capabilities tab. The
RakomiAppleSignInButton SwiftUI view (see Authentication) wraps
Apple’s native SignInWithAppleButton.
macOS sandboxed apps
Section titled “macOS sandboxed apps”Declare com.apple.security.network.client in your app’s .entitlements file so the sandboxed app
can reach the Rakomi API.
tvOS does not use a redirect URL scheme at all — it authenticates via the OAuth device authorization grant (RFC 8628) instead, which requires no URL scheme registration. See Authentication for the flow.
Next steps
Section titled “Next steps”- Configuration — construct a
RakomiAuthConfiguration. - Authentication — wire up sign-in.