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

# Create token

> Create a WhatsApp session token.

Creates a stable token your app can use for pairing, connection checks, and message sends.

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST "https://api.wadial.com/api/v1/sessions" \
    -H "Authorization: Bearer $WADIAL_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{"displayName":"Support line","deviceBrowser":"Chrome"}'
  ```

  ```js JavaScript theme={null}
  const response = await fetch("https://api.wadial.com/api/v1/sessions", {
    method: "POST",
    headers: {
      Authorization: `Bearer ${process.env.WADIAL_API_KEY}`,
      "Content-Type": "application/json",
    },
    body: JSON.stringify({ displayName: "Support line", deviceBrowser: "Chrome" }),
  });

  const { data } = await response.json();
  ```

  ```python Python theme={null}
  import os, requests

  response = requests.post(
      "https://api.wadial.com/api/v1/sessions",
      headers={"Authorization": f"Bearer {os.environ['WADIAL_API_KEY']}"},
      json={"displayName": "Support line", "deviceBrowser": "Chrome"},
  )
  data = response.json()["data"]
  ```
</RequestExample>

<ResponseExample>
  ```json theme={null}
  {
    "data": {
      "sessionId": "019eff5e-e24e-74ce-a9bb-ccd97e6946b6",
      "displayName": "Support line",
      "status": "created",
      "paired": false,
      "connected": false,
      "connectionState": "created"
    }
  }
  ```
</ResponseExample>
