/// <summary>
        /// Builds the full Uri for starting the OpenID Connect authentication / authorization process against the server
        /// using browser-based authentication / authorization.
        /// </summary>
        /// <param name="config">OAuth / OpenID Connect configuration of the client</param>
        /// <param name="responseType">OIDC response type</param>
        /// <param name="args"><see cref="BrowserBasedAuthorizationArgs"/> specifying arguments for the process to start</param>
        /// <param name="query">Query parameters to populate</param>
        /// <returns><see cref="Uri"/> to use for starting the process</returns>
        private static void BuildAuthorizationUriQuery(
            IBrowserBasedAuthorizationConfig config,
            string responseType,
            BrowserBasedAuthorizationArgs args,
            NameValueCollection query)
        {
            query["response_type"]  = responseType;
            query["client_id"]      = config.ClientID;
            query["showRememberMe"] = config.ShowRememberMe ? "true" : "false";

            if (config.RedirectUri != null)
            {
                query["redirect_uri"] = config.RedirectUri;
            }

            if (config.Scope != null)
            {
                query["scope"] = config.Scope;
            }

            if (args != null && args.State != null)
            {
                query["state"] = args.State;
            }

            if (args != null && args.Nonce != null)
            {
                query["nonce"] = args.Nonce;
            }
        }
 /// <summary>
 /// Builds the full Uri for starting the OpenID Connect authentication / authorization process against the server
 /// using browser-based authentication / authorization.
 /// </summary>
 /// <param name="config">OAuth / OpenID Connect configuration of the client</param>
 /// <param name="responseType">OIDC response type</param>
 /// <param name="args"><see cref="BrowserBasedAuthorizationArgs"/> specifying arguments for the process to start</param>
 /// <returns><see cref="Uri"/> to use for starting the process</returns>
 public static Uri BuildAuthorizationUri(IBrowserBasedAuthorizationConfig config, string responseType, BrowserBasedAuthorizationArgs args)
 {
     return(BuildAuthorizationUriInternal(config, responseType, args, BuildAuthorizationUriQuery));
 }