This class serves the fastest and easiest implementation of MJCS to perform on-boarding journey. The class abstracts all the business logic required to capture data and provides the aggregated result in the end. All you need are a few lines of code:
Swift
// Init a controller with a config if requiredlet customerController = IDSCustomerJourneyController(config: nil)// Specify CredentialscustomerController.credentials = IDSEnterpriseCredentials(username: username, password: password, urlPrefix: baseURL)// Specify delegatecustomerController.delegate = self// Optional: specify journeyDefinitionID if you would like to perform certain journeycustomerController.journeyDefinitionID = journeyDefinitionID// PresentcustomerController.modalPresentationStyle = .fullScreenpresent(customerController, animated: true, completion: nil)
That’s it! Once presented, the controller will do all required steps. Depending on the outcome, you should listen to the delegate methods that are documented under IDSCustomerJourneyControllerDelegate interface.