Execute command's preview item

URLRequires AuthHTTP Method

/api/v1/commands.preview

yes

POST

Payload

ArgumentExampleRequiredDescription

command

unmute

Required

The name of the command to be executed.

roomId

ByehQjC44FwMeiLbX

Required

The ID of the room.

tmid

Hsj2435g4bvrj4bjh

Optional

The ID of the thread to run the command.

params

@user123

Optional Default: undefined

Parameters of the command if required.

triggerId

awovufbukuefzuper

Optional

The triggerId generated by the client that allows the command to interact with the UI

previewItem

Object

Required

The data of the preview item to be executed by the command

previewItem.id

nucobdipokaikazia

Required

The ID of the selected preview item

previewItem.type

image

Required

The type of the selected preview item

priviewItem.value

https://dev.null/gif

Required

The value of the selected preview item

Change Log

VersionDescription

3.0.0

Added tmid and triggerId fields

0.65.0

Added

Last updated

Rocket.Chat versions receive support for six months after release.