Android Mobile SDK: Notify Login Event

“Notify login event” is used to indicate that the contact has logged in. This event notifies, via the Mobile SDK, when a user logs in to the website using Connectif.sendLogin().

 

How to use it

The login notification uses the method Connectif.sendLogin(email: String), where we include the email property of the user logging in.

Attribute Definition Required Limitations
email

Email of the user logging in.

Yes

- A valid email must contain a username, followed by @, a domain, and an extension without spaces or special characters.

- Maximum 200 characters.

This type of event automatically collects the following information:

  • Operating system: Android or iOS.
  • App version.
  • Operating system version.
  • Connectif SDK version.

 

Example

The notification will look like this:

Connectif.sendLogin("useremail@example.com")

 

Callbacks (Optional)

If you want feedback on potential errors when sending events, you can add an EventCallbacks when using our method.

 object : EventCallbacks {
    override fun onSuccess() {
        //Handle success
    }
    override fun onError(message: String?) {
         //Handle error
    }
}

 

 

Congratulations!
You've reached the end of the lesson.

 

Still have questions?
Remember that you can reach our Connectif specialists by opening a support ticket through the “Help” button on your dashboard.


Keep learning!

To take full advantage of your Connectif account, we recommend continuing with the following articles:

Was this article helpful?
0 out of 0 found this helpful