Appearance
On after sign in
You can use this event to run custom logic after a user successfully signs in. For example, you could update the user's last login time, send a welcome back email, record a sign in for analytics, or sync the user's information with other systems.
Interface actions that fire the
On after sign in eventExample Potential Use Cases
- Update a
lastSeenAtcolumn for the user - Send analytics/CRM identify/track events (Segment, Amplitude, HubSpot)
- Sync user metadata with external systems (e.g., Stripe customer id)
Event data
| Display Key | Example Value | Description |
|---|---|---|
| user | { id: "b20fd6fd-...", email: "user@example.com", emailVerified: true } | The authenticated user object. |
Example payload
json
{
"user": {
"id": "b20fd6fd-aa0a-44c2-8429-2e39cc4d59b4",
"email": "user@example.com",
"name": "",
"image": null,
"emailVerified": true,
"roles": [],
"createdAt": "2024-05-29T10:15:00.123Z",
"updatedAt": "2024-05-29T10:15:00.123Z"
}
}
