Show / Hide Table of Contents

Class AccountController

Inheritance
object
ControllerBase
AbpControllerBase
AccountController
Implements
IAvoidDuplicateCrossCuttingConcerns
IAccountAppService
IApplicationService
IRemoteService
Inherited Members
AbpControllerBase.CreateLocalizer()
AbpControllerBase.ValidateModel()
AbpControllerBase.LazyServiceProvider
AbpControllerBase.UnitOfWorkManager
AbpControllerBase.ObjectMapperContext
AbpControllerBase.ObjectMapper
AbpControllerBase.GuidGenerator
AbpControllerBase.LoggerFactory
AbpControllerBase.Logger
AbpControllerBase.CurrentUser
AbpControllerBase.CurrentTenant
AbpControllerBase.AuthorizationService
AbpControllerBase.CurrentUnitOfWork
AbpControllerBase.Clock
AbpControllerBase.ModelValidator
AbpControllerBase.FeatureChecker
AbpControllerBase.StringLocalizerFactory
AbpControllerBase.L
AbpControllerBase.LocalizationResource
AbpControllerBase.AppliedCrossCuttingConcerns
ControllerBase.StatusCode(int)
ControllerBase.StatusCode(int, object)
ControllerBase.Content(string)
ControllerBase.Content(string, string)
ControllerBase.Content(string, string, Encoding)
ControllerBase.Content(string, MediaTypeHeaderValue)
ControllerBase.NoContent()
ControllerBase.Ok()
ControllerBase.Ok(object)
ControllerBase.Redirect(string)
ControllerBase.RedirectPermanent(string)
ControllerBase.RedirectPreserveMethod(string)
ControllerBase.RedirectPermanentPreserveMethod(string)
ControllerBase.LocalRedirect(string)
ControllerBase.LocalRedirectPermanent(string)
ControllerBase.LocalRedirectPreserveMethod(string)
ControllerBase.LocalRedirectPermanentPreserveMethod(string)
ControllerBase.RedirectToAction()
ControllerBase.RedirectToAction(string)
ControllerBase.RedirectToAction(string, object)
ControllerBase.RedirectToAction(string, string)
ControllerBase.RedirectToAction(string, string, object)
ControllerBase.RedirectToAction(string, string, string)
ControllerBase.RedirectToAction(string, string, object, string)
ControllerBase.RedirectToActionPreserveMethod(string, string, object, string)
ControllerBase.RedirectToActionPermanent(string)
ControllerBase.RedirectToActionPermanent(string, object)
ControllerBase.RedirectToActionPermanent(string, string)
ControllerBase.RedirectToActionPermanent(string, string, string)
ControllerBase.RedirectToActionPermanent(string, string, object)
ControllerBase.RedirectToActionPermanent(string, string, object, string)
ControllerBase.RedirectToActionPermanentPreserveMethod(string, string, object, string)
ControllerBase.RedirectToRoute(string)
ControllerBase.RedirectToRoute(object)
ControllerBase.RedirectToRoute(string, object)
ControllerBase.RedirectToRoute(string, string)
ControllerBase.RedirectToRoute(string, object, string)
ControllerBase.RedirectToRoutePreserveMethod(string, object, string)
ControllerBase.RedirectToRoutePermanent(string)
ControllerBase.RedirectToRoutePermanent(object)
ControllerBase.RedirectToRoutePermanent(string, object)
ControllerBase.RedirectToRoutePermanent(string, string)
ControllerBase.RedirectToRoutePermanent(string, object, string)
ControllerBase.RedirectToRoutePermanentPreserveMethod(string, object, string)
ControllerBase.RedirectToPage(string)
ControllerBase.RedirectToPage(string, object)
ControllerBase.RedirectToPage(string, string)
ControllerBase.RedirectToPage(string, string, object)
ControllerBase.RedirectToPage(string, string, string)
ControllerBase.RedirectToPage(string, string, object, string)
ControllerBase.RedirectToPagePermanent(string)
ControllerBase.RedirectToPagePermanent(string, object)
ControllerBase.RedirectToPagePermanent(string, string)
ControllerBase.RedirectToPagePermanent(string, string, string)
ControllerBase.RedirectToPagePermanent(string, string, object, string)
ControllerBase.RedirectToPagePreserveMethod(string, string, object, string)
ControllerBase.RedirectToPagePermanentPreserveMethod(string, string, object, string)
ControllerBase.File(byte[], string)
ControllerBase.File(byte[], string, bool)
ControllerBase.File(byte[], string, string)
ControllerBase.File(byte[], string, string, bool)
ControllerBase.File(byte[], string, DateTimeOffset?, EntityTagHeaderValue)
ControllerBase.File(byte[], string, DateTimeOffset?, EntityTagHeaderValue, bool)
ControllerBase.File(byte[], string, string, DateTimeOffset?, EntityTagHeaderValue)
ControllerBase.File(byte[], string, string, DateTimeOffset?, EntityTagHeaderValue, bool)
ControllerBase.File(Stream, string)
ControllerBase.File(Stream, string, bool)
ControllerBase.File(Stream, string, string)
ControllerBase.File(Stream, string, string, bool)
ControllerBase.File(Stream, string, DateTimeOffset?, EntityTagHeaderValue)
ControllerBase.File(Stream, string, DateTimeOffset?, EntityTagHeaderValue, bool)
ControllerBase.File(Stream, string, string, DateTimeOffset?, EntityTagHeaderValue)
ControllerBase.File(Stream, string, string, DateTimeOffset?, EntityTagHeaderValue, bool)
ControllerBase.File(string, string)
ControllerBase.File(string, string, bool)
ControllerBase.File(string, string, string)
ControllerBase.File(string, string, string, bool)
ControllerBase.File(string, string, DateTimeOffset?, EntityTagHeaderValue)
ControllerBase.File(string, string, DateTimeOffset?, EntityTagHeaderValue, bool)
ControllerBase.File(string, string, string, DateTimeOffset?, EntityTagHeaderValue)
ControllerBase.File(string, string, string, DateTimeOffset?, EntityTagHeaderValue, bool)
ControllerBase.PhysicalFile(string, string)
ControllerBase.PhysicalFile(string, string, bool)
ControllerBase.PhysicalFile(string, string, string)
ControllerBase.PhysicalFile(string, string, string, bool)
ControllerBase.PhysicalFile(string, string, DateTimeOffset?, EntityTagHeaderValue)
ControllerBase.PhysicalFile(string, string, DateTimeOffset?, EntityTagHeaderValue, bool)
ControllerBase.PhysicalFile(string, string, string, DateTimeOffset?, EntityTagHeaderValue)
ControllerBase.PhysicalFile(string, string, string, DateTimeOffset?, EntityTagHeaderValue, bool)
ControllerBase.Unauthorized()
ControllerBase.Unauthorized(object)
ControllerBase.NotFound()
ControllerBase.NotFound(object)
ControllerBase.BadRequest()
ControllerBase.BadRequest(object)
ControllerBase.BadRequest(ModelStateDictionary)
ControllerBase.UnprocessableEntity()
ControllerBase.UnprocessableEntity(object)
ControllerBase.UnprocessableEntity(ModelStateDictionary)
ControllerBase.Conflict()
ControllerBase.Conflict(object)
ControllerBase.Conflict(ModelStateDictionary)
ControllerBase.Problem(string, string, int?, string, string)
ControllerBase.Problem(string, string, int?, string, string, IDictionary<string, object>)
ControllerBase.ValidationProblem(ValidationProblemDetails)
ControllerBase.ValidationProblem(ModelStateDictionary)
ControllerBase.ValidationProblem()
ControllerBase.ValidationProblem(string, string, int?, string, string, ModelStateDictionary)
ControllerBase.ValidationProblem(string, string, int?, string, string, ModelStateDictionary, IDictionary<string, object>)
ControllerBase.Created()
ControllerBase.Created(string, object)
ControllerBase.Created(Uri, object)
ControllerBase.CreatedAtAction(string, object)
ControllerBase.CreatedAtAction(string, object, object)
ControllerBase.CreatedAtAction(string, string, object, object)
ControllerBase.CreatedAtRoute(string, object)
ControllerBase.CreatedAtRoute(object, object)
ControllerBase.CreatedAtRoute(string, object, object)
ControllerBase.Accepted()
ControllerBase.Accepted(object)
ControllerBase.Accepted(Uri)
ControllerBase.Accepted(string)
ControllerBase.Accepted(string, object)
ControllerBase.Accepted(Uri, object)
ControllerBase.AcceptedAtAction(string)
ControllerBase.AcceptedAtAction(string, string)
ControllerBase.AcceptedAtAction(string, object)
ControllerBase.AcceptedAtAction(string, string, object)
ControllerBase.AcceptedAtAction(string, object, object)
ControllerBase.AcceptedAtAction(string, string, object, object)
ControllerBase.AcceptedAtRoute(object)
ControllerBase.AcceptedAtRoute(string)
ControllerBase.AcceptedAtRoute(string, object)
ControllerBase.AcceptedAtRoute(object, object)
ControllerBase.AcceptedAtRoute(string, object, object)
ControllerBase.Challenge()
ControllerBase.Challenge(params string[])
ControllerBase.Challenge(AuthenticationProperties)
ControllerBase.Challenge(AuthenticationProperties, params string[])
ControllerBase.Forbid()
ControllerBase.Forbid(params string[])
ControllerBase.Forbid(AuthenticationProperties)
ControllerBase.Forbid(AuthenticationProperties, params string[])
ControllerBase.SignIn(ClaimsPrincipal)
ControllerBase.SignIn(ClaimsPrincipal, string)
ControllerBase.SignIn(ClaimsPrincipal, AuthenticationProperties)
ControllerBase.SignIn(ClaimsPrincipal, AuthenticationProperties, string)
ControllerBase.SignOut()
ControllerBase.SignOut(AuthenticationProperties)
ControllerBase.SignOut(params string[])
ControllerBase.SignOut(AuthenticationProperties, params string[])
ControllerBase.TryUpdateModelAsync<TModel>(TModel)
ControllerBase.TryUpdateModelAsync<TModel>(TModel, string)
ControllerBase.TryUpdateModelAsync<TModel>(TModel, string, IValueProvider)
ControllerBase.TryUpdateModelAsync<TModel>(TModel, string, params Expression<Func<TModel, object>>[])
ControllerBase.TryUpdateModelAsync<TModel>(TModel, string, Func<ModelMetadata, bool>)
ControllerBase.TryUpdateModelAsync<TModel>(TModel, string, IValueProvider, params Expression<Func<TModel, object>>[])
ControllerBase.TryUpdateModelAsync<TModel>(TModel, string, IValueProvider, Func<ModelMetadata, bool>)
ControllerBase.TryUpdateModelAsync(object, Type, string)
ControllerBase.TryUpdateModelAsync(object, Type, string, IValueProvider, Func<ModelMetadata, bool>)
ControllerBase.TryValidateModel(object)
ControllerBase.TryValidateModel(object, string)
ControllerBase.HttpContext
ControllerBase.Request
ControllerBase.Response
ControllerBase.RouteData
ControllerBase.ModelState
ControllerBase.ControllerContext
ControllerBase.MetadataProvider
ControllerBase.ModelBinderFactory
ControllerBase.Url
ControllerBase.ObjectValidator
ControllerBase.ProblemDetailsFactory
ControllerBase.User
ControllerBase.Empty
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Volo.Abp.Account
Assembly: Volo.Abp.Account.HttpApi.dll
Syntax
[RemoteService(true, Name = "AbpAccount")]
[Area("account")]
[Route("api/account")]
public class AccountController : AbpControllerBase, IAvoidDuplicateCrossCuttingConcerns, IAccountAppService, IApplicationService, IRemoteService

Constructors

AccountController(IAccountAppService)

Declaration
public AccountController(IAccountAppService accountAppService)
Parameters
Type Name Description
IAccountAppService accountAppService

AccountController(IAccountAppService, IVirtualFileProvider, IOptionsSnapshot<reCAPTCHAOptions>, ISettingProvider)

Declaration
public AccountController(IAccountAppService accountAppService, IVirtualFileProvider virtualFileProvider, IOptionsSnapshot<reCAPTCHAOptions> reCaptchaOptions, ISettingProvider settingProvider)
Parameters
Type Name Description
IAccountAppService accountAppService
IVirtualFileProvider virtualFileProvider
IOptionsSnapshot<reCAPTCHAOptions> reCaptchaOptions
ISettingProvider settingProvider

Fields

DefaultAvatarContent

Declaration
protected static byte[] DefaultAvatarContent
Field Value
Type Description
byte[]

Properties

AccountAppService

Declaration
protected IAccountAppService AccountAppService { get; }
Property Value
Type Description
IAccountAppService

ReCaptchaOptions

Declaration
protected IOptionsSnapshot<reCAPTCHAOptions> ReCaptchaOptions { get; }
Property Value
Type Description
IOptionsSnapshot<reCAPTCHAOptions>

RecaptchaValidatorFactory

Declaration
public IAbpRecaptchaValidatorFactory RecaptchaValidatorFactory { get; set; }
Property Value
Type Description
IAbpRecaptchaValidatorFactory

SettingProvider

Declaration
protected ISettingProvider SettingProvider { get; }
Property Value
Type Description
ISettingProvider

VirtualFileProvider

Declaration
protected IVirtualFileProvider VirtualFileProvider { get; }
Property Value
Type Description
IVirtualFileProvider

Methods

ConfirmEmailAsync(ConfirmEmailInput)

Declaration
[HttpPost]
[Route("confirm-email")]
public virtual Task ConfirmEmailAsync(ConfirmEmailInput input)
Parameters
Type Name Description
ConfirmEmailInput input
Returns
Type Description
Task

ConfirmPhoneNumberAsync(ConfirmPhoneNumberInput)

Declaration
[HttpPost]
[Route("confirm-phone-number")]
public virtual Task ConfirmPhoneNumberAsync(ConfirmPhoneNumberInput input)
Parameters
Type Name Description
ConfirmPhoneNumberInput input
Returns
Type Description
Task

GetAuthenticatorInfoAsync()

Declaration
[HttpGet]
[Route("authenticator-info")]
public virtual Task<AuthenticatorInfoDto> GetAuthenticatorInfoAsync()
Returns
Type Description
Task<AuthenticatorInfoDto>

GetConfirmationStateAsync(Guid)

Declaration
[HttpGet]
[Route("confirmation-state")]
public virtual Task<IdentityUserConfirmationStateDto> GetConfirmationStateAsync(Guid id)
Parameters
Type Name Description
Guid id
Returns
Type Description
Task<IdentityUserConfirmationStateDto>

GetEmailConfirmationCodeLimitAsync(string)

Declaration
[HttpGet]
[Route("email-confirmation-code-limit")]
public virtual Task<EmailConfirmationCodeLimitDto> GetEmailConfirmationCodeLimitAsync(string emailAddress)
Parameters
Type Name Description
string emailAddress
Returns
Type Description
Task<EmailConfirmationCodeLimitDto>

GetProfilePictureAsync(Guid)

Declaration
[HttpGet]
[Route("profile-picture/{id}")]
public virtual Task<ProfilePictureSourceDto> GetProfilePictureAsync(Guid id)
Parameters
Type Name Description
Guid id
Returns
Type Description
Task<ProfilePictureSourceDto>

GetProfilePictureFileAsync(Guid)

Declaration
[HttpGet]
[Route("profile-picture-file/{id}")]
public virtual Task<IRemoteStreamContent> GetProfilePictureFileAsync(Guid id)
Parameters
Type Name Description
Guid id
Returns
Type Description
Task<IRemoteStreamContent>

GetSecurityLogListAsync(GetIdentitySecurityLogListInput)

Declaration
[HttpGet]
[Route("security-logs")]
public virtual Task<PagedResultDto<IdentitySecurityLogDto>> GetSecurityLogListAsync(GetIdentitySecurityLogListInput input)
Parameters
Type Name Description
GetIdentitySecurityLogListInput input
Returns
Type Description
Task<PagedResultDto<IdentitySecurityLogDto>>

GetTwoFactorProvidersAsync(GetTwoFactorProvidersInput)

Declaration
[HttpGet]
[Route("two-factor-providers")]
public virtual Task<List<string>> GetTwoFactorProvidersAsync(GetTwoFactorProvidersInput input)
Parameters
Type Name Description
GetTwoFactorProvidersInput input
Returns
Type Description
Task<List<string>>

HasAuthenticatorAsync()

Declaration
[HttpGet]
[Route("has-authenticator-key")]
public virtual Task<bool> HasAuthenticatorAsync()
Returns
Type Description
Task<bool>

Recaptcha(string)

Declaration
[HttpGet]
[Route("recaptcha-validate")]
public virtual Task Recaptcha(string captchaResponse)
Parameters
Type Name Description
string captchaResponse
Returns
Type Description
Task

RegisterAsync(RegisterDto)

Declaration
[HttpPost]
[Route("register")]
public virtual Task<IdentityUserDto> RegisterAsync(RegisterDto input)
Parameters
Type Name Description
RegisterDto input
Returns
Type Description
Task<IdentityUserDto>

ResetAuthenticatorAsync()

Declaration
[HttpPost]
[Route("reset-authenticator")]
public virtual Task ResetAuthenticatorAsync()
Returns
Type Description
Task

ResetPasswordAsync(ResetPasswordDto)

Declaration
[HttpPost]
[Route("reset-password")]
public virtual Task ResetPasswordAsync(ResetPasswordDto input)
Parameters
Type Name Description
ResetPasswordDto input
Returns
Type Description
Task

SendEmailConfirmationCodeAsync(SendEmailConfirmationCodeDto)

Declaration
[HttpPost]
[Route("send-email-confirmation-code")]
public virtual Task SendEmailConfirmationCodeAsync(SendEmailConfirmationCodeDto input)
Parameters
Type Name Description
SendEmailConfirmationCodeDto input
Returns
Type Description
Task

SendEmailConfirmationTokenAsync(SendEmailConfirmationTokenDto)

Declaration
[HttpPost]
[Route("send-email-confirmation-token")]
public virtual Task SendEmailConfirmationTokenAsync(SendEmailConfirmationTokenDto input)
Parameters
Type Name Description
SendEmailConfirmationTokenDto input
Returns
Type Description
Task

SendPasswordResetCodeAsync(SendPasswordResetCodeDto)

Declaration
[HttpPost]
[Route("send-password-reset-code")]
public virtual Task SendPasswordResetCodeAsync(SendPasswordResetCodeDto input)
Parameters
Type Name Description
SendPasswordResetCodeDto input
Returns
Type Description
Task

SendPhoneNumberConfirmationTokenAsync(SendPhoneNumberConfirmationTokenDto)

Declaration
[HttpPost]
[Route("send-phone-number-confirmation-token")]
public virtual Task SendPhoneNumberConfirmationTokenAsync(SendPhoneNumberConfirmationTokenDto input)
Parameters
Type Name Description
SendPhoneNumberConfirmationTokenDto input
Returns
Type Description
Task

SendTwoFactorCodeAsync(SendTwoFactorCodeInput)

Declaration
[HttpPost]
[Route("send-two-factor-code")]
public virtual Task SendTwoFactorCodeAsync(SendTwoFactorCodeInput input)
Parameters
Type Name Description
SendTwoFactorCodeInput input
Returns
Type Description
Task

SetProfilePictureAsync(ProfilePictureInput)

Declaration
[Authorize]
[HttpPost]
[Route("profile-picture")]
public virtual Task SetProfilePictureAsync(ProfilePictureInput input)
Parameters
Type Name Description
ProfilePictureInput input
Returns
Type Description
Task

UseCaptchaOnRegistration()

Declaration
protected virtual Task<bool> UseCaptchaOnRegistration()
Returns
Type Description
Task<bool>

VerifyAuthenticatorCodeAsync(VerifyAuthenticatorCodeInput)

Declaration
[HttpPost]
[Route("verify-authenticator-code")]
public virtual Task<VerifyAuthenticatorCodeDto> VerifyAuthenticatorCodeAsync(VerifyAuthenticatorCodeInput input)
Parameters
Type Name Description
VerifyAuthenticatorCodeInput input
Returns
Type Description
Task<VerifyAuthenticatorCodeDto>

VerifyEmailConfirmationTokenAsync(VerifyEmailConfirmationTokenInput)

Declaration
[HttpPost]
[Route("verify-email-confirmation-token")]
public virtual Task<bool> VerifyEmailConfirmationTokenAsync(VerifyEmailConfirmationTokenInput input)
Parameters
Type Name Description
VerifyEmailConfirmationTokenInput input
Returns
Type Description
Task<bool>

VerifyPasswordResetTokenAsync(VerifyPasswordResetTokenInput)

Declaration
[HttpPost]
[Route("verify-password-reset-token")]
public virtual Task<bool> VerifyPasswordResetTokenAsync(VerifyPasswordResetTokenInput input)
Parameters
Type Name Description
VerifyPasswordResetTokenInput input
Returns
Type Description
Task<bool>

Implements

IAvoidDuplicateCrossCuttingConcerns
IAccountAppService
IApplicationService
IRemoteService

Extension Methods

AbpObjectExtensions.As<T>(object)
AbpObjectExtensions.To<T>(object)
LockExtensions.Locking(object, Action)
LockExtensions.Locking<TResult>(object, Func<TResult>)
AbpObjectExtensions.If<T>(T, bool, Action<T>)
AbpObjectExtensions.If<T>(T, bool, Func<T, T>)
AbpObjectExtensions.IsIn<T>(T, IEnumerable<T>)
AbpObjectExtensions.IsIn<T>(T, params T[])
AbpQueryableExtensions.OrderByIf<T, TQueryable>(TQueryable, bool, string)
AbpQueryableExtensions.PageBy<T, TQueryable>(TQueryable, int, int)
AbpQueryableExtensions.WhereIf<T, TQueryable>(TQueryable, bool, Expression<Func<T, bool>>)
AbpQueryableExtensions.WhereIf<T, TQueryable>(TQueryable, bool, Expression<Func<T, int, bool>>)
AbpOpenIddictQueryableExtensions.SkipIf<T, TQueryable>(TQueryable, bool, int?)
AbpOpenIddictQueryableExtensions.TakeIf<T, TQueryable>(TQueryable, bool, int?)
LockExtensions.Locking<T>(T, Action<T>)
LockExtensions.Locking<T, TResult>(T, Func<T, TResult>)
In this article
Back to top Powered by ABP.IO Platform