question

ropaplanet avatar image
0 Likes"
ropaplanet asked

How to get and store eBay SOAP response from a Platform notification in C# using ebay .net SDK

I have subscribed my ebay users for different Platform notifications. I am getting the responses perfectly for all the methods. I am getting the SOAP action URL as well . e.g: like - " http://developer.ebay.com/notification/MyMessagesM2MMessage". But what I want is to get the SOAP response so that I can get the details of the notification means whats the correlation id etc.. So that I can get the exact data for which the user has been notified. Below is the code snippet written to get the response details from notification alert: writer.BaseStream.Seek(0, SeekOrigin.End); writer.WriteLine("IP Address: " + VisitorsIPAddr); sb.Append("IP Address: " + VisitorsIPAddr + " "); writer.WriteLine("-------------------------------------------------------"); writer.WriteLine(); writer.Flush(); // Set the file pointer to the end of the file writer.BaseStream.Seek(0, SeekOrigin.End); writer.WriteLine("Browser: " + Request.Browser.Browser); sb.Append("Browser: " + Request.Browser.Browser + " "); writer.WriteLine("-------------------------------------------------------"); writer.WriteLine(); writer.Flush(); // Set the file pointer to the end of the file writer.WriteLine("Below is the URL response details"); sb.Append("Below is the URL response details" + " "); writer.WriteLine("*********************************************************"); sb.Append("*********************************************************" + " "); writer.WriteLine("Full Headers: " + Server.UrlDecode(Request.Headers.ToString())); sb.Append("Full Headers: " + Server.UrlDecode(Request.Headers.ToString()) + " "); writer.WriteLine("-------------------------------------------------------"); foreach (var hdata in Request.Headers.AllKeys) { if (hdata.Trim() == "SOAPAction") { _soapAction = Request.Headers[hdata]; } writer.BaseStream.Seek(0, SeekOrigin.End); writer.WriteLine(hdata + ": " + Request.Headers[hdata]); sb.Append(hdata + ": " + Request.Headers[hdata] + " "); writer.WriteLine("-------------------------------------------------------"); writer.WriteLine(); writer.Flush(); } writer.WriteLine("############################################################");
notificationssoapplatform-notifications-g
10 |600

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

0 Answers

·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.