guides docs
Connect Custom Website
Guide to connect any custom website or platform with WhatAPI via REST API webhooks.
Connect Custom Website
This guide explains how to connect a custom-built website or any platform with a REST API to WhatAPI.
Prerequisites
- A website or platform with REST API access
- Ability to create and configure webhooks
- WhatAPI account with WhatsApp connected
Step 1: Get Your API Key
- In your WhatAPI dashboard, go to **Settings → API Keys**.
- Generate a new API key if you don't have one.
- Copy the key — you'll use it to authenticate requests.
Step 2: Configure Webhook URL
- In your platform's settings, find the **Webhooks** section.
- Add a new webhook with the following URL:
```
https://whatsapi.pk/api/shopify/webhook?uid=YOUR_USER_ID
```
- Replace `YOUR_USER_ID` with your actual user ID.
- Select the events you want to trigger (order created, payment received, etc.).
- Set the format to **JSON**.
Step 3: Connect in WhatAPI
- Go to your WhatAPI dashboard → **Connect Store**.
- Select **Custom Website** as your platform.
- Enter your website URL.
- Enter your API key or any identifier for your platform.
- Click **Connect**.
Step 4: Test the Connection
Place a test order on your website. You should receive a WhatsApp notification if everything is configured correctly.
Custom Integration
If your platform isn't supported natively, you can:
- Use our REST API directly: `https://whatsapi.pk/api/v1/messages/send`
- Set up custom webhook forwarding
- Contact our support team for custom integration assistance
