Detailed instructions for setting up HelpDesk API in your environment.
- PHP 8.5.1 or higher
- PostgreSQL 18 or higher
- Composer 2.0+
- 512MB RAM
- 200MB disk space
- PHP 8.5.1 (latest)
- PostgreSQL 18
- Composer latest
- 2GB RAM
- 1GB disk space
- Linux or macOS
git clone https://github.com/yourusername/helpdesk-api.git
cd helpdesk-apicomposer installCopy the example environment file:
cp .env.example .envEdit .env with your database credentials:
database.default.driver = Postgre
database.default.hostname = localhost
database.default.port = 5432
database.default.database = help_desk
database.default.username = postgres
database.default.password = your_password
database.default.DBDebug = trueCreate the database:
createdb help_desk -U postgresCreate tables:
php spark migratePopulate with sample data:
php spark db:seed DatabaseSeederThis seeds:
- 4 roles with 10 permissions
- 5 departments
- 6 locations (Italy, Belgium, Germany)
- 50 users
- 100 sample tickets with relationships
php spark serve- Interactive API Docs: http://localhost:8080/api/docs
- Raw OpenAPI Spec: http://localhost:8080/api/v1/docs
php spark db:clean && php spark db:seed DatabaseSeederphp spark testFor questions or issues, contact Zoran Makrevski at zoran@makrevski.com
Enable PostgreSQL extension in php.ini and restart server:
extension=pdo_pgsql
extension=pgsqlUse different port:
php spark serve --port 8081php spark db:clean
php spark migrate
php spark test