Send Text

Send a Message

Sends a text message to given chat

Parameters

Description

receiverNumber

Receiver number (e.g, [code country][number] 6283838204803)

message

Message that you will send

function message(String $message, String $receiverNumber)

Example

\Ardzz\Wavel\Wavel::text()->message('This message was sent from Wavel', 6283838204803);

Send a Message With Mention

Sends a text message to given chat that includes mentions. In order to use this method correctly you will need to send the text like this: "@4474747474747 how are you?" Basically, add a @ symbol before the number of the contact you want to mention.

Parameters

Description

receiverNumber

Receiver number (e.g, [code country][number] 6283838204803)

message

Message that you will send

function messageWithMention(String $message, String $receiverNumber)

Example

\Ardzz\Wavel\Wavel::text()->messageWithMention('Hi @6283838204803, This message was sent from Wavel', 6283838204803);

Automatically sends a youtube link with the auto generated link preview. You can also add a custom message.

Parameters

Description

receiverNumber

Receiver number (e.g, [code country][number] 6283838204803)

message

Message that you will send

youtubeLink

URL string A youtube link

Example

Reply Message

Sends a reply to a given message. Please note, you need to have at least sent one normal message to a contact in order for this to work properly.

Parameters

Description

receiverNumber

Receiver number (e.g, [code country][number] 6283838204803)

message

Message that you will send

messageId

The id of a message. The format is [boolean]_[ChatId]_[random character string]

Example:

"false_447123456789@c.us_9C4D0965EA5C09D591334AB6BDB07FEB"

sendSeen

sendSeen boolean If set to true, the chat will 'blue tick' all messages before sending the reply

Example

Automatically sends a link with the auto generated link preview. You can also add a custom message.

Parameters

Description

receiverNumber

Receiver number (e.g, [code country][number] 6283838204803)

message

Message that you will send

link

URL string a link

Example

Last updated

Was this helpful?