feat(ops): ECR-007 行为分析与 ECR-008 内容运营后台
ci / h5 (push) Canceled after 0s
ci / api (push) Canceled after 0s
ci / ess-docs (push) Canceled after 0s

落地埋点 ingest/数据看板、首页宫格 CMS 与测评上下架;含账号引导、问答流式与免责声明去重,以及 review P1 审计同事务修复。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
jackyu66git
2026-08-07 02:26:16 +08:00
co-authored by Cursor
parent 7e9023f0a8
commit 7ab9add5dd
132 changed files with 8276 additions and 491 deletions
+171 -3
View File
@@ -148,6 +148,174 @@ paths:
'200':
description: OK
/api/v1/admin/analytics/overview:
get:
tags: [admin]
summary: Behavior analytics overview (DAU / sessions)
parameters:
- in: query
name: from
schema: { type: string, format: date }
- in: query
name: to
schema: { type: string, format: date }
responses:
'200':
description: OK
/api/v1/admin/analytics/pages:
get:
tags: [admin]
summary: Page PV/UV/dwell/exit aggregates
parameters:
- in: query
name: from
schema: { type: string, format: date }
- in: query
name: to
schema: { type: string, format: date }
responses:
'200':
description: OK
/api/v1/admin/analytics/exits:
get:
tags: [admin]
summary: Exit page ranking
parameters:
- in: query
name: from
schema: { type: string, format: date }
- in: query
name: to
schema: { type: string, format: date }
responses:
'200':
description: OK
/api/v1/admin/analytics/clicks:
get:
tags: [admin]
summary: UI click ranking
parameters:
- in: query
name: from
schema: { type: string, format: date }
- in: query
name: to
schema: { type: string, format: date }
responses:
'200':
description: OK
/api/v1/admin/analytics/funnel:
get:
tags: [admin]
summary: Core funnel step counts
parameters:
- in: query
name: from
schema: { type: string, format: date }
- in: query
name: to
schema: { type: string, format: date }
responses:
'200':
description: OK
/api/v1/analytics/events:
post:
tags: [system]
summary: Batch ingest behavior events (DeviceAuth)
requestBody:
required: true
content:
application/json:
schema:
type: object
required: [items]
properties:
items:
type: array
maxItems: 100
items:
type: object
required: [name, session_id, client_ts]
properties:
name: { type: string }
session_id: { type: string }
page_path: { type: string }
client_ts: {}
props: { type: object }
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/Envelope'
/api/v1/home/tools:
get:
tags: [system]
summary: Homepage grid tools (enabled only)
responses:
'200':
description: OK
/api/v1/admin/home/tools:
get:
tags: [admin]
summary: List all homepage tools
responses:
'200':
description: OK
put:
tags: [admin]
summary: Replace homepage tools
requestBody:
required: true
content:
application/json:
schema:
type: object
required: [items]
properties:
items: { type: array }
responses:
'200':
description: OK
/api/v1/admin/scales:
get:
tags: [admin]
summary: List all scales (incl. draft)
responses:
'200':
description: OK
/api/v1/admin/scales/{id}:
patch:
tags: [admin]
summary: Set scale status published|draft
parameters:
- in: path
name: id
required: true
schema: { type: string, format: uuid }
requestBody:
required: true
content:
application/json:
schema:
type: object
required: [status]
properties:
status: { type: string, enum: [published, draft] }
responses:
'200':
description: OK
/api/v1/profiles:
get:
tags: [profile]
@@ -681,7 +849,7 @@ paths:
/api/v1/orders:
post:
tags: [commerce]
summary: 创建订单(membership | deep_access
summary: 创建订单(membership | deep_access | ask_pack
requestBody:
required: true
content:
@@ -735,8 +903,8 @@ components:
type: object
required: [kind]
properties:
kind: { type: string, enum: [membership, deep_access] }
plan: { type: string, description: month|quarter|year when membership }
kind: { type: string, enum: [membership, deep_access, ask_pack] }
plan: { type: string, description: month|quarter|year when membership; pack10|pack30|pack100 when ask_pack }
report_id: { type: string, format: uuid, description: when deep_access }
# --- Aligned with packages/types (ECR-004) ---