0

I am trying to retrieve a product using the .Net client library.

The product in question has a slash in its id: online:en:GB:AKM274/IX_SS

using the Google APIs explorer, I use Fiddler to see where the request is sent:

https://content.googleapis.com/content/v2/6081032/products/online%3Aen%3AGB%3AAKM274%2FIX_SS

When I submit the request via the client library:

service.Products.Get((ulong) 6081032, "online:en:GB:AKM274/IX_SS").Execute();

It goes to:

https://www.googleapis.com/content/v2/6081032/products/online%3Aen%3AGB%3AAKM274/IX_SS

which 404s

When I try to urlencode the last slash:

service.Products.Get((ulong) 6081032, "online:en:GB:AKM274%2FIX_SS").Execute();

it sends the request to:

https://content.googleapis.com/content/v2/6081032/products/online%3Aen%3AGB%3AAKM274%252FIX_SS

as you can see, it encodes the %!

what should I use to encode my product codes with slashes in???

it also appears to happen on products.delete and inventory.set

thanks,

vince

Vince Lee
  • 89
  • 11
  • In what environment do you run? We had a similar issue in the past that occurred in .NET 4.0 if I remember correctly, take a look in https://code.google.com/p/google-api-dotnet-client/issues/detail?id=454 for more details. Feel free to update the issue there as well. – peleyal Mar 05 '15 at 17:56
  • 4.0 - its a bug in the client library code: https://groups.google.com/forum/embed/?place=forum/google-content-api-for-shopping&showsearch=true&showpopout=true&parenturl=https%3A%2F%2Fdevelopers.google.com%2Fshopping-content%2Fforum%2Findex%23!topic%2Fgoogle-content-api-for-shopping%2Fx8_B3PUEv20#!topic/google-content-api-for-shopping/Le_Xi1czCHc – Vince Lee Mar 07 '15 at 10:00
  • Can you upgrade to 4.5? – peleyal Mar 08 '15 at 23:02

0 Answers0