# A payment-slip verification flow for LINE OA shop orders (pattern + lessons)

**URL:** <https://discourse.nodered.org/t/a-payment-slip-verification-flow-for-line-oa-shop-orders-pattern-lessons/102003>\
**Category:** Share Your Projects\
**Created:** [28 October 2026 00:07 UTC](https://discourse.nodered.org/t/a-payment-slip-verification-flow-for-line-oa-shop-orders-pattern-lessons/102003 "2026-10-28T00:07:48Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![chatdechateam](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/chatdechateam/32/108735_2.png) [@chatdechateam](https://discourse.nodered.org/u/chatdechateam)\
**Post date:** [28 October 2026 00:07 UTC](https://discourse.nodered.org/t/a-payment-slip-verification-flow-for-line-oa-shop-orders-pattern-lessons/102003/1 "2026-10-28T00:07:48Z")

</div>

We run customer support for small Thai online shops that take orders through LINE Official Accounts. The most time-consuming part was never the chat — it was verifying bank-transfer slips: customers paste a transfer screenshot or reference number into the chat, and someone had to open a banking app and match the amount before shipping.

We wired the whole check into Node-RED and it cut verification from minutes to seconds per order. Sharing the pattern in case it helps anyone automating order ops:

**Flow outline**

1. `http in` receives the LINE webhook (or `email in` / IMAP for bank notification mails on a dedicated inbox).
2. A `function` node normalizes the payload and extracts amount, transfer reference and timestamp (regex per bank message format — every Thai bank has a slightly different one, so keep one regex map per bank).
3. Matching: keep expected payments in context (order id → expected amount, valid time window). A `switch` node routes: exact match / amount mismatch / duplicate / no reference found.
4. Only mismatch cases go to a human queue — that was the big win: roughly 90% of slips never need a person.
5. Replies go through the LINE Messaging API `push` endpoint via `http request`, with per-customer rate limiting so retry storms never spam customers.

**Lessons**

- Store matched slips with a `file` node (JSONL) instead of memory, so restarts don't wipe the audit trail.
- Duplicate detection matters more than OCR: impatient customers re-send the same slip 3-4 times.
- Answer the webhook fast and push heavy work downstream — LINE times out quickly.

Happy to go deeper on any step. We also wrote up the slip-verification checklist we hand to shop admins here: [แผนภูมิตัดสินใจก่อนอนุมัติสลิปโอน (ฉบับร้าน 1–5 คน)](https://chatdechateam.github.io/easyrobin-docs/slip-fraud-flowchart.html)
