DotNetOpenAuth.OAuth2.AuthorizationServer.ApproveAuthorizationRequest C# (CSharp) Method

ApproveAuthorizationRequest() public method

Approves an authorization request and sends an HTTP response to the user agent to redirect the user back to the Client.
public ApproveAuthorizationRequest ( DotNetOpenAuth.OAuth2.Messages.EndUserAuthorizationRequest authorizationRequest, string userName, IEnumerable scopes = null, Uri callback = null ) : void
authorizationRequest DotNetOpenAuth.OAuth2.Messages.EndUserAuthorizationRequest The authorization request to approve.
userName string The username of the account that approved the request (or whose data will be accessed by the client).
scopes IEnumerable The scope of access the client should be granted. If null, all scopes in the original request will be granted.
callback System.Uri The Client callback URL to use when formulating the redirect to send the user agent back to the Client.
return void
		public void ApproveAuthorizationRequest(EndUserAuthorizationRequest authorizationRequest, string userName, IEnumerable<string> scopes = null, Uri callback = null) {
			Requires.NotNull(authorizationRequest, "authorizationRequest");

			var response = this.PrepareApproveAuthorizationRequest(authorizationRequest, userName, scopes, callback);
			this.Channel.Respond(response);
		}