# Hướng dẫn theo dõi tracking landing cho SEO

Tài liệu này giúp team SEO/Marketing theo dõi kết quả theo từng trang landing và từng event.

## 1) Phạm vi trang được tracking

- Landing Membership
- Landing Bee Support
- Landing Physical Card

Tất cả event đều có tham số:

- `landing_variant`
  - `membership`
  - `bee_support`
  - `physical_card`

## 2) Danh sách event chuẩn

### A. Event theo trang

- `landing_page_view`
  - Khi vào trang landing.
- `landing_page_exit`
  - Khi rời trang.
  - Có params:
    - `time_on_page_seconds` (thời gian ở trang)
    - `is_bounce` (1 = bounce, 0 = không bounce)

### B. Event theo hành vi click

- `landing_page_product_buy_click`
  - Click nút mua thẻ (chưa cần thanh toán thành công).
  - Params:
    - `product_id`
    - `product_name`
    - `product_slug`
    - `product_price`

- `landing_page_product_tab_click`
  - Click nút tên loại thẻ/tab thẻ.
  - Params:
    - `product_index`
    - `product_name`
    - `product_slug`
  - Lưu ý:
    - Bee Support hiện tại không có UI tab thẻ giống Membership/Physical, nên event này có thể ít hoặc không phát sinh trên Bee.

- `landing_page_benefit_click`
  - Click vào quyền lợi.
  - Params:
    - `benefit_position`
    - `benefit_title`
    - `benefit_device` (`desktop`/`mobile`)
    - `click_source` (`number_dot` hoặc `benefit_title`)

- `landing_page_guide_flow_click`
  - Click tên flow quy trình (Đăng ký/Quản lý/Sử dụng...).
  - Params:
    - `flow_name`
    - `flow_index`

- `landing_page_guide_function_click`
  - Click tên quy trình/chức năng bên trong flow.
  - Params:
    - `flow_name`
    - `function_name`
    - `flow_index`
    - `function_index`

- `landing_page_app_download_click`
  - Click nút tải app.
  - Params:
    - `platform` (`app_store`, `google_play`, `mobile_auto`)
    - `device` (`desktop`/`mobile`)
    - `href`

## 3) Mapping KPI SEO/Marketing -> event

- Lượt traffic vào trang
  - Event: `landing_page_view`
  - Nhóm theo: `landing_variant`

- Thời gian ở trang bình quân
  - Event: `landing_page_exit`
  - Metric: average(`time_on_page_seconds`)
  - Lọc theo: `landing_variant`

- Tỉ lệ thoát (bounce)
  - Event: `landing_page_exit`
  - Công thức gợi ý:
    - `Bounce rate = Số event is_bounce=1 / Tổng event landing_page_exit`
  - Lọc theo: `landing_variant`

- Lượt click nút mua theo từng loại thẻ
  - Event: `landing_page_product_buy_click`
  - Nhóm theo:
    - `landing_variant`
    - `product_name` (hoặc `product_slug`)

- Lượt click tên loại thẻ
  - Event: `landing_page_product_tab_click`
  - Nhóm theo:
    - `landing_variant`
    - `product_name`

- Lượt click từng quyền lợi
  - Event: `landing_page_benefit_click`
  - Nhóm theo:
    - `landing_variant`
    - `benefit_title`
    - `click_source`

- Lượt click tên quy trình sử dụng dịch vụ
  - Event:
    - `landing_page_guide_flow_click`
    - `landing_page_guide_function_click`
  - Nhóm theo:
    - `landing_variant`
    - `flow_name`
    - `function_name`

- Lượt click tải app (App Store/CH Play)
  - Event: `landing_page_app_download_click`
  - Nhóm theo:
    - `landing_variant`
    - `platform`
    - `device`

## 4) Checklist đối soát sau khi release

- Đã thấy `landing_page_view` trên cả 3 variant.
- Đã thấy `landing_page_exit` có `time_on_page_seconds`.
- Click nút mua có event `landing_page_product_buy_click` và có `product_name`.
- Click quyền lợi có event `landing_page_benefit_click`.
- Click flow/function trong Guides có event tương ứng.
- Click App Store/Google Play có `landing_page_app_download_click`.

## 5) Lưu ý khi làm report

- Luôn đặt bộ lọc `landing_variant` để tránh gộp chung 3 trang.
- Nếu cần đối chiếu conversion:
  - dùng `landing_page_product_buy_click` là mốc click intent
  - đối chiếu tiếp với event/dữ liệu thanh toán ở hệ thống checkout.
