Amazon Affiliate Links to Mastodon with AI Descriptions & Shlink Tracking
This n8n workflow automates posting Amazon affiliate products to Mastodon β complete with image upload, description, and a shortened tracking URL using Shlink.
π§ How it works
Input Source: The workflow starts by reading from a connected Google Sheet that contains:
SHlink (Shortlink) Amazon Link Description (Optional) PicURL Send /NO or YES
A Send column (used as a flag to check if the row was already posted)
Image Upload: It fetches the product image via HTTP and uploads it directly to a Mastodon instance via the /media API endpoint.
URL Shortening (Shlink): The original Amazon URL is shortened using your self-hosted or cloud-hosted Shlink instance to enable click tracking and better presentation.
Text Generation: A two-line promotional text is automatically generated using a Language Model (LLM), based on the product description.
Posting to Mastodon: The post is then published on Mastodon with:
The image
The generated text
The shortened Shlink URL
Row Update: Once published, the Send column in the Google Sheet is updated to "YES" to prevent duplicates.
Requirements
β
Shlink β Required for shortening and tracking Amazon URLs
β
Google Sheet β Used as a product queue and post
β
Google Sheet Example https://link.unixweb.home64.de/w7VqY
β
Mastodon account β OAuth2 credentials with write scope
β
Product image URL β Must be valid and accessible
β
n8n credentials β Set up for Google Sheets, Mastodon, and optionally OpenRouter or other LLM providers
This workflow is ideal for content creators, affiliate marketers, and automation fans who want to save time and optimize reach across the Fediverse.
#affiliate #amazon #mastodon #advertisment
Related Templates
Extract Named Entities from Web Pages with Google Natural Language API
Who is this for? Content strategists analyzing web page semantic content SEO professionals conducting entity-based anal...
Add product ideas to Notion via a Slack command
Use Case In most companies, employees have a lot of great ideas. That was the same for us at n8n. We wanted to make it a...
Automate Daily Keyword Research with Google Sheets, Suggest API & Custom Search
Who's it for This workflow is perfect for SEO specialists, marketers, bloggers, and content creators who want to automa...
π Please log in to import templates to n8n and favorite templates
Workflow Visualization
Loading...
Preparing workflow renderer
Comments (0)
Login to post comments