> For the complete documentation index, see [llms.txt](https://osl.mistium.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://osl.mistium.com/legacy-osl-originos/networking/websockets/.wshasnew.md).

# wsHasnew

> ⚠️ **Not implemented in the current OSL CLI.**

## Description

wsHasnew allows you to check if a websocket has received new data.

## Parameters

wsHasnew takes no parameters.

## Usage

```javascript
ws_id = "url".newWebsocket()

if ws_id.wsHasnew() (
  // handle the new messages using ws_id.wsGetnext() to get the next message and then discard it
)
```
