diff --git a/Swagger.Net/Application/SwaggerUiConfig.cs b/Swagger.Net/Application/SwaggerUiConfig.cs index 7b820dd7..64b58369 100644 --- a/Swagger.Net/Application/SwaggerUiConfig.cs +++ b/Swagger.Net/Application/SwaggerUiConfig.cs @@ -44,6 +44,7 @@ public SwaggerUiConfig(IEnumerable discoveryPaths, Func additionalQueryStringParams = null) { _templateParams["%(OAuth2Enabled)"] = "true"; @@ -191,6 +193,7 @@ public void EnableOAuth2Support( _templateParams["%(OAuth2Realm)"] = realm; _templateParams["%(OAuth2AppName)"] = appName; _templateParams["%(OAuth2ScopeSeparator)"] = scopeSeperator; + _templateParams["%(UsePkceWithAuthorizationCodeGrant)"] = usePkce ? "true" : "false"; if (additionalQueryStringParams != null) _templateParams["%(OAuth2AdditionalQueryStringParams)"] = JsonConvert.SerializeObject(additionalQueryStringParams); @@ -233,4 +236,4 @@ public enum DefaultModelRender Model, Example } -} \ No newline at end of file +}