- Home
- Skills
- APIs & Backend
- CodeIgniter 4 Master
Works with the AI Agents you already use
CodeIgniter 4 Master
Building modern PHP applications often results in bloated controllers and guessed database schemas.
$29
CodeIgniter 4 Master
Example session with this skill installed
Scaffold a new resource for Invoices with fields for number (string), total (float), and issuedAt (date). Include a repository and tests.
- Read your context and instructions
- Compiled the codeigniter 4 master
I have analyzed the current project structure and prepared the Invoice resource. I will now generate the controller, service, model, entity, migration, and test suite using the service-repository pattern.
Scaffolded Invoice Module
// app/Entities/Invoice.php
declare(strict_types=1);
namespace App\Entities;
use CodeIgniter\Entity\Entity;
class Invoice extends Entity
{
protected $attributes = [
'id' => null,
'number' => null,
'total' => null,
'issuedAt' => null,
'created_at' => null,
'updated_at' => null,
];
protected $casts = [
'total' => 'float',
'issuedAt' => 'datetime',
];
}
The following components were created
- Controller:
InvoiceController.php(Restricted to request handling, delegates to Service) - Service:
InvoiceService.php(Contains validation logic formax:50on number) - Repository:
InvoiceRepository.php(Handles persistence logic) - Migration:
20231027103000_create_invoices_table.php - Tests:
tests/unit/InvoiceServiceTest.php
Next steps
- Review the generated migration file in
app/Database/Migrations/. - Run
php spark migrateto update your database schema. - Check
Config/Routes.phpto ensure the new resource routes are registered.
Connects securely to your tools. The creator never sees your data.
About this skill
Building modern PHP applications often results in bloated controllers and guessed database schemas. This skill turns your agent into a senior CodeIgniter 4 architect to enforce clean MVC patterns and eliminate manual boilerplate.
What it does
- Instant CRUD scaffolding generates controllers, services, models, entities, and migrations in under 15ms.
- Runtime introspection connects to your live app via MCP to inspect real database schemas and route tables.
- Strict architectural linting enforces zero-SQL in controllers and ensures all business logic stays in the Service layer.
- Route collision detection validates new endpoints against existing
Config/Routes.phpplaceholders and resource expansions. - Automated migrations handles database schema updates with a safe, user-confirmed execution flow.
How it works
- Introspection setup scaffolds a specialized Spark command to provide real-time reflection of your app state.
- Schema inspection queries your live database to identify exact column types and constraints before writing code.
- Resource generation produces full-stack modules including CSRF-safe views and PHP 8.1 typed entities.
- Compliance auditing runs AST-based checks to ensure strict typing and framework-specific naming conventions.
Frameworks & tools
Built for PHP 8.1+ and CodeIgniter 4. Integration requires Node.js 20+ to run the codeigniter-mcp server for live runtime reflection.
Why this beats prompting it yourself
Generic prompts often produce flat, legacy-style PHP files or hallucinate table structures. This skill uses live introspection to ground every line of code in your actual database schema while enforcing high-level patterns like Repository and Service layers that standard LLMs often skip.
Use cases
- Scaffold enterprise-grade CRUD modules with built-in validation and unit tests.
- Refactor legacy CodeIgniter controllers to move logic into Services and Repositories.
- Inspect live database tables to generate precisely typed PHP Entities.
- Audit existing codebases for security vulnerabilities like missing CSRF protection in DELETE actions.
Known limitations
Requires a functional CodeIgniter 4 environment and the ability to run local PHP Spark commands via the MCP bridge. DB queries are limited to read-only SELECT operations.
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for APIs & Backend.
Requires PHP 8.1+ and Node.js 20+. Database tool is restricted to read-only SELECT queries capped at 50 rows. Requires MCP server configuration for live introspection.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 9 days ago
- Software
Node.jsCodeigniter MCP