This is a sample implementation of gRPC running on Node.js and written in TypeScript.
- Change to the server directory. Run
cd ./server
. - Install the dependencies. Run
npm ci
. - Compile the proto file. Run
npm run proto:generate
. - Run the server. Run
npm run dev
.
You can send a request to the server using an HTTP client GUI, such as Postman.
- Change to the client directory. Run
cd ./client
. - Install the dependencies. Run
npm ci
. - Compile the proto file. Run
npm run proto:generate
- Run the client. Run
npm run dev
.
The client application will print Monika ID: 1
.