From e7dd7182e3ec697233b58577af16b083feb37419 Mon Sep 17 00:00:00 2001 From: Aleksandr Soloshenko Date: Tue, 21 Oct 2025 20:25:01 +0700 Subject: [PATCH] [docs] troubleshooting duplicate messages --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 42fc7e9..98b1c3e 100644 --- a/README.md +++ b/README.md @@ -136,6 +136,9 @@ The script expects webhook payloads from SMSGate in the following format: - **Data not appearing**: Check that your webhook URL is correct and accessible - **Authorization errors**: Re-deploy the web app with proper permissions - **Column mismatch**: Verify your headers match exactly: "Timestamp", "From", "Message", "DeviceID", "MessageID" +- **Duplicate messages in sheet**: If you notice the same SMS message being logged multiple times, this occurs because Google Apps Script returns a 302 redirect for POST requests. SMSGate retries webhook delivery on non-2xx responses. To fix: + - Option 1: Set "Retry count" to 1 in SMSGate settings ([Settings → Webhooks → Retry count](https://docs.sms-gate.app/features/webhooks/#step-5-receive-the-payload)) + - Option 2: Implement deduplication in your Apps Script using the unique `messageId` from the webhook payload

back to top