Skip to content

Commit eb50069

Browse files
Merge pull request #32 from oracleNetworkProtocol/worry-free
update swagger
2 parents d4b66cc + 7486c69 commit eb50069

File tree

4 files changed

+37
-37
lines changed

4 files changed

+37
-37
lines changed

client/static/openapi.yml

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -4236,7 +4236,7 @@ paths:
42364236
type: string
42374237
description: >-
42384238
denom represents the string name of the given
4239-
denom unit (e.g plug).
4239+
denom unit (e.g uplugcn).
42404240
exponent:
42414241
type: integer
42424242
format: int64
@@ -4249,10 +4249,10 @@ paths:
42494249

42504250
1 denom = 1^exponent base_denom
42514251

4252-
(e.g. with a base_denom of plug, one can create a
4253-
DenomUnit of 'plug' with
4252+
(e.g. with a base_denom of uplugcn, one can create a
4253+
DenomUnit of 'plugcn' with
42544254

4255-
exponent = 6, thus: 1 plug = 10^6 plug).
4255+
exponent = 6, thus: 1 plugcn = 10^6 uplugcn).
42564256
aliases:
42574257
type: array
42584258
items:
@@ -4424,7 +4424,7 @@ paths:
44244424
type: string
44254425
description: >-
44264426
denom represents the string name of the given denom
4427-
unit (e.g plug).
4427+
unit (e.g uplugcn).
44284428
exponent:
44294429
type: integer
44304430
format: int64
@@ -4437,10 +4437,10 @@ paths:
44374437

44384438
1 denom = 1^exponent base_denom
44394439

4440-
(e.g. with a base_denom of plug, one can create a
4441-
DenomUnit of 'plug' with
4440+
(e.g. with a base_denom of uplugcn, one can create a
4441+
DenomUnit of 'plugcn' with
44424442

4443-
exponent = 6, thus: 1 plug = 10^6 plug).
4443+
exponent = 6, thus: 1 plugcn = 10^6 uplugcn).
44444444
aliases:
44454445
type: array
44464446
items:
@@ -8265,7 +8265,7 @@ paths:
82658265
title: minimum inflation rate
82668266
goal_bonded:
82678267
type: string
8268-
title: goal of percent bonded plugs
8268+
title: goal of percent bonded plugcns
82698269
blocks_per_year:
82708270
type: string
82718271
format: uint64
@@ -15848,7 +15848,7 @@ paths:
1584815848
type: array
1584915849
format: sdk.Coins
1585015850
example:
15851-
- denom: plug
15851+
- denom: uplugcn
1585215852
amount: '100000000'
1585315853
items:
1585415854
type: object
@@ -19497,7 +19497,7 @@ definitions:
1949719497
properties:
1949819498
denom:
1949919499
type: string
19500-
description: denom represents the string name of the given denom unit (e.g plug).
19500+
description: denom represents the string name of the given denom unit (e.g uplugcn).
1950119501
exponent:
1950219502
type: integer
1950319503
format: int64
@@ -19508,10 +19508,10 @@ definitions:
1950819508

1950919509
1 denom = 1^exponent base_denom
1951019510

19511-
(e.g. with a base_denom of plug, one can create a DenomUnit of 'plug'
19511+
(e.g. with a base_denom of uplugcn, one can create a DenomUnit of 'plugcn'
1951219512
with
1951319513

19514-
exponent = 6, thus: 1 plug = 10^6 plug).
19514+
exponent = 6, thus: 1 plugcn = 10^6 uplugcn).
1951519515
aliases:
1951619516
type: array
1951719517
items:
@@ -19534,7 +19534,7 @@ definitions:
1953419534
type: string
1953519535
description: >-
1953619536
denom represents the string name of the given denom unit (e.g
19537-
plug).
19537+
uplugcn).
1953819538
exponent:
1953919539
type: integer
1954019540
format: int64
@@ -19546,10 +19546,10 @@ definitions:
1954619546

1954719547
1 denom = 1^exponent base_denom
1954819548

19549-
(e.g. with a base_denom of plug, one can create a DenomUnit of
19550-
'plug' with
19549+
(e.g. with a base_denom of uplugcn, one can create a DenomUnit of
19550+
'plugcn' with
1955119551

19552-
exponent = 6, thus: 1 plug = 10^6 plug).
19552+
exponent = 6, thus: 1 plugcn = 10^6 uplugcn).
1955319553
aliases:
1955419554
type: array
1955519555
items:
@@ -19682,7 +19682,7 @@ definitions:
1968219682
type: string
1968319683
description: >-
1968419684
denom represents the string name of the given denom unit
19685-
(e.g plug).
19685+
(e.g uplugcn).
1968619686
exponent:
1968719687
type: integer
1968819688
format: int64
@@ -19694,10 +19694,10 @@ definitions:
1969419694

1969519695
1 denom = 1^exponent base_denom
1969619696

19697-
(e.g. with a base_denom of plug, one can create a DenomUnit
19698-
of 'plug' with
19697+
(e.g. with a base_denom of uplugcn, one can create a DenomUnit
19698+
of 'plugcn' with
1969919699

19700-
exponent = 6, thus: 1 plug = 10^6 plug).
19700+
exponent = 6, thus: 1 plugcn = 10^6 uplugcn).
1970119701
aliases:
1970219702
type: array
1970319703
items:
@@ -19758,7 +19758,7 @@ definitions:
1975819758
type: string
1975919759
description: >-
1976019760
denom represents the string name of the given denom unit
19761-
(e.g plug).
19761+
(e.g uplugcn).
1976219762
exponent:
1976319763
type: integer
1976419764
format: int64
@@ -19770,10 +19770,10 @@ definitions:
1977019770

1977119771
1 denom = 1^exponent base_denom
1977219772

19773-
(e.g. with a base_denom of plug, one can create a
19774-
DenomUnit of 'plug' with
19773+
(e.g. with a base_denom of uplugcn, one can create a
19774+
DenomUnit of 'plugcn' with
1977519775

19776-
exponent = 6, thus: 1 plug = 10^6 plug).
19776+
exponent = 6, thus: 1 plugcn = 10^6 uplugcn).
1977719777
aliases:
1977819778
type: array
1977919779
items:
@@ -21564,7 +21564,7 @@ definitions:
2156421564
title: minimum inflation rate
2156521565
goal_bonded:
2156621566
type: string
21567-
title: goal of percent bonded plugs
21567+
title: goal of percent bonded plugcns
2156821568
blocks_per_year:
2156921569
type: string
2157021570
format: uint64
@@ -21611,7 +21611,7 @@ definitions:
2161121611
title: minimum inflation rate
2161221612
goal_bonded:
2161321613
type: string
21614-
title: goal of percent bonded plugs
21614+
title: goal of percent bonded plugcns
2161521615
blocks_per_year:
2161621616
type: string
2161721617
format: uint64
@@ -26045,7 +26045,7 @@ definitions:
2604526045
type: array
2604626046
format: sdk.Coins
2604726047
example:
26048-
- denom: plug
26048+
- denom: uplugcn
2604926049
amount: '100000000'
2605026050
items:
2605126051
type: object
@@ -26418,7 +26418,7 @@ definitions:
2641826418
type: array
2641926419
format: sdk.Coins
2642026420
example:
26421-
- denom: plug
26421+
- denom: uplugcn
2642226422
amount: '100000000'
2642326423
items:
2642426424
type: object

docs/endpoints/legacy-rest.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ Denom uses `plug` which affects fields:
359359
The same code as integrating with Plug Chain Hub mainnet, call `POST` `/txs` to send a transaction, as the example below:
360360

361361
```bash
362-
curl -X POST "http://localhost:1317/txs" -H "accept: application/json" -H "Content-Type: application/json" -d "{ \"tx\": {\"msg\":[{\"type\":\"cosmos-sdk/MsgSend\",\"value\":{\"from_address\":\"gx1rkgdpj6fyyyu7pnhmc3v7gw9uls4mnajvzdwkt\",\"to_address\":\"gx1q6t5439f0rkvkzl38m0f43e0kpv3mx7x2shlq8\",\"amount\":[{\"denom\":\"plug\",\"amount\":\"1000000\"}]}}],\"fee\":{\"amount\":[{\"denom\":\"plug\",\"amount\":\"30000\"}],\"gas\":\"200000\"},\"signatures\":[{\"pub_key\":{\"type\":\"tendermint/PubKeySecp256k1\",\"value\":\"AxGagdsRTKni/h1+vCFzTpNltwoiU7SwIR2dg6Jl5a//\"},\"signature\":\"Pu8yiRVO8oB2YDDHyB047dXNArbVImasmKBrm8Kr+6B08y8QQ7YG1eVgHi5OIYYclccCf3Ju/BQ78qsMWMniNQ==\"}],\"memo\":\"Sent gx Plug Chain Hub client\"}, \"mode\": \"block\"}"
362+
curl -X POST "http://localhost:1317/txs" -H "accept: application/json" -H "Content-Type: application/json" -d "{ \"tx\": {\"msg\":[{\"type\":\"cosmos-sdk/MsgSend\",\"value\":{\"from_address\":\"gx1rkgdpj6fyyyu7pnhmc3v7gw9uls4mnajvzdwkt\",\"to_address\":\"gx1q6t5439f0rkvkzl38m0f43e0kpv3mx7x2shlq8\",\"amount\":[{\"denom\":\"uplugcn\",\"amount\":\"1000000\"}]}}],\"fee\":{\"amount\":[{\"denom\":\"uplugcn\",\"amount\":\"30000\"}],\"gas\":\"200000\"},\"signatures\":[{\"pub_key\":{\"type\":\"tendermint/PubKeySecp256k1\",\"value\":\"AxGagdsRTKni/h1+vCFzTpNltwoiU7SwIR2dg6Jl5a//\"},\"signature\":\"Pu8yiRVO8oB2YDDHyB047dXNArbVImasmKBrm8Kr+6B08y8QQ7YG1eVgHi5OIYYclccCf3Ju/BQ78qsMWMniNQ==\"}],\"memo\":\"Sent gx Plug Chain Hub client\"}, \"mode\": \"block\"}"
363363
```
364364

365365
## Breaking Changes in Querying Transactions
@@ -380,7 +380,7 @@ curl -X POST "http://localhost:1317/txs" -H "accept: application/json" -H "Conte
380380
"height": "5",
381381
"txhash": "E663768B616B1ACD2912E47C36FEBC7DB0E0974D6DB3823D4C656E0EAB8C679D",
382382
"data": "0A060A0473656E64",
383-
"raw_log": "[{\"events\":[{\"type\":\"message\",\"attributes\":[{\"key\":\"action\",\"value\":\"send\"},{\"key\":\"sender\",\"value\":\"gx18awn3k70u05tlcul8w2qnl64g002uj4kjn93rn\"},{\"key\":\"module\",\"value\":\"bank\"}]},{\"type\":\"transfer\",\"attributes\":[{\"key\":\"recipient\",\"value\":\"gx1w976a5jrhsj06dqmrh2x9qxzel74qtcmapklxc\"},{\"key\":\"sender\",\"value\":\"gx18awn3k70u05tlcul8w2qnl64g002uj4kjn93rn\"},{\"key\":\"amount\",\"value\":\"1000000plug\"}]}]}]",
383+
"raw_log": "[{\"events\":[{\"type\":\"message\",\"attributes\":[{\"key\":\"action\",\"value\":\"send\"},{\"key\":\"sender\",\"value\":\"gx18awn3k70u05tlcul8w2qnl64g002uj4kjn93rn\"},{\"key\":\"module\",\"value\":\"bank\"}]},{\"type\":\"transfer\",\"attributes\":[{\"key\":\"recipient\",\"value\":\"gx1w976a5jrhsj06dqmrh2x9qxzel74qtcmapklxc\"},{\"key\":\"sender\",\"value\":\"gx18awn3k70u05tlcul8w2qnl64g002uj4kjn93rn\"},{\"key\":\"amount\",\"value\":\"1000000uplugcn\"}]}]}]",
384384
"logs": [
385385
{
386386
"events": [
@@ -414,7 +414,7 @@ curl -X POST "http://localhost:1317/txs" -H "accept: application/json" -H "Conte
414414
},
415415
{
416416
"key": "amount",
417-
"value": "1000000plug"
417+
"value": "1000000uplugcn"
418418
}
419419
]
420420
}

docs/zh/endpoints/legacy-rest.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,7 @@ Denom 替换为 `plug` ,这会影响到以下字段:
360360
与 Plug Chain Hub 主网集成的代码相同,调用`POST` `/txs` 发送交易,示例如下:
361361

362362
```bash
363-
curl -X POST "http://localhost:1317/txs" -H "accept: application/json" -H "Content-Type: application/json" -d "{ \"tx\": {\"msg\":[{\"type\":\"cosmos-sdk/MsgSend\",\"value\":{\"from_address\":\"gx1rkgdpj6fyyyu7pnhmc3v7gw9uls4mnajvzdwkt\",\"to_address\":\"gx1q6t5439f0rkvkzl38m0f43e0kpv3mx7x2shlq8\",\"amount\":[{\"denom\":\"plug\",\"amount\":\"1000000\"}]}}],\"fee\":{\"amount\":[{\"denom\":\"plug\",\"amount\":\"30000\"}],\"gas\":\"200000\"},\"signatures\":[{\"pub_key\":{\"type\":\"tendermint/PubKeySecp256k1\",\"value\":\"AxGagdsRTKni/h1+vCFzTpNltwoiU7SwIR2dg6Jl5a//\"},\"signature\":\"Pu8yiRVO8oB2YDDHyB047dXNArbVImasmKBrm8Kr+6B08y8QQ7YG1eVgHi5OIYYclccCf3Ju/BQ78qsMWMniNQ==\"}],\"memo\":\"Sent gx Plug Chain Hub client\"}, \"mode\": \"block\"}"
363+
curl -X POST "http://localhost:1317/txs" -H "accept: application/json" -H "Content-Type: application/json" -d "{ \"tx\": {\"msg\":[{\"type\":\"cosmos-sdk/MsgSend\",\"value\":{\"from_address\":\"gx1rkgdpj6fyyyu7pnhmc3v7gw9uls4mnajvzdwkt\",\"to_address\":\"gx1q6t5439f0rkvkzl38m0f43e0kpv3mx7x2shlq8\",\"amount\":[{\"denom\":\"uplugcn\",\"amount\":\"1000000\"}]}}],\"fee\":{\"amount\":[{\"denom\":\"uplugcn\",\"amount\":\"30000\"}],\"gas\":\"200000\"},\"signatures\":[{\"pub_key\":{\"type\":\"tendermint/PubKeySecp256k1\",\"value\":\"AxGagdsRTKni/h1+vCFzTpNltwoiU7SwIR2dg6Jl5a//\"},\"signature\":\"Pu8yiRVO8oB2YDDHyB047dXNArbVImasmKBrm8Kr+6B08y8QQ7YG1eVgHi5OIYYclccCf3Ju/BQ78qsMWMniNQ==\"}],\"memo\":\"Sent gx Plug Chain Hub client\"}, \"mode\": \"block\"}"
364364
```
365365

366366
## 查询交易的不兼容更新
@@ -381,7 +381,7 @@ curl -X POST "http://localhost:1317/txs" -H "accept: application/json" -H "Conte
381381
"height": "5",
382382
"txhash": "E663768B616B1ACD2912E47C36FEBC7DB0E0974D6DB3823D4C656E0EAB8C679D",
383383
"data": "0A060A0473656E64",
384-
"raw_log": "[{\"events\":[{\"type\":\"message\",\"attributes\":[{\"key\":\"action\",\"value\":\"send\"},{\"key\":\"sender\",\"value\":\"gx18awn3k70u05tlcul8w2qnl64g002uj4kjn93rn\"},{\"key\":\"module\",\"value\":\"bank\"}]},{\"type\":\"transfer\",\"attributes\":[{\"key\":\"recipient\",\"value\":\"gx1w976a5jrhsj06dqmrh2x9qxzel74qtcmapklxc\"},{\"key\":\"sender\",\"value\":\"gx18awn3k70u05tlcul8w2qnl64g002uj4kjn93rn\"},{\"key\":\"amount\",\"value\":\"1000000plug\"}]}]}]",
384+
"raw_log": "[{\"events\":[{\"type\":\"message\",\"attributes\":[{\"key\":\"action\",\"value\":\"send\"},{\"key\":\"sender\",\"value\":\"gx18awn3k70u05tlcul8w2qnl64g002uj4kjn93rn\"},{\"key\":\"module\",\"value\":\"bank\"}]},{\"type\":\"transfer\",\"attributes\":[{\"key\":\"recipient\",\"value\":\"gx1w976a5jrhsj06dqmrh2x9qxzel74qtcmapklxc\"},{\"key\":\"sender\",\"value\":\"gx18awn3k70u05tlcul8w2qnl64g002uj4kjn93rn\"},{\"key\":\"amount\",\"value\":\"1000000uplugcn\"}]}]}]",
385385
"logs": [
386386
{
387387
"events": [
@@ -415,7 +415,7 @@ curl -X POST "http://localhost:1317/txs" -H "accept: application/json" -H "Conte
415415
},
416416
{
417417
"key": "amount",
418-
"value": "1000000plug"
418+
"value": "1000000uplugcn"
419419
}
420420
]
421421
}

scripts/protoc-swagger-gen.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@ sed -r -i '' 's/cosmosvalconspub1[a-z,0-9]+/gxvalconspub1zcjduepqwhwqn4h5v6mqa7k
4949
sed -i '' 's/Gaia/Plug Chain Hub/g' ./client/static/openapi.yml
5050
sed -i '' 's/gaia/plugchaind/g' ./client/static/openapi.yml
5151
sed -i '' 's/cosmoshub/plugchainhub/g' ./client/static/openapi.yml
52-
sed -i '' 's/uatom/plug/g' ./client/static/openapi.yml
53-
sed -i '' 's/atom/plug/g' ./client/static/openapi.yml
52+
sed -i '' 's/uatom/uplugcn/g' ./client/static/openapi.yml
53+
sed -i '' 's/atom/plugcn/g' ./client/static/openapi.yml
5454

5555
tendermintURL=https://github.com/tendermint/liquidity/blob/develop
5656
onpURL=https://github.com/oracleNetworkProtocol/liquidity/tree/main

0 commit comments

Comments
 (0)