1

I am looking into building an android app, which holds some simple data (probably stored in sqlite). I also have a app engine app which I intend to be an online data store for the information (the app engine app is wrote in python).

The question here is, what is the best way to authenticate a user with the app and how to get the data from the android app to the Google data store?

Thanks

Mike

2 Answers 2

1

You could use Google Account authentication and follow this useful post about Authenticating against App Engine from an Android app

You can also give a look at the SampleSyncAdapter sample from the SDK

0

If you want to authenticate using OAuth, you can do that. The only trick is that you need to launch the flow in an internal WebView, because App Engine's OAuth implementation doesn't allow custom protocols in the redirect. I recommend the Signpost library. If you'd like an example, the 2cloud Android client is licensed under the MIT license (full disclosure, I'm the lead dev for 2cloud). The benefit of this is it allows you to support Android 1.5 and higher. The Accounts API is only supported starting in 2.1.

Another option is the Accounts API. @systempuntoout has good links for that, so I won't reinvent the wheel here.

Finally, it might be worth taking a look at the App Engine-powered Android Eclipse project that was demo'd at I/O this year. It makes keeping code in sync and shared between the two simple. Only downsides are it requires Android 2.2 or higher, and it requires you to write in Java on the App Engine side and GWT for the client side.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.