Webhook
User Login
Triggered when a user logs in and a session is created
Body·
application/json
- Type: stringenvironment
_id min length:1max length:32Pattern: ^env_requiredThe environment ID where the event occurred
- Type: stringidmin length:1max length:32
Pattern: ^evt_requiredUnique identifier for the webhook event (must be prefixed with "evt_")
- Type: stringenumobjectrequired
The type of object that triggered the webhook
values- Organization
- Connection
- Role
- Directory
- Directory
User - Directory
Group - Permission
- Org
Membership - User
- Type: stringFormat: date-timeoccurred
_at requiredWhen the event occurred (ISO 8601 format)
- Type: stringspec
_version Pattern: ^[0-9]+$requiredThe webhook specification version
- Type: stringenumtyperequired
The event type
values- organization
.created - organization
.updated - organization
.deleted - organization
.sso _created - organization
.sso _deleted
- Type: objectdata
The event payload (structure varies by event type)
- Type: stringdisplay
_name min length:1max length:200Human-readable display name for the event
- Type: stringorganization
_id min length:1max length:32Pattern: ^org_The organization ID (if applicable)
Responses
- 200
Webhook received successfully
Request Example for postuser.login
{
"spec_version": "1",
"id": "evt_102701193859432713",
"type": "user.login",
"object": "User",
"occurred_at": "2025-12-09T12:04:41.781873312Z",
"environment_id": "env_96736846679245078",
"organization_id": "org_102701193188409609",
"data": {
"user": {
"create_time": "2025-12-09T12:04:41.39Z",
"email": "john.doe@acmecorp.com",
"external_id": "ext_123456789",
"id": "usr_123456789",
"last_login_time": "2025-12-09T12:04:41.48Z",
"metadata": {},
"update_time": "2025-12-09T12:04:41.391988Z",
"user_profile": {
"custom_attributes": null,
"email_verified": true,
"external_identities": [
{
"connection_id": "conn_97896332307464201",
"connection_provider": "GOOGLE",
"connection_type": "OAUTH",
"connection_user_id": "105055379523565727691",
"created_time": "2025-12-09T12:04:41.47Z",
"is_social": true,
"last_login_time": "2025-12-09T12:04:41.469311Z",
"last_synced_time": "2025-12-09T12:04:41.469311Z"
}
],
"family_name": "Doe",
"gender": "",
"given_name": "John",
"groups": null,
"id": "usp_102701193205186825",
"locale": "",
"metadata": {},
"name": "John Doe",
"phone_number": "",
"phone_number_verified": false,
"picture": "https://lh3.googleusercontent.com/a/abcdef",
"preferred_username": ""
}
},
"user_session": {
"absolute_expires_at": "2026-01-08T12:04:41.737394Z",
"authenticated_organizations": [
"org_102701193188409609"
],
"created_at": "2025-12-09T12:04:41.48Z",
"expired_at": null,
"idle_expires_at": "2025-12-16T12:04:41.737395Z",
"last_active_at": "2025-12-09T12:04:41.747206Z",
"logout_at": null,
"organization_id": "org_102701193188409609",
"session_id": "ses_102701193356116233",
"status": "ACTIVE",
"updated_at": "2025-12-09T12:04:41.748512Z",
"user_id": "usr_102701193205121289",
"device": {
"browser": "Chrome",
"browser_version": "142.0.0.0",
"device_type": "Desktop",
"ip": "152.59.144.211",
"location": {
"city": "Patna",
"latitude": "25.594095",
"longitude": "85.137564",
"region": "IN",
"region_subdivision": "INBR"
},
"os": "macOS",
"os_version": "10.15.7",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36"
}
}
},
"display_name": "User Login"
}
No Body