Golang implemented sidechain for Bytom
修订版 | 52e7985be7fad2f77e60fb255f0bc6307606d8e8 (tree) |
---|---|
时间 | 2019-06-26 18:39:16 |
作者 | HAOYUatHZ <haoyu@prot...> |
Commiter | HAOYUatHZ |
update docs
@@ -85,8 +85,6 @@ To list cross-chain transactions and filter the transactions. | ||
85 | 85 | |
86 | 86 | ##### Parameters |
87 | 87 | |
88 | -<!-- --> | |
89 | - | |
90 | 88 | Optional: |
91 | 89 | |
92 | 90 | - `Object` - *filter*, transactions filter. |
@@ -107,16 +105,20 @@ Optional: | ||
107 | 105 | |
108 | 106 | - `String` - *source_chain_name*, source chain name of the cross-chain transaction. |
109 | 107 | - `Integer` - *source_block_height*, block height of the cross-chain transaction on the source chain. |
108 | +- `Integer` - *source_block_timestamp*, block timestamp of the cross-chain transaction on the source chain. | |
110 | 109 | - `String` - *source_block_hash*, block hash of the cross-chain transaction on the source chain. |
111 | 110 | - `Integer` - *source_tx_index*, transaction index in the source block. |
112 | 111 | - `String` - *source_tx_hash*, source transaction hash. |
113 | 112 | - `Integer` - *dest_block_height*, block height of the cross-chain transaction on the destination chain, `0` if `status` is `pending`. |
113 | +- `Integer` - *dest_block_timestamp*, block timestamp of the cross-chain transaction on the destination chain, `0` if `status` is `pending`. | |
114 | 114 | - `String` - *dest_block_hash*, block hash of the cross-chain transaction on the destination chain, empty string if `status` is `pending`. |
115 | 115 | - `Integer` - *dest_tx_index*, transaction index in the destination block, `0` if `status` is `pending`. |
116 | 116 | - `String` - *dest_tx_hash*, destination transaction hash, empty string if `status` is `pending`. |
117 | 117 | - `String` - *status*, cross-chain transaction status, can be `pending` or `completed`. |
118 | 118 | - `Array of objects` - *crosschain_requests*, asset transfer details per request included in the cross-chain transaction. |
119 | 119 | + `Integer` - *amount*, asset transfer amount. |
120 | + + `String` - *from_address*, source address. | |
121 | + + `String` - *to_address*, destination address. | |
120 | 122 | + `Object` - *asset*, asset detail. |
121 | 123 | * `String` - *asset_id*, asset id string. |
122 | 124 |
@@ -138,10 +140,12 @@ curl -X POST 127.0.0.1:3000/api/v1/federation/list-crosschain-txs -d '{}' | ||
138 | 140 | { |
139 | 141 | "source_chain_name":"bytom", |
140 | 142 | "source_block_height":174, |
143 | + "source_block_timestamp":1561457348, | |
141 | 144 | "source_block_hash":"569a3a5a43910ea634a947fd092bb3085359db451235ae59c20daab4e4b0d274", |
142 | 145 | "source_tx_index":1, |
143 | 146 | "source_tx_hash":"584d1dcc4dfe741bb3ae5b193896b08db469169e6fd76098eac132af628a3183", |
144 | 147 | "dest_block_height":0, |
148 | + "dest_block_timestamp":0, | |
145 | 149 | "dest_block_hash":"", |
146 | 150 | "dest_tx_index":0, |
147 | 151 | "dest_tx_hash":"", |
@@ -149,6 +153,8 @@ curl -X POST 127.0.0.1:3000/api/v1/federation/list-crosschain-txs -d '{}' | ||
149 | 153 | "crosschain_requests":[ |
150 | 154 | { |
151 | 155 | "amount":1000000, |
156 | + "from_address":"bm1qf872k7nr8pwjt4afx60m2wwz5hwj2tu4jaxm9g", | |
157 | + "to_address":"vp1qf872k7nr8pwjt4afx60m2wwz5hwj2tu4eukxq7", | |
152 | 158 | "asset":{ |
153 | 159 | "asset_id":"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff" |
154 | 160 | } |