No description
Find a file
darbs-claude c315fc43c6
Some checks failed
CI / PHP 8.3 (pull_request) Failing after 1m47s
CI / PHP 8.4 (pull_request) Failing after 1m46s
fix: validate API keys on AgenticManager init (#29)
Log a warning for each AI provider registered without an API key so
that misconfiguration is surfaced at boot time (not silently on the
first API call).  Each message names the environment variable to set:

  ANTHROPIC_API_KEY  – Claude
  GOOGLE_AI_API_KEY  – Gemini
  OPENAI_API_KEY     – OpenAI

Providers without a key remain registered but are marked unavailable
via isAvailable(), preserving backward compatibility.

- Add Log::warning() calls in registerProviders() for empty keys
- Extend AgenticManagerTest with a dedicated 'API key validation
  warnings' describe block (7 new test cases)
- Update DX-002 in TODO.md as resolved

Closes #29

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-23 11:39:01 +00:00
.forgejo/workflows ci: run unit tests only (feature tests need full app) 2026-02-23 06:26:41 +00:00
.gemini Initial commit 2026-01-26 23:20:30 +00:00
.github monorepo sepration 2026-01-27 00:28:29 +00:00
changelog/2026/jan docs(changelog): add completed P2 items for January 2026 2026-01-29 19:52:33 +00:00
Configs refactor: rename namespace Core\Agentic to Core\Mod\Agentic 2026-01-27 16:12:58 +00:00
Console/Commands chore: fix pint code style and add test config 2026-02-23 03:50:09 +00:00
Controllers refactor: namespace cache keys to prevent collisions (closes #20) 2026-02-23 06:18:30 +00:00
database/migrations monorepo sepration 2026-01-27 00:28:29 +00:00
docs security: fix SQL injection and add workspace scoping to MCP tools 2026-01-29 12:21:01 +00:00
Facades refactor: rename namespace Core\Agentic to Core\Mod\Agentic 2026-01-27 16:12:58 +00:00
Jobs refactor(jobs): remove processOutput stub from ProcessContentTask 2026-02-23 05:45:46 +00:00
Lang/en_GB monorepo sepration 2026-01-27 00:28:29 +00:00
Mcp chore: fix pint code style and add test config 2026-02-23 03:50:09 +00:00
Middleware chore: fix pint code style and add test config 2026-02-23 03:50:09 +00:00
Migrations fix: add missing database indexes (closes #21) 2026-02-23 06:29:14 +00:00
Models refactor: add Builder return types to all Eloquent query scopes 2026-02-23 05:32:38 +00:00
routes chore: fix pint code style and add test config 2026-02-23 03:50:09 +00:00
Service feat(menu): move Agentic to dedicated agents group 2026-02-08 20:10:24 +00:00
Services fix: validate API keys on AgenticManager init (#29) 2026-02-23 11:39:01 +00:00
Support refactor: rename namespace Core\Agentic to Core\Mod\Agentic 2026-01-27 16:12:58 +00:00
tests fix: validate API keys on AgenticManager init (#29) 2026-02-23 11:39:01 +00:00
View refactor: unify ApiKeyManager to use AgentApiKey model (#19) 2026-02-23 06:09:05 +00:00
.editorconfig Initial commit 2026-01-26 23:20:30 +00:00
.gitattributes Initial commit 2026-01-26 23:20:30 +00:00
.gitignore Initial commit 2026-01-26 23:20:30 +00:00
AGENTS.md Initial commit 2026-01-26 23:20:30 +00:00
Boot.php refactor: rename namespace Core\Agentic to Core\Mod\Agentic 2026-01-27 16:12:58 +00:00
CLAUDE.md docs: update CLAUDE.md to be package-specific 2026-01-28 14:02:45 +00:00
cliff.toml Initial commit 2026-01-26 23:20:30 +00:00
composer.json test: fix TestCase to use Orchestra Testbench for CI 2026-02-23 06:20:06 +00:00
config.php refactor: namespace cache keys to prevent collisions (closes #20) 2026-02-23 06:18:30 +00:00
FINDINGS.md docs: add Phase 0 environment assessment and findings 2026-02-20 02:49:52 +00:00
GEMINI.md Initial commit 2026-01-26 23:20:30 +00:00
LICENSE Initial commit 2026-01-26 23:20:30 +00:00
phpunit.xml chore: fix pint code style and add test config 2026-02-23 03:50:09 +00:00
README.md Initial commit 2026-01-26 23:20:30 +00:00
TODO.md fix: validate API keys on AgenticManager init (#29) 2026-02-23 11:39:01 +00:00

Core PHP Framework Project

CI codecov PHP Version Laravel License

A modular monolith Laravel application built with Core PHP Framework.

Features

  • Core Framework - Event-driven module system with lazy loading
  • Admin Panel - Livewire-powered admin interface with Flux UI
  • REST API - Scoped API keys, rate limiting, webhooks, OpenAPI docs
  • MCP Tools - Model Context Protocol for AI agent integration

Requirements

  • PHP 8.2+
  • Composer 2.x
  • SQLite (default) or MySQL/PostgreSQL
  • Node.js 18+ (for frontend assets)

Installation

# Clone or create from template
git clone https://github.com/host-uk/core-template.git my-project
cd my-project

# Install dependencies
composer install
npm install

# Configure environment
cp .env.example .env
php artisan key:generate

# Set up database
touch database/database.sqlite
php artisan migrate

# Start development server
php artisan serve

Visit: http://localhost:8000

Project Structure

app/
├── Console/      # Artisan commands
├── Http/         # Controllers & Middleware
├── Models/       # Eloquent models
├── Mod/          # Your custom modules
└── Providers/    # Service providers

config/
└── core.php      # Core framework configuration

routes/
├── web.php       # Public web routes
├── api.php       # REST API routes
└── console.php   # Artisan commands

Creating Modules

# Create a new module with all features
php artisan make:mod Blog --all

# Create module with specific features
php artisan make:mod Shop --web --api --admin

Modules follow the event-driven pattern:

<?php

namespace App\Mod\Blog;

use Core\Events\WebRoutesRegistering;
use Core\Events\ApiRoutesRegistering;
use Core\Events\AdminPanelBooting;

class Boot
{
    public static array $listens = [
        WebRoutesRegistering::class => 'onWebRoutes',
        ApiRoutesRegistering::class => 'onApiRoutes',
        AdminPanelBooting::class => 'onAdminPanel',
    ];

    public function onWebRoutes(WebRoutesRegistering $event): void
    {
        $event->routes(fn() => require __DIR__.'/Routes/web.php');
        $event->views('blog', __DIR__.'/Views');
    }
}

Core Packages

Package Description
host-uk/core Core framework components
host-uk/core-admin Admin panel & Livewire modals
host-uk/core-api REST API with scopes & webhooks
host-uk/core-mcp Model Context Protocol tools

Flux Pro (Optional)

This template uses the free Flux UI components. If you have a Flux Pro license:

# Configure authentication
composer config http-basic.composer.fluxui.dev your-email your-license-key

# Add the repository
composer config repositories.flux-pro composer https://composer.fluxui.dev

# Install Flux Pro
composer require livewire/flux-pro

Documentation

License

EUPL-1.2 (European Union Public Licence)