Skip to main content

RestClient

Implements

  • unknown

Index

Constructors

constructor

Properties

publicclient

client: AccountsClient

Methods

publicaddEmail

  • addEmail(newEmail: string, customHeaders?: object): Promise<void>
  • Parameters

    • newEmail: string
    • optionalcustomHeaders: object

    Returns Promise<void>

publicauthFetch

  • authFetch(route: string, args: object, customHeaders?: object): Promise<any>
  • Parameters

    • route: string
    • args: object
    • customHeaders: object = {}

    Returns Promise<any>

publicauthenticateWithService

  • authenticateWithService(provider: string, data: any, customHeaders?: object): Promise<boolean>
  • Parameters

    • provider: string
    • data: any
    • optionalcustomHeaders: object

    Returns Promise<boolean>

publicchangePassword

  • changePassword(oldPassword: string, newPassword: string, customHeaders?: object): Promise<void>
  • Parameters

    • oldPassword: string
    • newPassword: string
    • optionalcustomHeaders: object

    Returns Promise<void>

publiccreateUser

  • createUser(user: CreateUser, customHeaders?: object): Promise<CreateUserResult>
  • Parameters

    • user: CreateUser
    • optionalcustomHeaders: object

    Returns Promise<CreateUserResult>

publicfetch

  • fetch(route: string, args: object, customHeaders?: object): Promise<any>
  • Parameters

    • route: string
    • args: object
    • customHeaders: object = {}

    Returns Promise<any>

publicgetTwoFactorSecret

  • getTwoFactorSecret(customHeaders?: object): Promise<any>
  • Parameters

    • optionalcustomHeaders: object

    Returns Promise<any>

publicgetUser

  • getUser(customHeaders?: object): Promise<User>
  • Parameters

    • optionalcustomHeaders: object

    Returns Promise<User>

publicimpersonate

  • impersonate(accessToken: string, impersonated: ImpersonationUserIdentity, customHeaders?: object): Promise<ImpersonationResult>
  • Parameters

    • accessToken: string
    • impersonated: ImpersonationUserIdentity
    • optionalcustomHeaders: object

    Returns Promise<ImpersonationResult>

publicloginWithService

  • loginWithService(provider: string, data: any, customHeaders?: object): Promise<LoginResult>
  • Parameters

    • provider: string
    • data: any
    • optionalcustomHeaders: object

    Returns Promise<LoginResult>

publiclogout

  • logout(customHeaders?: object): Promise<void>
  • Parameters

    • optionalcustomHeaders: object

    Returns Promise<void>

publicrefreshTokens

  • refreshTokens(accessToken: string, refreshToken: string, customHeaders?: object): Promise<LoginResult>
  • Parameters

    • accessToken: string
    • refreshToken: string
    • optionalcustomHeaders: object

    Returns Promise<LoginResult>

publicrequestMagicLinkEmail

  • requestMagicLinkEmail(email: string, customHeaders?: object): Promise<void>
  • Parameters

    • email: string
    • optionalcustomHeaders: object

    Returns Promise<void>

publicresetPassword

  • resetPassword(token: string, newPassword: string, customHeaders?: object): Promise<any>
  • Parameters

    • token: string
    • newPassword: string
    • optionalcustomHeaders: object

    Returns Promise<any>

publicsendResetPasswordEmail

  • sendResetPasswordEmail(email: string, customHeaders?: object): Promise<void>
  • Parameters

    • email: string
    • optionalcustomHeaders: object

    Returns Promise<void>

publicsendVerificationEmail

  • sendVerificationEmail(email: string, customHeaders?: object): Promise<void>
  • Parameters

    • email: string
    • optionalcustomHeaders: object

    Returns Promise<void>

publictwoFactorSet

  • twoFactorSet(secret: any, code: string, customHeaders?: object): Promise<void>
  • Parameters

    • secret: any
    • code: string
    • optionalcustomHeaders: object

    Returns Promise<void>

publictwoFactorUnset

  • twoFactorUnset(code: string, customHeaders?: object): Promise<void>
  • Parameters

    • code: string
    • optionalcustomHeaders: object

    Returns Promise<void>

publicverifyEmail

  • verifyEmail(token: string, customHeaders?: object): Promise<void>
  • Parameters

    • token: string
    • optionalcustomHeaders: object

    Returns Promise<void>