Hi,
Could u please post the following CCR and check, as it is working for us:-
CCR="<ContinuityOfCareRecord xmlns='urn:astm-org:CCR'>
<Body>
<Results>
<Result>
<Test>
<Description>
<Text>Diastolic</Text>
<Code>
<Value>18.4248</Value>
<CodingSystem>Google</CodingSystem>
</Code>
</Description>
<TestResult>
<Value>80</Value><Units><Unit>mmHg</Unit></Units></TestResult><DateTime><Type><Text>Collection
start
date</Text></Type><ExactDateTime>2007-05-02T07:00:00Z</ExactDateTime></DateTime></Test></Result><Result><Test><Description><Text>Systolic</Text><Code><Value>18.13801</Value><CodingSystem>Google</CodingSystem></Code></Description><TestResult><Value>120
</Value><Units><Unit>mmHg</Unit></Units></TestResult><DateTime><Type><Text>Collection
start
date</Text></Type><ExactDateTime>2007-05-02T07:00:00Z</ExactDateTime></DateTime></Test></Result></Results></Body></ContinuityOfCareRecord>
";
Thanks and Regards,
Kanaya
On Mon, Oct 11, 2010 at 11:11 AM, CTISTeam <[email protected]>wrote:
> Hi, All,
>
> We are using OAuth to connect to Google Health. We are able to
> retrieve CCR data. Now when we try to post/insert any new data, we
> are
> getting message “Execution of request failed”.
>
>
> Following is code snippet which we have used for posting new episode
> to Google H9.
>
>
> GOAuthRequestFactory reqFctry = new GOAuthRequestFactory("weaver",
> "domain-applcaiton-v1");
> reqFctry.ConsumerKey = consumerKey;
> reqFctry.ConsumerSecret = consumerSecret;
>
>
> reqFctry.GAuthToken = GAuthToken;
>
>
> HealthService service = new HealthService(reqFctry.ApplicationName);
> service.RequestFactory = reqFctry;
>
>
> AtomEntry newNotice = new AtomEntry();
>
>
> newNotice.Title.Text = "A test message";
> newNotice.Content.Content = "This is a test message.";
>
>
> String ccrXmlString ="<ContinuityOfCareRecord xmlns=\"urn:astm-
> org:CCR
> \"><Body><Results><Result><Test><Description><Text>Blood Pressure,
> Diastolic(Lower Number)</Text><Code><Value>18.4248</Value>
> <CodingSystem>Google</CodingSystem></Code></
> Description><TestResult><Value>80</Value><Units><Unit>mmHg</Unit></
> Units></TestResult><DateTime><Type><Text>Collection start date</
> Text></
> Type><ExactDateTime>2010-05-02T07:00:00Z</ExactDateTime></DateTime></
> Test></Result><Result><Test><Description><Text>Blood Pressure,
> Systolic (Upper Number) </Text><Code><Value>18.13801</
> Value><CodingSystem>Google</CodingSystem></Code></
> Description><TestResult><Value>120</Value><Units><Unit>mmHg</Unit></
> Units></TestResult><DateTime><Type><Text>Collection start date</
> Text></
> Type><ExactDateTime>2007-05-02T07:00:00Z</ExactDateTime> </
> DateTime></
> Test></Result></Results></Body></ContinuityOfCareRecord>";
>
>
> XmlDocument ccrDoc = new XmlDocument();
> ccrDoc.LoadXml(ccrXmlString);
> newNotice.ExtensionElements.Add(newXmlExtension(ccrDoc.DocumentElement));
>
>
> service.Insert(new Uri("https://www.google.com/h9/feeds/profile/
> default"), newNotice);
>
>
> So are we missing anything? Any help or guidance will be helpful.
>
> 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]<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.