Search…
Integrating the Decentralized Identity SDK

Prerequisites

Get Started

  • Integrate the iOS SDK
  • Integrate the Android SDK (Coming soon!)
  • Integrate the Web SDK (Coming soon!)

Integrate the iOS SDK

Add this line to your Podfile near the line pod 'SudoUser'
1
pod 'SudoDecentralizedIdentity'
Copied!
Install pod dependencies by running the following command in your project directory:
1
pod install --repo-update
Copied!
This will update the local CocoaPods repository and install the latest version of the Decentralized Identity SDK.
In order to instantiate a Decentralized Identity client, make sure you have followed instructions for Getting Started, User SDK and Sudo SDK (see Prerequisites above)
To instantiate a client in your application, add the following
Swift
1
import SudoDecentralizedIdentity
2
3
let userClient = // ... see "Users" docs
4
let profilesClient = // ... see "Sudos" docs
5
6
let decentralizedIdClient = try! DefaultDecentralizedIdentityClient(
7
sudoUserClient: userClient,
8
sudoProfilesClient: profilesClient
9
)
Copied!
You only need one client instance for a given user per device. Instantiating multiple clients with the same configuration and using them at the same time may cause unexpected runtime errors to occur.
Last modified 1mo ago