Warning
passage-ios was deprecated on September 18, 2024 and is no longer receiving updates or support. Please use passage-swift instead.
NOTE: passage-ios is currently in beta.
The Passage iOS framework provides an easy to use SDK interface to implement a Passkey focused authentication expierence for native apps built in Swift.
Want to see the end result before the setup work?
To see a code level implementation, checkout and run our Swift Example App
To see a quick demo reach out to our team on Discord and ask for a link to our TestFlight app.
Note: This package is currently in Beta - breaking changes may occur. To report a bug please create a Github Issue or get in touch with our team on Discord.
Compatile with Xcode version 14+.
The Passage-iOS SDK is supported for iOS version 14+. However, Passkeys are only supported on iOS v16+.
iOS Version | Passkey Login | Passcode & Magic Link Login |
---|---|---|
v16.x | ✅ | ✅ |
v15.x | ❌ | ✅ |
v14.x | ❌ | ✅ |
Add the passage-ios package to your app via SwiftPackage Manager or Cocoapods
- Open your project in Xcode
- Click "File" -> "Add Packages"
- Paste the following URL: https://github.com/passageidentity/passage-ios
- Click "Next" -> "Next" -> "Finish"
..or..
- Paste this url into the Swift Package Manager search bar in Xcode
https://github.com/passageidentity/passage-ios
Add the following line to your Podfile:
pod 'Passage', '~> 1.1'
Then, run pod install.
For further reference on Cocoapods, check their official documentation.
- Run
pod install
View the Documentation Catalog or dowload the Documentation Catalog to view in the Xcode Document Viewer. Follow the Getting Started
guide which consists the following steps:
- Setup your Passage application
- Associate your domain with your application
- Configure your application in Xcode
- Enable your backend to validate JWTs
- Send auth token on API requests
Import the Passage package into any source file that will use the iOS SDK.
import Passage
View the Documentation Catalog or dowload the Documentation Catalog to view in the Xcode Document Viewer, and navigate to the Getting Started
guide for a detailed step by step guide.
The package provides both Type Methods and Instance Methods. These methods provide everything you will need to register, login, and manage users on your application. The SDK methods below provide a high level overview of available actions. For the full a full list of available methos and their signatures view the Documentation Catalog or dowload the Documentation Catalog to view in the Xcode Document Viewer and navigate to Classes
.
PassageAuth is the primary class you will work with. It provides the following:
- Registration
- Login
- Sign Out (if you use a Passage Token Store)
- User Management
- App Details
- And More
See the User Registration
guide in the Documentation Catalog or dowload the Documentation Catalog to view in the Xcode Document Viewer.
See the Login
guide in the Documentation Catalog or dowload the Documentation Catalog to view in the Xcode Document Viewer.
This package includes a documentation catalog that can be viewed in the Xcode developer documentation browser.
To generate the documentation catalog, in Xcode click "Product" -> "Build Documentation", it should open the Documentation Viewer, if not select "Window" -> "Developer Documentation"
Download the DocC Archive