Religion BFF API
App 所需的內容、版本、公告通知、會員支援與點數查詢都由 BFF 統一承接。
Religion BFF 是 App 與後端服務之間的安全邊界。公開查詢可以直接使用;會員、付款點數與管理端點需要相應 token 或後端授權。
Endpoint 清單
| 方法 | 路徑 | 用途 | 權限 |
|---|---|---|---|
| GET | /health | BFF 健康狀態。 | 公開 |
| GET | /api/app/config | App 顯示設定、平台能力與下載入口。 | 公開 |
| GET | /api/app/version | App 版本、build 與更新資訊。 | 公開 |
| GET | /api/app/bootstrap | App 啟動所需基本資料。 | 公開 |
| GET | /api/temples, /api/temples/{id} | 廟宇資料列表與詳情。 | 公開 |
| GET | /api/announcements, /api/announcements/{id} | Religion App 公告列表與詳情。 | 公開 |
| POST | /api/announcements/{id}/read | 標記公告已讀。 | App / Member token |
| GET | /api/notifications | 通知列表。 | App / Member token |
| POST | /api/notifications/{id}/read | 標記通知已讀。 | App / Member token |
| POST | /api/religion-ai/{mode} | 宗教 AI 模式互動。 | App / 受控 |
| GET | /api/member/onboarding, /api/member/query-profile | 集中會員 onboarding 與會員資料查詢代理。 | Member token |
| GET | /api/payment-points/me/balance, /api/payment-points/me/transactions | 目前會員的點數餘額與交易紀錄代理。 | Member token |
| GET | /api/payment-points/orders, /api/payment-points/finance/payment-summary | 訂單與財務摘要代理。 | 受控權限 |
| GET | /api/wems/announcements, /api/wems/notifications | 共用 WEMS 公告與通知整合。 | WEMS integration |
| POST | /api/admin/* | 管理端登入、公告、通知、廟宇、對話與支援訊息管理。 | Admin token |
快速測試
curl -sS "https://religion.sun-bd.com/health"
curl -sS "https://religion.sun-bd.com/api/app/version"
curl -sS "https://religion.sun-bd.com/api/app/bootstrap"公告通知
curl -sS "https://religion.sun-bd.com/api/announcements"
curl -sS "https://religion.sun-bd.com/api/notifications" \
-H "Authorization: Bearer MEMBER_TOKEN"


安全與分工
- BFF 可代理會員與點數資料,但會員登入與付款點數的正式 API 仍由專屬子系統負責。
- 管理端
/api/admin/*不作為公開對接入口,需 Admin token 與後台權限。 - 集中會員 API 請參考 會員登入 API 教學;付款點數請參考 Payment Points API。