Public open-source package
Laravel Post2Site
Adds draft review, content-key auth, field mapping, and IndexNow support to Laravel sites.
Laravel developers who want a content-only publishing API for n2n-post2site.
n2ns/laravel-post2sitev0.1.0MITLaravelPHPMCPPublishing

Overview
- Laravel package that adds a content-only API for n2n-post2site.
- Receives Markdown drafts from an MCP client while your Laravel app keeps control of storage and publishing.
- Supports review-only, configurable mapping, or custom adapters.
Common Uses
- Accept blog articles and guide updates from n2n-post2site.
- Keep content drafting separate from database, SSH, payment, and user permissions.
- Register published posts with search engines using IndexNow notifications.
Requirements
- PHP >= 8.2
- Laravel 12.x or 13.x
Install
- 1
composer require n2ns/laravel-post2site
- 2
php artisan vendor:publish --tag=post2site-config
- 3
php artisan vendor:publish --tag=post2site-migrations
- 4
php artisan migrate
Configure
- 1
php artisan post2site:key "Production MCP"
- 2
Set POST2SITE_PUBLISHING_MODE to review, configurable, or adapter in .env.
- 3
Map incoming content fields in config/post2site.php when using configurable mode.
Tools / Commands
- php artisan post2site:key [name] -- Generate a site-scoped API key for your MCP client.
- php artisan post2site:sync -- Manually sync publication status when needed.
Resources / Settings
- Draft and translation tables for reviewing incoming content before publication.
- Default API route prefix: /api/v1/mcp.
- Extension points for mapping package content into your Laravel models.
FAQ
Frequently asked questions and troubleshooting guides.
It generates a site-scoped API key for the MCP client and stores only a secure hash in your database. Requests must include that key in the Authorization header.
The package maps incoming Markdown fields, titles, slugs, and metadata into the Laravel models you define in config/post2site.php.