JSON REST API simple skeleton based on symfony-flex, JWT, api-platform, fosuserbundle etc.
Create project :
composer create-project svp1989/symfony-api-skeleton:@devOr clone repository from GitHub:
git clone https://github.com/svp1989/symfony-api-skeleton.gitInstall all needed dependencies:
composer installCreate JWT auth keys and configure .env:
ssh-keygen -t rsa -b 4096 -f private.pem
openssl rsa -in private.pem -pubout -outform PEM -out public.pem
Create .env file, which contains all the necessary
environment variables that application needs:
cp .env.dist .envCreate database and upload fixtures:
bin/console doctrine:database:create 
bin/console doctrine:schema:create
bin/console doctrine:fixtures:loadStart server and open in the browser http://127.0.0.1:8000/api/doc:
bin/console server:startGo to route /api/login:
ROLE_USER:
--username:user
--password:user
ROLE_ADMIN
--username:admin
--password:admin