Home > Mobile >  Why does postman substitute characters in my get request string?
Why does postman substitute characters in my get request string?

Time:12-23

I am making a get request through postman enter image description here

then select the value and right click the value chose EncodeURIComponent enter image description here

then you will get encoded parameter

enter image description here

Reference: Picture of a non encoded url in postman

You can select the text and right click it to get the option to encode the value.

Picture of the context menu in Postman to encode values

This will encode the value properly and it will be received in your C# application as expected.

Picture of an encoded url in postman

CodePudding user response:

As people mentioned in other answers, it's encoding issue. Alternatively you could use [FromBody] and then just put your string in body request part of postman

public IHttpActionResult GetDescifrarCusResponse( [FromBody] string cus = null ) {
        return Ok (ExecGetDescifrarCusResponse(cus));
        //return Ok();
    }
  • Related