Audit channels

The CLI allows you to create, delete and update the Audit channel. The commands for these actions are shown in the table below.

createCreate a new audit channel
deleteDelete an audit channel
updateUpdate an existing audit channel

List audit channels 

Basic list 

lenses-cli auditchannels

Detailed view 

lenses-cli auditchannels --details

List audit channels with possible flags 

lenses-cli auditchannels \
  --page=1 \
  --pageSize=10 \
  --sortField="name" \
  --sortOrder="asc" \
  --templateName=[TEMPLATE_NAME] \

List audit channel templates 

When creating audit channels, one of existing predefined channel templates needs to be used.

Such a command lists all available audit channel templates:

lenses-cli auditchannel-templates

To get all details, use JSON format:

lenses-cli auditchannel-templates --output JSON

Create new audit channel 

lenses-cli auditchannels create \
  --name "my-audit-channel-1" \
  --connectionName=[CONECTION_NAME] \
  --templateName=[TEMPLATE_NAME] \

Create new audit channel using a YAML file:

name: "my-audit-channel-2"
templateName: [TEMPLATE_NAME]
connectionName: [CONECTION_NAME]
  - key: "body"
    value: "body-payload"
  - key: "insecure"
    value: true
  - key: "method"
    value: "GET"

Save the file as audit_chann.yml and execute it like this:
lenses-cli auditchannels create audit_chann.yml

Update an audit channel 

lenses-cli auditchannels update \
  --name "my-audit-channel-2-updated" \
  --connectionName=[CONNECTION_NAME] \
  --templateName=[TEMPLATE_NAME] \

Delete an audit channel 

lenses-cli auditchannels delete \
Last modified: July 17, 2024