Back to Templates

Get Douyin video comments and replies with JustOneAPI

Created by

Created by: apisub001 || apisub001
apisub001

Last update

Last update 3 days ago

Categories

Share


Use this n8n workflow to get Douyin video comments and fetch replies for the first comment with replies using JustOneAPI.

Who’s it for

This template is for content researchers, creator operations teams, marketing teams, analysts, and automation builders who want to collect Douyin video comments and inspect reply threads inside n8n.

What this workflow does

The workflow starts from a Douyin video ID and requests the video comment list with the Video Comments V1 endpoint. It keeps the raw comments response for inspection, cleans the returned top-level comments, and selects the first comment where reply_comment_total is greater than 0.

If a matching comment is found, the workflow sends that comment ID to the Comment Replies V1 endpoint, keeps the raw replies response, cleans the returned replies, and outputs a final structured result. If no comment with replies is found on the selected comments page, the workflow returns a clear no-replies output with the cleaned comments and raw comments response.

This makes it useful for comment review, reply thread collection, engagement research, sentiment workflows, and downstream reporting automations.

What you need

  • A JustOneAPI token
  • A Douyin video ID / aweme ID
  • An n8n environment with HTTP Request node support

Set up

  1. Import the workflow into n8n.
  2. Open the Prepare API and Comment Data node.
  3. Add your JustOneAPI token.
  4. Replace awemeId with the Douyin video ID you want to inspect.
  5. Optionally adjust commentPage and replyPage.
  6. Run the workflow.
  7. Review the final output node and the raw output nodes if you need to debug the API response.

How it works

  1. Prepare the API inputs.
  2. Request the Douyin video comment list.
  3. Keep the raw comments response for troubleshooting.
  4. Clean the returned top-level comments.
  5. Select the first comment with reply_comment_total greater than 0.
  6. Request replies for the selected comment.
  7. Keep the raw replies response for troubleshooting.
  8. Clean the returned replies and build the final output.

Output

The final output can include:

  • awemeId
  • commentPage
  • replyPage
  • hasCommentWithReplies
  • commentsMeta
  • selectedComment
  • repliesMeta
  • totalCommentsReturned
  • replyCountReturned
  • comments
  • replies
  • rawCommentsResponse
  • rawRepliesResponse

If no comment with replies is found on the selected page, the workflow returns a no-replies result with a message, cleaned comments, comment metadata, and the raw comments response.

Notes

  • This workflow is built around the Douyin Video Comments V1 and Comment Replies V1 endpoints.
  • It only fetches replies for the first returned top-level comment that has replies.
  • You can change the comment selection logic in the code node if you want to use a different comment selection rule.
  • You can connect the final output to Google Sheets, Airtable, Notion, databases, dashboards, alerts, or AI analysis steps.