fullstorydev / grpcurl

Like cURL, but for gRPC: Command-line tool for interacting with gRPC servers

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Allow to use yaml instead of json

anti-social opened this issue · comments

Yaml is more convenient for writing and modifying big chunks of data. So my suggest is to add yaml support.

It is possible to do in 2 ways:

  • add an option like -data-yaml (possibly with a short version -Y) for using instead of -d
  • autodetect yaml if there is a --- mark in the first line of data

As a work-around, you can use the tool yq and pipe your input through that and into the stdin of grpcurl. IIRC, yq . will print the input as JSON.