User Events

The User Event object

  • Standard

  • Webhook failure

{
  "date": "2018-08-07T09:54:34.183123Z",
  "auth_type": "password",
  "id": "AWUTz0naD6KwGSiAAIMN",
  "type": "signup",
  "user_id": "AWUTz0JBD6KwGSiAAIMH",
  "profile_id": "121146661725694",
  "login_time": "2018-08-07T09:54:34.183123Z",
  "client_id": "sg48CdAYohRPeRWZ9j1H",
  "provider": "password",
  "device": "desktop",
  "origin": "www.example.fr/login",
  "ip": "127.0.0.1",
  "user_agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 10_3_3 like Mac OS X) AppleWebKit/603.3.8 (KHTML, like Gecko) Mobile/14G60"
}
{
  "date": "2022-05-07T09:54:34.183123Z",
  "auth_type": "password",
  "id": "AWUTz0..6KwGSiAAIMN",
  "type": "post_event_failure",
  "failed_hook_user_event_type": "signup",
  "failed_hook_key": "a_post_event_webhook",
  "failed_hook_error_code": "webhook_host_unreachable",
  "failed_hook_attempts": 3,
  "failed_hook_http_status": "404",
  "user_id": "AWUTz0JBD6KwGSiAAIMH",
  "profile_id": "121146661725694",
  "login_time": "2018-08-07T09:54:34.183123Z",
  "client_id": "sg48CdAYohRPeRWZ9j1H",
  "provider": "password",
  "device": "desktop",
  "origin": "www.example.fr/login",
  "ip": "127.0.0.1",
  "user_agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 10_3_3 like Mac OS X) AppleWebKit/603.3.8 (KHTML, like Gecko) Mobile/14G60"
}

User Event Fields

Name Description

date

The date on which the event occurred.

auth_type

The type of authentication used.

options
  • password

  • phone_number_password

  • magic_link

  • sms

  • external

  • refresh

  • login_as

  • third_party

  • webauthn

id

User event id.

type

User event type.

See User Event Types for more details.

user_id

The ReachFive User ID.

profile_id

The provider profile ID. For example, the facebook ID if facebook is the provider.

login_time

The time at which the event occurred.

client_id

Client id used.

provider

The provider. This is often a social login provider. If a standard login is used, password is the displayed value.

device

The user’s device.

This is taken directly the HTTP request header. See here for more on the User-Agent request header (where the device field comes from).

origin

Free text parameter describing the source of the login (for reporting purposes only). You can influence this value this by using a request parameter such as <url>?origin=<origin>.

This is taken directly the HTTP request header. See here for more on the Origin request header.

ip

User IP address.

This is taken directly the HTTP request header. See here for more on the X-Forwarded-For request header.

user_agent

Web user agent.

This is taken directly the HTTP request header. See here for more on the User-Agent request header. You can influence the values in the user_agent by using your software library.

Format: User-Agent: <product> / <product-version> <comment>

where product could be your app name such as TheApp and comment could hold your domain such as fr.example.

Example: User-Agent: TheApp/2.1 (fr.TheApp; build:742; iOS 14.7.1) Alamofire/4.9.1

failed_hook_key

The unique webhook key.

failed_hook_http_status

The http status that is returned.

This is not always returned.

failed_hook_error_code

The specific error code for the failure.

possible values
  • webhook_host_unreachable

  • webhook_invalid_response

  • server_error

failed_hook_user_event_type

The user event for which the webhook was triggered.

failed_hook_attempts

The number of retry attempts.

User Event Types

The table below describes the types of events that occur under the type parameter in the User Event object.

Name Description

login

Emitted after a successful authentication.

signup

Emitted after a successful signup.

managed_user_created

Emitted after a new user is successfully created through the Management API.

unlink

Emitted after a successful unlink identity.

email_updated

Emitted after a successful email update.

phone_number_updated

Emitted after a successful phone number update.

phone_number_verified

Emitted after a successful phone number verification.

password_reset_requested

Emitted after a successful password reset request.

password_changed

Emitted after a successful password change.

password_reset

Emitted after a successful password reset process.

profile_compromised

Emitted when the IFP module detects a compromised profile.

otp_sent

Emitted after a one-time password (otp) is successfully sent (via sms or email) for verification.

This includes otps for Two-factor authentication (2FA) flows.

login_not_matching_password

Emitted after an unsuccessful login attempt due to the password not matching.

login_matching_password

Emitted after a successful login via the /password/login call.

user_updated

Emitted after a successful user update.

user_deleted

Emitted after a successful user deletion.

We retain the user_deleted event type for a certain period of time after a user profile is deleted.

user_updated_by_merge

Emitted after a successful merge (for the updated user).

user_deleted_by_merge

Emitted after a successful merge (for the deleted user).

user_suspended

Emitted after a successful user account suspension.

user_unsuspended

Emitted after a successful user account unsuspension.

login_successful_suspended_account

Emitted after an unsuccessful login attempt on a suspended account with the correct credentials.

email_verified

Emitted after a successful email verification.

phone_number_verified

Emitted after a successful mobile number verification.

user_created

Emitted after successfully creating a new Lite profile.

authorization_refused

Emitted after an unsuccessful authorization attempt.

authorization_deleted

Emitted after authorization was deleted.

authorization_granted

Emitted after authorization was successfully granted.

lite_merged_into_managed

Emitted after a lite profile was succesfully merged into a managed profile.

login_2nd_step

Emitted after the user has successfully logged in using the Two-factor authentication (2FA) flow.

WEBHOOK FAILURES

pre_event_failure

Emitted when a failure occurred in the pre-event webhook.

Currently, you can only set up PubSub hooks to trigger based on this event. It’s not possible on standard pre/post event webhooks.

post_event_failure

Emitted when a failure occurred in the post-event webhook.

Currently, you can only set up PubSub hooks to trigger based on this event. It’s not possible on standard pre/post event webhooks.

MFA EVENTS

mfa_phone_number_deleted

Emitted after an MFA credential (phone number) is deleted.

mfa_email_deleted

Emitted after an MFA credential (email) is deleted.

mfa_email_start_registration

Emitted after an email is used to start the MFA registration process.

mfa_email_verify_registration

Emitted after an email has been verified as an MFA credential.

mfa_phone_number_verify_registration

Emitted after a phone number is used to start the MFA registration process.

mfa_phone_number_verify_registration

Emitted after a phone number has been verified as an MFA credential.

GUEST EVENTS

login_invalid_identifier_format

Emitted after an unsuccessful login due to the identifier format.

login_unknown_identifier

Emitted after an unsuccessful login attempt due to an unknown identifier.

signup_invalid_email_format

Emitted after an unsuccessful signup attempt due to an invalid email format.

signup_not_compliant_password

Emitted after an unsuccessful signup attempt because the password was not compliant.