Skip to content

UnsupportedApiVersion when the request is redirected from HTTP (via 302). #123

@enihcam

Description

@enihcam

The redirect logic is
app.UseRewriter(new RewriteOptions().AddRedirectToHttps(StatusCodes.Status302Found, 44346));

Then when I accessed http://localhost:80/subscriptions/12345?api-version=2.0, I got:
{ "Error": { "Code": "UnsupportedApiVersion", "Message": "The HTTP resource that matches the request URI 'https://localhost:44346/subscriptions/12345?api-version=2.0' does not support the API version '2.0'." } }

But directly access to https://localhost:44346/subscriptions/12345?api-version=2.0 worked fine.

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions