Hey Everyone,

A few notes on Android+Health integration:

There are potentially XML-related issues using the version 1.41.x
GData client libraries on Android.  The alpha Android GData libraries,
available at the following location, should fix these.  Since these
APIs are alpha, however, they will likely differ from the GData
libraries that we have documented for Health.

http://code.google.com/p/gdata-java-client/wiki/Version2

We are looking to enhance our support mobile+Health development, and
welcome any and all questions in this group.  However, it may be worth
(cross-)posting Android and GData questions in the GData Java client
group.

http://groups.google.com/group/gdata-java-client

For ClientLogin, it's good to use the Android AccountManager if
possible, which stores user credentials and should have a the phone
owner's GMail credentials already, so your application won't need to
ask for and store the user's credentials itself.  However, the
AccountManager is available on Android 2.x devices only, and appears
to return no accounts when it is run in the Android emulator.

When data is entered into Health via the ClientLogin GData APIs, there
presently isn't a way for the data to be attributed to a particular
organization (i.e. data is "user-entered").  Therefore, it is strongly
recommended that Health partners use the non-ClientLogin,
"intermediary web app" approach to integrating.  Having the web app
allows users authenticate to Health with AuthSub or OAuth tokens,
which means that data can be attributed to the organization that
signed the authentication tokens.  The attribution is visible in the
Health UI as well as the GData feed.

If anyone has any successes with integrating Android with Health,
please don't hesitate to post code or tips to the group!  The Health
team will certainly be doing the same!

Paul


On Jun 9, 3:48 pm, Achie <[email protected]> wrote:
> Can you guys tell what the dependencies are for integrating google
> health on android.
>
> Megha, I am not using Client Login as Google specifically asks us to
> not do it. But you should be able to do it on android 1.5 also since
> they do not use any android specific code and both of them support
> Java 1.5.
>
> Thank you
>
> On Jun 8, 1:10 am, Idoya Olalde <[email protected]> wrote:
>
>
>
> > Hi,
>
> > Each user can have more than one profile. Yo have to obtain the list of
> > profiles and select the one you want:
>
> > Feed profileListFeed = healthService.getFeed(new
> > URL("https://www.google.com/health/feeds/profile/list";, Feed.class);
> > List<Entry> entries = profileListFeed.getEntries();
> > for (Entry profileListEntry : entries) {
> >   System.out.println("Profile name: " +
> > profileListEntry.getTitle().getPlainText());
> >   System.out.println("Profile id: " + 
> > profileListEntry.getPlainTextContent());
>
> > }
>
> > // Select the user's first profile
> > String firstProfileID = entries.get(0).getPlainTextContent();
>
> > //and then you can make the request to the url
> > "https://www.google.com/health/feeds/profile/ui/"; + firstProfileID;
>
> > Here you have more 
> > information:http://code.google.com/intl/es-ES/apis/health/docs/2.0/developers_gui...
>
> > Good luck!
>
> > 2010/6/8 Megha Bapat <[email protected]>
>
> > > hello,
> > >       I am building an application for google health using android as my
> > > final year project.
> > > So far i have been able to authenticate the account using Clientlogin. I
> > > need to retrieve the google health profile related to this token.
> > > How can i do this? please guide me.... is gdata library supported by
> > > android 1.5 or should i switch to android 1.6 for making use of this
> > > library.
> > > Please help its urgent as my submission date is very near.
> > >                                      Thanking you.....in adv..
>
> > > --
> > > You received this message because you are subscribed to the Google Groups
> > > "Google Health Developers" group.
> > > To post to this group, send email to
> > > [email protected].
> > > To unsubscribe from this group, send email to
> > > [email protected]<googlehealthdevelopers%
> > >  [email protected]>
> > > .
> > > For more options, visit this group at
> > >http://groups.google.com/group/googlehealthdevelopers?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Health Developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/googlehealthdevelopers?hl=en.

Reply via email to