You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Unable to set message body as data-urlencode in HTTP POST
It was possible to add rest request parameter as query string or plain text body.
However, I have requirement to pass body as url encoded data, which was not possible.
I was able to make HTTP POST call using Postman
Curl command allows you to pass basic data using parameter --data and to pass url encoded data using parameter --data-urlencode
Postman code snipped shows use of parameter --data-urlencode
Describe the bug
Unable to set message body as data-urlencode in HTTP POST
It was possible to add rest request parameter as query string or plain text body.
However, I have requirement to pass body as url encoded data, which was not possible.
To Reproduce
restRequest.AddOrUpdateHeader("Authorization", "Basic basc64encodedUsernameColonPassword");
restRequest.AddOrUpdateParameter("queryStringParameter1", "queryStringParameterValue1", ParameterType.QueryString);
restRequest.AddOrUpdateParameter("bodyContent", ParameterType.RequestBody, true);
I was able to make HTTP POST call using Postman
Curl command allows you to pass basic data using parameter --data and to pass url encoded data using parameter --data-urlencode
Postman code snipped shows use of parameter --data-urlencode
curl --location 'https://server:port/export?queryParameter1=queryParameterValue1'
--header 'Authorization: Basic basc64encodedUsernameColonPassword'
--data-urlencode 'some search query with some condition'
Expected behavior
A valid response containing json data was expected, however, I received message saying no data found or empty search.
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: