From ccf154e7063be5430da36331e1e3fe0a684af293 Mon Sep 17 00:00:00 2001 From: Anthony Romano Date: Wed, 16 Nov 2016 13:26:10 -0800 Subject: [PATCH] Documentation: add grpc gateway watch example Shows how to use watch via grpc gateway. --- Documentation/dev-guide/api_grpc_gateway.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Documentation/dev-guide/api_grpc_gateway.md b/Documentation/dev-guide/api_grpc_gateway.md index 6407937f6..7169a7a01 100644 --- a/Documentation/dev-guide/api_grpc_gateway.md +++ b/Documentation/dev-guide/api_grpc_gateway.md @@ -8,6 +8,8 @@ etcd v3 uses [gRPC][grpc] for its messaging protocol. The etcd project includes The gateway accepts a [JSON mapping][json-mapping] for etcd's [protocol buffer][api-ref] message definitions. Note that `key` and `value` fields are defined as byte arrays and therefore must be base64 encoded in JSON. +Use `curl` to put and get a key: + ```bash </dev/null 2>&1 +# {"result":{"header":{"cluster_id":"12585971608760269493","member_id":"13847567121247652255","revision":"2","raft_term":"2"},"events":[{"kv":{"key":"Zm9v","create_revision":"2","mod_revision":"2","version":"1","value":"YmFy"}}]}} +``` ## Swagger