# HTML

**Step 1: Add Secqure JS SDK**

```
<!-- Get Secqure JS SDK -->
<script
    src="https://dev.secuuth.io/JS/prod/Secuuth.bundle.js"
    type="text/javascript"
></script>
```

**Step 2: Add a div element**

```
<div id="secuuthForm"></div>
```

**Step 3: Invoke Secqure**

```
const secuuth = new Secuuth({
      // Key Id obtained while creating Project in Dashboard
      keyId: "xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      // Name of the Form
      profileName: "Default",
      // Div id created in above step
      containerId: "secuuthForm",
      onSubmit: (payload) => {
      // Send payload to your backend server
      })
```

The above steps render  your Login form

<img src="/files/fiJbrrx43YNsJzPlJkr1" alt="" data-size="original">

Secqure returns tokens as part of the payload. Your backend server should validate the access and Id tokens and extract information. Use [SDKs](/backend-response-handling-sdks.md) to validate tokens

```
{
  "accessToken": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIi...",
  "idToken": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJi...",
  "refreshToken": "ad40e2af38f35937bc702cd8bd9c5c3d0af1aad460df..."
}
```

**Congratulations... You are done!!!**


---

# 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.secuuth.io/integration/htms-and-js.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.
