OSDN Git Service

update (#333)
[bytom/vapor.git] / docs / federation / README-en.md
index ff5628f..86d21ef 100644 (file)
@@ -5,14 +5,13 @@ To run a federation node, you will need to:
 1. init a MySQL database with this [schema](./federation.sql);
 2. run a `bytomd` node;
 3. run a `vapord` node and import the federation private key;
-4. and last but not least, run a `fedd` node with a `fed_cfg.json`.
+4. and last but not least, run a `fedd` node with a `fed_cfg.json` and it will listen at 9886 port.
 
 A `fed_cfg.json` would look like this:
 
 ```json
 {
     "api" : {
-        "listening_port" : 3000,
         "is_release_mode": false
     },
     "mysql" : {
@@ -25,24 +24,19 @@ A `fed_cfg.json` would look like this:
         },
         "log_mode" : true
     },
-    "warders" : [
-        {
-            "position" : 1,
-            "xpub" : "50ef22b3a3fca7bc08916187cc9ec2f4005c9c6b1353aa1decbd4be3f3bb0fbe1967589f0d9dec13a388c0412002d2c267bdf3b920864e1ddc50581be5604ce1"
-        }
-    ],
-    "quorum": 1,
+    "network" : "testnet",
+    "federation_prog" : "0020f86826d640810eb08a2bfb706e0092273e05e9a7d3d71f9d53f4f6cc2e3d6c6a",
     "mainchain" : {
-        "name" : "bytom",
+        "name" : "btm",
         "confirmations" : 10,
         "upstream" : "http://127.0.0.1:9888",
         "sync_seconds" : 150
     },
     "sidechain" : {
         "name" : "vapor",
-        "confirmations" : 100,
+        "confirmations" : 300,
         "upstream" : "http://127.0.0.1:9889",
-        "sync_seconds" : 5
+        "sync_seconds" : 150
     }
 }
 ```
@@ -91,6 +85,7 @@ Optional:
     + Optional
         * `String` - *status*, transactions status, which can be `pending` or `completed`.
         * `String` - *source_chain_name*, transactions source chain, which can be `bytom` or `vapor`.
+        * `String` - *address*, filter cross-chain requests by address. The address can be either a mainchain or a sidechain one. Note that other requests in such a transaction will also be filtered. 
         * `String` - *source_tx_hash*, souce transaction hash string.
         * `String` - *dest_tx_hash*, destination transaction hash string.
 - `Object` - *sort*, transactions sorter.
@@ -126,7 +121,7 @@ Optional:
 
 ```js
 // Request
-curl -X POST 127.0.0.1:3000/api/v1/federation/list-crosschain-txs -d '{}'
+curl -X POST 127.0.0.1:9886/api/v1/federation/list-crosschain-txs -d '{}'
 
 // Result
 {