How to Pass Object Parameter in http Get Request in visual studio

Viewed 10602

I have this https://www.bookstone.com/api/rest/bookshop/gettotal?products=[{\"PRICE\":39.95,\"RECIPIENT\":{\"ZIPCODE\":\"11779\"},\"CODE\":\"F1-509\"}] This https works fine in Postman and I get the result.

{
"SERVICECHARGE": 14.99,
"SUBTOTAL": 39.95,
"TAX": 0,
"ORDERTOTAL": 54.94,
"ORDERNO": 0,
}

But in visual studio it dose not work.

var url = "https://www.bookstone.com/api/rest/bookshop/gettotal?products=[{\"PRICE\":39.95,\"RECIPIENT\":{\"ZIPCODE\":\"11779\"},\"CODE\":\"F1-509\"}]";

var response = await client.GetAsync(url);

Any ideas please?

1 Answers
Related