Friends,
In a previous issue, I shared with you how LLMs are scraping LinkedIn to reference content in their answers. So in today’s issue, I’m going to share with you how you can turn your existing blog posts & case studies (which are great content assets to have) into LinkedIn posts in as little as 5 seconds.
The problem is you probably have a lot of long form content queued up in your blogs, but you will gain so much more mileage if you repurpose these into LinkedIn posts, without you lifting a finger.
So in this step-by-step tutorial, I’ll show you how to build an AI agent that turns and repurposes your blog posts & case studies into viral LinkedIn posts using n8n & Firecrawl.
Here’s the workflow in a nutshell: Enter your blog post/case study URL → Firecrawl API scrapes the content’s website → Sends it to an AI agent that writes LinkedIn posts in your tone of voice → Sends it back to you.
This is designed for complete beginners. No coding required. You’ll learn how to connect it all into a working system that can generate LinkedIn posts based on your blog posts and case studies. If you’ve been curious about how to build AI powered marketing workflows, but didn’t know where to start, this is the perfect place to begin.
Let’s dive in, shall we?
More of a video person? Check this out 👇
Want to read along? Here you go: 👇
You can build an AI agent to turn blog posts into LinkedIn posts by connecting n8n, Firecrawl, and an AI model, following these steps.
Here’s a clear, step-by-step action plan:
Step 1. Set Up n8n
Sign up for or install n8n, a no-code workflow automation platform.
Create a new workflow in n8n.
Step 2. Create a Chat Interface Trigger
Add a trigger node in n8n for receiving a chat message (this will be where you input your blog post or case study URL).
Make the chat interface publicly accessible or use it as a standalone URL.
Step 3. Integrate Firecrawl API for Content Scraping
Add an HTTP Request node in n8n to call the Firecrawl API.
Configure the node to send a POST request with the blog post URL.
In the request body, specify that you want the article’s title, author, and main content returned in JSON format.
here’s what you do:
Set the Method to POST.
URL - https://api.firecrawl.dev/v1/scrape
Set up Authentication as generic credential type
Set the generic auth type as header auth
Set up a new credential by pasting in your API key from Firecrawl. (Remember to put in Bearer *space* before pasting in your API key).
Set the body content type as Json:
Here’s the Curl import code you can copy paste into the Json body type node:
{
"url": "{{ $json.chatInput }}",
"formats": ["json"],
"onlyMainContent": true,
"removeBase64Images": true,
"blockAds": true,
"proxy": "auto",
"jsonOptions": {
"prompt": "Extract the article's title, author name, and the full main body text. Return the output in JSON format with fields: title, author, content."
}
}
You’re set.
Step 4: Process and Extract Content
When you run the workflow by pasting in your blog URL in the chat window, the Firecrawl API responds to extract the title, author, and main content fields (something like the image below).
Then, you simply pass the main content to the next step in your workflow.
Step 5. Connect to the AI agent
Add another node to build an AI agent. Connect it to your LLM of choice via your API key.
Craft a prompt for the AI model:
Instruct it to write a LinkedIn post (max 1500 characters) in the same tone as the original content.
Tell it to use a strong hook as the first line (see next step).
Add guardrails to avoid generic or AI-sounding phrases.
This is the prompt I used for the AI agent:
You are a helpful content creator for Chameleon's LinkedIn page. Use the below steps to create content:
Steps:
1. Write a 1500 character LinkedIn post based on this text:
{{ $json.data.json.content }}.
Always write the LinkedIn post in the same tone of voice as the above text. Never exceed 1500 characters.
2. Write the hook (the first line of the post) by using the Hook_Writer_Tool to make sure the hook is of a high quality.
3. The final output should be the LinkedIn post.
Rules:
- make sure to not include any words at the top like "here's your post" or "here's the generated post" or even ends like "the post fufils your requirements" or something like that. There should be ZERO of these introduction or concluding phrases. Just output the main post, that's it. Nothing more, nothing less.
- The first line of your output should be the hook - the first line of the LinkedIn post.
- Don't use phrases like "it's not X it's Y" or "here's what this means" or "And the kicker?" Or similar phrases.
- Keep it actionable and useful. Always ask yourself - Would the reader find this useful?
- NEVER use phrases like "Based on the Hook Writer Tool analysis, I'll create a strong hook for the post about product tours". Your first line of the response should be the hook aka the first line of the LinkedIn post.
Pro tip - Save this prompt to Lexi & tag it so you can re-use it any time.
Step 6. Build or Integrate a Hook Writer Tool
Create a hook-writer with a list of high-performing LinkedIn hooks in a separate workflow.
here there’s simply a test workflow button + a Google sheets node where I have stored a list of 100-150 Linkedin hooks.
Add this tool in the tool section of the AI agent by simply choosing “call another workflow” when clicking the tool button.
And as you can see in the prompt above that its instructed to call this tool when creating Linkedin posts.
Step 7. Generate and Output the LinkedIn Post
The AI model returns a LinkedIn-ready post.
Display the output in your chat interface or send it to another platform (e.g., Slack, Notion, Airtable) as needed.
Step 8. (Optional) Expand Integrations
Add more nodes to send the LinkedIn post to other tools or platforms (e.g., Slack, Notion, Airtable, ClickUp, Typefully). or you can even set up a Slack trigger where you can paste in your blog posts into Slack or even via email, whatsapp what have you.
Liked this issue? Here’s how you can support me:
Hire me to build out your own custom AI marketing workflow.
Share this issue with your friends!
See you soon!
Best,
Shounak.