This Laravel-based application provides a comprehensive solution for managing company information. The system offers both a user-friendly web interface and a RESTful API for integrating with other systems.
This application is deployed and accessible online:
The live web interface can be accessed at:
URL: https://aicoll-technical-test.jehicoob.dev/
The live API documentation, generated by Swagger/OpenAPI, is available at:
URL: https://aicoll-technical-test.jehicoob.dev/api/documentation
- Complete company management (creation, viewing, updating, and deletion)
- Interactive web interface with real-time updates
- RESTful API with comprehensive documentation
- Validation to ensure data integrity
- Status-based company management (active/inactive)
- Bulk operations for inactive companies
- Frontend: Blade templates, Tailwind CSS, JavaScript
- Backend: Laravel 12
- Database: MySQL
- Documentation: Swagger/OpenAPI via L5-Swagger
- PHP 8.2 or higher
- Composer
- Node.js and NPM
- MySQL database
- SQLite (required for running tests)
-
Clone the repository:
git clone https://github.com/jehicoob/aicoll-technical-test.git cd aicoll-technical-test -
Install PHP dependencies:
composer install
-
Install JavaScript dependencies:
npm install
-
Create a copy of the environment file:
cp .env.example .env
-
Generate application key:
php artisan key:generate
-
Configure your database in the
.envfile:DB_CONNECTION=mysql DB_HOST=127.0.0.1 DB_PORT=3306 DB_DATABASE=your_database DB_USERNAME=your_username DB_PASSWORD=your_password -
Run database migrations:
php artisan migrate --seed
-
Build assets:
npm run build
-
Start the development server:
php artisan serve
The web interface is available at:
- Local development:
http://localhost:8000 - The main screen provides access to all functionality:
- View all companies
- Add new companies
- Edit existing companies
- Delete inactive companies
- Change company status
The API documentation is automatically generated using Swagger/OpenAPI and is available at:
- Local development:
http://localhost:8000/api/documentation
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/v1/companies | List all companies |
| POST | /api/v1/companies | Create a new company |
| GET | /api/v1/companies/{nit} | Get details of a specific company |
| PUT | /api/v1/companies/{nit} | Update a company |
| DELETE | /api/v1/companies/{nit} | Delete a company (only if inactive) |
| DELETE | /api/v1/companies/inactive | Delete all inactive companies |
Run the automated tests using:
php artisan testTo view a code coverage report, you need to have xDebug installed and enabled. Once it's set up, run:
php artisan test --coverage💡 Note: Tests use an in-memory SQLite database for fast execution and test isolation. No additional database configuration is needed for testing.
💡 If you don't have xDebug installed, you can follow the official xDebug installation guide for your environment.
This will execute all feature and unit tests to ensure the application is functioning correctly.
The Laravel framework is open-sourced software licensed under the MIT license.
