Saltar al contenido principal
EjemploAvanzado2 min de lecturaActualizado el Jul 2, 2026
agentactortwitchmoderationspamcommands

Twitch Moderator Bot

Agente actor de Twitch basado en reglas que maneja comandos simples de chat y reenvía todos los demás mensajes a un workflow de moderación vinculado que detecta venta de espectadores, venta de suscriptores y spam similar.

Descargar ZIP · 2.3 KB

Dependencias Incluidas

info

El ZIP descargable incluye todas las dependencias listadas a continuación. Todas las referencias cruzadas se vinculan automáticamente durante la importación.

Workflows: Workflow de Moderación de Twitch (Clasificador de Anuncios)

Sustituya workflowId por el ID de este workflow vinculado al configurar el agente actor.

JSON Completo

Clic para expandir
{
"description": "Rule-based Twitch actor agent that handles simple chat commands and forwards all other messages to a linked moderation workflow that detects viewer-selling, subscriber-selling, and similar spam.",
"tags": [
"agent",
"actor",
"twitch",
"moderation",
"spam",
"commands"
],
"linkedExamples": [
{
"type": "workflows",
"variant": "twitch-bot-assistant-moderator",
"relationship": "Replace `workflowId` with the ID of this linked workflow when seeding the actor."
}
],
"document": {
"name": "Twitch Moderator",
"assistantType": "actor",
"platformType": null,
"options": {
"log_level": "info"
},
"platform": {
"actor": {
"rules": [
{
"condition": {
"expr": "contactMessage.body.text.startsWith('!hello')",
"onFailure": "throw"
},
"action": {
"actionType": "actions/messaging/conversation/response/compose",
"actions/messaging/conversation/response/compose": {
"messages": [
{
"type": "text",
"payload": {
"text": {
"expr": "\"Hello! Welcome to the stream!\"",
"onFailure": "throw",
"useSimpleCel": true
}
}
}
]
}
}
},
{
"condition": {
"expr": "contactMessage.body.text.startsWith('!help')",
"onFailure": "throw"
},
"action": {
"actionType": "actions/messaging/conversation/response/compose",
"actions/messaging/conversation/response/compose": {
"messages": [
{
"type": "text",
"payload": {
"text": {
"expr": "\"Available commands: !hello, !help, !socials\"",
"onFailure": "throw",
"useSimpleCel": true
}
}
}
]
}
}
},
{
"condition": {
"expr": "contactMessage.body.text.startsWith('!socials')",
"onFailure": "throw"
},
"action": {
"actionType": "actions/messaging/conversation/response/compose",
"actions/messaging/conversation/response/compose": {
"messages": [
{
"type": "text",
"payload": {
"text": {
"expr": "\"Follow us on Twitter @example and Instagram @example_ig\"",
"onFailure": "throw",
"useSimpleCel": true
}
}
}
]
}
}
},
{
"condition": {
"expr": "contactMessage.body.text.startsWith('!')",
"onFailure": "throw"
},
"action": {
"actionType": "actions/messaging/conversation/response/compose",
"actions/messaging/conversation/response/compose": {
"messages": [
{
"type": "text",
"payload": {
"text": {
"expr": "\"Unknown command. Try !hello, !help, or !socials\"",
"onFailure": "throw"
}
}
}
]
}
}
},
{
"condition": {
"expr": "true",
"onFailure": "throw"
},
"action": {
"actionType": "actions/data/company/automation/execute_workflow_manual",
"actions/data/company/automation/execute_workflow_manual": {
"workflowId": "<linked-workflow-id>",
"args": {
"expr": "{\n \"twitch_username\": contact.name,\n \"twitch_message\": contactMessage.body.text,\n}",
"onFailure": "throw"
}
}
}
}
]
}
}
}
}
TipoAgent · actor
Reglas5
Canaltwitch
Versión1.0.0
Descargar ZIP
twitch-bot-assistant-moderator2.3 KB
En esta página