> For the complete documentation index, see [llms.txt](https://docs.conscent.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.conscent.ai/version-1.0/login.md).

# Login

<table><thead><tr><th>Parameters</th><th>Description</th></tr></thead><tbody><tr><td><pre><code>clientId
</code></pre></td><td><p></p><p>The 'clientId' is retrieved from the <a href="https://client.conscent.in/dashboard/integration">Client Integrations Page</a> of the ConsCent Client Dashboard.</p></td></tr><tr><td><pre><code>wrappingElementId
</code></pre></td><td>'wrappingElementId' is a mandatory string that is the id of an element (e.g. a div with absolute positioning on your website) within which you want the login popup to be embedded.</td></tr><tr><td></td><td></td></tr></tbody></table>

{% tabs %}
{% tab title="shell" %}

```sh
const csc = window._csc as any;
    csc('conscent-login', {
      debug: true,
      clientId: clientId,
      defaultEmail: defaultEmail || '',
      defaultName: defaultName || '',
      defaultPhone: defaultPhone || '',
      wrappingElementId: 'embed',
      successCallback: async (userDetailsObject: any) => {
        console.log('Success callback received from conscent login', userDetailsObject);
        setUserDetails(userDetailsObject);
        props.setShowLoginModal(false)
      },
      onCrossBtnClickSuccess: async () => {
        console.log('cross btn click successfully');
        props.setShowLoginModal(false)
      },
      unauthorizedCallback: () => {
        console.log('unauthorized callback called');
      },
    });
```

{% endtab %}

{% tab title="javaScript" %}

```javascript
const csc = window._csc as any;
    csc('conscent-login', {
      debug: true,
      clientId: clientId,
      defaultEmail: defaultEmail || '',
      defaultName: defaultName || '',
      defaultPhone: defaultPhone || '',
      wrappingElementId: 'embed',
      successCallback: async (userDetailsObject: any) => {
        console.log('Success callback received from conscent login', userDetailsObject);
        setUserDetails(userDetailsObject);
        props.setShowLoginModal(false)
      },
      onCrossBtnClickSuccess: async () => {
        console.log('cross btn click successfully');
        props.setShowLoginModal(false)
      },
      unauthorizedCallback: () => {
        console.log('unauthorized callback called');
      },
    });

```

{% endtab %}

{% tab title="php" %}

```php
const csc = window._csc as any;
    csc('conscent-login', {
      debug: true,
      clientId: clientId,
      defaultEmail: defaultEmail || '',
      defaultName: defaultName || '',
      defaultPhone: defaultPhone || '',
      wrappingElementId: 'embed',
      successCallback: async (userDetailsObject: any) => {
        console.log('Success callback received from conscent login', userDetailsObject);
        setUserDetails(userDetailsObject);
        props.setShowLoginModal(false)
      },
      onCrossBtnClickSuccess: async () => {
        console.log('cross btn click successfully');
        props.setShowLoginModal(false)
      },
      unauthorizedCallback: () => {
        console.log('unauthorized callback called');
      },
    });

```

{% endtab %}
{% endtabs %}

After integrating the Login script, the Login popup appears on the screen which can be customizable for all the Clients.

<figure><img src="/files/228jzuhuk4nYHBjFlr2n" alt="" width="375"><figcaption></figcaption></figure>

<figure><img src="/files/EYQnDqyLfhg0u9574U7l" alt="" width="372"><figcaption><p>Verify OTP Screen</p></figcaption></figure>
