# SSO Login Flow

<table><thead><tr><th width="174">PARAMETERS</th><th width="324">Description</th><th>DATATYPE</th><th><select><option value="59f54b85d1b44dedb3fc87b01340c1c7" label="REQUIRED" color="blue"></option><option value="5d81d115016a4a67943345e8408d77ba" label="OPTIONAL" color="blue"></option></select></th></tr></thead><tbody><tr><td><mark style="color:orange;">clientId</mark></td><td>The unique clientId is found on the dashboard.</td><td>string</td><td><span data-option="59f54b85d1b44dedb3fc87b01340c1c7">REQUIRED</span></td></tr><tr><td><mark style="color:orange;">eventType</mark></td><td></td><td>string</td><td><span data-option="59f54b85d1b44dedb3fc87b01340c1c7">REQUIRED</span></td></tr><tr><td><mark style="color:orange;">eventLocation</mark></td><td></td><td>string</td><td><span data-option="59f54b85d1b44dedb3fc87b01340c1c7">REQUIRED</span></td></tr><tr><td><mark style="color:orange;">anonId</mark></td><td>A unique anonymous ID for each user.</td><td>uuid</td><td><span data-option="59f54b85d1b44dedb3fc87b01340c1c7">REQUIRED</span></td></tr><tr><td><mark style="color:orange;">url</mark></td><td></td><td>string</td><td><span data-option="5d81d115016a4a67943345e8408d77ba">OPTIONAL</span></td></tr><tr><td><mark style="color:orange;">isCookieBlocked</mark></td><td></td><td>boolean</td><td><span data-option="5d81d115016a4a67943345e8408d77ba">OPTIONAL</span></td></tr><tr><td><mark style="color:orange;">contentId</mark></td><td>A unique id of each content.</td><td>string</td><td><span data-option="59f54b85d1b44dedb3fc87b01340c1c7">REQUIRED</span></td></tr><tr><td><mark style="color:orange;">clickAction</mark></td><td></td><td>string</td><td><span data-option="59f54b85d1b44dedb3fc87b01340c1c7">REQUIRED</span></td></tr><tr><td><mark style="color:orange;">validationType</mark></td><td></td><td>string</td><td><span data-option="59f54b85d1b44dedb3fc87b01340c1c7">REQUIRED</span></td></tr><tr><td><mark style="color:orange;">firstTimeLogin</mark></td><td></td><td>boolean</td><td><span data-option="59f54b85d1b44dedb3fc87b01340c1c7">REQUIRED</span></td></tr><tr><td><mark style="color:orange;">userAgent</mark></td><td></td><td>string</td><td><span data-option="59f54b85d1b44dedb3fc87b01340c1c7">REQUIRED</span></td></tr></tbody></table>

<details>

<summary>User SignUp View Event</summary>

**Description**

It is an event that is triggered when the user views the sign-up/ login page for the first time.

**Example:**

```json
{
"eventType": "VIEW",
"eventLocation": "SSO_SIGNUP",
"clientId": "5f92a62013332e0f667794dc",
"anonId": "b79064d2-2256-4c36-ad06-8c38cc0396c7",
"url": "http://localhost:9000/test.html",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
"isCookieBlocked": 0,
"contentId":'contentId-1'
}
```

</details>

<details>

<summary>User Login View Event</summary>

**Description**

It is an event that is triggered when the user views the login page.

**Example**

```json
{
"eventType": "VIEW",
"eventLocation": "SSO_LOGIN",
"clientId": "5f92a62013332e0f667794dc",
"anonId": "b79064d2-2256-4c36-ad06-8c38cc0396c7",
"url": "http://localhost:9000/test.html",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
"isCookieBlocked": 0,
"contentId": 'article-20',
}
```

</details>

<details>

<summary>User OTP View Event</summary>

**Description**

It is an event that is triggered when the user views the OTP Page.

**Example**

```json
{
"eventType": "VIEW",
"eventLocation": "SSO_LOGIN_OTP",
"clientId": "5f92a62013332e0f667794dc",
"anonId": "b79064d2-2256-4c36-ad06-8c38cc0396c7",
"url": "http://localhost:9000/test.html",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
"isCookieBlocked": 0,
"contentId": 'article-20',
}
```

**Note: This event is only needed to be sent when the Login is based on OTP.**

</details>

<details>

<summary>User Click Event</summary>

**Description**

It is an event that is triggered when the user performs the click action when he/she logs in.

**Example**

```json
{
"eventType": "CLICK",
"eventLocation": "SSO_LOGIN",
"clickAction": 'EMAIL' | 'MOBILE' | 'GOOGLE'
"clientId": "5f92a62013332e0f667794dc",
"anonId": "b79064d2-2256-4c36-ad06-8c38cc0396c7",
"url": "http://localhost:9000/test.html",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
"isCookieBlocked": 0,
"contentId": 'article-20',
}
```

</details>

<details>

<summary>User Registration Event</summary>

**Description**

It is an event that is triggered when the user registers to your platform for the first time.

**Example**

```json
{
"eventType": "REGISTRATION",
"eventLocation": "SSO_LOGIN",
"clientId": "5f92a62013332e0f667794dc",
"anonId": "b79064d2-2256-4c36-ad06-8c38cc0396c7",
"url": "http://localhost:9000/test.html",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
"isCookieBlocked": 0
"userId": "5f92a62013332e0f667794dc",
"validationType": "OTP",
"firstTimeLogin": 1,
"contentId": 'article-20',
}
```

</details>

<details>

<summary>User Validation Event</summary>

**Description**

It is an event that is triggered when the user is validated whenever he logs in.

**Example**

```json
{
"eventType": "VALIDATION",
"eventLocation": "SSO_LOGIN",
"clientId": "5f92a62013332e0f667794dc",
"anonId": "b79064d2-2256-4c36-ad06-8c38cc0396c7",
"url": "http://localhost:9000/test.html",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
"isCookieBlocked": 0
"userId": "5f92a62013332e0f667794dc",
"validationType": "OTP",
"firstTimeLogin": 1,
"contentId": 'article-20',
}
```

</details>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.conscent.ai/events-api-docs/sso-login-flow.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
