pChat is the included web sender app. It can send via SMS/WhatsApp/Telegram/email/notify and also supports a
private
web-to-web channel (pchat) backed by the relay.
Open the sender app from the site:
Server URL = the hosted relay URL shown on Setup QR / portal
API Key = CLIENT_API_KEY
Phone ID = your PHONE_ID
These endpoints power the pChat web-to-web channel. They require the same auth header as the send API:
Authorization: Bearer CLIENT_API_KEY.
POST /api/v1/messagesPOST /api/v1/webchat/pollPOST /api/v1/webchat/presencePOST /api/v1/webchat/readPOST /api/v1/webchat/receipt-statusPOST /api/v1/messages
Authorization: Bearer CLIENT_API_KEY
Content-Type: application/json
{
"phone_id": "phone_main",
"channel": "pchat",
"to": "16hexchataddressofrecipient",
"text": "hello",
"source": "16hexchataddressofsender",
"idempotency_key": "pchat-001"
}
POST /api/v1/webchat/poll
Authorization: Bearer CLIENT_API_KEY
Content-Type: application/json
{ "phone_id": "phone_main", "chat_address": "your16hex...", "limit": 20 }
POST /api/v1/webchat/presence
Authorization: Bearer CLIENT_API_KEY
Content-Type: application/json
{ "chat_address": "your16hex...", "display_name": "Alice", "visible": true }
POST /api/v1/webchat/read
Authorization: Bearer CLIENT_API_KEY
Content-Type: application/json
{ "chat_address": "your16hex...", "message_ids": ["msg_...","msg_..."] }
POST /api/v1/webchat/receipt-status
Authorization: Bearer CLIENT_API_KEY
Content-Type: application/json
{ "message_ids": ["msg_...","msg_..."] }
Used by the pChat UI for attachments and voice notes.
POST /api/v1/webchat/upload
Authorization: Bearer CLIENT_API_KEY
Content-Type: multipart/form-data
file=@/path/to/file
// response includes:
{ "success": true, "url": "/api/v1/webchat/files/<file_id>", "size": 12345 }