grpcurl icon indicating copy to clipboard operation
grpcurl copied to clipboard

Don't forget to escape in windows

Open Yikuanzz opened this issue 1 year ago • 0 comments

❌ Incorrect

If you run this:

grpcurl -d '{"name": "Go"}' -plaintext localhost:50051 helloworld.Greeter.SayHello

You will get the result:

Too many arguments.
Try 'grpcurl -help' for more details.

✔ Correct

The correct usage is this:

grpcurl -d "{\"name\":\"Go\"}" -plaintext localhost:50051 helloworld.Greeter.SayHello

You can get the expected result:

{
  "message": "Hello Go"
}

Yikuanzz avatar Nov 27 '24 04:11 Yikuanzz