> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hiveku.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Workflow Recipe: Auto-Post New Blog Articles to LinkedIn

> Automatically share every new blog post on LinkedIn

Publish a blog post, walk away, and let the workflow push it to LinkedIn on your behalf — with optional AI rewriting to match LinkedIn's tone.

<Info>
  Before you start: connect your LinkedIn account (see [Social Posts](/how-tos/social-posts)) and publish at least one [blog post](/how-tos/post-a-blog) so the trigger has something to watch.
</Info>

## The Flow at a Glance

<CardGroup cols={3}>
  <Card title="1. DB trigger" icon="database">
    New published blog row
  </Card>

  <Card title="2. Delay + AI" icon="wand-magic-sparkles">
    Optional typo grace, tone rewrite
  </Card>

  <Card title="3. LinkedIn post" icon="linkedin">
    Publish to profile or org page
  </Card>
</CardGroup>

## Step 1: Create the Workflow

<Steps>
  <Step title="Start a new workflow">
    **Workflows** > **New Workflow**. Name it `Blog → LinkedIn`.
  </Step>

  <Step title="Add a Database trigger">
    Click **Add Trigger** > **Database**. Configure:

    * **Table:** `blog_posts`
    * **Event:** `INSERT` or `UPDATE`
    * **Condition:** `status = 'published'`

    This fires any time a row in `blog_posts` gets its status flipped to `published`.
  </Step>

  <Step title="Add an optional delay">
    Click **+ Add Action** > **Delay**. Set it to **15 minutes**. This gives you a grace window to catch typos before the post hits LinkedIn.
  </Step>

  <Step title="Add a Create LinkedIn Post action">
    Click **+ Add Action** > **Create LinkedIn Post**. Configure:

    * **Target:** your LinkedIn profile or org page (see [LinkedIn Organization Pages](/how-tos/linkedin-org-pages))
    * **Content:** the template below
    * **Schedule:** `Immediate`
  </Step>

  <Step title="Save and enable">
    Flip the **Enabled** toggle. Publish a test post (with throwaway content) to verify.
  </Step>
</Steps>

## Content Templates

### Manual Template

Straightforward. Copies title, excerpt, and a link:

```
New on the blog: {{trigger.title}}

{{trigger.excerpt}}

Read more: https://yoursite.com/blog/{{trigger.slug}}
```

### AI-Rewritten (Recommended)

Blog excerpts often read stiff on LinkedIn. Add an **AI Generation** step before the LinkedIn action:

<Steps>
  <Step title="Add AI Generation before the LinkedIn action">
    Click **+ Add Action** > **AI Generation**. Name the output `linkedin_copy`.
  </Step>

  <Step title="Write a strong prompt">
    Something like:

    ```
    Rewrite this blog excerpt as an engaging LinkedIn post.
    Requirements:
    - Start with a hook line (question or bold claim)
    - 3 short bullet points pulled from the content
    - End with a CTA to read the full post
    - Match this voice: conversational, smart, no jargon
    - Keep it under 1300 characters

    Blog title: {{trigger.title}}
    Blog excerpt: {{trigger.excerpt}}
    URL: https://yoursite.com/blog/{{trigger.slug}}
    ```
  </Step>

  <Step title="Reference the output in the LinkedIn action">
    In the Create LinkedIn Post action's **Content** field, use `{{linkedin_copy}}` instead of the manual template.
  </Step>
</Steps>

<Tip>
  Include a relevant image with every LinkedIn post. Posts with images see 2–3x the engagement of text-only. You can generate one in the workflow with an **AI Image Generation** step, or upload a cover image on the blog row and pass it through with `{{trigger.featured_image_url}}`.
</Tip>

## Template Shortcut

If a **Weekly Blog Pipeline** template is available in **Workflows > New**, it ships with this flow plus a weekly digest email.

## Test It

<Steps>
  <Step title="Create a test blog post">
    Title it something clearly testy — `Test Post — delete me`. Save as **Draft** first.
  </Step>

  <Step title="Flip to Published">
    Change status to `published` and save. This triggers the workflow.
  </Step>

  <Step title="Watch the runs log">
    **Workflows > Blog → LinkedIn > Runs**. The run should appear within seconds. If you added the 15-minute delay, the LinkedIn call is scheduled 15 minutes out — you'll see the run paused.
  </Step>

  <Step title="Verify on LinkedIn">
    After the delay, check your LinkedIn profile or org page. Delete the test post afterward.
  </Step>
</Steps>

## Customizations

### Avoid Double-Posting on Edits

If your blog is set to re-trigger on every edit, a post can go out twice. Add a condition to the trigger:

```
status = 'published' AND (old.status IS NULL OR old.status != 'published')
```

That limits firing to the transition from non-published to published, not subsequent edits.

### Cross-Post to Multiple Networks

After the LinkedIn action, add a parallel branch with **Create Twitter Post** and **Create Facebook Post** actions. The AI step can produce per-network copy variants:

```
Generate three social posts:
1. Twitter (under 280 chars, punchy)
2. LinkedIn (professional, with bullets)
3. Facebook (warm, conversational)

Blog: {{trigger.title}}
```

Then reference `{{ai_output.twitter}}`, `{{ai_output.linkedin}}`, etc.

## Troubleshooting

<AccordionGroup>
  <Accordion title="Post never appeared on LinkedIn">
    Most likely: the workflow is disabled (toggle it), or the LinkedIn connection expired. Go to **Marketing > Social > Accounts**, find LinkedIn, and click **Reconnect** if the token is stale. Also check the workflow's **Runs** tab for error messages.
  </Accordion>

  <Accordion title="AI copy reads generic">
    Improve the prompt. Include a voice/tone example, provide a do-not-say list, and give the model a hook or opening line style. Generic prompts get generic output — treat the prompt like a brief you'd give a freelancer.
  </Accordion>

  <Accordion title="Double-posting on every edit">
    Your trigger is firing on every update to the row. Either narrow the trigger to `INSERT` only, or add the status-transition condition above so only the draft→published flip triggers.
  </Accordion>

  <Accordion title="LinkedIn rate limit hit">
    LinkedIn limits posts per day per account (typically 25 for profiles, 100 for org pages). If you're batching a backlog, spread posts across days with a **Delay Until** step, or pick a smaller subset to auto-post.
  </Accordion>

  <Accordion title="Image doesn't attach">
    LinkedIn requires publicly accessible image URLs (not `localhost`, not behind auth). Host the image on your deployed site or a CDN, then pass the full URL. Max 5MB, PNG/JPG.
  </Accordion>
</AccordionGroup>

## What's Next?

<CardGroup cols={2}>
  <Card title="Content Pillars" icon="layer-group" href="/how-tos/content-pillars">
    Organize social content around consistent themes
  </Card>

  <Card title="LinkedIn Org Pages" icon="building" href="/how-tos/linkedin-org-pages">
    Post from your company page, not just your profile
  </Card>

  <Card title="Post a Blog" icon="pen" href="/how-tos/post-a-blog">
    Publish the blog posts that fuel this workflow
  </Card>
</CardGroup>
