Description
Issue Description
I can see support for query parameters were added to the RestClient as per issue #172 however they were only added to some calls but not all. Is there a reason for that? It seems misleading that the library accepts query parameters for other calls however simply drops them without error or warning.
As an example, when trying to query googleapi
with a post request, it requires the apikey
to be supplied as a query parameter. This currently seems to not be possible through the RestClient unless I specify the parameters as part of the URL.
Expected behaviour
Query parameters should not be dropped from any request or the compiler should complain if they are not supported.
Actual behaviour
create
, update
and replace
requests do not honor the query parameters however they accept it without compilation errors.
Steps to reproduce
- Make the following request
const client = new rm.RestClient('', 'https://test.com')
const options = {
queryParameters: {
lang: "en",
terms: ["foo bar", 4.2, "baz"]
}
}
const response = await client.create('path', null, options)
- Notice that the query parameters are missing from the request (however you can introspect it)