Video
Description
The first fully customizable Laravel JSON:API builder. "CRUD" and protect your resources with 0 (zero) extra line of code.
1. Setup the package:
php artisan restify:setup
2. Create your first repository:
php artisan restify:repository PostRepository --all
3. Enable MCP for AI agents (optional):
Add to your config/ai.php:
use Binaryk\LaravelRestify\MCP\RestifyServer;use Laravel\Mcp\Facades\Mcp; Mcp::web('restify', RestifyServer::class) ->middleware(['auth:sanctum']) ->name('mcp.restify');
That's it! Your API now serves both:
For Humans (JSON:API):
GET /api/restify/postsPOST /api/restify/postsPUT /api/restify/posts/1DELETE /api/restify/posts/1
For AI Agents (MCP):
GET /mcp/restify # Tool definitions and capabilities
Example Repository
use Binaryk\LaravelRestify\Http\Requests\RestifyRequest;use Binaryk\LaravelRestify\Repositories\Repository;use Binaryk\LaravelRestify\Attributes\Model; #[Model(Post::class)]class PostRepository extends Repository{ public function fields(RestifyRequest $request): array { return [ field('title')->rules('required', 'string', 'max:255'), textarea('content')->rules('required'), field('author')->readonly(), datetime('published_at')->nullable(), ]; }}
This single definition automatically provides:
- ✅ JSON:API CRUD endpoints with validation
- ✅ MCP tools for AI agents with the same validation
- ✅ Authorization policies applied to both interfaces
- ✅ Search and filtering capabilities for all consumers
Related Content on Laravel Daily
Video
Recent Courses on Laravel Daily
AI Agents/IDEs for Laravel: May 2026 (Claude Code, Codex, OpenCode, etc)
7 lessons
52 min
Roles and Permissions in Laravel 13
14 lessons
57 min
Queues in Laravel 13
18 lessons
1 h 12 min read