I am trying to get a list of albums. I would like to use the partial
response because I only want a few of the fields.

 I cannot get it to work using the examples from the Picasa web albums dev
guide.

 Here is what is happening.

 If I use the following code it works and I get the correct partial
response. Note it is not url encoded. The problem is that I want the post
link.
  String fields =
"fields=gphoto:quotalimit,gphoto:quotacurrent,gphoto:maxPhotosPerAlbum,entry(title,gphoto:numphotos)";
  HttpGet method = new
HttpGet("https://picasaweb.google.com/data/feed/api/user/default?kind=album&v=2.0&";
+ fields);

 If I add the link parm and do not url encode it I get an error. I have run
a bunch of tests and don't remember if it is a 400 or 403 anyway the error
is
     Invalid selector expression at position 135: mismatched character
'<EOF>' expecting '''
  String fields =
"fields=gphoto:quotalimit,gphoto:quotacurrent,gphoto:maxPhotosPerAlbum,entry(title,gphoto:numphotos,
link[@rel='http://schemas.google.com/g/2005#post'](@href))";
  HttpGet method = new
HttpGet("https://picasaweb.google.com/data/feed/api/user/default?kind=album&v=2.0&";
+ fields);


 If I add the link parm and  url encode it I get a 200 response indicating
OK, but it seems to ignore the fields parm and I get the full response not
the partial...

       HttpGet method = new
HttpGet("https://picasaweb.google.com/data/feed/api/user/default?kind=album&v=2.0&";
+ fields);

       String fields = null;

        try {
fields =
URLEncoder.encode("fields=gphoto:quotalimit,gphoto:quotacurrent,gphoto:maxPhotosPerAlbum,entry(title,gphoto:numphotos,
link[@rel='http://schemas.google.com/g/2005#post'](@href))", "UTF-8");
} catch (UnsupportedEncodingException e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
}
        HttpGet method = new
HttpGet("https://picasaweb.google.com/data/feed/api/user/default?kind=album&v=2.0&";
+ fields);


  I would like to get the partial response working, any help will be
appreciated.
 Thanks

-- 
You received this message because you are subscribed to the Google Groups 
"Google Picasa Web Albums API" 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/google-picasa-data-api?hl=en.

Reply via email to