With release of SAP Cloud Platform SDK for iOS 2.0 SP01 , there is a new capability of integrating Discovery service has been added in iOS SDK Assistant.
- Provides configuration information necessary for a user without enrolling a device in mobile device management (MDM).
- enhances the user onboarding process by letting you distribute initial configuration data to mobile apps.
Using SAP Cloud Platform Mobile Service for Development and Operations cockpit, you can publish application configurations to the SAP Discovery service
In your Mobile service for Development and operations trial account, there will be a default provider and domain.
When you create an app using Assistant, you would notice an additional feature “Discovery service” under “Optional Features” step
- In above screenshot, i opted to choose “Sample” application identifiier and hence optional features will get selected by default and grayed out as well.
- If you choose either “Create” or “Use Existing” , you will have option to enable or disable optional features.
Once you are done with “Finish”, in Mobile service cockpit, you will notice that Application configuration has been published to Discovery Service automatically.
In the Xcode Project (below screenshot, left side), you will notice that, there is no longer ConfigurationProvider.plist
Since i selected Discovery service option, configuration data is published to Cloud Platform. When i will launch app , i would ask to enter email (pre-filled) in the on-boarding screen and the data is pulled online from Cloud Plaform.
(If you do not use Discovery service, the Assistant will generate the ConfigurationProvider.plist file , this contains bootstrapping data for the application)
Now , running the application on simulator
I will have username+email domain already pre-filled on the screen.
Once you click on “Start” , configurationd data will get downloaded from Discovery Service. Since, i opted to select “Sample” application, this application has been configured with OAuth security provider in Mobile service cockpit. Once credentials are validated, you will need to agree on EULA screen and followed by collections screen and so on.
1. To retrieve the configured data, you can perform an HTTPS GET request to the following URL
Here: com.sap.TestApp > AppID in Mobile service cockpit
email@example.com > username+email-domain
2. Application running on the device must be integreated using the Mobile service for Development and Operations – Discovery Service in order for end-to-end process to function.
3. Above flow was for using default application configuration. You can also configure parameters either by selecting
- Custom Properties : to add key value pairs to the application configuration
- Custom JSON : to customize the generated JSON code.
4. If you want to use your own domains, you will need to register them first. The domain registration process requires verification of domain ownership by your organization.
Check below resources for more information:
Product Management, SAP Cloud Platform User Experience