Hello Eric,

By using this i just add notice to profile , but i want to create a
new profile programatically.
Is it possible to create a new profile programatically.
& one more think eric, how can i add multiple medication or any
category at a time just creating only 1 xml file & i alos want to add
USerComments for each entry.


Thanks in advance.

On Mar 26, 4:43 am, "Eric (Google)" <[email protected]> wrote:
> ClientLogin uses different feed 
> URIs:http://code.google.com/apis/health/docs/2.0/reference.html#ClientLogi...
>
> You need to POST to register/ui/<yourProfileID>.
>
> Eric
>
> On Mar 24, 9:35 pm, "[email protected]" <[email protected]> wrote:
>
>
>
> > Hello Eric,
>
> > I have used the following code to add new profile:
>
> > NSString *myStr = [NSString stringWithFormat: @"https://www.google.com/
> > health/feeds/register/default"];
>
> >         NSMutableURLRequest *httpReq = [[NSMutableURLRequest alloc]
> > initWithURL:[NSURL URLWithString:myStr] ];
>
> >         [httpReq setTimeoutInterval:30.0];
>
> >         [httpReq setHTTPMethod:@"POST"];
> >         //      [httpReq addValue:@"Content-Type" 
> > forHTTPHeaderField:@"application/
> > atom+xml"];
> >         [httpReq addValue:@"application/atom+xml"
> > forHTTPHeaderField:@"Content-Type"];
>
> >         NSString* param = [NSString stringWithFormat:@"GoogleLogin auth=%@",
> > [parameter objectForKey:@"Auth"]];
>
> >         [httpReq setValue:param forHTTPHeaderField: @"Authorization"];
>
> >         [httpReq addValue:@"Authorization" forHTTPHeaderField:param];
>
> >         NSHTTPURLResponse *response = nil;
> >         NSString *strData=@"<?xml version=\"1.0\" encoding=\"utf-8\"?>   
> > <entry
> > xmlns=\"http://www.w3.org/2005/Atom\";>     <title type=\"text\">Testing</
> > title>       <content type=\"text\">Test data</content>
> > <ContinuityOfCareRecord xmlns=\"urn:astm-org:CCR\">     </
> > ContinuityOfCareRecord>      </entry>";
> >         NSString *requestBody = [[NSString alloc]
>
> >                                                          
> > initWithFormat:strData ];
>
> >         [httpReq setHTTPBody:[requestBody
> > dataUsingEncoding:NSASCIIStringEncoding]];
>
> >         NSData *data = nil;
>
> >         NSError *error = nil;
>
> >         NSString* responseStr;
>
> >         data = [NSURLConnection sendSynchronousRequest:httpReq
> > returningResponse:&response error:&error];
>
> >         if( [data length] >0)
>
> >                 responseStr = [[NSString alloc] initWithData:data
> > encoding:NSASCIIStringEncoding];
>
> > & i get the following error:
> > "Cannot retrieve Profile Key for URI null and AS null"
>
> > On Mar 25, 9:22 am, "[email protected]" <[email protected]> wrote:
>
> > > Thanks Eric, i got my problem.
> > > Thanks foe quick reply..
>
> > > Now i want to how can we create multiple profile on google health?
>
> > > I m trying with the following 
> > > linkhttp://code.google.com/apis/health/docs/2.0/developers_guide_protocol...
>
> > > Please help me,
>
> > > Thanks
>
> > > On Mar 24, 11:39 pm, "Eric (Google)" <[email protected]> wrote:
>
> > > > I believe <ActorID> will take the name/email
> > > > of the party that sent the information.
>
> > > > To answer your second question, 'Condition' maps
> > > > to <Problems>.
>
> > > > Eric
>
> > > > On Mar 23, 2:59 am, "[email protected]" <[email protected]> wrote:
>
> > > > > Hi,
>
> > > > > In my application i have multiple user for those i have to add their
> > > > > records to google health.
> > > > > I m trying to add their records to google by changing their ActorID
> > > > > but when i retrieve their records o always got ActorID as my email id.
> > > > > Following is my input:
>
> > > > > @"<?xml version=\"1.0\" encoding=\"utf-8\"?><entry 
> > > > > xmlns=\"http://www.w3.org/2005/Atom\";><title type=\"text\">THE NOTICE 
> > > > > SUBJECT LINE</
> > > > > title><content type=\"text\">THE NOTICE MESSAGE BODY</content>
> > > > > <ContinuityOfCareRecord xmlns=\"urn:astm-org:CCR
> > > > > \"><Language><Text>English</Text><Code><Value>en</
> > > > > Value><CodingSystem>ISO-639-1</CodingSystem>     </Code>   </Language>
> > > > > <Version>V1.0</Version>     <DateTime>        <Type />  
> > > > > <ExactDateTime>
> > > > > %...@t11:57:20Z</ExactDateTime>      </DateTime>       <Patient>
> > > > > <ActorID>D6E5D510-592D-C613-DB46-A4CF2AC91C1D</ActorID>     </Patient>
> > > > > <Body><Procedures> <Procedure>  <DateTime>  <Type><Text>Start date</
> > > > > Text></Type>  <ExactDateTime>%...@t07:00:00Z</ExactDateTime>  </
> > > > > DateTime>  <Description>  <Text>%@</Text>   <Code>   <Value>%@</Value>
> > > > > <CodingSystem>CPT</CodingSystem>   </Code>  </Description>
> > > > > <Source><Actor> <ActorID>%@</ActorID>  <ActorRole>%@</ActorRole>   </
> > > > > Actor>          </Source>   </Procedure>  </Procedures></
> > > > > Body><Actors><Actor><ActorObjectID>D6E5D510-592D-C613-DB46-
> > > > > A4CF2AC91C1D</ActorObjectID><Person><Name><CurrentName><Given>Test5</
> > > > > Given><Family>Surescripts</Family></CurrentName></
> > > > > Name><DateOfBirth><Type /><ExactDateTime>1955-01-02T12:00:00Z</
> > > > > ExactDateTime></DateOfBirth><Gender /></
> > > > > Person><Address><Type><Text>Home</Text></Type></
> > > > > Address><Telephone><Value>123-456-7890</Value></
> > > > > Telephone><EMail><Value>[email protected]</Value></
> > > > > EMail><URL><Value>http://mttaboros.com</Value></URL><Status /><Source 
> > > > > /></Actor></Actors></ContinuityOfCareRecord></entry>",[self
>
> > > > > replaceStringWith:Date],[self replaceStringWith:srDate],[self
> > > > > replaceStringWith:Description],[self replaceStringWith:Value],[self
> > > > > replaceStringWith:ActorID],[self replaceStringWith:ActorRole]];
>
> > > > > Here i m changing the value from my coding.
> > > > > I am changing the ActorID for different Actors.
> > > > > Pls Help me.
>
> > > > > & one more Question is there any problem category in google Health?
> > > > > If yes then how can i access their data e.g for medication 
> > > > > :"https://www.google.com/health/feeds/profile/ui/myProfileName/-/medica......";
>
> > > > > Thanks
--~--~---------~--~----~------------~-------~--~----~
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