0

Hi I am experiencing weird problem. I want to consume Google Bookmarks RSS in my .NET application. Here is the code:

string rssUrl = "https://www.google.com/bookmarks/?output=rss";
NetworkCredential credentials = new NetworkCredential("myusername", "mypassword");
XmlUrlResolver resolver = new XmlUrlResolver { Credentials = credentials };
XmlReaderSettings settings = new XmlReaderSettings { XmlResolver = resolver };
XmlReader reader = XmlReader.Create(rssUrl, settings);
XDocument document1 = XDocument.Load(reader); // Fails here

When I open rssUrl in browser I see all my bookmarks as RSS feed prefectly. When I run this code, it fails. In fact, what is returned back is the Google SignOn page instead of the RSS.

Using exactly the same code I can read Gmail RSS no problem.

But not Google Bookmarks RSS. This doesn't make any sense to me. It should be straight forward and very simple.

Please advice. Thanks a bunch.

monstro
  • 6,254
  • 10
  • 65
  • 111
  • 1
    Do you get an error back from the server? And check your network traffic with Fiddler so you can see what you are sending over the net and what they return. – Jordy van Eijk Sep 13 '12 at 14:12
  • As I mentioned, the content that is returned is the Google SignOn page instead of the RSS. – monstro Sep 14 '12 at 15:21
  • You can try yourself, the code is very simple - that's all you need... – monstro Sep 14 '12 at 15:22
  • This request returns Google Sign-In page html content instead of RSS. This means that validation for some reason is not working for that RSS url. This is strange. Any suggestion how I can authenticate the request to consume the RSS is highly appreciated. Thanks a lot. – monstro Sep 20 '12 at 15:00

0 Answers0