Options
All
  • Public
  • Public/Protected
  • All
Menu

A user that a StitchAppClient is currently authenticated as. Can be retrieved from a StitchAuth or from the result of certain methods.

Hierarchy

  • CoreStitchUser
    • StitchUser

Index

Properties

id

id: string

The String representation of the ID of this Stitch user.

identities

identities: StitchUserIdentity[]

An array of StitchUserIdentity objects representing the identities linked to this user which can be used to log in as this user.

loggedInProviderName

loggedInProviderName: string

The name of the authentication provider used to log in as this user.

loggedInProviderType

loggedInProviderType: string

The type of authentication provider used to log in as this user.

profile

profile: StitchUserProfile

A StitchUserProfile object describing this user.

Optional userType

userType: undefined | string

A string describing the type of this user. (Either server or normal)

Methods

linkUserWithRedirect

  • Links this StitchUser with a new identity, where the identity is resolved via an external OAuth2 login process (e.g. Facebook or Google). This method will redirect the user to the external login page. That external page will redirect the user back to the page specified in the redirect credential. To complete the link, that page will need to handle the redirect by calling {@link StitchAuth.handleRedirectResult()}.

    Parameters

    Returns Promise<void>

linkWithCredential

  • linkWithCredential(credential: StitchCredential): Promise<StitchUser>
  • Links this StitchUser with a new identity, where the identity is defined by the credential specified as a parameter. This will only be successful if this StitchUser is the currently authenticated StitchUser for the client from which it was created.

    Parameters

    • credential: StitchCredential

      The credential to use to link this user to a new identity.

    Returns Promise<StitchUser>

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method

Generated using TypeDoc