PageSourceSearch

https://elastos-wiki.netlify.app/assets/js/6aa20731.55c72fd9.js

js elastos-wiki.netlify.app collected 2026-10-03 10:43:29 UTC 145,780 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[4970],{3905:(t,e,a)=>{a.d(e,{Zo:()=>u,kt:()=>k});var n=a(7294);function l(t,e,a){return e in t?Object.defineProperty(t,e,{value:a,enumerable:!0,configurable:!0,writable:!0}):t[e]=a,t}function r(t,e){var a=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),a.push.apply(a,n)}return a}function d(t){for(var e=1;e<arguments.length;e++){var a=null!=arguments[e]?arguments[e]:{};e%2?r(Object(a),!0).forEach((function(e){l(t,e,a[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):r(Object(a)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(a,e))}))}return t}function i(t,e){if(null==t)return{};var a,n,l=function(t,e){if(null==t)return{};var a,n,l={},r=Object.keys(t);for(n=0;n<r.length;n++)a=r[n],e.indexOf(a)>=0||(l[a]=t[a]);return l}(t,e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);for(n=0;n<r.length;n++)a=r[n],e.indexOf(a)>=0||Object.prototype.propertyIsEnumerable.call(t,a)&&(l[a]=t[a])}return l}var p=n.createContext({}),o=function(t){var e=n.useContext(p),a=e;return t&&(a="function"==typeof t?t(e):d(d({},e),t)),a},u=function(t){var e=o(t.components);return n.createElement(p.Provider,{value:e},t.children)},m="mdxType",s={inlineCode:"code",wrapper:function(t){var e=t.children;return n.createElement(n.Fragment,{},e)}},c=n.forwardRef((function(t,e){var a=t.components,l=t.mdxType,r=t.originalType,p=t.parentName,u=i(t,["components","mdxType","originalType","parentName"]),m=o(a),c=l,k=m["".concat(p,".").concat(c)]||m[c]||s[c]||r;return a?n.createElement(k,d(d({ref:e},u),{},{components:a})):n.createElement(k,d({ref:e},u))}));function k(t,e){var a=arguments,l=e&&e.mdxType;if("string"==typeof t||l){var r=a.length,d=new Array(r);d[0]=c;var i={};for(var p in e)hasOwnProperty.call(e,p)&&(i[p]=e[p]);i.originalType=t,i[m]="string"==typeof t?t:l,d[1]=i;for(var o=2;o<r;o++)d[o]=a[o];return n.createElement.apply(null,d)}return n.createElement.apply(null,a)}c.displayName="MDXCreateElement"},9480:(t,e,a)=>{a.r(e),a.d(e,{assets:()=>u,contentTitle:()=>p,default:()=>k,frontMatter:()=>i,metadata:()=>o,toc:()=>m});var n=a(7462),l=a(3366),r=(a(7294),a(3905)),d=["components"],i={title:"Mainchain JSON-RPC"},p="API reference (JSON-RPC)",o={unversionedId:"api/mainchain/rpc",id:"api/mainchain/rpc",title:"Mainchain JSON-RPC",description:"The ELA JSON RPC interfaces follow conform to the json-rpc 2.0 protocol but also remain compatible with 1.0 version.",source:"@site/../docs/6.api/mainchain/rpc.md",sourceDirName:"6.api/mainchain",slug:"/api/mainchain/rpc",permalink:"/api/mainchain/rpc",draft:!1,editUrl:"https://github.com/elastos/Elastos.Wiki/edit/master/website/../docs/6.api/mainchain/rpc.md",tags:[],version:"current",lastUpdatedBy:"racollette",lastUpdatedAt:1676175778,formattedLastUpdatedAt:"Feb 12, 2023",frontMatter:{title:"Mainchain JSON-RPC"},sidebar:"apiSidebar",previous:{title:"Elastos Mainchain CLI",permalink:"/api/mainchain/cli"},next:{title:"Mainchain REST API",permalink:"/api/mainchain/rest"}},u={},m=[{value:"getbestblockhash",id:"getbestblockhash",level:3},{value:"Example",id:"example",level:4},{value:"getblockhash",id:"getblockhash",level:3},{value:"Parameter",id:"parameter",level:4},{value:"Result",id:"result",level:4},{value:"Example",id:"example-1",level:4},{value:"getblock",id:"getblock",level:3},{value:"Parameter",id:"parameter-1",level:4},{value:"Example",id:"example-2",level:4},{value:"getblockcount",id:"getblockcount",level:3},{value:"Example",id:"example-3",level:4},{value:"getrawtransaction",id:"getrawtransaction",level:3},{value:"Parameter",id:"parameter-2",level:4},{value:"Results",id:"results",level:4},{value:"Example",id:"example-4",level:4},{value:"getrawmempool",id:"getrawmempool",level:3},{value:"Example",id:"example-5",level:4},{value:"getreceivedbyaddress",id:"getreceivedbyaddress",level:3},{value:"Parameter",id:"parameter-3",level:4},{value:"Example",id:"example-6",level:4},{value:"listunspent",id:"listunspent",level:3},{value:"Parameter",id:"parameter-4",level:4},{value:"Example",id:"example-7",level:4},{value:"setloglevel",id:"setloglevel",level:3},{value:"Parameter",id:"parameter-5",level:4},{value:"Example",id:"example-8",level:4},{value:"getconnectioncount",id:"getconnectioncount",level:3},{value:"Example",id:"example-9",level:4},{value:"getneighbors",id:"getneighbors",level:3},{value:"Example",id:"example-10",level:4},{value:"getnodestate",id:"getnodestate",level:3},{value:"Result",id:"result-1",level:4},{value:"Example",id:"example-11",level:4},{value:"sendrawtransaction",id:"sendrawtransaction",level:3},{value:"Parameter",id:"parameter-6",level:4},{value:"Result",id:"result-2",level:4},{value:"Example",id:"example-12",level:4},{value:"togglemining",id:"togglemining",level:3},{value:"Parameter",id:"parameter-7",level:4},{value:"Example",id:"example-13",level:4},{value:"discretemining",id:"discretemining",level:3},{value:"Parameter",id:"parameter-8",level:4},{value:"Example",id:"example-14",level:4},{value:"getmininginfo",id:"getmininginfo",level:3},{value:"Result",id:"result-3",level:4},{value:"Example",id:"example-15",level:4}
1,{value:"createauxblock",id:"createauxblock",level:3},{value:"Parameter",id:"parameter-9",level:4},{value:"Example",id:"example-16",level:4},{value:"submitauxblock",id:"submitauxblock",level:3},{value:"Parameter",id:"parameter-10",level:4},{value:"Example",id:"example-17",level:4},{value:"getinfo",id:"getinfo",level:3},{value:"listproducers",id:"listproducers",level:3},{value:"Parameter",id:"parameter-11",level:4},{value:"Result",id:"result-4",level:4},{value:"Example",id:"example-18",level:4},{value:"producerstatus",id:"producerstatus",level:3},{value:"Parameter",id:"parameter-12",level:4},{value:"Result",id:"result-5",level:4},{value:"Example",id:"example-19",level:4},{value:"votestatus",id:"votestatus",level:3},{value:"Parameter",id:"parameter-13",level:4},{value:"Result",id:"result-6",level:4},{value:"Example",id:"example-20",level:4},{value:"estimatesmartfee",id:"estimatesmartfee",level:3},{value:"Parameter",id:"parameter-14",level:4},{value:"Result",id:"result-7",level:4},{value:"Example",id:"example-21",level:4},{value:"getdepositcoin",id:"getdepositcoin",level:3},{value:"Parameter",id:"parameter-15",level:4},{value:"Result",id:"result-8",level:4},{value:"Example",id:"example-22",level:4},{value:"getcrdepositcoin",id:"getcrdepositcoin",level:3},{value:"Parameter",id:"parameter-16",level:4},{value:"Result",id:"result-9",level:4},{value:"Example",id:"example-23",level:4},{value:"getarbiterpeersinfo",id:"getarbiterpeersinfo",level:3},{value:"Result",id:"result-10",level:4},{value:"Example",id:"example-24",level:4},{value:"submitsidechainillegaldata",id:"submitsidechainillegaldata",level:3},{value:"Parameter",id:"parameter-17",level:4},{value:"Example",id:"example-25",level:4},{value:"getconfirmbyheight",id:"getconfirmbyheight",level:3},{value:"Parameter",id:"parameter-18",level:4},{value:"Result",id:"result-11",level:4},{value:"Example",id:"example-26",level:4},{value:"getconfirmbyhash",id:"getconfirmbyhash",level:3},{value:"Parameter",id:"parameter-19",level:4},{value:"Result",id:"result-12",level:4},{value:"Example",id:"example-27",level:4},{value:"getarbitersinfo",id:"getarbitersinfo",level:3},{value:"Result",id:"result-13",level:4},{value:"Example",id:"example-28",level:4},{value:"getutxosbyamount",id:"getutxosbyamount",level:3},{value:"Parameter",id:"parameter-20",level:4},{value:"Example",id:"example-29",level:4},{value:"getamountbyinputs",id:"getamountbyinputs",level:3},{value:"Parameter",id:"parameter-21",level:4},{value:"Result",id:"result-14",level:4},{value:"Example",id:"example-30",level:4},{value:"getblockbyheight",id:"getblockbyheight",level:3},{value:"Parameter",id:"parameter-22",level:4},{value:"Result",id:"result-15",level:4},{value:"Example",id:"example-31",level:4},{value:"getarbitratorgroupbyheight",id:"getarbitratorgroupbyheight",level:3},{value:"Parameter",id:"parameter-23",level:4},{value:"Result",id:"result-16",level:4},{value:"Example",id:"example-32",level:4},{value:"getexistwithdrawtransactions",id:"getexistwithdrawtransactions",level:3},{value:"Parameter",id:"parameter-24",level:4},{value:"Result",id:"result-17",level:4},{value:"Example",id:"example-33",level:4},{value:"listcrcandidates",id:"listcrcandidates",level:3},{value:"Parameter",id:"parameter-25",level:4},{value:"Result",id:"result-18",level:4},{value:"Example",id:"example-34",level:4},{value:"getsecretarygeneral",id:"getsecretarygeneral",level:3},{value:"Example",id:"example-35",level:4},{value:"listcurrentcrs",id:"listcurrentcrs",level:3},{value:"Parameter",id:"parameter-26",level:4},{value:"Result",id:"result-19",level:4},{value:"Example",id:"example-36",level:4},{value:"listcrproposalbasestate",id:"listcrproposalbasestate",level:3},{value:"Parameter",id:"parameter-27",level:4},{value:"Result",id:"result-20",level:4},{value:"Example",id:"example-37",level:4},{value:"getcrproposalstate",id:"getcrproposalstate",level:3},{value:"Parameter",id:"parameter-28",level:4},{value:"Result",id:"result-21",level:4},{value:"Example",id:"example-38",level:4},{value:"getproposaldraftdata",id:"getproposaldraftdata",level:3},{value:"Parameter",id:"parameter-29",level:4},{value:"Result",id:"result-22",level:4},{value:"Example",id:"example-39",level:4},{value:"createrawtransaction",id:"createrawtransaction",level:3},{value:"Parameter",id:"parameter-30",level:4},{value:"Example",id:"example-40",level:4},{value:"signrawtransactionwithkey",id:"signrawtransactionwithkey",level:3},{value:"Parameter",id:"parameter-31",level:4},{value:"Example",id:"example-41",level:4},{value:"decoderawtransaction",id:"decoderawtransaction",level:3},{value:"Parameter",id:"parameter-32",level:4},{value:"Example",id:"example-42",level:4},{value:"getcrrelatedstage",id:"getcrrelatedstage",level:3},{value:"Example",id:"example-43",level:4}],s={toc:m},c="wrapper";function k(t){var e=t.components,a=(0,l.Z)(t,d);return(0,r.kt)(c,(0,n.Z)({},s,a,{components:e,mdxType:"MDXLayout"}),(0,r.kt)("h1",{id:"api-reference-json-rpc"},"API reference (JSON-RPC)"),(0,r.kt)("p",null,"The ELA JSON RPC interfaces follow conform to the json-rpc 2.0 protocol but also remain compatible with 1.0 version.\nThat means both named params and positional params are acceptable."),(0,r.kt)("admonition",{type:"info"},(0,r.kt)("p",{parentName:"admonition"},(0,r.kt)("strong",{parentName:"p"},'"id"')," is optional, which will be sent back in the result samely if you add it in a request.\nIt is needed when you want to distinguish different requests."),(0,r.kt)("p",{parentName:"admonition"},(0,r.kt)("strong",{parentName:"p"},'"jsonrpc"')," is also optional. It tells which version this request uses.\nIn version 2.0 it is required, while in ver
1sion 1.0 it does not exist.")),(0,r.kt)("h3",{id:"getbestblockhash"},"getbestblockhash"),(0,r.kt)("p",null,"Return the hash of the most recent block"),(0,r.kt)("p",null,"result:"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"blockhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the hash of the most recent block")))),(0,r.kt)("h4",{id:"example"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},'{\n  "jsonrpc": "2.0",\n  "method":"getbestblockhash",\n  "params": [],\n  "id": 1\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},'{\n  "id": 1,\n  "jsonrpc": "2.0",\n  "result": "68692d63a8bfc8887553b97f99f09e523d34a2b599bf5b388436b2ddc85ed76e",\n  "error": null\n}\n')),(0,r.kt)("h3",{id:"getblockhash"},"getblockhash"),(0,r.kt)("p",null,"Return the hash of the specific blockchain height."),(0,r.kt)("h4",{id:"parameter"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"height"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the height of blockchain")))),(0,r.kt)("h4",{id:"result"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"blockhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the hash of the block")))),(0,r.kt)("h4",{id:"example-1"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getblockhash",\n  "params": { "height": 1 }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": "3893390c9fe372eab5b356a02c54d3baa41fc48918bbddfbac78cf48564d9d72",\n  "error": null\n}\n')),(0,r.kt)("h3",{id:"getblock"},"getblock"),(0,r.kt)("p",null,"Return the block information of the specific blockchain hash."),(0,r.kt)("h4",{id:"parameter-1"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"blockhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the blockchain hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"verbosity"),(0,r.kt)("td",{parentName:"tr",align:null},"int"),(0,r.kt)("td",{parentName:"tr",align:null},"the verbosity of result, can be 0, 1, 2")))),(0,r.kt)("h4",{id:"example-2"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},'{\n  "method":"getblock",\n  "params":{\n    "blockhash":"f3a7469bb59452ab665f8b8870e1fb30e6a7181e2ea70f377e218d5b13cfa8ed",\n    "verbosity": 0},\n}\n')),(0,r.kt)("p",null,"Response when verbosity is 0:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": "00000000c0433b918f500392869aa14cf7a909430fd94502b5c9f05421c9da7519bd6a652
119184ea3c0a2973b90b8402c8405b76d7fbe10a268f6de7e4f48e93f5d03df7c31e095bffff7f2000000000d107000001000000010000000000000000000000000000000000000000000000000000000000000000000000002cfabe6d6d3ca6bcc86bada4642fea709731f1653bd34b28ab15b790e102e14e0d7bd138d80100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffff7f00000000000000000000000000000000000000000000000000000000000000000ce39baabcdbb4adce38c5f23314c5f63a536bbcc8f0a47c7054c36ca27f5acd771d095b00000000020000000101000000000403454c4101000846444170b0e427d2010000000000000000000000000000000000000000000000000000000000000000ffffffffffff02b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a31b2913000000000000000000129e9cf1c5f336fcf3a6c954444ed482c5d916e506b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a341b52c000000000000000000219e9cc4320c3018ced30242b25c03e13a1b2f57c7d107000000"\n}\n')),(0,r.kt)("p",null,"Response when verbosity is 1:"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"hash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the blockchain hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"confirmations"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"confirmations")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"size"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the size of a block in bytes")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"strippedsize"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"equals to size")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"weight"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"This block\u2019s weight")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"height"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the height of block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"version"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"block header's version")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"versionhex"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"block header's version in hex format")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"merkleroot"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the merkleroot hash of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"tx"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"transaction hashes of this block, in an array")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"time"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the Unix timestamp of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"mediantime"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"equals to time")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nonce"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the nonce of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"bits"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"bits of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"difficulty"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"difficulty of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"chainwork"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"The estimated number of block header hashes miners had to check from the genesis block to this block, encoded as big-endian hex")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"previousblockhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"previous block hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nextblockhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"next block hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"auxpow"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"Auxpow information in hex format")))),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "id": null,\n  "error": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "hash": "3893390c9fe372eab5b356a02c54d3baa41fc48918bbddfbac78cf48564d9d72",\n    "confirmations": 5156,\n    "strippedsize": 498,\n    "size": 498,\n    "weight": 1992,\n    "height": 1,\n    "version": 0,\n    "versionhex": "00000000",\n    "merkleroot": "764691821f937fd566bcf533611a5e5b193008ea1ba1396f67b7b0da22717c02",\n    "tx": ["764691821f937fd566bcf533611a5e5b193008ea1ba1396f67b7b0da22717c02"],\n    "time": 1524737598,\n    "mediantime": 1524737598,\n    "nonce": 0,\n    "bits": 545259519,\n    "difficulty": "1",\n    "chainwork": "00001423",\n    "previousblockhash": "8d7014f2f941caa1972c8033b2f0a860ec8d4938b12bae2c62512852a558f405",\n    "nextblockhash": "aa98305779686e66294a9b667e6ac77f5231bb2ce09fe7d9ca64
11775413ecb5a",\n    "auxpow": "01000000010000000000000000000000000000000000000000000000000000000000000000000000002cfabe6d6d3893390c9fe372eab5b356a02c54d3baa41fc48918bbddfbac78cf48564d9d720100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffff7f0000000000000000000000000000000000000000000000000000000000000000a19035123a440356c0a41a85fe26865620fb4c34dcf1b83b46b5e11efcbbdd893ea6e15a0000000000000000"\n  }\n}\n')),(0,r.kt)("p",null,"Response when verbosity is 2:"),(0,r.kt)("p",null,"result format except 'tx' is the same as it is when verbosity=1"),(0,r.kt)("p",null,"result format in 'tx' please see interface 'getrawtransaction'"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "hash": "3ca6bcc86bada4642fea709731f1653bd34b28ab15b790e102e14e0d7bd138d8",\n    "confirmations": 1,\n    "strippedsize": 498,\n    "size": 498,\n    "weight": 1992,\n    "height": 2001,\n    "version": 0,\n    "versionhex": "00000000",\n    "merkleroot": "219184ea3c0a2973b90b8402c8405b76d7fbe10a268f6de7e4f48e93f5d03df7",\n    "tx": [\n      {\n        "txid": "219184ea3c0a2973b90b8402c8405b76d7fbe10a268f6de7e4f48e93f5d03df7",\n        "hash": "219184ea3c0a2973b90b8402c8405b76d7fbe10a268f6de7e4f48e93f5d03df7",\n        "size": 192,\n        "vsize": 192,\n        "version": 0,\n        "locktime": 2001,\n        "vin": [\n          {\n            "txid": "0000000000000000000000000000000000000000000000000000000000000000",\n            "vout": 65535,\n            "sequence": 4294967295\n          }\n        ],\n        "vout": [\n          {\n            "value": "0.01255707",\n            "n": 0,\n            "address": "8VYXVxKKSAxkmRrfmGpQR2Kc66XhG6m3ta",\n            "assetid": "b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a3",\n            "outputlock": 0\n          },\n          {\n            "value": "0.02929985",\n            "n": 1,\n            "address": "EXca4DJwqCXa6vbJmpovwatHiP8HRTVS1Z",\n            "assetid": "b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a3",\n            "outputlock": 0\n          }\n        ],\n        "blockhash": "3ca6bcc86bada4642fea709731f1653bd34b28ab15b790e102e14e0d7bd138d8",\n        "confirmations": 1,\n        "time": 1527324355,\n        "blocktime": 1527324355,\n        "type": 0,\n        "payloadversion": 4,\n        "payload": {\n          "CoinbaseData": "ELA"\n        },\n        "attributes": [\n          {\n            "usage": 0,\n            "data": "46444170b0e427d2"\n          }\n        ],\n        "programs": []\n      }\n    ],\n    "time": 1527324355,\n    "mediantime": 1527324355,\n    "nonce": 0,\n    "bits": 545259519,\n    "difficulty": "1",\n    "chainwork": "00000000",\n    "previousblockhash": "c0433b918f500392869aa14cf7a909430fd94502b5c9f05421c9da7519bd6a65",\n    "nextblockhash": "0000000000000000000000000000000000000000000000000000000000000000",\n    "auxpow": "01000000010000000000000000000000000000000000000000000000000000000000000000000000002cfabe6d6d3ca6bcc86bada4642fea709731f1653bd34b28ab15b790e102e14e0d7bd138d80100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffff7f00000000000000000000000000000000000000000000000000000000000000000ce39baabcdbb4adce38c5f23314c5f63a536bbcc8f0a47c7054c36ca27f5acd771d095b0000000002000000"\n  }\n}\n')),(0,r.kt)("h3",{id:"getblockcount"},"getblockcount"),(0,r.kt)("p",null,"Get block count"),(0,r.kt)("h4",{id:"example-3"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getblockcount"\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "jsonrpc": "2.0",\n  "id": null,\n  "error": null,\n  "result": 171454\n}\n')),(0,r.kt)("h3",{id:"getrawtransaction"},"getrawtransaction"),(0,r.kt)("p",null,"Get transaction infomation of given transaction hash."),(0,r.kt)("h4",{id:"parameter-2"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"txid"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"transaction hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"verbose"),(0,r.kt)("td",{parentName:"tr",align:null},"bool"),(0,r.kt)("td",{parentName:"tr",align:null},"verbose of result")))),(0,r.kt)("h4",{id:"results"},"Results"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"txid"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"transaction id")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"hash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"transaction id")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"size"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"transaction size")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null}
1,"vsize"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"The virtual transaction size, equals to size")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"version"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"The transaction format version number")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"locktime"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"The transaction\u2019s locktime")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"sequence"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"The transaction\u2019s sequence number")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"vin"),(0,r.kt)("td",{parentName:"tr",align:null},"array"),(0,r.kt)("td",{parentName:"tr",align:null},"input utxo vector of this transaction")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"n"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"index of utxo outputs")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"vout"),(0,r.kt)("td",{parentName:"tr",align:null},"array"),(0,r.kt)("td",{parentName:"tr",align:null},"output utxo vector of this transaction")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"assetid"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"asset id")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"outputlock"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"outputlock of this transaction")))),(0,r.kt)("h4",{id:"example-4"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getrawtransaction",\n  "params": ["caa0d52ea2b90a08480834b97c271a8b847aadf90057318a33ccc8674b77c796"]\n}\n')),(0,r.kt)("p",null,"Response when verbosity is ture:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "id": null,\n  "error": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "txid": "6864bbf52a3e140d40f1d707bae31d006265efc54dcb58e34037645060ce3e16",\n    "hash": "6864bbf52a3e140d40f1d707bae31d006265efc54dcb58e34037645060ce3e16",\n    "size": 192,\n    "vsize": 192,\n    "version": 0,\n    "locktime": 1000,\n    "vin": [\n      {\n        "txid": "0000000000000000000000000000000000000000000000000000000000000000",\n        "vout": 65535,\n        "sequence": 4294967295\n      }\n    ],\n    "vout": [\n      {\n        "value": "0.01255707",\n        "n": 0,\n        "address": "8VYXVxKKSAxkmRrfmGpQR2Kc66XhG6m3ta",\n        "assetid": "b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a3",\n        "outputlock": 0\n      },\n      {\n        "value": "0.02929985",\n        "n": 1,\n        "address": "ENTogr92671PKrMmtWo3RLiYXfBTXUe13Z",\n        "assetid": "b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a3",\n        "outputlock": 0\n      }\n    ],\n    "blockhash": "0000000000000000000000000000000000000000000000000000000000000000",\n    "confirmations": 4158,\n    "time": 1524737766,\n    "blocktime": 1524737766,\n    "type": 0,\n    "payloadversion": 4,\n    "payload": {\n      "CoinbaseData": "ELA"\n    },\n    "attributes": [\n      {\n        "usage": 0,\n        "data": "b52165c186769037"\n      }\n    ],\n    "programs": []\n  }\n}\n')),(0,r.kt)("p",null,"Response when verbosity is false:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": "000403454c4101000846444170b0e427d2010000000000000000000000000000000000000000000000000000000000000000ffffffffffff02b037db964a231458d2d  6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a31b2913000000000000000000129e9cf1c5f336fcf3a6c954444ed482c5d916e506b037db964a231458d2d6ffd  5ea18944c4f90e63d547c5d3b9874df66a4ead0a341b52c000000000000000000219e9cc4320c3018ced30242b25c03e13a1b2f57c7d107000000"\n}\n')),(0,r.kt)("h3",{id:"getrawmempool"},"getrawmempool"),(0,r.kt)("p",null,"Return hashes of transactions in memory pool."),(0,r.kt)("h4",{id:"example-5"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getrawmempool"\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": [\n    "5da460632a154fe75df0d5ec98560e4bc1115374a37a75e984a534f8da3ca941",\n    "5da460632a154fe75df0d5ec98560e4bc1115374a37a75e984a534f8da3ca941"\n  ]\n}\n')),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getrawmempool",\n  "params": {\n    "state": "all"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "jsonrpc": "2.0",\n  "result": [\n    {\n      "txid": "7bc35c1bb5d21c74cb94b73e2774c1be77a460b7ba1a5d8e73baa1721bb8c98d",\n      "hash": "7bc35c1bb5d21c74cb94b73e2774c1be77a460b7ba1a5d8e73baa1721bb8c98d",\n      "size": 369,\n      "vsize": 369,\n      "version": 0,\n      "type": 5,\n      "payloadversion": 0,\n      "payload": {\n        "blockheight": 366174,\n        "sideblockhash": "50e95c5452808282249827971def9b6d01a83a62251aada221b20ea66755f44b",\n        "sidegenesishash": "a3c455a90843db2acd22554f2768a8d4233fafbf8dd549e6b261c2786993be56",\n        "signature": "fdcb69746140a2c9b42c91642e5f887c7859c3709c189a83ed09ac2305d524d66e3b77dff3e9c070323d312afb8efedc60ce41c12e6684e0db5088bad1683a92"\n      },\n      "attributes": [\n        {\n          "usage": 0,\n          "data": "38303631373539313233303934363232343938"\n        }\n      ],\n      "vin": [\n        {\n          "txid": "754552520bbc5241fe5e59aae333a7e72d65c1d4ecec3a123cab3c773186a6b2",\n          "vout": 0,\n          "sequence": 0\n        }\n      ],\n      "vout": [\n        {\n          "value": "0.00300000",\n          "n": 0,\n          "address": "EfJDXdRiPk8aiSFwQ4Wf6BCddxgLS4o5hG",\n          "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n          "outputlock": 0,\n          "type": 0,\n          "payload": null\n        }\n      ],\n      "locktime": 688434,\n      "programs": [\n        {\n          "code": "21036eac18a8fe9722f5afee095334b3970496a92024f832530a51f6f1faba36a881ac",\n          "parameter": "407943915fb2d4938479757dea9cd75e957a9bfe9b45fd973139dd101e1ce4cba3520360ecb2a5da90652fbe05682bb6c7548075225effc87aadc272c27eddcc83"\n        }\n      ],\n      "blockhash": "",\n      "confirmations": 0,\n      "time": 0,\n      "blocktime": 0\n    }\n  ],\n  "id": null,\n  "error": null\n}\n')),(0,r.kt)("h3",{id:"getreceivedbyaddress"},"getreceivedbyaddress"),(0,r.kt)("p",null,"Get the balance of an address"),(0,r.kt)("h4",{id:"parameter-3"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"address"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"address")))),(0,r.kt)("h4",{id:"example-6"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getreceivedbyaddress",\n  "params": { "address": "8VYXVxKKSAxkmRrfmGpQR2Kc66XhG6m3ta" }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": "33000000"\n}\n')),(0,r.kt)("h3",{id:"listunspent"},"listunspent"),(0,r.kt)("p",null,"List all utxo of given addresses"),(0,r.kt)("h4",{id:"parameter-4"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"addresses"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"addresses")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"utxotype"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the utxo type")))),(0,r.kt)("p",null,'if not set utxotype will use "mixed" as default value\nif set utxotype to "mixed" or not set will get all utxos ignore the type\nif set utxotype to "vote" will get vote utxos\nif set utxotype to "normal" will get normal utxos without vote'),(0,r.kt)("h4",{id:"example-7"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "listunspent",\n  "params": {\n    "addresses": [\n      "8ZNizBf4KhhPjeJRGpox6rPcHE5Np6tFx3",\n      "EeEkSiRMZqg5rd9a2yPaWnvdPcikFtsrjE"\n    ]\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": [\n    {\n      "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n      "txid": "9132cf82a18d859d200c952aec548d7895e7b654fd1761d5d059b91edbad1768",\n      "vout": 0,\n      "address": "8ZNizBf4KhhPjeJRGpox6rPcHE5Np6tFx3",\n      "amount": "33000000",\n      "confirmations": 1102,\n      "outputlock": 0\n    },\n    {\n      "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n      "txid": "3edbcc839fd4f16c0b70869f2d477b56a006d31dc7a10d8cb49bd12628d6352e",\n      "vout": 0,\n      "address": "8ZNizBf4KhhPjeJRGpox6rPcHE5Np6tFx3",\n      "amount": "0.01255707",\n      "confirmations": 846,\n      "outputlock": 0\n    }\n  ]\n}\n')),(0,r.kt)("h3",{id:"setloglevel"},"setloglevel"),(0,r.kt)("p",null,"Set log level"),(0,r.kt)("h4",{id:"parameter-5"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"level"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the log level")))),(0,r.kt)("h4",{id:"example-8"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "setloglevel",\n  "params": {\n    "level": 0\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "id": null,\n  "jsonrpc": "2.0",\n  "error": null,\n  "result": "log level has been set to 0"\n}\n')),(0,r.kt)("h3",{id:"getconnectioncount"},"getconnectioncount"),(0,r.kt)("p",null,"Get peer's count of this node"),(0,r.kt)("h4",{id:"example-9"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getconnectioncount"\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "id": null,\n  "error": null,\n  "jsonrpc": "2.0",\n  "result": 0\n}\n')),(0,r.kt)("h3",{id:"getneighbors"},"getneighbors"),(0,r.kt)("p",null,"Get peer's info"),(0,r.kt)("h4",{id:"example-10"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getneighbors"\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": [\n    "127.0.0.1:64890 (inbound)",\n    "127.0.0.1:64880 (inbound)",\n    "127.0.0.1:64822 (inbound)",\n    "127.0.0.1:22338 (outbound)",\n    "127.0.0.1:23338 (outbound)",\n    "127.0.0.1:24338 (outbound)"\n  ]\n}\n')),(0,r.kt)("h3",{id:"getnodestate"},"getnodestate"),(0,r.kt)("p",null,"Get node state"),(0,r.kt)("h4",{id:"result-1"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"compile"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"node's compile version")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"height"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"current height of local node")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"version"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"peer-to-peer network protocol version of this node")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"services"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the services provided by this node")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"port"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"P2P network port")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"rpcport"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"JSON-RPC service port")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"restport"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"RESTful service port")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"wsport"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"webservice port")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"neighbors"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[neighbor]"),(0,r.kt)("td",{parentName:"tr",align:null},"neighbor nodes information")))),(0,r.kt)("p",null,"neighbor:"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"netaddress"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"network address of the neighbor in host:port format")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"services"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the services neighbor provides")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"relaytx"),(0,r.kt)("td",{parentName:"tr",align:null},"bool"),(0,r.kt)("td",{parentName:"tr",align:null},"relay transactions to the neighbor or not")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"lastsend"),(0,r.kt)("td",{parentName:"tr",align:null},"st
1ring"),(0,r.kt)("td",{parentName:"tr",align:null},"the last time send a message to the neighbor")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"lastrecv"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the last time received a message from the neighbor")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"conntime"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the time when this neighbor was connected")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"timeoffset"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"time offset between local time and the time advertised by the neighbor")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"version"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"peer-to-peer network version advertised by the neighbor")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"inbound"),(0,r.kt)("td",{parentName:"tr",align:null},"bool"),(0,r.kt)("td",{parentName:"tr",align:null},"the connection direction of the neighbor (inbound/outbound)")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"startingheight"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the height advertised by the neighbor when connected")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"lastblock"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the height of the last block advertised by the neighbor")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"lastpingtime"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the last time send a ping message to the neighbor")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"lastpingmicros"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"microseconds to receive pong message after sending last ping message")))),(0,r.kt)("h4",{id:"example-11"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getnodestate"\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "compile": "v0.2.2-231-g75d2-dirty",\n    "height": 0,\n    "version": 20000,\n    "services": "SFNodeNetwork|SFTxFiltering|SFNodeBloom",\n    "port": 21338,\n    "rpcport": 21336,\n    "restport": 21334,\n    "wsport": 21335,\n    "neighbors": [\n      {\n        "netaddress": "127.0.0.1:57656",\n        "services": "SFNodeNetwork|SFTxFiltering|SFNodeBloom",\n        "relaytx": false,\n        "lastsend": "2019-03-06 14:52:03 +0800 CST",\n        "lastrecv": "2019-03-06 14:52:18 +0800 CST",\n        "conntime": "2019-03-06 14:51:33.65298 +0800 CST m=+36.604516146",\n        "timeoffset": 0,\n        "version": 20000,\n        "inbound": true,\n        "startingheight": 0,\n        "lastblock": 0,\n        "lastpingtime": "2019-03-06 14:52:03.658121 +0800 CST m=+66.609840707",\n        "lastpingmicros": 1033\n      },\n      {\n        "netaddress": "127.0.0.1:22338",\n        "services": "SFNodeNetwork|SFTxFiltering|SFNodeBloom",\n        "relaytx": false,\n        "lastsend": "2019-03-06 14:52:02 +0800 CST",\n        "lastrecv": "2019-03-06 14:52:02 +0800 CST",\n        "conntime": "2019-03-06 14:51:02.097149 +0800 CST m=+5.048492921",\n        "timeoffset": 0,\n        "version": 20000,\n        "inbound": false,\n        "startingheight": 0,\n        "lastblock": 0,\n        "lastpingtime": "2019-03-06 14:52:02.104806 +0800 CST m=+65.056516088",\n        "lastpingmicros": 541\n      }\n    ]\n  }\n}\n')),(0,r.kt)("h3",{id:"sendrawtransaction"},"sendrawtransaction"),(0,r.kt)("p",null,"Send a raw transaction to node"),(0,r.kt)("h4",{id:"parameter-6"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"data"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"raw transaction data in hex")))),(0,r.kt)("h4",{id:"result-2"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"hash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"transaction hash")))),(0,r.kt)("h4",{id:"example-12"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "sendrawtransaction",\n  "params": ["xxxxxx"]\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "result": "764691821f937fd566bcf533611a5e5b193008ea1ba1396f67b7b0da22717c02",\n  "id": null,\n  "jsonrpc": "2.0",\n  "error": null\n}\n')),(0,r.kt)("h3",{id:"togglemining"},"togglemining"),(0,r.kt)("p",null,"The switch of mining"),(0,r.kt)("h4",{id:"parameter-7"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"mining"),(0,r.kt)("td",{parentName:"tr",align:null},"bool"),(0,r.kt)("td",{parentName:"tr",align:null},"whether mine or not")))),(0,r.kt)("h4",{id:"example-13"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "togglemining",\n  "params": { "mining": false }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": "mining stopped",\n  "error": null\n}\n')),(0,r.kt)("h3",{id:"discretemining"},"discretemining"),(0,r.kt)("p",null,"Generate one or more blocks instantly"),(0,r.kt)("h4",{id:"parameter-8"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"count"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"count of blocks")))),(0,r.kt)("h4",{id:"example-14"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "discretemining",\n  "params": { "count": 1 }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": [\n    "741d8131f0eea94c1c72c8bb1f0e9051a0a98441e131585bf5bf01868bf0ef46"\n  ],\n  "error": null\n}\n')),(0,r.kt)("h3",{id:"getmininginfo"}
1,"getmininginfo"),(0,r.kt)("p",null,"Returns a json object containing mining-related information"),(0,r.kt)("h4",{id:"result-3"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"blocks"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the current block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"currentblocktx"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the number of block transactions of the last assembled block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"difficulty"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the current difficulty")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"networkhashps"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the network hashes per second")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"pooledtx"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the size of the mempool")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"chain"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"current network name")))),(0,r.kt)("h4",{id:"example-15"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getmininginfo",\n  "params": {}\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "blocks": 397720,\n    "currentblocktx": 7,\n    "difficulty": "1553768014955882",\n    "networkhashps": "27618978773646499814",\n    "pooledtx": 0,\n    "chain": "mainnet"\n  }\n}\n')),(0,r.kt)("h3",{id:"createauxblock"},"createauxblock"),(0,r.kt)("p",null,"Generate an auxiliary block"),(0,r.kt)("h4",{id:"parameter-9"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"paytoaddress"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"miner's address")))),(0,r.kt)("h4",{id:"example-16"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("p",null,"named arguments:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "createauxblock",\n  "params": { "paytoaddress": "Ef4UcaHwvFrFzzsyVf5YH4JBWgYgUqfTAB" }\n}\n')),(0,r.kt)("p",null,"positional arguments:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "createauxblock",\n  "params": ["Ef4UcaHwvFrFzzsyVf5YH4JBWgYgUqfTAB"]\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "chainid": 1224,\n    "height": 152789,\n    "coinbasevalue": 175799086,\n    "bits": "1d36c855",\n    "hash": "e28a262b38316fddefb0b5c753f7cc0022afe94e95f881576ad6b8f33f4e49fe",\n    "previousblockhash": "f297d03791f4cf2c6ef093b02a77465ea876b040b7772e56b8e140f3bff73871"\n  }\n}\n')),(0,r.kt)("h3",{id:"submitauxblock"},"submitauxblock"),(0,r.kt)("p",null,"Submit the solved auxpow of an auxiliary block"),(0,r.kt)("h4",{id:"parameter-10"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"blockhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the auxiliary block hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"auxpow"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the solved auxpow of this auxiliary block")))),(0,r.kt)("h4",{id:"example-17"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("p",null,"named arguments sample:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "submitauxblock",\n  "params": {\n    "blockhash": "7926398947f332fe534b15c628ff0cd9dc6f7d3ea59c74801dc758ac65428e64",\n    "auxpow": "02000000010000000000000000000000000000000000000000000000000000000000000000ffffffff4b0313ee0904a88
10495b742f4254432e434f4d2ffabe6d6d9581ba0156314f1e92fd03430c6e4428a32bb3f1b9dc627102498e5cfbf26261020000004204cb9a010f32a00601000000000000ffffffff0200000000000000001976a914c0174e89bd93eacd1d5a1af4ba1802d412afc08688ac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf90000000014acac4ee8fdd8ca7e0b587b35fce8c996c70aefdf24c333038bdba7af531266000000000001ccc205f0e1cb435f50cc2f63edd53186b414fcb22b719da8c59eab066cf30bdb0000000000000020d1061d1e456cae488c063838b64c4911ce256549afadfc6a4736643359141b01551e4d94f9e8b6b03eec92bb6de1e478a0e913e5f733f5884857a7c2b965f53ca880495bffff7f20a880495b"\n  }\n}\n')),(0,r.kt)("p",null,"positional arguments sample:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "submitauxblock",\n  "params": [\n    "7926398947f332fe534b15c628ff0cd9dc6f7d3ea59c74801dc758ac65428e64",\n    "02000000010000000000000000000000000000000000000000000000000000000000000000ffffffff4b0313ee0904a880495b742f4254432e434f4d2ffabe6d6d9581ba0156314f1e92fd03430c6e4428a32bb3f1b9dc627102498e5cfbf26261020000004204cb9a010f32a00601000000000000ffffffff0200000000000000001976a914c0174e89bd93eacd1d5a1af4ba1802d412afc08688ac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf90000000014acac4ee8fdd8ca7e0b587b35fce8c996c70aefdf24c333038bdba7af531266000000000001ccc205f0e1cb435f50cc2f63edd53186b414fcb22b719da8c59eab066cf30bdb0000000000000020d1061d1e456cae488c063838b64c4911ce256549afadfc6a4736643359141b01551e4d94f9e8b6b03eec92bb6de1e478a0e913e5f733f5884857a7c2b965f53ca880495bffff7f20a880495b"\n  ]\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": true\n}\n')),(0,r.kt)("h3",{id:"getinfo"},"getinfo"),(0,r.kt)("p",null,"Return node information.\nwarning: this interface is ready to be deprecated. So no api information will be supplied."),(0,r.kt)("h3",{id:"listproducers"},"listproducers"),(0,r.kt)("p",null,"Show producers infromation"),(0,r.kt)("h4",{id:"parameter-11"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"start"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the start index of producers")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"limit"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the limit count of producers")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"state"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the producer state you want",(0,r.kt)("br",null),'"all": get producers in any state',(0,r.kt)("br",null),'"pending": get producers in the pendding state',(0,r.kt)("br",null))))),(0,r.kt)("p",null,'"active": get producers in the active state',(0,r.kt)("br",null),'\n"inactive": get producers in the inactive state',(0,r.kt)("br",null),'\n"canceled": get producers in the canceled state',(0,r.kt)("br",null),'\n"illegal": get producers in the illegal state',(0,r.kt)("br",null),'\n"returned": get producers in the returned state |\nif state flag not provided return the producers in pending and active state.'),(0,r.kt)("h4",{id:"result-4"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"ownerpublickey"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the owner public key of producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nodepublickey"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the node public key of the producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nickname"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the nick name of the producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"url"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the url of the producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"location"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the location number of the producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"active"),(0,r.kt)("td",{parentName:"tr",align:null},"bool"),(0,r.kt)("td",{parentName:"tr",align:null},"if producer has confirmed")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"votes"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the votes currently held")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"state"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the current state of the producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"registerheight"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the height of cancel producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"cancelheight"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the cancel height of the producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"inactiveheight"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the inactive start height of the producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"illegalheight"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the illegal start height of the producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"index"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the index of the producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"totalvotes"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the total votes of registered producers")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"totalcounts"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the total counts of registered producers")))),(0,r.kt)("h4",{id:"example-18"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "listproducers",\n  "params": {\n    "start": 0,\n    "limit": 3\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "producers": [\n      {\n        "ownerpublickey": "0237a5fb316caf7587e052125585b135361be533d74b5a094a68c64c47ccd1e1eb",\n        "nodepublickey": "0237a5fb316caf7587e052125585b135361be533d74b5a094a68c64c47ccd1e1eb",\n        "nickname": "elastos1",\n        "url": "http://www.elastos1.com",\n        "location": 401,\n        "active": true,\n        "votes": "3.11100000",\n        "state": "Active",\n        "registerheight": 236,\n        "cancelheight": 0,\n        "inactiveheight": 0,\n        "illegalheight": 0,\n        "index": 0\n      },\n      {\n        "ownerpublickey": "030a26f8b4ab0ea219eb461d1e454ce5f0bd0d289a6a64ffc0743dab7bd
15be0be9",\n        "nodepublickey": "030a26f8b4ab0ea219eb461d1e454ce5f0bd0d289a6a64ffc0743dab7bd5be0be9",\n        "nickname": "elastos2",\n        "url": "http://www.elastos2.com",\n        "location": 402,\n        "active": true,\n        "votes": "2.10000000",\n        "state": "Active",\n        "registerheight": 225,\n        "cancelheight": 0,\n        "inactiveheight": 0,\n        "illegalheight": 0,\n        "index": 1\n      },\n      {\n        "ownerpublickey": "0288e79636e41edce04d4fa95d8f62fed73a76164f8631ccc42f5425f960e4a0c7",\n        "nodepublickey": "0288e79636e41edce04d4fa95d8f62fed73a76164f8631ccc42f5425f960e4a0c7",\n        "nickname": "elastos3",\n        "url": "http://www.elastos3.com",\n        "location": 403,\n        "active": true,\n        "votes": "0",\n        "state": "Active",\n        "registerheight": 216,\n        "cancelheight": 0,\n        "inactiveheight": 0,\n        "illegalheight": 0,\n        "index": 2\n      }\n    ],\n    "totalvotes": "5.21100000",\n    "totalcounts": 10\n  }\n}\n')),(0,r.kt)("h3",{id:"producerstatus"},"producerstatus"),(0,r.kt)("p",null,"Show producer status"),(0,r.kt)("h4",{id:"parameter-12"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"publickey"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the public key of producer")))),(0,r.kt)("h4",{id:"result-5"},"Result"),(0,r.kt)("p",null,"0: producer has not registered\n1: producer has confirmed (6 confirms)\n2: producer registered but not confirmed (less than 6 confirms)"),(0,r.kt)("h4",{id:"example-19"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "producerstatus",\n  "params": {\n    "publickey": "0237a5fb316caf7587e052125585b135361be533d74b5a094a68c64c47ccd1e1eb"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": 1\n}\n')),(0,r.kt)("h3",{id:"votestatus"},"votestatus"),(0,r.kt)("p",null,"Show producer vote status"),(0,r.kt)("h4",{id:"parameter-13"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"address"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the address of user")))),(0,r.kt)("h4",{id:"result-6"},"Result"),(0,r.kt)("p",null,"Note: If the EnableUtxoDB configuration entry is true, the total field is computed, otherwise the total field returns -1"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"total"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the total voting rights")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"voting"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the used voting rights")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"pending"),(0,r.kt)("td",{parentName:"tr",align:null},"bool"),(0,r.kt)("td",{parentName:"tr",align:null},"have vote in tx pool")))),(0,r.kt)("h4",{id:"example-20"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "votestatus",\n  "params": {\n    "address": "EZwPHEMQLNBpP2VStF3gRk8EVoMM2i3hda"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "total": "4.66088900",\n    "voting": "0",\n    "pending": true\n  }\n}\n')),(0,r.kt)("h3",{id:"estimatesmartfee"},"estimatesmartfee"),(0,r.kt)("p",null,"Estimate transaction fee smartly."),(0,r.kt)("h4",{id:"parameter-14"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"confirmations"),(0,r.kt)("td",{parentName:"tr",align:null}
1,"int"),(0,r.kt)("td",{parentName:"tr",align:null},"in how many blocks do you want your transaction to be packed")))),(0,r.kt)("h4",{id:"result-7"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"-"),(0,r.kt)("td",{parentName:"tr",align:null},"int"),(0,r.kt)("td",{parentName:"tr",align:null},"fee rate, the unit is sela per KB")))),(0,r.kt)("h4",{id:"example-21"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "estimatesmartfee",\n  "params": {\n    "confirmations": 5\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": 10000\n}\n')),(0,r.kt)("h3",{id:"getdepositcoin"},"getdepositcoin"),(0,r.kt)("p",null,"Get deposit coin by owner public key."),(0,r.kt)("h4",{id:"parameter-15"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"ownerpublickey"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the ownerPublicKey of producer")))),(0,r.kt)("h4",{id:"result-8"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"available"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the available deposit coin of producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"deducted"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the deducted deposit coin of producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"deposit"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the deposit amount coin of producer")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"assets"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the total assets coin of producer")))),(0,r.kt)("h4",{id:"example-22"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getdepositcoin",\n  "params": {\n    "ownerpublickey": "024babfecea0300971a6f0ad13b27519faff0ef595faf9490dc1f5f4d6e6d7f3fb"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "available": "1",\n    "deducted": "0",\n    "deposit": "3",\n    "assets": "4"\n  }\n}\n')),(0,r.kt)("h3",{id:"getcrdepositcoin"},"getcrdepositcoin"),(0,r.kt)("p",null,"Get deposit coin by owner public key or cid or did."),(0,r.kt)("h4",{id:"parameter-16"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"id"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cid or did address of CR candidate")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"publickey"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the public key of CR candidate")))),(0,r.kt)("h4",{id:"result-9"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"available"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null}
1,"the available deposit coin of CR candidate")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"deducted"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the deducted deposit coin of CR candidate")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"deposit"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the deposit amount coin of CR candidate")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"assets"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the total assets coin of CR candidate")))),(0,r.kt)("h4",{id:"example-23"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getcrdepositcoin",\n  "params": {\n    "id": "iUzjmMPTYZq2afqtR46coY6B7h2qD1PQbyq"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "available": "1",\n    "deducted": "0",\n    "deposit": "3",\n    "assets": "4"\n  }\n}\n')),(0,r.kt)("h3",{id:"getarbiterpeersinfo"},"getarbiterpeersinfo"),(0,r.kt)("p",null,"Get dpos peers information."),(0,r.kt)("h4",{id:"result-10"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"ownerpublickey"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"owner public key of the peer which should be one of current arbiters")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nodepublickey"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"node public key of the peer which should be one of current arbiters")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"ip"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"ip address of the peer (including port)")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"connstate"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"connection state about the peer, the value can be: NoneConnection, OutboundOnly, InboundOnly, or 2WayConnection")))),(0,r.kt)("h4",{id:"example-24"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getarbiterpeersinfo"\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": [\n    {\n      "ownerpublickey": "0243ff13f1417c69686bfefc35227ad4f5f4ca03ccb3d3a635ae8ed67d57c20b97",\n      "nodepublickey": "0243ff13f1417c69686bfefc35227ad4f5f4ca03ccb3d3a635ae8ed67d57c20b97",\n      "ip": "127.0.0.1:22339",\n      "connstate": "2WayConnection"\n    },\n    {\n      "ownerpublickey": "024ac1cdf73e3cbe88843b2d7279e6afdc26fc71d221f28cfbecbefb2a48d48304",\n      "nodepublickey": "0393e823c2087ed30871cbea9fa5121fa932550821e9f3b17acef0e581971efab0",\n      "ip": "127.0.0.1:23339",\n      "connstate": "InboundOnly"\n    },\n    {\n      "ownerpublickey": "0274fe9f165574791f74d5c4358415596e408b704be9003f51a25e90fd527660b5",\n      "nodepublickey": "03e281f89d85b3a7de177c240c4961cb5b1f2106f09daa42d15874a38bbeae85dd",\n      "ip": "127.0.0.1:24339",\n      "connstate": "NoneConnection"\n    }\n  ]\n}\n')),(0,r.kt)("h3",{id:"submitsidechainillegaldata"},"submitsidechainillegaldata"),(0,r.kt)("p",null,"Submit illegal data from side chain."),(0,r.kt)("h4",{id:"parameter-17"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"illegaldata"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"serialized illegal data in hex string format")))),(0,r.kt)("h4",{id:"example-25"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "submitsidechainillegaldata",\n  "params": {\n    "illegaldata": "016400000021023a133480176214f88848c6eaa684a54b316849df2b8570b57f3a917f19bbc77a52fdfc072182654f163f5f0f9a621d729566c74d10037c4d7bbb0407d1e2c64981855ad8681d0d86d1e91e00167939
1cb6694d2c422acd208a0072939487f699940353662653933363937386332363162326536343964353864626661663366323364346138363832373466353532326364326164623433303861393535633461330221030a26f8b4ab0ea219eb461d1e454ce5f0bd0d289a6a64ffc0743dab7bd5be0be9210288e79636e41edce04d4fa95d8f62fed73a76164f8631ccc42f5425f960e4a0c7"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": true\n}\n')),(0,r.kt)("h3",{id:"getconfirmbyheight"},"getconfirmbyheight"),(0,r.kt)("p",null,"Get block confirm by height of block."),(0,r.kt)("h4",{id:"parameter-18"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"height"),(0,r.kt)("td",{parentName:"tr",align:null},"int"),(0,r.kt)("td",{parentName:"tr",align:null},"the height of block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"verbosity"),(0,r.kt)("td",{parentName:"tr",align:null},"int"),(0,r.kt)("td",{parentName:"tr",align:null},"the verbosity of result, 0 will return serialized confirmed data, default 1")))),(0,r.kt)("h4",{id:"result-11"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"sponsor"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the sponsor nodePublicKey of the proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"viewoffset"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the viewoffset of the proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"votes"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[struct]"),(0,r.kt)("td",{parentName:"tr",align:null},"the votes of confirm")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"signer"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the singner nodePublicKey of the proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"accept"),(0,r.kt)("td",{parentName:"tr",align:null},"bool"),(0,r.kt)("td",{parentName:"tr",align:null},"accept or not of the proposal")))),(0,r.kt)("h4",{id:"example-26"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getconfirmbyheight",\n  "params": {\n    "height": 300000,\n    "verbosity": 1\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "blockhash": "65fd07f4069a1ca6833d38e0baa9b0b4a9bac35131feb5c363bd2fb99f8d06d8",\n    "sponsor": "024ac1cdf73e3cbe88843b2d7279e6afdc26fc71d221f28cfbecbefb2a48d48304",\n    "viewoffset": 0,\n    "votes": [\n      {\n        "signer": "024babfecea0300971a6f0ad13b27519faff0ef595faf9490dc1f5f4d6e6d7f3fb",\n        "accept": true\n      },\n      {\n        "signer": "024ac1cdf73e3cbe88843b2d7279e6afdc26fc71d221f28cfbecbefb2a48d48304",\n        "accept": true\n      },\n      {\n        "signer": "0274fe9f165574791f74d5c4358415596e408b704be9003f51a25e90fd527660b5",\n        "accept": true\n      }\n    ]\n  }\n}\n')),(0,r.kt)("h3",{id:"getconfirmbyhash"},"getconfirmbyhash"),(0,r.kt)("p",null,"Get block confirm by hash of block."),(0,r.kt)("h4",{id:"parameter-19"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"blockhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the hash of block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"verbosity"),(0,r.kt)("td",{parentName:"tr",align:null}
1,"int"),(0,r.kt)("td",{parentName:"tr",align:null},"the verbosity of result, 0 will return serialized confirmed data, default 1")))),(0,r.kt)("h4",{id:"result-12"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"sponsor"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the sponsor nodePublicKey of the proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"viewoffset"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the viewoffset of the proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"votes"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[struct]"),(0,r.kt)("td",{parentName:"tr",align:null},"the votes of confirm")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"signer"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the singner nodePublicKey of the proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"accept"),(0,r.kt)("td",{parentName:"tr",align:null},"bool"),(0,r.kt)("td",{parentName:"tr",align:null},"accept or not of the proposal")))),(0,r.kt)("h4",{id:"example-27"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getconfirmbyhash",\n  "params": {\n    "blockhash": "65fd07f4069a1ca6833d38e0baa9b0b4a9bac35131feb5c363bd2fb99f8d06d8",\n    "verbosity": 1\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "blockhash": "65fd07f4069a1ca6833d38e0baa9b0b4a9bac35131feb5c363bd2fb99f8d06d8",\n    "sponsor": "024ac1cdf73e3cbe88843b2d7279e6afdc26fc71d221f28cfbecbefb2a48d48304",\n    "viewoffset": 0,\n    "votes": [\n      {\n        "signer": "024babfecea0300971a6f0ad13b27519faff0ef595faf9490dc1f5f4d6e6d7f3fb",\n        "accept": true\n      },\n      {\n        "signer": "024ac1cdf73e3cbe88843b2d7279e6afdc26fc71d221f28cfbecbefb2a48d48304",\n        "accept": true\n      },\n      {\n        "signer": "0274fe9f165574791f74d5c4358415596e408b704be9003f51a25e90fd527660b5",\n        "accept": true\n      }\n    ]\n  }\n}\n')),(0,r.kt)("h3",{id:"getarbitersinfo"},"getarbitersinfo"),(0,r.kt)("p",null,"Get arbiters and candidates about current and next turn."),(0,r.kt)("h4",{id:"result-13"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"arbiters"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"get node public keys about arbiters of current turn")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"candidates"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"get node public keys about candidates of current turn")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nextarbiters"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"get node public keys about arbiters of next turn")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nextcandidates"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"get node public keys about candidates of next turn")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null}
1,"ondutyarbiter"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"get node public key of current on duty arbiter")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"currentturnstartheight"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"get height of current turn")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nextturnstartheight"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"get an estimate height of next turn")))),(0,r.kt)("h4",{id:"example-28"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getarbitersinfo"\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "arbiters": [\n      "0247984879d35fe662d6dddb4edf111c9f64fde18ccf8af0a51e4b278c3411a8f2",\n      "032e583b6b578cccb9bbe4a53ab54a3e3e60156c01973b16af52b614813fca1bb2",\n      "0223b8e8098dd694f4d20ea74800b1260a5a4a0afe7f6a0043c7e459c84ff80fba",\n      "03982eaa9744a3777860013b6b988dc5250198cb81b3aea157f9b429206e3ae80f",\n      "0328443c1e4bdb5b60ec1d017056f314ba31f8f9f43806128fac20499a9df27bc2"\n    ],\n    "candidates": [],\n    "nextarbiters": [\n      "0247984879d35fe662d6dddb4edf111c9f64fde18ccf8af0a51e4b278c3411a8f2",\n      "032e583b6b578cccb9bbe4a53ab54a3e3e60156c01973b16af52b614813fca1bb2",\n      "0223b8e8098dd694f4d20ea74800b1260a5a4a0afe7f6a0043c7e459c84ff80fba",\n      "03982eaa9744a3777860013b6b988dc5250198cb81b3aea157f9b429206e3ae80f",\n      "0328443c1e4bdb5b60ec1d017056f314ba31f8f9f43806128fac20499a9df27bc2"\n    ],\n    "nextcandidates": [],\n    "ondutyarbiter": "03982eaa9744a3777860013b6b988dc5250198cb81b3aea157f9b429206e3ae80f",\n    "currentturnstartheight": 200,\n    "nextturnstartheight": 212\n  }\n}\n')),(0,r.kt)("h3",{id:"getutxosbyamount"},"getutxosbyamount"),(0,r.kt)("p",null,"Get utxo by given amount, amount of utxo >= given amount."),(0,r.kt)("h4",{id:"parameter-20"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"address"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the address of ela")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"amount"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the min amount to get utxo")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"utxotype"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the utxo type")))),(0,r.kt)("p",null,'if not set utxotype will use "mixed" as default value\nif set utxotype to "mixed" or not set will get all utxos ignore the type\nif set utxotype to "vote" will get vote utxos\nif set utxotype to "normal" will get normal utxos without vote\nif set utxotype to "unused" will get all utxos that are not in tx pool'),(0,r.kt)("h4",{id:"example-29"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getutxosbyamount",\n  "params": {\n    "address": "XKUh4GLhFJiqAMTF6HyWQrV9pK9HcGUdfJ",\n    "amount": "0.25"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": [\n    {\n      "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n      "txid": "9132cf82a18d859d200c952aec548d7895e7b654fd1761d5d059b91edbad1768",\n      "vout": 0,\n      "address": "XKUh4GLhFJiqAMTF6HyWQrV9pK9HcGUdfJ",\n      "amount": "0.1",\n      "confirmations": 1102,\n      "outputlock": 0\n    },\n    {\n      "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n      "txid": "3edbcc839fd4f16c0b70869f2d477b56a006d31dc7a10d8cb49bd12628d6352e",\n      "vout": 0,\n      "address": "XKUh4GLhFJiqAMTF6HyWQrV9pK9HcGUdfJ",\n      "amount": "0.2",\n      "confirmations": 846,\n      "outputlock": 0\n    }\n  ]\n}\n')),(0,r.kt)("h3",{id:"getamountbyinputs"},"getamountbyinputs"),(0,r.kt)("p",null,"Get amount of given inputs."),(0,r.kt)("h4",{id:"parameter-21"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null}
1,"inputs"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the hex string of inputs")))),(0,r.kt)("h4",{id:"result-14"},"Result"),(0,r.kt)("p",null,"Amount of all given inputs, the type is string, if not found input will return error"),(0,r.kt)("h4",{id:"example-30"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getamountbyinputs",\n  "params": {\n    "inputs": "029132cf82a18d859d200c952aec548d7895e7b654fd1761d5d059b91edbad17680000000000003edbcc839fd4f16c0b70869f2d477b56a006d31dc7a10d8cb49bd12628d6352e000000000000"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": "0.3"\n}\n')),(0,r.kt)("h3",{id:"getblockbyheight"},"getblockbyheight"),(0,r.kt)("p",null,"Get a block by specifying block height."),(0,r.kt)("h4",{id:"parameter-22"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"height"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the height of block")))),(0,r.kt)("h4",{id:"result-15"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"hash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the blockchain hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"confirmations"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"confirmations")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"size"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the size of a block in bytes")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"strippedsize"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"equals to size")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"weight"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"This block\u2019s weight")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"height"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the height of block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"version"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"block header's version")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"versionhex"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"block header's version in hex format")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"merkleroot"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the merkleroot hash of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"tx"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[struct]"),(0,r.kt)("td",{parentName:"tr",align:null},"transactions of this block as an array")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"time"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the Unix timestamp of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"mediantime"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"equals to time")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nonce"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the nonce of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"bits"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"bits of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"difficulty"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"difficulty of this block")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"chainwork"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"The estimated number of block header hashes miners had to check from the genesis block to this block, encoded as big-endian hex")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"previousblockhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"previous block hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nextblockhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"next block hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"auxpow"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"Auxpow information in hex format")))),(0,r.kt)("h4",{id:"example-31"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getblockbyheight",\n  "params": {\n    "height": 5\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "hash": "d428cf8a8e8e2c265ccceb0ed0a017aae45a89c98529d1f6dd43efc219089e0e",\n    "confirmations": 452,\n    "strippedsize": 563,\n    "size": 563,\n    "weight": 2252,\n    "height": 5,\n    "version": 0,\n    "versionhex": "00000000",\n    "merkleroot": "c1accbe3434279f74db674728d7020190680474f11c4ec2976bd1223
1cf7c9c66",\n    "tx": [\n      {\n        "txid": "c1accbe3434279f74db674728d7020190680474f11c4ec2976bd1223cf7c9c66",\n        "hash": "c1accbe3434279f74db674728d7020190680474f11c4ec2976bd1223cf7c9c66",\n        "size": 257,\n        "vsize": 257,\n        "version": 0,\n        "locktime": 5,\n        "vin": [\n          {\n            "txid": "0000000000000000000000000000000000000000000000000000000000000000",\n            "vout": 65535,\n            "sequence": 4294967295\n          }\n        ],\n        "vout": [\n          {\n            "value": "1.50684931",\n            "n": 0,\n            "address": "EPha6MJ2Y9HAdrtNvMVrBu6ePMnmZJtmyv",\n            "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n            "outputlock": 0,\n            "type": 0,\n            "payload": null\n          },\n          {\n            "value": "1.75799086",\n            "n": 1,\n            "address": "EQzEvQbz5XGDZeWu2u48dPaeLTzvmfSyG4",\n            "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n            "outputlock": 0,\n            "type": 0,\n            "payload": null\n          },\n          {\n            "value": "1.75799088",\n            "n": 2,\n            "address": "EPha6MJ2Y9HAdrtNvMVrBu6ePMnmZJtmyv",\n            "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n            "outputlock": 0,\n            "type": 0,\n            "payload": null\n          }\n        ],\n        "blockhash": "d428cf8a8e8e2c265ccceb0ed0a017aae45a89c98529d1f6dd43efc219089e0e",\n        "confirmations": 452,\n        "time": 1556595214,\n        "blocktime": 1556595214,\n        "type": 0,\n        "payloadversion": 4,\n        "payload": {\n          "coinbasedata": "ELA"\n        },\n        "attributes": [\n          {\n            "usage": 0,\n            "data": "f53c107eec00d337"\n          }\n        ],\n        "programs": []\n      }\n    ],\n    "time": 1556595214,\n    "mediantime": 1556595214,\n    "nonce": 0,\n    "bits": 545259519,\n    "difficulty": "1",\n    "chainwork": "000001c3",\n    "previousblockhash": "b45f9e479340c6d2889076f6bd1e138d14e8620bc2cc0ef642bd15278509d49f",\n    "nextblockhash": "185cf0322f3f38abe0ecc0fffbca84d87965492042e87036bf78bfdb665b53fa",\n    "auxpow": "01000000010000000000000000000000000000000000000000000000000000000000000000000000002cfabe6d6d0e9e0819c2ef43ddf6d12985c9895ae4aa17a0d00eebcc5c262c8e8e8acf28d40100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffff7f0000000000000000000000000000000000000000000000000000000000000000a0c69cab73b8541e6d5b17d5c27e3482d3cc0264da80142645f4ad67677a44940cc2c75c0000000001000000",\n    "minerinfo": "ELA"\n  }\n}\n')),(0,r.kt)("h3",{id:"getarbitratorgroupbyheight"},"getarbitratorgroupbyheight"),(0,r.kt)("p",null,"Get amount of given inputs."),(0,r.kt)("h4",{id:"parameter-23"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"height"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"block height about the chain")))),(0,r.kt)("h4",{id:"result-16"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null}
1,"ondutyarbitratorindex"),(0,r.kt)("td",{parentName:"tr",align:null},"int"),(0,r.kt)("td",{parentName:"tr",align:null},"index of current on duty arbitrator")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"arbitrators"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"an array of current arbitrators")))),(0,r.kt)("h4",{id:"example-32"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getarbitratorgroupbyheight",\n  "params": {\n    "height": 310\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "ondutyarbitratorindex": 10,\n    "arbitrators": [\n      "02338fc098e08ed9a798f0d40b5320f52ad0539b98a972856a948bf652b0014110",\n      "026ef6740c405e9ff137410f47fe92597c82a8dd236e87e7f4aafe4dc1aa0cd06b",\n      "02c684ec9883bb5397243d9e129b9334a643f4778c28e99d59858162884081b183",\n      "02d20a48b4287737912de6af53b6afef2596a755f2a541374dda1fd3ab0aa1b984",\n      "02d2dd22fa2abfebb94d34666da47b15f214cc1a9ea1b8db0fda22d264bb922b36",\n      "02fc936192cfb02b8a22e4ba090638f05ac60c8bf9d70f1558c5166cb7768a182e",\n      "030936942e4bbe3d7f7dc45cea38195f4c4bb1474b336d6bf35fcba179872332b4",\n      "0320cb8d823c5d202e0ec481f4e0fa0d3e191fb9d0a7629543882bad7444ad3016",\n      "03268eb4064889047863485288515cdd880a986b57ccc9d72ae58d4401f67509a7",\n      "034282d36e034272f7c289fd9655797a352d1c76a917e94d6dedaf484acf167e2d",\n      "03d732f3df7c081d149bd585b77afe1077cedb4b6c6fd9b6278a8ffd456d34c3ab",\n      "03f9a1f5b23e3d57e8d95a45008ad4574352fa55f755a655c81ee22e62894811b2"\n    ]\n  }\n}\n')),(0,r.kt)("h3",{id:"getexistwithdrawtransactions"},"getexistwithdrawtransactions"),(0,r.kt)("p",null,"Find out which are already exist in chain by providing a list of withdraw transaction hashes."),(0,r.kt)("h4",{id:"parameter-24"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"txs"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"a list of transaction hashes in string format")))),(0,r.kt)("h4",{id:"result-17"},"Result"),(0,r.kt)("p",null,"A list of existing transaction hashes."),(0,r.kt)("h4",{id:"example-33"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getexistwithdrawtransactions",\n  "params": {\n    "txs": [\n      "3edbcc839fd4f16c0b70869f2d477b56a006d31dc7a10d8cb49bd12628d6352e",\n      "9132cf82a18d859d200c952aec548d7895e7b654fd1761d5d059b91edbad1768",\n      "764691821f937fd566bcf533611a5e5b193008ea1ba1396f67b7b0da22717c02"\n    ]\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": [\n    "3edbcc839fd4f16c0b70869f2d477b56a006d31dc7a10d8cb49bd12628d6352e",\n    "9132cf82a18d859d200c952aec548d7895e7b654fd1761d5d059b91edbad1768"\n  ]\n}\n')),(0,r.kt)("h3",{id:"listcrcandidates"},"listcrcandidates"),(0,r.kt)("p",null,"Show cr candidates information"),(0,r.kt)("h4",{id:"parameter-25"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"start"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the start index of cr candidates")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"limit"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the limit count of cr candidates")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"state"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr candidates state you want",(0,r.kt)("br",null),'"all": get cr candidates in any state',(0,r.kt)("br",null),'"pending": get cr candidates in the pendding state',(0,r.kt)("br",null))))),(0,r.kt)("p",null,'"active": get cr candidates in the active state',(0,r.kt)("br",null),'\n"canceled": get cr candidates in the canceled state',(0,r.kt)("br",null),'\n"returned": get cr candidates in the returned state |\nif state flag not provided return the cr candidates in pending and active state.'),(0,r.kt)("h4",{id:"result-18"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"code"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr candiate code")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"cid"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr candiate address")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"did"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr candiate did address")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nickname"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the nick name of the cr candiate")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"url"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the url of the cr candiate")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"location"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the location number of the cr candiate")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"state"),(0,r.kt)("td",{parentName:"tr",align:null},"bool"),(0,r.kt)("td",{parentName:"tr",align:null},"if cr candiate has confirmed")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"votes"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the votes currently held")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"registerheight"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the register CR candidate height")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"cancelheight"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the unregister CR candidate height")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"index"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the index of the cr candiate")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"totalvotes"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the total votes of registered cr candiate")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"totalcounts"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the total counts of registered cr candiate")))),(0,r.kt)("h4",{id:"example-34"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "listcrcandidates",\n  "params": {\n    "start": 0,\n    "limit": 3\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "crcandidatesinfo": [\n      {\n        "code": "21036db5984e709d2e0ec62fd974283e9a18e7b87e8403cc784baf1f61f775926535ac",\n        "cid": "iUzjmMPTYZq2afqtR46coY6B7h2qD1PQbyq",\n        "did": "iTgmaqaMpMj46MW3GCU2h7bPaytwuvQrV3",\n        "nickname": "ela_test11",\n        "url": "ela_test.org11",\n        "location": 38025,\n        "state": "Canceled",\n        "votes": "0",\n        "registerheight": 111,\n        "cancelheight": 151,\n        "index": 0\n      }\n    ],\n    "totalvotes": "0",\n    "totalcounts": 1\n  }\n}\n')),(0,r.kt)("h3",{id:"getsecretarygeneral"},"getsecretarygeneral"),(0,r.kt)("p",null,"get secretary general public key"),(0,r.kt)("h4",{id:"example-35"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getsecretarygeneral"\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "secretarygeneral": "033279a88abf504192f36d0a8f06d66ab1fff80d2715cf3ecbd243b4db8ff2e77e"\n  }\n}\n')),(0,r.kt)("h3",{id:"listcurrentcrs"},"listcurrentcrs"),(0,r.kt)("p",null,"Show current cr members information"),(0,r.kt)("h4",{id:"parameter-26"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"state"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr member state you want know ",(0,r.kt)("br",null))))),(0,r.kt)("h4",{id:"result-19"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"code"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr member code")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"cid"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr member address")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"did"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr member did address")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"nickname"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the nick name of the cr member")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"url"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the url of the cr member")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"location"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the location number of the cr member")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"impeachmentvotes"),(0,r.kt)("td",{parentName:"tr",align:null},"int64"),(0,r.kt)("td",{parentName:"tr",align:null},"impeachment votes of the cr member")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"depositamount"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the deposite amout of the cr member")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"depositaddress"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the deposite address of the cr member")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"penalty"),(0,r.kt)("td",{parentName:"tr",align:null},"int64"),(0,r.kt)("td",{parentName:"tr",align:null},"the penalty of the cr member")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"index"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the index of the cr member")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"totalcounts"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the total counts of current cr member")))),(0,r.kt)("h4",{id:"example-36"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "listcurrentcrs",\n  "params": {\n    "state": "all"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "crmembersinfo": [\n      {\n        "code": "2102e23f70b9b967af35571c32b1442d787c180753bbed5cd6e7d5a5cfe75c
17fc1ffac",\n        "cid": "iaiZJM922uWo2Uc2gYwZk1nEgiVV7NTtxR",\n        "did": "inTc9GeWyNNKNwT1cDcvvEgQwnjszbtpZ5",\n        "nickname": "ela_cr2",\n        "url": "ela_cr2.org",\n        "location": 112211,\n        "impeachmentvotes": 0,\n        "depositamout": "5000",\n        "deposithash": "De87Qiekzpx7Xqf8RphdwNX5Z84iGgHLKMF5b",\n        "penalty": 0,\n        "index": 0,\n        "State": "Elected"\n      },\n      {\n        "code": "2103c3dd01baa4e3d0625f6c0026ad3d06d085e80c57477efa1a4aa2ab209c210e95ac",\n        "cid": "iUBoqE5KnBA1zsd4EWeyj2mXMfUrm5rDmf",\n        "did": "intySungjAK3uyHeoajez3yRqX5x68NrNi",\n        "nickname": "ela_cr1",\n        "url": "ela_cr1.org",\n        "location": 112211,\n        "impeachmentvotes": 0,\n        "depositamout": "5000",\n        "depositaddress": "DnemZpPgHLKMF5bMX3WbJYSGTpqJkBN7pe",\n        "penalty": 0,\n        "index": 1,\n        "State": "Elected"\n      }\n    ],\n    "totalcounts": 2\n  }\n}\n')),(0,r.kt)("h3",{id:"listcrproposalbasestate"},"listcrproposalbasestate"),(0,r.kt)("p",null,"Show current cr proposal base state information"),(0,r.kt)("h4",{id:"parameter-27"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:"left"},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:"left"},"start"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the start index of cr proposal state")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:"left"},"limit"),(0,r.kt)("td",{parentName:"tr",align:null},"integer"),(0,r.kt)("td",{parentName:"tr",align:null},"the limit count of cr proposal state")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:"left"},"state"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the proposal state you want",(0,r.kt)("br",null))))),(0,r.kt)("p",null,'"all": get proposals in any state',(0,r.kt)("br",null),'\n"registered": get proposals in the registered state',(0,r.kt)("br",null),'\n"cragreed": get proposals in the cragreed state',(0,r.kt)("br",null),'\n"voteragreed": get proposals in the voteragreed state',(0,r.kt)("br",null),'\n"finished": get proposals in the finished state',(0,r.kt)("br",null),'\n"crcanceled": get proposals in the crcanceled state',(0,r.kt)("br",null),'\n"votercanceled": get proposals in the votercanceled state |\n"aborted": get proposals in the aborted state .'),(0,r.kt)("h4",{id:"result-20"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"status"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the proposal status")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"proposalhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr proposal hash")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"txhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the transacion's hash which cr proposal located in")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"crvotes"),(0,r.kt)("td",{parentName:"tr",align:null},"map","[string]","VoteResult"),(0,r.kt)("td",{parentName:"tr",align:null},"per cr VoteResult")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"votersrejectamount"),(0,r.kt)("td",{parentName:"tr",align:null},"common.Fixed64"),(0,r.kt)("td",{parentName:"tr",align:null},"voters reject amount")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"registerheight"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"register height of proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"terminatedheight"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"terminated height of proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"trackingcounts"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"tracking counts of proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"proposalowner"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"owner of proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"Index"),(0,r.kt)("td",{parentName:"tr",align:null},"uint64"),(0,r.kt)("td",{parentName:"tr",align:null},"the index of the cr proposal")))),(0,r.kt)("h4",{id:"example-37"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "listcrproposalbasestate",\n  "params": {\n    "state": "all",\n    "start": 0,\n    "limit": 10\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "proposalbasestates": [\n      {\n        "status": "CRAgreed",\n        "proposalhash": "e6942385c899889d4afd4b093e44a29f7d374c25c21432347faf3f82af2e5a88",\n        "txhash": "a859222538901eb656ad293483bb361dc0ec2835ce804fb7dffc67241c0ee965",\n        "crvotes": {\
1n          "intySungjAK3uyHeoajez3yRqX5x68NrNi": "approve",\n          "iUBoqE5KnBA1zsd4EWeyj2mXMfUrm5rDmf": "approve",\n          "iTgmaqaMpMj46MW3GCU2h7bPaytwuvQrV3": "approve",\n          "inTc9GeWyNNKNwT1cDcvvEgQwnjszbtpZ5": "approve"\n        },\n        "votersrejectamount": "324.22213333",\n        "registerHeight": 1764,\n        "terminatedheight": 0,\n        "trackingcount": 0,\n        "proposalowner": "02de2bdd021fd17418d1696afb4709fb908401c81fa674f26e8ca0afa624a48727",\n        "index": 14\n      }\n    ],\n    "totalcounts": 1\n  }\n}\n')),(0,r.kt)("h3",{id:"getcrproposalstate"},"getcrproposalstate"),(0,r.kt)("p",null,"Get one cr proposal detail state information by proposalhash or drafthash"),(0,r.kt)("h4",{id:"parameter-28"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"proposalhash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"hash of the proposal which you want get detail state")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"drafthash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"drafthash of the proposal which you want get detail state")))),(0,r.kt)("h4",{id:"result-21"},"Result"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"Status"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the proposal status")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"Proposal"),(0,r.kt)("td",{parentName:"tr",align:null},"CRCProposal"),(0,r.kt)("td",{parentName:"tr",align:null},"the cr proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"TxHash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"hash of the transacion which cr proposal located in")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"CRVotes"),(0,r.kt)("td",{parentName:"tr",align:null},"map","[string]","VoteResult"),(0,r.kt)("td",{parentName:"tr",align:null},"per cr VoteResult")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"VotersRejectAmount"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"voters reject amount")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"RegisterHeight"),(0,r.kt)("td",{parentName:"tr",align:null},"uint32"),(0,r.kt)("td",{parentName:"tr",align:null},"the proposal register height")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"ProposalType"),(0,r.kt)("td",{parentName:"tr",align:null},"CRCProposalType"),(0,r.kt)("td",{parentName:"tr",align:null},"the type of cr proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"OwnerPublicKey"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the public key of proposal's owner")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"CRCouncilMemberDID"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the did of CR Council Member")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"DraftHash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the hash of draft proposal")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"Budgets"),(0,r.kt)("td",{parentName:"tr",align:null},"[]Budget"),(0,r.kt)("td",{parentName:"tr",align:null},"the budget of different stages")))),(0,r.kt)("p",null,'ProposalType value as follows:\n0x00:"Normal" Normal indicates the normal types of proposal.\n0x01:"Code" indicates the code upgrade t
1ypes of proposals.\n0x02:"SideChain" indicates the side chain related types of proposals.\n0x03:"ChangeOwner" indicates the change proposal owner types of proposals.\n0x04:"CloseProposal" indicates the close proposal types of proposals.\n0x05:"SecretaryGeneral"indicates the vote secretary general types of proposals.'),(0,r.kt)("h4",{id:"example-38"},"Example"),(0,r.kt)("p",null,"Request by proposalhash:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getcrproposalstate",\n  "params": {\n    "proposalhash": "42de0adf2b3673d712fc3efdaf643889ef8442fe25987b25add8c0c961b13612"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "proposalstate": {\n      "status": "Registered",\n      "proposal": {\n        "proposaltype": 0,\n        "ownerpublickey": "03c3dd01baa4e3d0625f6c0026ad3d06d085e80c57477efa1a4aa2ab209c210e95",\n        "crcouncilmemberdid": "iUBoqE5KnBA1zsd4EWeyj2mXMfUrm5rDmf",\n        "drafthash": "9c5ab8998718e0c1c405a719542879dc7553fca05b4e89132ec8d0e88551fcc0",\n        "budgets": [\n          {\n            "type": "Imprest",\n            "stage": 0,\n            "amount": "1.1",\n            "status": "Withdrawable"\n          },\n          {\n            "type": "NormalPayment",\n            "stage": 1,\n            "amount": "2.2",\n            "status": "Unfinished"\n          },\n          {\n            "type": "FinalPayment",\n            "stage": 2,\n            "amount": "3.3",\n            "status": "Unfinished"\n          }\n        ]\n      },\n      "txhash": "9f425a8012a3e36128ee61be78a0b6a7832f9d895d08c86cc16e6a084e7f054f",\n      "crvotes": {\n        "iTgmaqaMpMj46MW3GCU2h7bPaytwuvQrV3": 0\n      },\n      "votersrejectamount": 0,\n      "registerheight": 1277\n    }\n  }\n}\n')),(0,r.kt)("p",null,"Request by drafthash:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getcrproposalstate",\n  "params": {\n    "drafthash": "9c5ab8998718e0c1c405a719542879dc7553fca05b4e89132ec8d0e88551fcc0"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": {\n    "proposalstate": {\n      "status": "Registered",\n      "proposal": {\n        "proposaltype": 0,\n        "ownerpublickey": "03c3dd01baa4e3d0625f6c0026ad3d06d085e80c57477efa1a4aa2ab209c210e95",\n        "crcouncilmemberdid": "iUBoqE5KnBA1zsd4EWeyj2mXMfUrm5rDmf",\n        "drafthash": "9c5ab8998718e0c1c405a719542879dc7553fca05b4e89132ec8d0e88551fcc0",\n        "budgets": [\n          {\n            "type": "Imprest",\n            "stage": 0,\n            "amount": "1.1",\n            "status": "Withdrawable"\n          },\n          {\n            "type": "NormalPayment",\n            "stage": 1,\n            "amount": "2.2",\n            "status": "Unfinished"\n          },\n          {\n            "type": "FinalPayment",\n            "stage": 2,\n            "amount": "3.3",\n            "status": "Unfinished"\n          }\n        ]\n      },\n      "txhash": "9f425a8012a3e36128ee61be78a0b6a7832f9d895d08c86cc16e6a084e7f054f",\n      "crvotes": {\n        "iTgmaqaMpMj46MW3GCU2h7bPaytwuvQrV3": 0\n      },\n      "votersrejectamount": 0,\n      "registerheight": 1277,\n      "votestartheight": 0\n    }\n  }\n}\n')),(0,r.kt)("h3",{id:"getproposaldraftdata"},"getproposaldraftdata"),(0,r.kt)("p",null,"Get draft data of proposal or proposalReview or proposalTracking transaction detail information by draft hash."),(0,r.kt)("h4",{id:"parameter-29"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"drafthash"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"draft hash of proposal or proposalReview or proposalTracking transaction")))),(0,r.kt)("h4",{id:"result-22"},"Result"),(0,r.kt)("p",null,"Result is the hex string of draft data."),(0,r.kt)("h4",{id:"example-39"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "method": "getproposaldraftdata",\n  "params": {\n    "drafthash": "9c5ab8998718e0c1c405a719542879dc7553fca05b4e89132ec8d0e88551fcc0"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-json"},'{\n  "error": null,\n  "id": null,\n  "jsonrpc": "2.0",\n  "result": "6d6d9581ba0156314f1e92fd03430c6e4428a32bb3f1b9dc6271024"\n}\n')),(0,r.kt)("h3",{id:"createrawtransaction"},"createrawtransaction"),(0,r.kt)("p",null,"Create a transaction spending the given inputs and creating new outputs.\nWarning: you should calculate the change output and append it to transaction outputs, otherwise the change should\nbe given to the miners."),
1(0,r.kt)("h4",{id:"parameter-30"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"inputs"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"inputs json array of json objects")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"outputs"),(0,r.kt)("td",{parentName:"tr",align:null},"array","[string]"),(0,r.kt)("td",{parentName:"tr",align:null},"outputs json array of json objects")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"locktime"),(0,r.kt)("td",{parentName:"tr",align:null},"interger"),(0,r.kt)("td",{parentName:"tr",align:null},"the transaction lock time number")))),(0,r.kt)("h4",{id:"example-40"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},' {\n  "method": "createrawtransaction",\n  "params":{\n    "inputs":"[{\\"txid\\":\\"a704c4c04c70043a2cce34fa95e20f3d33b0a3dc95dd948dee573673b701c7e7\\",\\"vout\\":1}]",\n    "outputs": "[{\\"address\\":\\"EKn3UGyEoycACJxKu7F8R5U1Pe6NUpni1H\\",\\"amount\\":1},{\\"address\\":\\"EUmvbPnoC59DJWnEx5VkcJNhK6GnjkoHao\\",\\"amount\\":98.9}]",\n    "locktime": 0\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},'{\n    "error": null,\n    "id": null,\n    "jsonrpc": "2.0",\n    "result": "0902000001285f24620c18ddc75b7d1f3090efa619bd5b901a5355c30621dad1c2c6dcfbc000000000000002b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a300e1f5050000000000000000211cc5e2ab8654b4fe70949aceaacb017410df55c300b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a3806c7d4d0200000000000000217f7946d05f62a92ed345ed9f1391869517bff44d000000000000"\n}\n')),(0,r.kt)("h3",{id:"signrawtransactionwithkey"},"signrawtransactionwithkey"),(0,r.kt)("p",null,"Sign the raw transaction with private key."),(0,r.kt)("h4",{id:"parameter-31"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"data"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the transaction hex string")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"codes"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the codes json array of json objects")),(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"privkeys"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the private key json array of json objects")))),(0,r.kt)("h4",{id:"example-41"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},' {\n  "method": "signrawtransactionwithkey",\n  "params":{\n    "data": "0902000001e7c701b7733657ee8d94dd95dca3b0333d0fe295fa34ce2c3a04704cc0c404a701000000000002b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a300e1f505000000000000000021121c2c946cb3d88b5272038621290e120193c7e600b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a380a2e2110200000000000000126aa11de1372f5763cd93e9eef71008be74a94693000000000000",\n    "codes": "[\\"5321033b4606d3cec58a01a09da325f5849754909fec030e4cf626e6b4104328599fc7210251a471359b13d22cfdb2d8c8ec687a61f9e01c26e6475d58acf77c153c75d62121036e9eebad12dfbd6ea41a770baa735ec8db0a0be39e35db5ff8f5c87a47543e852103e630e917b0cfd076478780dcbfed89bc6db71f2865c2c124c6f95a4e3b9b307b54ae\\"]",\n    "privkeys": "[\\"ea3ddc681a780866577334de8a2f3e25cbb590c21671d705ce1fef46d84ffd81\\"]"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"}
1,'{\n    "error": null,\n    "id": null,\n    "jsonrpc": "2.0",\n    "result": "0902000001e7c701b7733657ee8d94dd95dca3b0333d0fe295fa34ce2c3a04704cc0c404a701000000000002b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a300e1f505000000000000000021121c2c946cb3d88b5272038621290e120193c7e600b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a380a2e2110200000000000000126aa11de1372f5763cd93e9eef71008be74a946930000000000014140e0bdb6879df338b0aa0039e900237471315342a06e4f40de2777903179c4fd77a48557058e6428bb403318ac2f101501761ce7ae2bb68bc0b5ccf47f5049aef38b5321033b4606d3cec58a01a09da325f5849754909fec030e4cf626e6b4104328599fc7210251a471359b13d22cfdb2d8c8ec687a61f9e01c26e6475d58acf77c153c75d62121036e9eebad12dfbd6ea41a770baa735ec8db0a0be39e35db5ff8f5c87a47543e852103e630e917b0cfd076478780dcbfed89bc6db71f2865c2c124c6f95a4e3b9b307b54ae"\n}\n')),(0,r.kt)("h3",{id:"decoderawtransaction"},"decoderawtransaction"),(0,r.kt)("p",null,"Return a JSON object representing the serialized, hex-encoded transaction."),(0,r.kt)("h4",{id:"parameter-32"},"Parameter"),(0,r.kt)("table",null,(0,r.kt)("thead",{parentName:"table"},(0,r.kt)("tr",{parentName:"thead"},(0,r.kt)("th",{parentName:"tr",align:null},"name"),(0,r.kt)("th",{parentName:"tr",align:null},"type"),(0,r.kt)("th",{parentName:"tr",align:null},"description"))),(0,r.kt)("tbody",{parentName:"table"},(0,r.kt)("tr",{parentName:"tbody"},(0,r.kt)("td",{parentName:"tr",align:null},"data"),(0,r.kt)("td",{parentName:"tr",align:null},"string"),(0,r.kt)("td",{parentName:"tr",align:null},"the transaction hex string")))),(0,r.kt)("h4",{id:"example-42"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},' {\n  "method": "decoderawtransaction",\n  "params":{\n    "data":"0200018151747970653a746578742c6d73673a46726f6d20454c4142616e6b2c456e74657220456c6173746f73202d43616c6c6973746f205375706572204e6f64652052657761726420446973747269627574696f6e015241653c7bcee5347ce08918fb52232312cdf14611bd5ab3ed8434a44d379a3701000000000002b037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a386a20500000000000000000021da7a8bc95561e969706abbaf87b12089cd9667dab037db964a231458d2d6ffd5ea18944c4f90e63d547c5d3b9874df66a4ead0a3b0fdfa5302000000000000002157cbdce387181d010890a972f93acf0ff54346b100000000014140a1d30614cc236006f31d67b9dc74af8298692c0fd09d1236d3c50fd50a64df82864359e441efde018d47f69bbcf92e46720baa160621c2160d7830a2bebfc144232103bd33d4fb0697bba896790a132439f402941b6b184cdd06dddf9ce8658f0c0443ac"\n  }\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},'{\n    "error": null,\n    "id": null,\n    "jsonrpc": "2.0",\n    "result": {\n        "txid": "4089d8362dfae2680bedb0e6ebab78afe64843b16c2b7e5734b70ff1a2659eef",\n        "hash": "4089d8362dfae2680bedb0e6ebab78afe64843b16c2b7e5734b70ff1a2659eef",\n        "size": 363,\n        "vsize": 363,\n        "version": 0,\n        "type": 2,\n        "payloadversion": 0,\n        "payload": null,\n        "attributes": [\n            {\n                "usage": 129,\n                "data": "747970653a746578742c6d73673a46726f6d20454c4142616e6b2c456e74657220456c6173746f73202d43616c6c6973746f205375706572204e6f64652052657761726420446973747269627574696f6e"\n            }\n        ],\n        "vin": [\n            {\n                "txid": "379a374da43484edb35abd1146f1cd12232352fb1889e07c34e5ce7b3c654152",\n                "vout": 1,\n                "sequence": 0\n            }\n        ],\n        "vout": [\n            {\n                "value": "0.00369286",\n                "n": 0,\n                "address": "Ed57c3wF3J1u8vEYE9cjGUpqGPkEJC69v8",\n                "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n                "outputlock": 0,\n                "type": 0,\n                "payload": null\n            },\n            {\n                "value": "99.98892464",\n                "n": 1,\n                "address": "ERA8VusTKV78LTiEseuQC4wBPRu3BQo6rE",\n                "assetid": "a3d0eaa466df74983b5d7c543de6904f4c9418ead5ffd6d25814234a96db37b0",\n                "outputlock": 0,\n                "type": 0,\n                "payload": null\n            }\n        ],\n        "locktime": 0,\n        "programs": [\n            {\n                "code": "2103bd33d4fb0697bba896790a132439f402941b6b184cdd06dddf9ce8658f0c0443ac",\n                "parameter": "40a1d30614cc236006f31d67b9dc74af8298692c0fd09d1236d3c50fd50a64df82864359e441efde018d47f69bbcf92e46720baa160621c2160d7830a2bebfc144"\n            }\n        ]\n    }\n}\n')),(0,r.kt)("h3",{id:"getcrrelatedstage"}
1,"getcrrelatedstage"),(0,r.kt)("p",null,"Get CR related stage information."),(0,r.kt)("h4",{id:"example-43"},"Example"),(0,r.kt)("p",null,"Request:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},'{\n  "method": "getcrrelatedstage"\n}\n')),(0,r.kt)("p",null,"Response:"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre"},'{\n    "error": null,\n    "id": null,\n    "jsonrpc": "2.0",\n    "result": {\n        "onduty":true,\n        "ondutystartheight":1000,\n        "ondutyendheight":2000,\n        "invoting":false,\n        "votingstartheight":0,\n        "votingendheight":0\n    }\n}\n')))}k.isMDXComponent=!0}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.