Contributors: daniyal
Tags: api, automation, blogging, seo, content, wordpress
Requires at least: 5.8
Tested up to: 6.5
Requires PHP: 7.4
Stable tag: 1.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Description
API to Blog Post Publisher is a WordPress plugin that automatically fetches content from an external API and publishes it as a WordPress blog post.
The plugin:
Fetches blog data via cURL
Creates a WordPress post
Downloads and sets a featured image from URL
Assigns posts to categories by name
Adds SEO meta title & description
Supports Yoast SEO, Rank Math, and All in One SEO
Allows manual publishing and daily automatic scheduling
Ideal for:
Auto-blogging systems
Content syndication
Headless CMS integrations
AI-generated content pipelines
Features
🔌 Fetch data from API using cURL
📝 Auto-create WordPress blog posts
🖼 Download & attach featured images
🗂 Auto-create & assign categories
🔍 SEO meta support (Yoast, Rank Math, AIO SEO)
⚙ Manual publish button in admin
⏱ Daily scheduled auto-publishing (WP-Cron)
🔐 Secure admin actions with nonce verification
Supported SEO Plugins
The plugin automatically detects and supports:
✅ Yoast SEO
✅ Rank Math SEO
✅ All in One SEO
No extra configuration needed.
API Response Format
Your API endpoint should return JSON in the following format:
Copy code
Json
{
	"title": "aritcle title",
	"description": "<html><head></head><body><p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s,</p></body></html>",
	"feature_img":"https://domain.com/image.png",
	"meta_title": "article meta title",
	"meta_description": "aritcle meta description",
	"category": ["category A", "category B", "category C"]
}
Installation
Upload the plugin folder to /wp-content/plugins/
Activate API to Blog Post Publisher from the Plugins menu
Go to Dashboard → API Publisher
Usage
Manual Publish
Navigate to Admin Dashboard → API Publisher
Click Fetch & Publish Post
The plugin will:
Fetch API data
Create the post
Assign categories
Upload featured image
Apply SEO meta
Enable Daily Auto-Publishing
Go to Admin Dashboard → API Publisher
Click Enable Daily Schedule
The plugin will automatically publish one post daily
⚠ WP-Cron requires site traffic. For production, a real server cron is recommended.
Scheduling (WP-Cron)
The plugin registers a daily cron job:
Copy code
Php
atp_daily_event
To trigger WP-Cron via server (recommended):
Copy code
Bash
*/5 * * * * wget -q -O - https://example.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1
Security
Nonce verification for admin actions
Sanitized post data
Safe image handling
WordPress native APIs only
Requirements
WordPress 5.8+
PHP 7.4+
cURL enabled on server
Known Limitations
One post per API request
No duplicate detection (can be extended)
API URL is currently hardcoded
Roadmap
API settings page
Authentication (Bearer / API Key)
Duplicate post prevention
Draft & review mode
Multiple API sources
Error logging panel
Custom scheduling intervals
Frequently Asked Questions
Does this plugin support multiple SEO plugins?
Yes. It auto-detects Yoast, Rank Math, and All in One SEO.
Can I schedule posts hourly?
Currently daily only. Custom intervals can be added.
Can I use this for AI-generated content?
Yes. This plugin is ideal for AI and auto-blogging workflows.
Changelog
1.0
Initial release
API fetch via cURL
Auto post creation
Featured image upload
Category assignment
SEO plugin integration
Manual & scheduled publishing
License
This plugin is licensed under the GPLv2 or later.
Author
Daniyal Hassan