Skip to Content
Technical Articles

How-to use Storage Service from SAP Cloud Platform Mobile Services with SAP Cloud Platform SDK for iOS

Motivation

Do you develop native iOS applications with the SAP Cloud Platform SDK for iOS and do you want to store device-specific configuration data without the need to enhance your backend?

SAP Cloud Platform Mobile Services offers a storage service. This service stores flexible data structure and supports application-level, user-level, and device-level storage. SAP Cloud Platform Mobile Services offers authorization and authentication schemes that secure the data.

In this article, I will help you to understand how to use the Storage Service of SAP Cloud Platform Mobile Services with the SAP Cloud Platform SDK for iOS.

How-To

The SAPFoundation framework offers SAPcpmsSettings as API to read, store and delete settings that are centrally maintained on SAP Cloud Platform Mobile Services.

The use is simply .. once you know it 🙂

Store

Load

Appendix

SDK’s official documentation

Storage Service official documentation

5 Comments
You must be Logged on to comment or reply to a post.
  • Hey,

    This is very useful information.

    As I understood, using SAPcpmsSettings in iOS Application we can store/retrieve device specific data.

    But we have some different requirement in our application i.e we want to store device specific information in Mobile platform. So that we can get information regarding our customer usage i.e which user is using which device/configuration.

    Let me know if you have some detail information regarding the same.

    Jyotishree

    • Hi Per-Åge,

      the configuration is stored as JSON in SAP Cloud Platform Mobile Services to be platform agnostic.

      SAP Cloud Platform Mobile Services on NEO allows you to edit configuration as JSON via a JSON Editor.

      SAP Cloud Platform Mobile Services on Cloud Foundry does not have that capability as you can only export the configuration as JSON 🙁

      I recommend either use the REST APIs for Storage Service or use the SDK to communicate with Storage Service. The latter looks more convenient for me as a Swift developer 🙂

      To sum it up: no but you can create a plist, deserialize it in Swift and then use the SDK to store configuration in SAP Cloud Platform Mobile Services

      P.S.: You can store configuration on application, user, or device level.

      Kind regards,
      Marco