Technical Articles
Migration of Android application from Neo environment to Cloud Foundry environment with SAML Configuration
If the version of your SAP BTP SDK for Android is 2.3 or below, refer to this blog post, else if the version of your SAP BTP SDK for Android is between 3.0 and 3.1 releases, this blog post will help you migrate Android Application configured with SAML from Neo environment to Cloud Foundry environment.
Following is the list of tools I used:
- Android Studio 4.0.1
- Android SDK 28
- SAP BTP SDK Android 3.1.3
- Java Development Kit 14.0.2
For getting more insights, read:
- The official help documentation
- Migrating from SAP BTP Neo environment to SAP BTP Cloud Foundry environment
Follow the steps given below to migrate your android application from Neo environment to Cloud Foundry environment with SAML configuration:
Create an application in Neo environment with SAML configuration:
- Open mobile services cockpit (neo environment) and under Mobile Applications select Native/Hybrid.
- Click on the new button, a dialog box will appear. Enter the following details and click on Save.
Config Templates Native Name com.sap.migrationSAML ID MigrationSAML - Once the app is created, under the Assigned Features section, click on Connectivity.
- Click on create button.
Enter the following details and click next:
Type Mobile Destination Destination Name es5DemoSystem Enter the URL ‘https://sapes5.sapdevcenter.com/sap/opu/odata/sap/EPM_REF_APPS_SHOP_SRV’ and click next until you reach the SSO Mechanism page. Choose ‘Basic Authentication’ and click next.
Enter your username and Password and click next and then click finish.
- Open your Android Studio, click on Start a new SAP Cloud Platform Android Project.
- Enter the following details and click on Next.
Account Name Neo Mobile Services Admin API URL Refer the note below. Admin UI URL Refer the note below. Authentication Type SAML Username Your BTP account username Password Your BTP account password NOTE: For the Admin API URL and Admin UI URL, click on the Important Links tab in the Mobile Services Cockpit, and copy the Admin API and Admin UI.
- Select com.sap.migrationSAML from the drop down and click next.
- Select es5DemoSystem and click next.
- Give the Project Name as MigrationSAML, Project Namespace as com.sap.migrationsaml and click next and then click finish.
- Wait for the application to load completely. Open app -> java -> com.sap.migrationsaml -> app -> WelcomeActivity.java. On line 104, you can see your Neo tenant’s URL. Now, run the app on your device.
![]() |
![]() |
You can see that the application is running on Neo environment.
Now export the application from your Neo mobile services cockpit. A zip file will be downloaded.
Once import is complete, you will get a toast message “Application imported successfully”.
Uninstall the application you installed earlier and run the application again.
![]() |
![]() |
You will see that your app is pointing to Cloud Foundry environment now which means you successfully migrated your android application from Neo environment to Cloud Foundry environment with SAML configuration.
If the version of your SAP BTP SDK for Android is 3.2.0 or above, follow the steps given below:
- In your android project, go inside app -> res -> raw folder. Here, you will see sap_mobile_services.json file.
- Replace the service URL on line 9 with the host value you copied from defaultConfig.json file.
Now, uninstall the application you installed earlier and run the application.
You will see that your app is pointing to Cloud Foundry environment now which means you successfully migrated your android application from Neo environment to Cloud Foundry environment with SAML configuration.