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

# Quickstart

> Run GOWA, pair a WhatsApp account and send your first message in a few minutes.

## 1. Start the server

**Docker**

```bash theme={null}
docker run -d --name gowa \
  -p 3000:3000 \
  -v gowa_storages:/app/storages \
  -v gowa_statics:/app/statics \
  -e APP_BASIC_AUTH=admin:changeme \
  aldinokemal2104/go-whatsapp-web-multidevice:latest
```

The image's default command is `rest`, so no arguments are needed. The same image is published as `ghcr.io/aldinokemal/go-whatsapp-web-multidevice`.

**Binary**

Download the archive for your platform from [GitHub Releases](https://github.com/aldinokemal/go-whatsapp-web-multidevice/releases) (for example `whatsapp_9.7.0_linux_amd64.zip`), then:

```bash theme={null}
unzip whatsapp_9.7.0_linux_amd64.zip
chmod +x whatsapp
./whatsapp rest --basic-auth=admin:changeme
```

Install FFmpeg and libwebp (`cwebp`) first; GOWA uses them for media conversion.

**From source**

Requires Go 1.26+, FFmpeg and libwebp.

```bash theme={null}
git clone https://github.com/aldinokemal/go-whatsapp-web-multidevice.git
cd go-whatsapp-web-multidevice/src
go run . rest --basic-auth=admin:changeme
```

Check it is up:

```bash theme={null}
curl http://localhost:3000/health
# OK
```

> [!NOTE]
>
> Basic Auth is optional but strongly recommended. Without `APP_BASIC_AUTH`, every route except `/health` is open to anyone who can reach the port.

## 2. Create a device

Each WhatsApp account lives in a device slot. Create one and give it an ID you will reuse:

```bash theme={null}
curl -u admin:changeme -X POST http://localhost:3000/devices \
  -H "Content-Type: application/json" \
  -d '{"device_id": "my-device"}'
```

Omit `device_id` to get a generated UUID.

## 3. Pair the account

**QR code**

```bash theme={null}
curl -u admin:changeme http://localhost:3000/devices/my-device/login
```

Open `results.qr_link` in a browser and scan it from WhatsApp → **Linked devices** → **Link a device**. The code expires after `results.qr_duration` seconds; request a new one if it lapses.

**Pairing code**

```bash theme={null}
curl -u admin:changeme -X POST \
  "http://localhost:3000/devices/my-device/login/code?phone=628123456789"
```

Enter `results.pair_code` on the phone under **Linked devices** → **Link with phone number instead**.

**Dashboard**

Open `http://localhost:3000/`, enter your Basic Auth credentials when the browser prompts, and pair the device from the UI.

Confirm the device is logged in (`results.is_logged_in` should be `true`):

```bash theme={null}
curl -u admin:changeme http://localhost:3000/devices/my-device/status
```

## 4. Send a message

```bash theme={null}
curl -u admin:changeme -X POST http://localhost:3000/send/message \
  -H "Content-Type: application/json" \
  -H "X-Device-Id: my-device" \
  -d '{"phone": "628123456789", "message": "Hello from GOWA"}'
```

```json theme={null}
{
  "code": "SUCCESS",
  "message": "Success",
  "results": {
    "message_id": "3EB0B430B6F8F1D0E053AC120E0A9E5C",
    "status": "Message sent to 628123456789 (server timestamp: ...)"
  }
}
```

`phone` takes a number with country code and no `+` or spaces, or a full JID such as `628123456789@s.whatsapp.net` or `120363025246125486@g.us` for a group. With only one device registered, `X-Device-Id` is optional.

## 5. Receive messages

Restart with a webhook URL and GOWA will POST every event to it:

```bash theme={null}
./whatsapp rest --basic-auth=admin:changeme --webhook=https://example.com/wa-hook --webhook-secret=change-me
```

See [Webhooks](https://gowa-docs.mintlify.site/concepts/webhooks.md) for payloads and signature checks.

## Next steps

> **[Installation](https://gowa-docs.mintlify.site/installation.md)**
>
> Docker Compose, reverse proxy, PostgreSQL.

> **[Configuration reference](https://gowa-docs.mintlify.site/configuration.md)**
>
> Every flag and environment variable.

> **[Multi-device](https://gowa-docs.mintlify.site/concepts/multidevice.md)**
>
> Run several accounts on one server.

> **[API reference](https://gowa-docs.mintlify.site/api-reference/introduction.md)**
>
> All endpoints.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.