Skip to content

Commit d7954e2

Browse files
StartAutomatingStartAutomating
StartAutomating
authored and
StartAutomating
committed
feat: Get-WebSocket -Filter ( Fixes #42 )
1 parent 8e1be05 commit d7954e2

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

docs/Get-WebSocket.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,17 @@ The subprotocol used by the websocket. If not provided, this will default to `j
254254
|----------|--------|--------|-------------|
255255
|`[String]`|false |named |false |
256256

257+
#### **Filter**
258+
One or more filters to apply to the output of the WebSocket.
259+
These can be strings, regexes, scriptblocks, or commands.
260+
If they are strings or regexes, they will be applied to the raw text.
261+
If they are scriptblocks, they will be applied to the deserialized JSON.
262+
These filters will be run within the WebSocket job.
263+
264+
|Type |Required|Position|PipelineInput|
265+
|--------------|--------|--------|-------------|
266+
|`[PSObject[]]`|false |named |false |
267+
257268
#### **WatchFor**
258269
If set, will watch the output of a WebSocket job for one or more conditions.
259270
The conditions are the keys of the dictionary, and can be a regex, a string, or a scriptblock.
@@ -313,5 +324,5 @@ RunspacePools allow you to limit the scope of the handler to a pool of runspaces
313324

314325
### Syntax
315326
```PowerShell
316-
Get-WebSocket [[-WebSocketUri] <Uri>] [-QueryParameter <IDictionary>] [-Handler <ScriptBlock>] [-Variable <IDictionary>] [-Name <String>] [-InitializationScript <ScriptBlock>] [-BufferSize <Int32>] [-OnConnect <ScriptBlock>] [-OnError <ScriptBlock>] [-OnOutput <ScriptBlock>] [-OnWarning <ScriptBlock>] [-Watch] [-RawText] [-Binary] [-SubProtocol <String>] [-WatchFor <IDictionary>] [-TimeOut <TimeSpan>] [-PSTypeName <String[]>] [-Maximum <Int64>] [-ConnectionTimeout <TimeSpan>] [-Runspace <Runspace>] [-RunspacePool <RunspacePool>] [<CommonParameters>]
327+
Get-WebSocket [[-WebSocketUri] <Uri>] [-QueryParameter <IDictionary>] [-Handler <ScriptBlock>] [-Variable <IDictionary>] [-Name <String>] [-InitializationScript <ScriptBlock>] [-BufferSize <Int32>] [-OnConnect <ScriptBlock>] [-OnError <ScriptBlock>] [-OnOutput <ScriptBlock>] [-OnWarning <ScriptBlock>] [-Watch] [-RawText] [-Binary] [-SubProtocol <String>] [-Filter <PSObject[]>] [-WatchFor <IDictionary>] [-TimeOut <TimeSpan>] [-PSTypeName <String[]>] [-Maximum <Int64>] [-ConnectionTimeout <TimeSpan>] [-Runspace <Runspace>] [-RunspacePool <RunspacePool>] [<CommonParameters>]
317328
```

0 commit comments

Comments
 (0)