athibanraj / gdata-java-client

Automatically exported from code.google.com/p/gdata-java-client
Apache License 2.0
0 stars 0 forks source link

Webmaster site verification via APIs fails. #157

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Ran the WebmasterToolsClient with my webmaster username and password
2. The client fails after trying to verify my website.
3.

What is the expected output? What do you see instead?

I'm expecting my site to be uploaded to webmaster tools and the sample 
client to run to completion without throwing errors.

What version of the product are you using? On what operating system?
V1.34 . Windows and Ubuntu.

Please provide any additional information below.

The error I get is:
com.google.gdata.util.InvalidEntryException: Bad Request

<html><head>
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<title>400 Bad Request</title>
<style><!--
body {font-family: arial,sans-serif}
div.nav {margin-top: 1ex}
div.nav A {font-size: 10pt; font-family: arial,sans-serif}
span.nav {font-size: 10pt; font-family: arial,sans-serif; font-weight: 
bold}
div.nav A,span.big {font-size: 12pt; color: #0000cc}
div.nav A {font-size: 10pt; color: black}
A.l:link {color: #6f6f6f}
A.u:link {color: green}
//--></style>
<script><!--
var rc=400;
//-->
</script>
</head>
<body text=#000000 bgcolor=#ffffff>
<table border=0 cellpadding=2 cellspacing=0 width=100%><tr><td rowspan=3 
width=1% nowrap>
<b><font face=times color=#0039b6 size=10>G</font><font face=times 
color=#c41200 size=10>o</font><font face=times color=#f3c518 
size=10>o</font><font face=times color=#0039b6 size=10>g</font><font 
face=times color=#30a72f size=10>l</font><font face=times color=#c41200 
size=10>e</font>&nbsp;&nbsp;</b>
<td>&nbsp;</td></tr>
<tr><td bgcolor="#3366cc"><font face=arial,sans-serif 
color="#ffffff"><b>Error</b></td></tr>
<tr><td>&nbsp;</td></tr></table>
<blockquote>
<H1>Bad Request</H1>
Your client has issued a malformed or illegal request.

<p>
</blockquote>
<table width=100% cellpadding=0 cellspacing=0><tr><td 
bgcolor="#3366cc"><img alt="" width=1 height=4></td></tr></table>
</body></html>

    at 
com.google.gdata.client.http.HttpGDataRequest.handleErrorResponse(HttpGData
Request.java:557)
    at 
com.google.gdata.client.http.GoogleGDataRequest.handleErrorResponse(GoogleG
DataRequest.java:543)
    at 
com.google.gdata.client.http.HttpGDataRequest.checkResponse(HttpGDataReques
t.java:535)
    at 
com.google.gdata.client.http.HttpGDataRequest.execute(HttpGDataRequest.java
:514)
    at 
com.google.gdata.client.http.GoogleGDataRequest.execute(GoogleGDataRequest.
java:515)
    at com.google.gdata.client.Service.update(Service.java:1463)
    at com.google.gdata.client.Service.update(Service.java:1429)
    at 
com.google.gdata.client.GoogleService.update(GoogleService.java:590)
    at 
com.foodoro.alerts.handlers.sitemapgenerator.WebmasterToolsClient.verifySit
e(WebmasterToolsClient.java:223)
    at 
com.foodoro.alerts.handlers.sitemapgenerator.WebmasterToolsClient.runExampl
es(WebmasterToolsClient.java:467)
    at 
com.foodoro.alerts.handlers.sitemapgenerator.WebmasterToolsClient.main(Webm
asterToolsClient.java:430)

Original issue reported on code.google.com by dannie%f...@gtempaccount.com on 3 Jul 2009 at 5:34

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Looks like you are using the sample code shipped with the library.  I tested 
the code
(META TAG) with a Google Sites site page, and it seem to be working fine.  

Did you use HTML PAGE or META TAG verification method.  The sample code by 
default
tries to use HTML PAGE verification method.  If the issue still exists, please 
send
the html trace
(http://code.google.com/apis/gdata/articles/debugging_client_libs.html#java)
associated with the failed request.

Original comment by vbarat...@gmail.com on 7 Aug 2009 at 3:23