> For the complete documentation index, see [llms.txt](https://sending-network.gitbook.io/sending.network/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://sending-network.gitbook.io/sending.network/sdk-documentation/website-chat-widget-sdk/user.md).

# User

## Get user ID

```javascript
window.chatWidgetApi.getUserId()
```

| Method Name                     | Description     | Parameters | Return Values |
| ------------------------------- | --------------- | ---------- | ------------- |
| window\.chatWidgetApi.getUserId | Get the user id | N/A        | userID        |

## **Get User ID from wallet address**

```javascript
window.chatWidgetApi.getUidByAddress(address).then((userId)=>{console.log(userId)})
```

| Method Name                           | Description                   | Parameters     | Return Values |
| ------------------------------------- | ----------------------------- | -------------- | ------------- |
| window\.chatWidgetApi.getUidByAddress | Get user ID by wallet address | wallet address | userId        |

## **Get user information**

| Method Name                       | Description          | Parameters | Return Values                                                   |
| --------------------------------- | -------------------- | ---------- | --------------------------------------------------------------- |
| window\.chatWidgetApi.getUserData | Get user information | N/A        | User info: avatar\_url, displayname, signature, wallet\_address |

## Log Out

| Method Name                  | Description                    | Parameters                                      | Return Values |
| ---------------------------- | ------------------------------ | ----------------------------------------------- | ------------- |
| window\.chatWidgetApi.logout | Log out of the current session | callback (optional): Callback after logging out | N/A           |
