A modern, high-performance headless Content Management System (CMS) built with Laravel 13 and PHP 8.5. This application serves as a pure backend API for my personal portfolio at mohammedzomlot.dev. It is designed with an API-first approach, providing exclusively RESTful JSON endpoints without any integrated frontend tooling or templates.
- Project Management: Complete CRUD with multi-image uploads, slug generation, and order sorting.
- Skill Tracking: Categorize and rank technical skills using dedicated Skill Categories.
- Professional Showcase: Manage Services, Experiences, Educations, and Achievements to display a complete professional history.
- Site Settings: Manage global portfolio information (bio, social links, etc.).
- Messaging System: Secure contact form endpoints with read/unread tracking.
- Admin Dashboard: Aggregated analytics and recent data overview.
- Robust Authentication: Secured via Laravel Sanctum and API key validation.
This project strictly adheres to modern Laravel architecture and "Skinny Controller" principles:
- Pure API: No frontend build tools, no Blade templates. All functionality is exposed via structured REST endpoints using Laravel Eloquent API Resources.
- Action Classes: Complex business logic (like handling multiple file uploads and database transactions) is extracted into single-purpose Action classes using
lorisleiva/laravel-actions. - Data Integrity: Database operations involving multiple steps or file uploads are wrapped in
DB::transaction()to prevent data corruption. - Performance: Extensive use of Laravel Cache to serve read-heavy endpoints (like the public portfolio) blazingly fast.
- Type Safety: Strict return type hinting (
JsonResponse) across all API controllers. - Validation: Dedicated
FormRequestclasses handle incoming data validation and custom error messages.
The API is covered by feature tests written in Pest (pestphp/pest).
To run the test suite:
composer run test- Framework: Laravel 13
- Language: PHP 8.5
- Authentication: Laravel Sanctum
- Testing: Pest v4
- Formatting: Laravel Pint
- Clone the repository.
- Run the setup script which will install dependencies, copy
.env.exampleto.env, generate the app key, and run migrations:composer run setup
- Link storage (for project images and uploads):
php artisan storage:link
- Start the local development server (API only):
composer run dev
A comprehensive Postman collection is available in the resources/ directory (Portfolio-cms.postman_collection.json) containing all available endpoints, required headers, and payload examples for both the public API and the protected Admin API.
