Skip to Content
Technical Articles

Registration count limitation for trial plan of SAP Mobile Services

Do you evaluate the SAP BTP SDK for iOS/Android and SAP Mobile Services with a trial account? Then you might have encountered an unexpected “Failed to logon!” error.

Failed to logon! Please check the authentication URL

In this blog post, I will inform you about a limitation for the trial plan of SAP Mobile Services which might be the root cause of this error. I will also show you how to fix the issue and give a deeper explanation of when and why you can expect that this particular error occurs.

To explain the situation I am using my trial account as well as the SAP BTP SDK for iOS Assistant to create a sample application.

Creating%20a%20Sample%20Application%20with%20SAP%20BTP%20SDK%20for%20iOS%20Assistant

Creating a Sample Application with SAP BTP SDK for iOS Assistant

The Assistant will create an Xcode project but also creates an application definition in SAP Mobile Services.

App%20Definition%20in%20SAP%20Mobile%20Services%20created%20by%20SAP%20BTP%20SDK%20for%20iOS%20Assistant

App Definition in SAP Mobile Services created by SAP BTP SDK for iOS Assistant

If you encounter an expected “Failed to logon!” error I recommend checking the logs in SAP Mobile Services.

If you encounter the warnings

  • “Registration count is beyond the account limit”
  • “Failed to create auto device registration”

then the error is caused by the fact that the registration count exceeds the trial account limitation.

SAP%20Mobile%20Service%20Logs

SAP Mobile Service Logs

On the trial plan, Mobile Services does not allow more than 3 registrations per app.

Solution: if you encounter this error, delete the existing user registrations in Mobile Services to keep your registration count below the trial account limit.

Delete%20User%20Registrations%20for%20application%20under%20Mobile%20Settings%20Exchange

Delete User Registrations for application under Mobile Settings Exchange

In my example, I installed the same app on multiple iOS simulators and onboard the same user. Different iOS simulators will result in various registrations so it is no surprise that I encounter the error for the 4th onboarding.

I would have encountered the error also if I deleted and reinstalled the app multiple times on the same iOS simulator. But why? The answer is that the registration is calculated based on “Device ID” and “Username”. But there is no such thing as a stable “Device ID” provided by the iOS operation system. The SAP BTP SDK for iOS uses an alphanumeric string that uniquely identifies a device to the app’s vendor (identifierForVendor).

As the Apple documentation states

The value in this property remains the same while the app (or another app from the same vendor) is installed on the iOS device. The value changes when the user deletes all of that vendor’s apps from the device and subsequently reinstalls one or more of them.

The vendor identifier is calculated based on the app’s bundle ID. In my example the bundle ID is example com.sap.btpsdkios.AppConnectingToTrial

Therefore deleting and reinstalling the only app with a bundle ID starting with example com.sap.btpsdkios will cause a new “Device ID” and therefore a new registration.

I hope this blog post help helped you to understand the limitation better and how to circumvent the “Failed to logon!” error.

1 Comment
You must be Logged on to comment or reply to a post.