Sample server code for a graphql server
npm install
sequelize db:migrate
to init the databasesequelize db:seed:all
to add seed data to the databasenpm start
to start the server in port 4000
- try
http://localhost:4000/universities
for normal REST API call - access
http://localhost:4000
for GraphiQL and use the below query
{
universities {
faculties {
programs {
description
}
}
}
}