GenerateRandomMessages - Service to generate random chat messages from participants.
This service generates random direct and group messages based on participants and a given host setup, with options to tailor messages for chat broadcast.
GenerateRandomMessages
const generateRandomMessagesService = new GenerateRandomMessages();const messages = generateRandomMessagesService.generateRandomMessages({ participants: [ { name: 'Alice' }, { name: 'Bob' }, { name: 'Charlie' } ], member: 'Alice', coHost: 'Bob', host: 'Charlie', forChatBroadcast: true});console.log(messages); Copy
const generateRandomMessagesService = new GenerateRandomMessages();const messages = generateRandomMessagesService.generateRandomMessages({ participants: [ { name: 'Alice' }, { name: 'Bob' }, { name: 'Charlie' } ], member: 'Alice', coHost: 'Bob', host: 'Charlie', forChatBroadcast: true});console.log(messages);
Options for generating random messages.
List of participants for message generation.
The primary member in the chat.
Optional co-host participant.
The chat host.
Flag to indicate if messages are for chat broadcast.
Array of randomly generated messages with direct and group messaging.
Generates random messages for a given set of participants.
The options for generating random messages.
An array of generated messages.
GenerateRandomMessages - Service to generate random chat messages from participants.
This service generates random direct and group messages based on participants and a given host setup, with options to tailor messages for chat broadcast.
Name
GenerateRandomMessages
Example
Param: options
Options for generating random messages.
Param: options.participants
List of participants for message generation.
Param: options.member
The primary member in the chat.
Param: options.coHost
Optional co-host participant.
Param: options.host
The chat host.
Param: options.forChatBroadcast
Flag to indicate if messages are for chat broadcast.
Returns
Array of randomly generated messages with direct and group messaging.