Mbaas for hybrid app (with cordova) - android

I'm starting a new mobile hybrid application with cordova and i want to use an mbaas to accelerate development process. I need:
Database
Authentication (with social logins)
Push notifications sent from client
Server-side scripting (optional)
I've seen Firebase, but it's a little bit tricky for push notifications (i have to create another server) and also it don't support very well the hybrid applications.
Anyone can help me? Thanks

You can use a mbaas like built.io's backend, I am not sure if they support server side scripting but rest all can be achived.
You can refer to their docs https://docs.built.io/
Refer to this feature list https://www.built.io/products/backend/features

Related

How to wrap a responsive web app that uses ADFS auth into a native iOS/Android app using only bluemix services?

The following idea is in our heads and we did not find out how to realize it.
We have a responsive web application that is based on a domino server using xpages. The service authenticates using SAML against our adfs 2.0 service.
We want to use native mobile apps to improve the mobile web app it two disciplines:
1. use notifications to alert users about tasks and events
2. Store the password in a secure way on the device so it won't be asked every time you use the app.
The web app stays on that domino server and is used as is.
I thought this should be possible using only bluemix services.
But how?
We do not want to develop native apps by ourselves so apache Cordova came in our minds. That or a similar solution should enable us to provide native mobile apps with in app stored passwords (or tokens or even touchID logon) and mobile notifications.
Which is the best bluemix practice?
Bernd,
you have a rather large set of technology moving parts here :-). Let me pick them into pieces:
Domino: you need something outside of Bluemix for storing the NSF, like a Softlayer Domino server. That will be key to the solution.
mobile app: Cordova is right, but look one step further and have a look at Ionic. It uses Cordova under the hood. You can add it to your app as is, or use IBM Mobile first foundation
Push notifications: there's a service for it in Bluemix
Authentication: there's a service for it
What I would do:
on the Domino server holding the NSFs deploy a OSGi plugin you write extending Domino Access Services that reads/writes the data you are interested in JSON. Use the OpenNTF Domino Api (ODA) to make your life easier
configure the server to only talk to Bluemix. I would use VPN technology for that - Bluemix has a service for that
Now the fun part: configure Domino to accept the WAS headers for user identity. Securing Domino in the step before is ESSENTIAL since hitting it direct would now allow to spoof identity. This is why ONLY your Bluemix VPN shall hit it
Now build your app layer in Bluemix using Liberty or Node.js (I would use Node.js since passport, a Node module, has the most authentication options) that handles auth using the Bluemix services and sets the header when talking to Domino
Make sure you use a web worker in your mobile app to take the network out of the user experience
That's roughly it. Hope it helps

Since Layer.com does not have a web SDK yet, what can I use to integrate it myself for a web-mobile chat app?

Layer looks awesome for mobile development, however, in case we need to build a web to mobile chat, the web SDK is not yet available. Can we integrate it with parse to do so? Or maybe some other solution.
The Web SDK is currently in Early Access so it's available to be used. You could potentially use the combination of the Platform API and Parse cloud code to do a partial chat from web to mobile in the meantime, but it depends on your use case.
I do not know Layer but I think(hope) you can send http request (REST api) to parse and trigger the cloud function. So the cloud function can send your message to your mobile client as a push notification. After that, the only thing that you have to do is handling the push notification cases such that when the app is opened, when the app is closed or when the app is on chat screen. Hope this helps.
Regards.
Another good alternative is Hyphenate. Similar to Layer, but Hyphenate supports both Mobile and Web SDK with rich features and very reliable services.
Parse is good, but shutting down soon, an good alternative is Firebase by Google.
https://hyphenate.io/
https://github.com/HyphenateInc/Hyphenate-SDK-Web

NodeJS Alternative For Android

I have visited many blogs and questions looking for a way to use android as a client and nodejs as a server for my app. I came up with a solution that is to use PhoneGap like frameworks so that it could act like native but is not in reality. I need to use native android sdk and connect with NodeJS server (using SocketIO) to create my app. Is there any way I could do this?
P.S I want to know that while I set up by GCM can I pass my IP and port that I have created in my socket.io file to the GCM?
Cordova (hence PhoneGap) allows you to use most of the hardware APIs. PhoneGap nowadays is just a build service of some sorts.
The Cordova website and plugin store explain all the details. But t WebSockets are just an upgraded protocol or feature of TCP. Any newer technology supports it without any dependencies, but in dependence of the network you're traveling in.
Without diving deep into the code here at socket.io-website, I reckon that the initial build of your Cordova app is a WebSocket implementation to the server. So you got everything bootstrapped already.
What this tutorial doesn't explain is how to connect to the server. But read it up here.
I have no prior experience but Google Cloud Messaging seems not to be in the scope of the problem of socket.io. Once you have a connection to the socket you can send to the client whatever payload you want and might or might not need GCM anymore. If you need to send stuff via GCM read up on the the GCM node module.
Passing IPs around shouldn't be much of a problem since you're are running a public service anyway. You'd need to secure it anyhow of course.

Appcelerator Titanium and Web Authentication - Android and iOS

Forgive me, but this is a vague question:
I am wanting to build an Android and iOS application to interact with my web application.
For example: Within my Android and iOS app, I am wanting to authenticate the users through my current web application, which currently is Laravel 4.2. The only tutorial I can find (which I'm sure is out of date) is - TutsPlus
My question is, do you have any more recent tutorials on web authentication (registering users with their tokens) / push notifications (sent from a server) etc... The script I can see on the above example is both vulnerable to MYSQL injection and has a lack of SSL.
Many thanks for your help in this. I know there is no right and wrong answer, this is mainly just for guidance for someone starting out in mobile development!
Try using HttpClient
Appcelerator has an example in there.
In essence, you're posting to the same URL as your web page, or another with a more mobile appropriate response
As for SQL injection, you can perform basic validation yourself, but remember for Http requests, clients can be bypassed, which is why you want your validation to be server side

Integrate Appcelerator Cloud Services to a custom website made with ASP.NET

I'm really new to mobile world, so I'd like to get some opinion from experienced people.
After several days searching over the internet, I'm wondering if it's possible
integrate Appcelerator Cloud Services to a custom website made with ASP.NET, for example.
Although my mobile application, built with Titanium, it's linked to ACS, and works fine, I don't know if
it's possible to manage data stored in ACS from a custom website. To clarify, in one point there is my mobile application
talks to a webserver (ACS, for example) and other point there is a website, to manage the data stored in ACS.
What do you think, someone achieved this?
Or is it preferable to write a webserver from the scratch, store my data in somewhere, and forget about ACS?
Thank you.
Appcelerator says
Appcelerator Cloud Services (ACS) is a Mobile Backend as a Service
(MBaaS), offering a fast and easy way to build connected mobile apps.
Choose from a library of services such as push notification, status
updates, photo storage, and social integration, or create your own
custom cloud services.
Here in this page - Getting Started: Using the Javascript SDK - you can see how we can use javascript SDK which lets you access the Appcelerator Cloud Services server through some simple to use JavaScript calls. You can use this to develop web-based app.
ACS has a REST API which you can access through anything that supports xhr (which .NET does). For instance, to create a new user in ACS, you use the following link:
https://api.cloud.appcelerator.com/v1/users/create.json?key=YOUR APP APP KEY?email=john.smith#company.com&role=teacher
There are other properties you can tag onto the querystring to create a new user from a REST call. They have a complete API using REST. It's all documented. You can even send push notifications to devices from your custom website using the REST API! It's pretty cool.
http://cloud.appcelerator.com/docs/api/v1/users/create#rest
Good luck!

Categories

Resources