Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/kaungmyathan22/nodejs-ec2-githubactions-cicd

Nodejs app deployment to ec2 with cicd using github actions
https://github.com/kaungmyathan22/nodejs-ec2-githubactions-cicd

cicd ec2 githubactions nodejs

Last synced: about 1 month ago
JSON representation

Nodejs app deployment to ec2 with cicd using github actions

Awesome Lists containing this project

README

        

# Nodejs app with rest and graphql example

An example of GraphQL queries/mutations with Node and Express js.

With GraphQL, clients can specify exactly what data they need, and the server responds with only that data, reducing the amount of data transferred over the network.

Rest API Endpoint for get all users: http://localhost:5000/rest/getAllUsers

GraphQL Endpont: http://localhost:5000/graphql

Query for below scenarios:

1. Get All Users with query operation

query{
getAllUsers{
id
email
}
}

2. Get single user details

query{
findUserById(id:1000){
id
firstName
lastName
email
}
}

3. Create User with mutation operation

mutation{
createUser(firstName:"sachin",lastName:"purohit",email:"[email protected]",password:"password"){
id
firstName
lastName
email
}
}