Step 1 :- start the mysql server & create database
Step 2 :- npm install
Step 3 :- npm run build
Step 4 :- npm start
APP_KEY=XXXXXXXXXX // Need to pass this key for every request with headers as (app-key:050fc028-74f0-45f0-b84c-9a12d7b8b60b). For security purpose every request requires this app key in headers.
PORT=XXXX // Server Running on this port.
DB_HOST=XXXX
DB_PORT=XXXX
DB_NAME=XXXX // place the databse name here which is created on step 1
DB_USERNAME=XXXX
DB_PASSWORD=XXXX
-
For Create User mutation{ createUser(first_name:"John", last_name:"Doe", email:"[email protected]", password:"123456"){ id first_name last_name email password } }
-
For Update User mutation{ updateUser(id:"6", input:{first_name:"Jack", last_name:"Rock"}){ status message } }
-
For Get user
query{ getAllUsers{ id first_name last_name email password } }