whatisgithub

What is threads-affiliate?

d4ncboz/threads-affiliate — explained in plain English

Analysis updated 2026-05-18

16PythonAudience · generalComplexity · 3/5LicenseSetup · moderate

In one sentence

A Python and Playwright tool that automates posting Indonesian-language affiliate marketing content to Threads, with link rotation and duplicate-post checks.

Mindmap

A visual breakdown will appear here once this repo is fully enriched.

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Automate daily affiliate posts to Threads for Shopee, Lazada, or Tokopedia products across skincare, perfume, haircare, and makeup categories.

USE CASE 2

Rotate between hook writing styles and product categories so consecutive posts don't repeat.

USE CASE 3

Schedule batches of posts at set times of day similar to a cron job.

USE CASE 4

Check new posts against recent ones for wording similarity before publishing.

What is it built with?

PythonPlaywrightCLI

How does it compare?

d4ncboz/threads-affiliate920linjerry-stack/capital-studioadya84/ha-world-cup-2026
Stars161616
LanguagePythonPythonPython
Setup difficultymoderateeasyeasy
Complexity3/53/52/5
Audiencegeneralresearchergeneral

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 1h+

Requires a warmed-up Instagram/Threads account, an approved Shopee affiliate account, and extracted browser session cookies before the first post can run.

MIT license: free to use, modify, and redistribute, including commercially.

So what is it?

Threads Affiliate Poster ID is a Python toolkit that automates posting affiliate marketing content, written in Indonesian, to the Threads social network. It is built for people promoting products from Shopee, Lazada, or Tokopedia in categories like skincare, perfume, haircare, and makeup, and it handles the repetitive parts of running many posts a day. Before the automation can run, a person has to do some setup by hand: creating a real, human-looking Instagram and Threads account and warming it up with a few manual posts, signing up for the Shopee affiliate program and waiting for approval, building a list of affiliate links in a simple Markdown table, and extracting the browser session cookies the tool needs to act as if it were logged in. Once that groundwork is done, the tool picks an unused affiliate link from the database, chooses a product category and a writing style while avoiding repeating the same category or style used in the last couple of posts, fills in a post using one of many prewritten hook templates, checks that the new post is not too similar in wording to the last several posts, and then uses the Playwright browser automation library to actually log in and publish the post. Posts can be run one at a time from the command line or scheduled automatically at set times of day, similar to a cron job. The project describes these repetition checks and category rotation as anti-spam measures meant to keep the posting pattern looking natural rather than mechanical. Affiliate links and session cookies are meant to be stored locally, not committed to the repository. The project includes documentation aimed specifically at AI coding agents, describing setup steps and canonical workflows for automating it further. It requires Python 3.10 or newer and is released under the MIT license, meaning it can be freely used, modified, and redistributed.

Copy-paste prompts

Prompt 1
Walk me through the four prerequisite setup steps before I can run this tool: account, affiliate signup, link database, and cookies.
Prompt 2
Help me build my affiliate_links.md database following the format this project expects.
Prompt 3
Explain how the hook-style and category rotation logic decides what to post next.
Prompt 4
Show me how to schedule batch posts using the built-in scheduler.
Prompt 5
Help me extract my Instagram and Threads session cookies for this tool using browser_cookie3.

Frequently asked questions

What is threads-affiliate?

A Python and Playwright tool that automates posting Indonesian-language affiliate marketing content to Threads, with link rotation and duplicate-post checks.

What language is threads-affiliate written in?

Mainly Python. The stack also includes Python, Playwright, CLI.

What license does threads-affiliate use?

MIT license: free to use, modify, and redistribute, including commercially.

How hard is threads-affiliate to set up?

Setup difficulty is rated moderate, with roughly 1h+ to a first successful run.

Who is threads-affiliate for?

Mainly general.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.