thread-master/docs/product/demand-radar/tasks/T550-reply-send-outbox-heal...

1.8 KiB
Raw Blame History

T550 — reply-send-outbox-health-gate

Status: done
Milestone: M3
Kind: feat
Est. change: ~180 lines

Goal

完成後系統應:公開留言版經既有海巡外展Outbox 送出且必過 AccountHealth 送出閘;私訊版只提供複製並標記完成。

Depends on

  • T549

Inputs

  • Spec../spec.md §4.5.6、§4.5.7、§9.3RP-04、RP-05、§6不新增繞過護欄路徑
  • 既有:apps/backend/internal/logic/outbox/**internal/module/growth/**AccountHealth 送出閘、scout 外展送出

Outputs

程式變更(預期路徑)

路徑 動作 說明
apps/backend/internal/module/radar/usecase/reply_send.go add 公開留言 → 既有 Outbox外展入口送前呼叫既有健康閘
apps/backend/generate/api/radar.api edit 送出/標記已使用 request`channel=outbox
apps/backend/internal/logic/radar/sendOpportunityReplyLogic.go edit 接線+錯誤映射;MarkUsed 記錄管道

行為變更

  • AccountHealth=warn:可送但回應帶警示;throttle拒絕自動送出,只回手動路徑提示(沿用既有錯誤語意)。
  • 私訊版(dm):不提供自動送出端點,只能 channel=manual_copy 標記;回應與文案不得宣稱已自動送出。
  • Outbox 行為不變:僅平台成功後才 publishedRG-02

Out of scope

  • 前端複製與送出按鈕T552
  • FollowUp 建立T585

Acceptance

  • RP-04throttle 帳號自動送出被拒,手動路徑可用
  • RP-05dm 無自動送出路徑
  • RG-02Outbox 發布語意回歸測試通過
  • 指令:
cd apps/backend && go test ./internal/module/radar/... ./internal/logic/outbox/... -count=1