Skip to Content
Author's profile photo Martin Grasshoff

AppBuilder – Connect to SAP Mobile Platform Cloud Version [AppBuilder is now deprecated, use WebIDE]

Hi there.

A couple of month ago SAP Mobile Platform Cloud Version was released as mentioned by my colleague Jens Koerner. Also for some weeks now AppBuilder was released to our community (SAP AppBuilder Developer Center ). Since AppBuilder is perfect to be used for mobile Apps, it seems natural to combine those worlds: AppBuilder to be the technology for the client development and SMP Cloud as Mobile as a Service (MaaS) to run the App.

So prepare your AppBuilder environment and follow me to configure an AppBuilder datasource connected to SMP Cloud.

Prerequisites:

Now let’s start:

Start AppBuilder and create a new App by clicking the “New” button on top of the welcome screen.

/wp-content/uploads/2013/12/appbuilder_1_339390.jpg

In the dialog that appears just type in a project name like : “SMPCLOUDDEMO” and click “confirm”.

Then click “SMP Settings” in the Help menu.

A dialog appears that lets you configure to which SMP Application you want to connect to.

/wp-content/uploads/2013/12/appbuilder_2_339416.jpg

This Application is a configuration container that hold information about your backend, your registrations, settings and a lot of other details. It is important here that we configure the correct values (case sensitiv).

In my Blog How to use the SMP Cloud with Copy & Paste I used the Application ID “firstApp”. Here is how it looks like in SMP Cloud Trial:

/wp-content/uploads/2013/12/appbuilder_3_339391.jpg

Now set the configuration settings in AppBuilder. The Profile name is up to you to decide. The server URL depends on your SMP Cloud URL. It typically consists of “smp-” followed by your SCN user ID follwed by “trial.hanatrial.ondemand.com”.

Choose “firstApp” as Appcliation ID and Security Config. Type in the Username and Password from the backend.

/wp-content/uploads/2013/12/appbuilder_4_339451.jpg

Confirm the settings. The dialog will disappear. In the lower left corner of AppBuilder click on “SMP SERVICES”. Select the pencil tool.

/wp-content/uploads/2013/12/appbuilder_5_339449.jpg

A dialog appears. Here you choose the “smpcloud” profile selection box on top of the dialog. Then click RETRIEVE.

If you have everything setup up correctly AppBuilder will now onboard itself to your SMP Cloud Account and retrieves the OData Service Document. It will then list all available services in the list on the right side.

/wp-content/uploads/2013/12/appbuilder_6_339455.jpg

Confirm the dialog by pressing “CONFIRM”.

That’s all. You can now use the datasource in your superlist and directly see live data while you are coding.

To learn more about the Superlist read this tutorial: AppBuilder Tutorial – SuperList

Hope you enjoyed this little tutorial.

Have Fun,

Martin Grasshoff

Assigned Tags

      34 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Avital Ben-Natan
      Avital Ben-Natan

      If I have a Hana XS application with native authentication, could I leverage this stack to develop mobile clients against that application?

      Are there any docs or blogs to that effect?

      Author's profile photo Martin Grasshoff
      Martin Grasshoff
      Blog Post Author

      Hi.

      Well if you like an HTML5 Application, you can give it a try. You can connect AppBuilder also to an OData feed from HANA XS if you like.

      Otherwise you have the option to build  a native Android or iOS App, it depends on the use case.

      -Martin

      Author's profile photo Hemendra Sabharwal
      Hemendra Sabharwal

      Thanks for sharing Martin, this is great direction to move forward.

      Warm Regards

      Hemendra

      Author's profile photo Former Member
      Former Member

      Hi this is a  great article.

      Would you happen to know if its possible to connect AppBuilder to a local copy of SMP 3.0 SP01, rather than the cloud version.

      Regards

      Jason

      Author's profile photo Martin Grasshoff
      Martin Grasshoff
      Blog Post Author

      Hi Jason.

      Yes, that is absolutely possible. Just point to your SMP on-premise URL.

      Have Fun,

      Martin

      Author's profile photo Former Member
      Former Member

      Hi Martin,

      Thanks Alot

      Jason

      Author's profile photo Former Member
      Former Member

      Hello Martin,

      I am trying to configure SMP settings in my app designer and I am getting following error:

      Failed to connect to SMP Onboarding Service. The error message is:

      {}

      Is there any way to debug/trace the reason for this error?

      Thanks,

      Kind Regards,

      Arpit

      Author's profile photo Former Member
      Former Member

      Was having same issue - cracked it at least for annonymous login configuration ... see below ... screenshost for AppBuilder 1.0.1251 ...

      /wp-content/uploads/2014/03/1_405869.jpg

      /wp-content/uploads/2014/03/2_405870.jpg

      /wp-content/uploads/2014/03/3_405871.jpg

      /wp-content/uploads/2014/03/4_405872.jpg

      /wp-content/uploads/2014/03/5_405873.jpg

      /wp-content/uploads/2014/03/6_405874.jpg

      Author's profile photo Former Member
      Former Member

      hi,

      I tried the above steps but still am getting

      Failed to connect to SMP Onboarding Service. The error message is:

      {}.

      any idea what else should be tried

      Author's profile photo Former Member
      Former Member

      hi Arpit,

      Even I am facing similar issue .However in my case earlier I was able to connect to SMP onboarding service but now on retreving connection getting error message

      Failed to connect to SMP Onboarding Service. The error message is:

      {}

      if you have any idea to resolve this please share it.

      Author's profile photo Former Member
      Former Member

      Hello Aditi,

      The reason I had problem was because I was using "Google Chrome Canary" as browser to launch my appbuilder. The moment I change it to Google Chrome it worked fine for me. Unfortunately I am unable to think any particular reason but logically thinking as you were able to connect to SMP onbaording service. The error could be in your service end point or odata service itself. It's just a guess!!

      Regards,

      Arpit

      Author's profile photo Former Member
      Former Member

      Thanks Martin,

      I followed your steps and its working. Thanks a lot.

      Author's profile photo Marius Stoica
      Marius Stoica

      Hi Martin ,

      I have a on premise install of SAP Mobile Platform and I'm trying to config AppBuidler to send my app to SMP and I get an error.

      Here are the differences from your example 🙂 (case sensitive)

      1. My app is called "Test" and app id is "com.test"

      /wp-content/uploads/2014/06/test_480375.jpg

      2. so here is my SM app profile:

      smp app prof.jpg

      but when I am trying to "Retreive" data, I get an error:

      Failed to connect to SMP Onboarding Service. The error message is:

      {"message":"HTTP request failed","request":{"headers":{"X-SUP-SC":"com.test","Authorization":"Basic bWFyaXVzOmV0ZG1pbnUzMDA=","Accept":"application/atom+xml,application/atomsvc+xml,application/xml","DataServiceVersion":"1.0","Content-Type":"application/atom+xml","MaxDataServiceVersion":"3.0"},"requestUri":"https://<server-name>:8083//odata/applications/latest/com.test/Connections","method":"POST","data":{"DeviceType":"iPhone"},"recognizeDates":false,"callbackParameterName":"$callback","formatQueryString":"$format=json","enableJsonpCallback":false,"inferJsonLightFeedAsObject":false,"body":"<a:entry xmlns:a=\"http://www.w3.org/2005/Atom\" xmlns:m=\"http://schemas.microsoft.com/ado/2007/08/dataservices/metadata\" xmlns:d=\"http://schemas.microsoft.com/ado/2007/08/dataservices\"><a:author><a:name/></a:author><a:content type=\"application/xml\"><m:properties><d:DeviceType m:type=\"Edm.String\">iPhone</d:DeviceType></m:properties></a:content></a:entry>"},"response":{"requestUri":"https://<server-name>:8083//odata/applications/latest/com.test/Connections","statusCode":0,"statusText":"","headers":[],"body":""}}

      What am I doing wrong?

      I tried with SMP admin user and pass, SUP admin user and pass, GW user and pass, Back-end user and pass ... same response.

      Thank you in advance,

      Marius

      Author's profile photo Midhun VP
      Midhun VP

      Make sure SMP server is accessible from your system (ping), make sure backend and security is configured properly in SMP cockpit. Also check whether the port 8083 is open and accessible from your system (telnet). The credentials you need to pass is GW credentails. You can check the backend url configured is working from a web browser.

      Midhun VP

      Author's profile photo Marius Stoica
      Marius Stoica

      Hi Midhun,

      SMP is accessible, it's on the same virtual machine as AppBuilder.

      Back-end is accessible, and the service works just fine, http://:8000/sap/opu/odata/sap/Z_AUTH_SERVICE/

      Here is my back-end tab:

      /wp-content/uploads/2014/06/back_end_480590.jpg

      and my authentication tab

      /wp-content/uploads/2014/06/auth_480592.jpg

      Everything else is standard 🙂 (with standard values, null, 0, default, etc 🙂 )

      Any clues ? 🙁

      Author's profile photo Midhun VP
      Midhun VP

      Are you able to ping the application you created ?

      Author's profile photo Marius Stoica
      Marius Stoica

      If u refer to the GW server, yes ... I can

      Author's profile photo Midhun VP
      Midhun VP

      Select the created application in Cockpit> Ping. You should get a success message as in last image in this blog,SAP Mobile Platform 3 tutorial using Integration Gateway - Part 1

      Midhun VP

      Author's profile photo Marius Stoica
      Marius Stoica

      Did. Works well (meaning i get the same success message).

      Author's profile photo Midhun VP
      Midhun VP

      Alright. You are using a port 8083, but the default port is 8080. Could you check whether it is working with 8080 instead of 8083. 8083 is a default port used by Integration gateway.

      Author's profile photo Marius Stoica
      Marius Stoica

      Where should I change the port 8083? The only place i see it, is at the SMP cockpit startup link.

      Author's profile photo Midhun VP
      Midhun VP

      I mean change the port you are giving in the appbuilder connection settings under server URL property.

      ScreenHunter_138 May. 27 00.39.jpg

      Author's profile photo Marius Stoica
      Marius Stoica

      I get the same error 🙁

      Author's profile photo Marius Stoica
      Marius Stoica

      Any other ideas Midhun, Martin, Ming Kho?

      Can you please help?

      Thanks Marius

      Author's profile photo Martin Grasshoff
      Martin Grasshoff
      Blog Post Author

      Sorry, no more ideas.

      Author's profile photo Ming Kho
      Ming Kho

      Hi Marius,

      Please try remove the trailing slash '/' at the end of the Server URL in the SMP Profile

      e.g.

      from:

      http://your-server.address.com:8083/

      to:

      http://your-server.address.com:8083

      Regards

      Ming

      Author's profile photo Marius Stoica
      Marius Stoica

      I made the change, it's the same result.

      "Failed to connect to SMP Onboarding Service."

      Q: Do all of them (com.test - app ID - and com.test - security config) have to be already created on the SMP? At the moment I have both of them created there. Is there anything else that needs to be creatd in the SMP Cockpit?

      Author's profile photo Midhun VP
      Midhun VP

      Use port 8080, use HTTP instead of https and check.

      ex.http://your-server.address.com:8083/

      Author's profile photo Marius Stoica
      Marius Stoica

      Worked 😀 Like a charm 😀 ,

      PS: Trying the actual deploy now to SMP...

      PS2: All done. The app is registered in SMP I have 1 user, 1 registration, 1 app. Now how do I deploy it to my device ? 🙂 )))

      Author's profile photo Midhun VP
      Midhun VP

      Read the comments I given in the blog to install the app in device,SAP Mobile Platform 3 tutorial using Integration Gateway - Part 2

      Author's profile photo Former Member
      Former Member

      Hi

      I hav established the connection ,created an app consuming the Odata service.

      Need help on Deployment of Appbuilder application on SMP server

      Please if you can let me know how to deploy the the app

      I have created cordova application it shows sucess 100%

      Deploy on SMP server 100% but it is not getting launch on simulator .

      Please let me know the steps for deployment.

      Author's profile photo Midhun VP
      Midhun VP
      Author's profile photo Former Member
      Former Member

      Hi Experts,

      May I get your feed backs for below questions?

      1- Can we say AppBuilder is positioned as RAD tool?

      2- When we say some dev tool supports RAD, how we evaluate the RAD capabilities of tool?

      3- Is AppBuilder capable of supporting complex Use Cases to develop?

      To my understanding, if any developer is comfortable working with any development tool(Netbeans, JavaScript IDEs etc supporting drag and drop features) of his/her choice, he can develop things faster than a developer who is recently trained on AppBuilder.

      Best Regards,

      Author's profile photo Martin Grasshoff
      Martin Grasshoff
      Blog Post Author

      HI Mohammed,

      AppBuilder is no longer maintained.

      Please take a look at the WebIDE.

      Getting started with SAP Web IDE trial version from registration to running application

      Regards,

      Martin