I need to pass the following URL:
https://api.softlayer.com/rest/v3/SoftLayer_Account/getVirtualGuests?objectFilter={"virtualGuests":{"hostname":{"operation":"hostnameTest"}}}
I tried by different ways, but it doesn't work, this is part of my code:
System.out.println(
given().
when().get("https://api.softlayer.com/rest/v3/SoftLayer_Account/getVirtualGuests?objectFilter={\"virtualGuests\":{\"hostname\":{\"operation\":\"hostnameTest\"}}}").asString());
}
Exception:
java.lang.IllegalArgumentException: Invalid number of path parameters. Expected 1, was 0. Undefined path parameters are: "virtualGuests":{"hostname":{"operation":"hostnameTest".
According to the exception, I think I should need to use path parameters, I tried with that but I didn't have success.
Also, I tried to replace { with character escape code %7B.
Any ideas? Thanks in advance