Skip to content

fix: collect Douyin metrics from current work-detail pages - #78

Closed
zhu-siyuan wants to merge 1 commit into
XBuilderLAB:mainfrom
zhu-siyuan:codex/fix-douyin-work-detail
Closed

zhu-siyuan wants to merge 1 commit into
XBuilderLAB:mainfrom
zhu-siyuan:codex/fix-douyin-work-detail

Conversation

@zhu-siyuan

Copy link
Copy Markdown

The Douyin detail collector still used /creator-micro/data/following/media?item_id=.... That route can load successfully while showing the account's following list, so the adapter silently misses work-level watch-time and retention data.

This change opens /creator-micro/work-management/work-detail/<aweme_id>, verifies the work-detail UI, and visits the Traffic Analysis tab to capture its lazy-loaded metrics. It excludes account-wide dashboard responses, removes URL query strings from captured endpoint labels, and fails explicitly on missing detail responses. Reports now include visible overview/traffic snapshots and preserve complete responses in a companion detail.json, including when the wrapper relocates the report.

Validation:

  • Six offline regression tests pass: ID validation, response filtering, wrong/login page failure, empty-response failure, lazy-loaded retention capture, and report text preservation.
  • Read-only verification against an authenticated published work retrieved summary JSON, average-watch-time UI, and retention JSON (eight matching responses).
  • git diff --check passes.

No account credentials, real work IDs, user metrics, comments, screenshots, or media are included. Existing comment collection behavior is unchanged. The browser selectors and API paths remain subject to future platform changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant