From 92938b1c77886e544f90a13a94ecbe6d2ee661d4 Mon Sep 17 00:00:00 2001 From: Jiyong Ha Date: Tue, 20 Jul 2021 17:00:59 +0900 Subject: [PATCH] docs: update swagger for wasm wasmd 0.17.0(#249) After merging, the legacy style wasm proto path was fixed. --- client/docs/swagger-ui/swagger.yaml | 29 ++++++++++++++++++++++++++++- scripts/protoc-swagger-gen.sh | 3 +-- 2 files changed, 29 insertions(+), 3 deletions(-) diff --git a/client/docs/swagger-ui/swagger.yaml b/client/docs/swagger-ui/swagger.yaml index 0150011a95..53bc251034 100644 --- a/client/docs/swagger-ui/swagger.yaml +++ b/client/docs/swagger-ui/swagger.yaml @@ -1,6 +1,6 @@ swagger: '2.0' info: - title: Cosmos SDK - Legacy REST and gRPC Gateway docs + title: LFB SDK - Legacy REST and gRPC Gateway docs description: 'A REST interface for state queries, legacy transactions' version: 1.0.0 paths: @@ -4920,6 +4920,9 @@ paths: sig_verify_cost_secp256k1: type: string format: uint64 + valid_sig_block_period: + type: string + format: uint64 description: >- QueryParamsResponse is the response type for the Query/Params RPC method. @@ -32334,6 +32337,9 @@ definitions: sig_verify_cost_secp256k1: type: string format: uint64 + valid_sig_block_period: + type: string + format: uint64 description: Params defines the parameters for the auth module. lfb.auth.v1beta1.QueryAccountResponse: type: object @@ -32425,6 +32431,9 @@ definitions: sig_verify_cost_secp256k1: type: string format: uint64 + valid_sig_block_period: + type: string + format: uint64 description: QueryParamsResponse is the response type for the Query/Params RPC method. lfb.bank.v1beta1.DenomUnit: type: object @@ -45702,6 +45711,15 @@ definitions: whole transaction. + sig_block_height: + type: string + format: uint64 + description: >- + sig block height is available between current block height and + current block height - `VALID_SIG_BLOCK_PERIOD` + + this is used for distinguish signatures instead of account number. + this is mandatory. memo: type: string title: memo is any arbitrary memo to be added to the transaction @@ -46272,6 +46290,15 @@ definitions: is referred to as the primary signer and pays the fee for the whole transaction. + sig_block_height: + type: string + format: uint64 + description: >- + sig block height is available between current block height and current + block height - `VALID_SIG_BLOCK_PERIOD` + + this is used for distinguish signatures instead of account number. + this is mandatory. memo: type: string title: memo is any arbitrary memo to be added to the transaction diff --git a/scripts/protoc-swagger-gen.sh b/scripts/protoc-swagger-gen.sh index ca55fb5171..bf62cd31e5 100755 --- a/scripts/protoc-swagger-gen.sh +++ b/scripts/protoc-swagger-gen.sh @@ -3,7 +3,7 @@ set -eo pipefail mkdir -p ./tmp-swagger-gen -proto_dirs=$(find ./proto ./x/wasm/internal/types -path -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq) +proto_dirs=$(find ./proto -path -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq) for dir in $proto_dirs; do # generate swagger files (filter query files) @@ -12,7 +12,6 @@ for dir in $proto_dirs; do buf protoc \ -I "proto" \ -I "third_party/proto" \ - -I "x/wasm/internal/types" \ "$query_file" \ --swagger_out=./tmp-swagger-gen \ --swagger_opt=logtostderr=true --swagger_opt=fqn_for_swagger_name=true --swagger_opt=simple_operation_ids=true