Skip to content

Subscribe to Presence

Subscribe to presence information for a specific chat. You can later retrieve presence information via Get Chat Presence or by listening to the presence.update webhook event.

Usage

php
use NjoguAmos\Waha\Facades\Presence;

/** @var \Saloon\Http\Response $response */
$response = Presence::subscribe(chatId: '[email protected]');
php
use NjoguAmos\Waha\Facades\Presence;

/** @var \Saloon\Http\Response $response */
$response = Presence::subscribe(chatId: '[email protected]', session: 'my-session');

Response

The response returned by the subscribe method is an instance of Saloon\Http\Response:

php
/** @var \Saloon\Http\Response $response */

$response->status(); // 200
$response->ok();     // true

Engines

WEBJSWPPNOWEBGOWS

References

Released under the MIT License.