WasenderApi - Low Cost WhatsApp API for Developers Get WhatsApp Session Status - API Documentation - WasenderApi - Low Cost WhatsApp API for Developers
WasenderApi API

API Documentation

WasenderApi WhatsApp API

Get WhatsApp Session Status

Sessions

GET/api/status

Returns the current status of the connected WhatsApp session.

Get WhatsApp Session Status

This endpoint returns the current status of a specific WhatsApp session. The session must be previously initialized and authenticated.

Session Statuses Explained

The following are the possible statuses that may be returned by this endpoint:

  • connectingThe session is attempting to establish a connection with WhatsApp servers. This typically occurs right after initialization.
  • connectedThe session is successfully authenticated and actively connected to WhatsApp. You can send and receive messages.
  • disconnectedThis is the first status before the user attempts to connect. Once the user tries to connect, this status will no longer be shown.
  • need_scanThis status means the session needs to be scanned with a QR code. It usually occurs when initializing a new session or if the previous session is no longer valid.
  • logged_outThe user has logged out of the WhatsApp session either manually or from another device. You'll need to re-authenticate by scanning a QR code again.
  • expiredThe session is no longer valid, often due to extended inactivity or because it was invalidated remotely. Reinitialization is required.

Code Examples

curl "https://www.wasenderapi.com/api/status"
  -H "Authorization: Bearer YOUR_API_KEY"

Response Examples

{
  "status":"connected"
}