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 required
let customerController = IDSCustomerJourneyController(config: nil)
// Specify Credentials
customerController.credentials = IDSEnterpriseCredentials(username: username, password: password, urlPrefix: baseURL)
// Specify delegate
customerController.delegate = self
// Optional: specify journeyDefinitionID if you would like to perform certain journey
customerController.journeyDefinitionID = journeyDefinitionID
// Present
customerController.modalPresentationStyle = .fullScreen
present(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.