Skip to main content

Streamplace regras de chat

Seja seu próprio chatbot no Streamplace respondendo para !regras as regras do seu chat

place.stream.chat.message
Lexicon
place.stream.chat.message
Operations
Record created
Watched repos
All repos

Steps (3)

Variablerules
Value
Hidden
Note
Chat rules
Conditionbranch
  • If event.commit.record.streamer equals {{self}} - Chat message was sent in my channel
  • and event.commit.record.text equals !regras - Command to show chat rules
Then

Create a recordAction 1

Target Collection
place.stream.chat.message
Record Template
{
  "$type": "place.stream.chat.message",
  "createdAt": "{{now}}",
  "reply": {
    "parent": {
      "cid": "{{event.commit.cid}}",
      "uri": "{{event.uri}}"
    },
    "root": {
      "cid": "{{event.commit.cid}}",
      "uri": "{{event.uri}}"
    }
  },
  "streamer": "{{self}}",
  "text": "{{rules}}"
}
$type is set to the target collection when the record is written.