Sign-in Event
The signin event type is used to validate user sign-in attempts. This helps detect account takeover, credential stuffing, and brute force attacks.
Category: Non-monetary
Relevant feedback outcomes: success, fail, fraud, rejected
note
Dispute, chargeback, and refund outcomes do not apply to sign-in events.
Request Example
POST /api/v1/generic/validate HTTP/1.1
Host: api.sa.mubeen.ai
X-API-Key: <your_key>
Content-Type: application/json
{
"event_type": "signin",
"timestamp": "2025-03-15T08:00:00Z",
"attempt_id": "att_login_8841",
"external_id": "session_aabbcc",
"device_id": "fp_signin_abc12345",
"user_id": "usr_678901",
"full_name": "Noura Al-Fahad",
"phone_number": "+966567890123",
"ip_address": "185.45.67.89",
"ip_country": "SA",
"user_agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 16_5 like Mac OS X)",
"channel": "app",
"platform": "ios",
"account_created_at": "2023-01-15T00:00:00Z"
}
Response Example
{
"request_id": "a1b2c3d4-0001-4567-8901-abcdef012345",
"decision": "allow",
"risk_score": 5,
"risk_level": "low"
}
Feedback Examples
Successful Sign-in
{
"request_id": "a1b2c3d4-0001-4567-8901-abcdef012345",
"outcome": "success",
"external_id": "session_aabbcc"
}
Failed Sign-in (Wrong Credentials)
{
"request_id": "a1b2c3d4-0001-4567-8901-abcdef012345",
"outcome": "fail",
"outcome_details": {
"failure_reason": "invalid_password",
"attempts_remaining": 2
},
"external_id": "session_aabbcc"
}
Fraudulent Sign-in (Account Takeover)
{
"request_id": "a1b2c3d4-0001-4567-8901-abcdef012345",
"outcome": "fraud",
"outcome_details": {
"fraud_type": "account_takeover",
"detection_method": "user_reported"
},
"external_id": "session_aabbcc"
}
Key Fields for Sign-in Events
| Field | Importance | Notes |
|---|---|---|
user_id | Required | Identifies the account being accessed |
user_email | Recommended | Account email for identity verification |
ip_address | Recommended | Detects logins from unusual locations |
device_id | Recommended | Detects logins from new or suspicious devices |