Create WordPress drafts with Claude Haiku and Pexels images
Ready for 3.0What this workflow does
This AI workflow has 10 nodes and runs manually, when you click “Execute workflow”. Along the way it connects Anthropic and Wordpress. It also calls api.pexels.com over HTTP.
How it runs
Trigger: Manually, when you click “Execute workflow”.
- Set Post Fields (Edit Fields (Set)): sets 2 fields: title, content
- Get Image Query from Content (Code): runs custom JavaScript code
- Generate Pexels Search Keywords (Anthropic): uses Anthropic
- Refine Search Keywords (Code): runs custom JavaScript code
- Fetch Pexels Images (HTTP Request): calls api.pexels.com
- Download Selected Image (HTTP Request): calls an HTTP API
- Upload Image to WordPress (HTTP Request): calls an HTTP API (POST)
- Publish WordPress Post (Wordpress): uses Wordpress
- Set Post Featured Image (HTTP Request): calls an HTTP API (PATCH)
Services it uses
HTTP calls to: api.pexels.com
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
Nodes used (6)
- Manual Trigger
n8n-nodes-base.manualTrigger - Edit Fields (Set)
n8n-nodes-base.set - Code
n8n-nodes-base.code - Anthropic
@n8n/n8n-nodes-langchain.anthropic - HTTP Request
n8n-nodes-base.httpRequest - Wordpress
n8n-nodes-base.wordpress
From the author
Quick overview This workflow takes a blog post title and content, generates a short Pexels search phrase with Anthropic Claude, downloads a matching stock photo from Pexels, uploads it to your WordPress media library, creates a draft WordPress post, and sets…