> ## Documentation Index
> Fetch the complete documentation index at: https://docs.livchat.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Logout

> Logout and terminate the WhatsApp session

Completely logout from WhatsApp and terminate the session. A new QR scan will be required to reconnect.

<Warning>
  This permanently ends the session. The device will be unlinked from your WhatsApp account.
</Warning>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST https://api.livchat.ai/v1/session/logout \
    -H "Authorization: Bearer YOUR_API_KEY"
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch("https://api.livchat.ai/v1/session/logout", {
    method: "POST",
    headers: {
      Authorization: "Bearer YOUR_API_KEY",
    },
  });
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "success": true,
    "code": 200,
    "data": {
      "details": "Logged out"
    }
  }
  ```
</ResponseExample>
