Azure / api-management-developer-portal

Developer portal provided by the Azure API Management service.
MIT License
489 stars 319 forks source link

Azure Portal "Try It Feature" No Url Encoding of Parameters for Get Request #635

Closed hebe0022 closed 4 years ago

hebe0022 commented 4 years ago

Bug description

When testing an API in the Portal with the TryIt Feature. The values entered for parameters are not encoded. Get Requests fail when using reserved characters like &.

Reproduction steps

  1. Go to the developer portal
  2. Click on an API
  3. Select a Get request with a parameter.
  4. Add a parameter.
  5. Enter a value with the & character.

Expected behavior

Url Encode Values Automatically or checkbox to allow encoding

Is your portal managed or self-hosted?

Managed

Environment

Additional context

EX: P&T will yield /qac/factories/search?name=P&T&country=USA [does not work]

and

EX: P%16T will yield /qac/factories/search?name=P%16T&country=USA [Works obviously]

image

Is this by Design and is there a way to turn on UrlEncoding in the portal automaticly I do not see a way to do so.

azaslonov commented 4 years ago

Hi @hebe0022, thanks for reporting the issue, we'll fix this.

ygrik commented 4 years ago

It was fixed in managed with the latest release