Skip to content

Diskcoin API

The DISC API allows interaction with DISC nodes using HTTP requests to default mainnet port 63336. We only support POST mode.

Each API call is documented below, with definitions given for HTTP request parameters and JSON response fields.

The JSON response fields are each followed by one of S for string, A for array, O for object, N for number or B for boolean.

Set Content-Type=application/json in headers, add the ciphertext generated by Username:Password through Base64 encoding to the request header with Basic Auth.

Username, Password is the account password set by rpc.

Blockchain

getbestblockhash

Get the current latest block hash. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getbestblockhash",
    "params": []
}
- Response:
{
    "result": "6c8bc8835df00bc0e961960f984904d5b5a537e3f388860aef2da4567c486ce2",
    "error": null,
    "id": "1"
}

getblock "hash" (verbose) (listtransactions)

Get the block imformation based on block hash or height. - Parameter - hash: the block hash value or height - verbose: Optional parameter, default is true, it indicates json object, 'false' is hexadecimal encoded data - listtransactions: Optional parameter, default is true, will list all txid, 'false' will only count the amount. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getblock",
    "params": ["6e46a54a4ddcb2640796787570f97210daf1f896a38693ecd6c67d49bfb61619", true, true]
}
- Response:
{
    "result": {
        "hash": "6e46a54a4ddcb2640796787570f97210daf1f896a38693ecd6c67d49bfb61619",
        "confirmations": 408,
        "size": 291,
        "height": 975,
        "version": 536870912,
        "versionHex": "20000000",
        "merkleroot": "0325ca3c4a8fd25d4224b38bbdfb6ca0c15fd63feeac0a051acbaef6e69f5308",
        "tx": [
            "0325ca3c4a8fd25d4224b38bbdfb6ca0c15fd63feeac0a051acbaef6e69f5308"
        ],
        "time": 1563185010,
        "mediantime": 1563184690,
        "nonce": 2190714007139005,
        "bits": "1d0fffff",
        "difficulty": 0.06249910592947572,
        "chainwork": "00000000000000000000000000000000000000000000000000000000000163fe",
        "basetarget": 39608397,
        "ploterid": 10924919180736888,
        "deadline": 92,
        "generatesignature": "385a13e649ae45161ae8f7c1f6ebd42eb16a74cb42957c35e0c9bde20983e771",
        "previousblockhash": "c1b84132c7dee0abe58dbacc44067f81bc12a85b4d24b6834df00f4417d6ccba",
        "nextblockhash": "874094a541eef686f640de285fd823981f8171f3bfd8636bfdaad8d018ae6870"
    },
    "error": null,
    "id": "1"
}

getblockchaininfo

Get status information of the current blockchain. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getblockchaininfo",
    "params": []
}
- Response:
{
    "result": {
        "chain": "test",
        "blocks": 975,
        "headers": 975,
        "bestblockhash": "6e46a54a4ddcb2640796787570f97210daf1f896a38693ecd6c67d49bfb61619",
        "difficulty": 0.06249910592947572,
        "mediantime": 1563184690,
        "verificationprogress": 1,
        "initialblockdownload": false,
        "chainwork": "00000000000000000000000000000000000000000000000000000000000163fe",
        "pruned": false,
        "netbasetarget": 0,
        "netcooperation": 0
    },
    "error": null,
    "id": "1"
}

getblockcount

Get the height of current block. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getblockcount",
    "params": []
}
- Response:
{
    "result": 1359,
    "error": null,
    "id": "1"
}

getblockhash index

Get the block hash based on the height. - Request parameter - index: Required, block height - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getblockhash",
    "params": [975]
}
- Response:
{
    "result": "6e46a54a4ddcb2640796787570f97210daf1f896a38693ecd6c67d49bfb61619",
    "error": null,
    "id": "1"
}

getblockheader "hash" (verbose)

Get block information based on the hash. - Parameter - hash:The block hash - verbose:Optional parameter, default is true, it indicates json object,'false' is Hexadecimal encoded data - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getblockheader",
    "params": ["6e46a54a4ddcb2640796787570f97210daf1f896a38693ecd6c67d49bfb61619"]
}
- Response:
{
    "result": {
        "hash": "6e46a54a4ddcb2640796787570f97210daf1f896a38693ecd6c67d49bfb61619",
        "confirmations": 394,
        "height": 975,
        "version": 536870912,
        "versionHex": "20000000",
        "merkleroot": "0325ca3c4a8fd25d4224b38bbdfb6ca0c15fd63feeac0a051acbaef6e69f5308",
        "time": 1563185010,
        "mediantime": 1563184690,
        "nonce": 2190714007139005,
        "bits": "1d0fffff",
        "difficulty": 0.06249910592947572,
        "chainwork": "00000000000000000000000000000000000000000000000000000000000163fe",
        "previousblockhash": "c1b84132c7dee0abe58dbacc44067f81bc12a85b4d24b6834df00f4417d6ccba",
        "nextblockhash": "874094a541eef686f640de285fd823981f8171f3bfd8636bfdaad8d018ae6870"
    },
    "error": null,
    "id": "1"
}

getchaintips

Return the header information of the current blockchain. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getchaintips",
    "params": []
}
- Response:
{
    "result": [
        {
            "height": 2125,
            "chainwork": "00000000000000000000000000000000000000000000000000000000000ecaab",
            "hash": "545df67716580a55342cd62af44c287b48d0cac0b07c87f22048c709b8b5b9ee",
            "branchlen": 0,
            "status": "active"
        },
        {
            "height": 1851,
            "chainwork": "00000000000000000000000000000000000000000000000000000000000ab89f",
            "hash": "6fc247f32d6c381cb81f26301955775e475e945b060631868693cf8e019ebe59",
            "branchlen": 1,
            "status": "valid-fork"
        },
        {
            "height": 1610,
            "chainwork": "000000000000000000000000000000000000000000000000000000000007d88f",
            "hash": "89e0b2597fbc790e1565a4f91408a5907865465ecc21273e8aae26ad16cabec1",
            "branchlen": 1,
            "status": "valid-fork"
        }
    ],
    "error": null,
    "id": "1"
}

getmempoolancestors txid (verbose)

If txid is in mempool, then all in-mempool ancestors are returned.

  • Request parameter
  • txid (string, required) The transaction id (must be in mempool)
  • verbose (boolean, optional, default=false) True for a json object, false for array of transaction ids
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "getmempoolancestors",
        "params": ["7b100c6083f8e6250f9dbc3585653b903cbae81dd7d0012b0be30bc8b3912570"]
    }
    
  • Response:
    {
        "result": [],
        "error": null,
        "id": "1"
    }
    

getmempooldescendants txid (verbose)

If txid is in mempool, then all in-mempool descendants are returned.

  • Request parameter:
  • txid (string, required) The transaction id (must be in mempool)
  • verbose (boolean, optional, default=false) True for a json object, false for array of transaction ids
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "getmempooldescendants",
        "params": ["7b100c6083f8e6250f9dbc3585653b903cbae81dd7d0012b0be30bc8b3912570"]
    }
    
  • Response:
    {
        "result": [],
        "error": null,
        "id": "1"
    }
    

getmempoolentry txid

Return the transaction details in the memory pool. - Request parameter - txid (string, required) The transaction id (must be in mempool) - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getmempoolentry",
    "params": ["7b100c6083f8e6250f9dbc3585653b903cbae81dd7d0012b0be30bc8b3912570"]
}
- Response:
{
    "result": {
        "size": 1431,
        "fee": 0.0002864,
        "modifiedfee": 0.0002864,
        "time": 1563346805,
        "height": 2125,
        "startingpriority": 11508630237.67279,
        "currentpriority": 11508630237.67279,
        "descendantcount": 1,
        "descendantsize": 1431,
        "descendantfees": 28640,
        "ancestorcount": 1,
        "ancestorsize": 1431,
        "ancestorfees": 28640,
        "depends": [],
        "spentby": []
    },
    "error": null,
    "id": "1"
}

getmempoolinfo

Get the details of TX memory pool with the status active. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getmempoolinfo",
    "params": []
}
- Response:
{
    "result": {
        "size": 2,
        "bytes": 1622,
        "usage": 4352,
        "maxmempool": 300000000,
        "mempoolminfee": 0,
        "tps": 0.02
    },
    "error": null,
    "id": "1"
}

getorphanpoolinfo

Get the details of TX orphan pool with status active. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getorphanpoolinfo",
    "params": []
}
- Response:
{
    "result": {
        "size": 0,
        "bytes": 0
    },
    "error": null,
    "id": "1"
}

getrawmempool (verbose)

Return all transaction IDs in memory pool. - Request parameter - verbose:Optional parameter, default is false, returns an array of transaction IDs, otherwise in json format. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getrawmempool",
    "params": [true]
}
- Response:
{
    "result": {
        "53fac9b470e646c472948721552214b27bc75e9a0e19265acb5b53d8c7d51c0f": {
            "size": 191,
            "fee": 0.0000382,
            "modifiedfee": 0.0000382,
            "time": 1563346822,
            "height": 2125,
            "startingpriority": 1739081549.897436,
            "currentpriority": 1739081549.897436,
            "descendantcount": 1,
            "descendantsize": 191,
            "descendantfees": 3820,
            "ancestorcount": 1,
            "ancestorsize": 191,
            "ancestorfees": 3820,
            "depends": [],
            "spentby": []
        },
        "7b100c6083f8e6250f9dbc3585653b903cbae81dd7d0012b0be30bc8b3912570": {
            "size": 1431,
            "fee": 0.0002864,
            "modifiedfee": 0.0002864,
            "time": 1563346805,
            "height": 2125,
            "startingpriority": 11508630237.67279,
            "currentpriority": 11508630237.67279,
            "descendantcount": 1,
            "descendantsize": 1431,
            "descendantfees": 28640,
            "ancestorcount": 1,
            "ancestorsize": 1431,
            "ancestorfees": 28640,
            "depends": [],
            "spentby": []
        }
    },
    "error": null,
    "id": "1"
}

getraworphanpool

Return all transaction IDs in orphan pool. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getraworphanpool",
    "params": []
}
- Response:
{
    "result": [],
    "error": null,
    "id": "1"
}

gettxout "txid" n (includemempool)

Return the output of the transaction - Request parameter - txid (string, required) The transaction id - n (numeric, required) vout number - include_mempool (boolean, optional) Whether to include the mempool - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "gettxout",
    "params": ["0325ca3c4a8fd25d4224b38bbdfb6ca0c15fd63feeac0a051acbaef6e69f5308", 1]
}
- Response:
{
    "result": {
        "bestblock": "0dd6ce2f9aeae64e0f30b723664724a09706fb31c58d254485e2b7f34a9a7454",
        "confirmations": 409,
        "value": 8,
        "scriptPubKey": {
            "asm": "0347542a5f9a5f70f0c0b3e19139079ed24111ffd5d690e8e44a140bc9e493684d OP_CHECKSIG",
            "hex": "210347542a5f9a5f70f0c0b3e19139079ed24111ffd5d690e8e44a140bc9e493684dac",
            "reqSigs": 1,
            "type": "pubkey",
            "addresses": [
                "1JZYyGKe8THWpXE93vMGwjuvRcYgQd2ZAH"
            ]
        },
        "coinbase": true
    },
    "error": null,
    "id": "1"
}

gettxoutproof ["txid",...] (blockhash)

Return hexadecimal data based on transaction ID. - Request parameter - txids (string) A json array of txids to filter - blockhash (string, optional) If specified, looks for txid in the block with this hash - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "gettxoutproof",
    "params": [["0325ca3c4a8fd25d4224b38bbdfb6ca0c15fd63feeac0a051acbaef6e69f5308"], "6e46a54a4ddcb2640796787570f97210daf1f896a38693ecd6c67d49bfb61619"]
}
- Response:
{
    "result": "00000020baccd617440ff04d83b6244d5ba812bc817f0644ccba8de5abe0dec73241b8c108539fe6f6aecb1a050aacee3fd65fc1a06cfbbd8bb324425dd28f4a3cca2503724f2c5dffff0f1dbd32335a71c807004d605c020000000078b9f7f627d026005c00000000000000385a13e649ae45161ae8f7c1f6ebd42eb16a74cb42957c35e0c9bde20983e771010000000108539fe6f6aecb1a050aacee3fd65fc1a06cfbbd8bb324425dd28f4a3cca25030101",
    "error": null,
    "id": "1"
}

gettxoutproofs ["txid",...] (blockhash)

The hexadecimal data is returned according to the transaction ID, and the transaction ID and the evidence correspond one-to-one. - Request parameter - txids (string) A json array of txids to filter - blockhash (string, optional) If specified, looks for txid in the block with this hash - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "gettxoutproofs",
    "params": [["0325ca3c4a8fd25d4224b38bbdfb6ca0c15fd63feeac0a051acbaef6e69f5308"], "6e46a54a4ddcb2640796787570f97210daf1f896a38693ecd6c67d49bfb61619"]
}
- Response:
{
    "result": {
        "0325ca3c4a8fd25d4224b38bbdfb6ca0c15fd63feeac0a051acbaef6e69f5308": "00000020baccd617440ff04d83b6244d5ba812bc817f0644ccba8de5abe0dec73241b8c108539fe6f6aecb1a050aacee3fd65fc1a06cfbbd8bb324425dd28f4a3cca2503724f2c5dffff0f1dbd32335a71c807004d605c020000000078b9f7f627d026005c00000000000000385a13e649ae45161ae8f7c1f6ebd42eb16a74cb42957c35e0c9bde20983e771010000000108539fe6f6aecb1a050aacee3fd65fc1a06cfbbd8bb324425dd28f4a3cca25030101"
    },
    "error": null,
    "id": "1"
}

gettxoutsetinfo

Return all current unspent output statistics. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "gettxoutsetinfo",
    "params": []
}
- Response:
{
    "result": {
        "height": 1386,
        "bestblock": "787462676f41dbd1aced66d6292904a9b662b42df6a16c7faeff1de2e2d4b764",
        "transactions": 1404,
        "txouts": 2770,
        "hash_serialized_2": "bf48323c671476821ec28408f0a5a1778aa38fd296feb7de4d1451290200c42e",
        "disk_size": 0,
        "total_amount": 27720
    },
    "error": null,
    "id": "1"
}

verifychain (checklevel numblocks)

Verify blockchain database. - Request parameter - checklevel:Optional parameter, Range 0-4, default is 3 - numblocks:Optional parameter, the number of blocks that need to be checked defaults to 6. If set to 0, it means all. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "verifychain",
    "params": []
}
- Response: Return value is true|false
{
    "result": true,
    "error": null,
    "id": "1"
}

verifytxoutproof "proof"

Verify transactions data in the block. - Request parameter - proof: hexadecimal data (gettxoutproof generated)proof: - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "verifytxoutproof",
    "params": ["00000020baccd617440ff04d83b6244d5ba812bc817f0644ccba8de5abe0dec73241b8c108539fe6f6aecb1a050aacee3fd65fc1a06cfbbd8bb324425dd28f4a3cca2503724f2c5dffff0f1dbd32335a71c807004d605c020000000078b9f7f627d026005c00000000000000385a13e649ae45161ae8f7c1f6ebd42eb16a74cb42957c35e0c9bde20983e771010000000108539fe6f6aecb1a050aacee3fd65fc1a06cfbbd8bb324425dd28f4a3cca25030101"]
}
- Response: Return value is the corresponding txid, or it is empty.
{
    "result": [
        "0325ca3c4a8fd25d4224b38bbdfb6ca0c15fd63feeac0a051acbaef6e69f5308"
    ],
    "error": null,
    "id": "1"
}

Control

getinfo

Get wallet information. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getinfo",
    "params": []
}
- Response:
{
    "result": {
        "version": 1060000,
        "protocolversion": 80003,
        "walletversion": 60000,
        "balance": 0.5,
        "blocks": 2133,
        "timeoffset": 0,
        "connections": 5,
        "proxy": "",
        "difficulty": 0.06249910592947572,
        "testnet": false,
        "keypoololdest": 1563271172,
        "keypoolsize": 10001,
        "unlocked_until": 0,
        "paytxfee": 0,
        "relayfee": 0.00001,
        "status": "ready",
        "errors": "",
        "fork": "Diskcoin Cash"
    },
    "error": null,
    "id": "1"
}

help ("command")

View help information for a command. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "help",
    "params": ["createrawtransaction"]
}
- Response:
{
    "result": "createrawtransaction [{\"txid\":\"id\",\"vout\":n},...] {\"address\":amount,\"data\":\"hex\",...} ( locktime )\n\nCreate a transaction spending the given inputs and creating new outputs.\nOutputs can be addresses or data.\nReturns hex-encoded raw transaction.\nNote that the transaction's inputs are not signed, and\nit is not stored in the wallet or transmitted to the network.\n\nArguments:\n1. \"transactions\"        (string, required) A json array of json objects\n     [\n       {\n         \"txid\":\"id\",    (string, required) The transaction id\n         \"vout\":n        (numeric, required) The output number\n         \"vout\":n,         (numeric, required) The output number\n         \"sequence\":n    (numeric, optional) The sequence number\n       }\n       ,...\n     ]\n2. \"outputs\"             (string, required) a json object with outputs\n    {\n      \"address\": x.xxx   (numeric or string, required) The key is the Diskcoin address, the numeric value (can be string) is the DISC amount\n      \"data\": \"hex\",     (string, required) The key is \"data\", the value is hex encoded data\n      ...\n    }\n3. locktime                (numeric, optional, default=0) Raw locktime. Non-0 value also locktime-activates inputs\n\nResult:\n\"transaction\"            (string) hex string of the transaction\n\nExamples\n> Diskcoin-cli createrawtransaction \"[{\\\"txid\\\":\\\"myid\\\",\\\"vout\\\":0}]\" \"{\\\"address\\\":0.01}\"\n> Diskcoin-cli createrawtransaction \"[{\\\"txid\\\":\\\"myid\\\",\\\"vout\\\":0}]\" \"{\\\"data\\\":\\\"00010203\\\"}\"\n> curl --user myusername --data-binary '{\"jsonrpc\": \"1.0\", \"id\":\"curltest\", \"method\": \"createrawtransaction\", \"params\": [\"[{\\\"txid\\\":\\\"myid\\\",\\\"vout\\\":0}]\", \"{\\\"address\\\":0.01}\"] }' -H 'content-type: text/plain;' http://127.0.0.1:8332/\n> curl --user myusername --data-binary '{\"jsonrpc\": \"1.0\", \"id\":\"curltest\", \"method\": \"createrawtransaction\", \"params\": [\"[{\\\"txid\\\":\\\"myid\\\",\\\"vout\\\":0}]\", \"{\\\"data\\\":\\\"00010203\\\"}\"] }' -H 'content-type: text/plain;' http://127.0.0.1:8332/\n",
    "error": null,
    "id": "1"
}

stop

Stop the diskcoin service. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "stop",
    "params": []
}
- Response:
{
    "result": "Diskcoin server stopping",
    "error": null,
    "id": "1"
}

Electrum

getelectruminfo

Get the status of the electrum server. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getelectruminfo",
    "params": []
}
- Response:
{
    "result": null,
    "error": {
        "code": -1,
        "message": "Electrum server is disabled"
    },
    "id": "1"
}

Generating

getgenerate

Check whether the server is set to mining mode. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getgenerate",
    "params": []
}
- Response:
{
    "result": true,
    "error": null,
    "id": "1"
}

setgenerate generate (genproclimit)

  • Request parameter
  • generate:Required, true means open, false means closed
  • genproclimit:Optional parameter, set the limit of the processor, -1 means unlimited
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "setgenerate",
        "params": [true, 10]
    }
    
  • Response:
    {
        "result": null,
        "error": null,
        "id": "1"
    }
    

Mining

addblackplotterid plotterId

Add a plotter id to the blacklist - Request parameter - plotterId:Required, Plotter ID - Request:


- Response:

getMiningInfo

Get current mining information. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getMiningInfo",
    "params": []
}
- Response:
{
    "result": {
        "height": 1524,
        "baseTarget": "43806524",
        "generationSignature": "5205f3dc6741413c3a555380a581479886cf94afe4d81a1ff1a3842fc6e1af36",
        "targetDeadline": 4294967295
    },
    "error": null,
    "id": "1"
}

getblocktemplate ("jsonrequestobject")

  • Request parameter
  • jsonrequestobject:Optional parameter
  • Request:
    
    
  • Response:
    
    

getblockversion

Get the block version when mining. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getblockversion",
    "params": []
}
- Response: The return value is the version number.
{
    "result": 536870912,
    "error": null,
    "id": "1"
}

getminercomment

  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "getminercomment",
        "params": []
    }
    
  • Response:
    {
        "result": "",
        "error": null,
        "id": "1"
    }
    

getmininginfo

Get mining information. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getmininginfo",
    "params": []
}
- Response:
{
    "result": {
        "blocks": 1528,
        "currentblocksize": 1145,
        "currentblocktx": 0,
        "difficulty": 0.06249910592947572,
        "errors": "",
        "genproclimit": 10,
        "networkhashps": 4.29681593952207,
        "pooledtx": 0,
        "testnet": false,
        "chain": "test",
        "generate": true
    },
    "error": null,
    "id": "1"
}

getminingmaxblock

Get the maximum number of bytes in the mining block. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getminingmaxblock",
    "params": []
}
- Response:
{
    "result": 8000000,
    "error": null,
    "id": "1"
}

getnetworkhashps (blocks height)

Estimating network hashes per second based on the last n blocks. - Request parameter - blocks:Optional parameter, the default is 120, which means the number of blocks, and -1 means the block taken since the last difficulty change. - height:Optional parameter, default is -1, which means calculation at the specified time point - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getnetworkhashps",
    "params": []
}
- Response:
{
    "result": 4.262611464968153,
    "error": null,
    "id": "1"
}

prioritisetransaction

Increase or decrease the priority of the transaction - Request parameter - txid:Required, transaction ID - priority delta:Required, need to increase or decrease the priority - fee value:Required - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "prioritisetransaction",
    "params": ["0325ca3c4a8fd25d4224b38bbdfb6ca0c15fd63feeac0a051acbaef6e69f5308", 0.0, 10000]
}
- Response:
{
    "result": true,
    "error": null,
    "id": "1"
}

setblockversion blockVersionNumber

Set the version number of the block. - Request parameter - blockVersionNumber:Required,version number (integer, hex integer, 'BIP109', 'BASE' or 'default') - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "setblockversion",
    "params": ["BASE"]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

setminercomment

Corresponds to getminercomment. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "setminercomment",
    "params": ["Diskcoin is fundamentally emergent consensus"]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

setminingmaxblock blocksize

Set the maximum number of bytes in the mining block. - Request parameter - blocksize:Required, the maximum number of bytes in the block - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "setminingmaxblock",
    "params": [8000000]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

submitNonce nonce plotterId (height)

  • Request parameter
  • nonce:Required
  • plotterId:Required, Plotter ID
  • height:Optional, target height, default is the current mining height
  • Request:
    
    
  • Response:
    
    

submitblock "hexdata" ("jsonparametersobject")

Attempts to submit new block to network. The 'jsonparametersobject' parameter is currently ignored. - Request parameter - "hexdata" (string, required) the hex-encoded block data to submit - "parameters" (string, optional) object of optional parameters - Request:


- Response:

submitminingsolution "Mining-Candidate data" ("jsonparametersobject")

  • Request parameter
  • Mining-Candidate data:Required, need to submit the mining answer
  • jsonparametersobject:Optional
  • Request:
    
    
  • Response:
    
    

validateblocktemplate "hexdata"

  • Request parameter
  • hexdata:Required, Hexadecimal block data to be verified
  • Request:
    
    
  • Response:
    
    

Network

addnode "node" "add|remove|onetry"

Add or remove nodes to the addnode list. - Request parameter - node (string, required) The node (see getpeerinfo for nodes) - command (string, required) 'add' to add a node to the list, 'remove' to remove a node from the list, 'onetry' to try a connection to the node once - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "addnode",
    "params": ["121.28.160.158:63335", "add"]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

clearbanned

Clear all banned IPs. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "clearbanned",
    "params": []
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

listbanned

List all banned IP/subnets. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "listbanned",
    "params": []
}
- Response:
{
    "result": [
        {
            "address": "124.236.118.112/32",
            "banned_until": 1563394173,
            "ban_created": 1563307773,
            "ban_reason": "node misbehaving"
        },
        {
            "address": "205.185.120.91/32",
            "banned_until": 1563377778,
            "ban_created": 1563291378,
            "ban_reason": "node misbehaving"
        }
    ],
    "error": null,
    "id": "1"
}

clearblockstats

  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "clearblockstats",
        "params": []
    }
    
  • Response:
    {
        "result": null,
        "error": null,
        "id": "1"
    }
    

disconnectnode "node"

Disconnect a node. - Request parameter - node:Required, node information - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "disconnectnode",
    "params": ["121.28.160.158:63335"]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

expedited block|tx "node IP addr" on|off

  • Request parameter
  • block | tx:Required, blocks or transactions that need to be accelerated
  • node ip addr:Required, node information
  • on | off:Required, turn the acceleration service on or off
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "expedited",
        "params": ["block", "121.28.160.158:63335", "on"]
    }
    
  • Response:
    {
        "result": null,
        "error": null,
        "id": "1"
    }
    

getconnectioncount

Get the number of connections to other nodes. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getconnectioncount",
    "params": []
}
- Response:
{
    "result": 6,
    "error": null,
    "id": "1"
}

getexcessiveblock

Corresponds to setexcessiveblock. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getexcessiveblock",
    "params": []
}
- Response:
{
    "result": {
        "excessiveBlockSize": 32000000,
        "excessiveAcceptDepth": 12
    },
    "error": null,
    "id": "1"
}

getnettotals

Get network traffic information. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getnettotals",
    "params": []
}
- Response:
{
    "result": {
        "totalbytesrecv": 6421953,
        "totalbytessent": 138173,
        "timemillis": 1563266107979,
        "uploadtarget": {
            "timeframe": 86400,
            "target": 0,
            "target_reached": false,
            "serve_historical_blocks": true,
            "bytes_left_in_cycle": 0,
            "time_left_in_cycle": 0
        }
    },
    "error": null,
    "id": "1"
}

getnetworkinfo

Get network status information. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getnetworkinfo",
    "params": []
}
- Response:
{
    "result": {
        "version": 1060000,
        "subversion": "/BUCash:1.6.0(EB32; AD12)/",
        "protocolversion": 80003,
        "localservices": "0000000000000075",
        "timeoffset": 0,
        "connections": 6,
        "networks": [
            {
                "name": "ipv4",
                "limited": false,
                "reachable": true,
                "proxy": "",
                "proxy_randomize_credentials": false
            },
            {
                "name": "ipv6",
                "limited": false,
                "reachable": true,
                "proxy": "",
                "proxy_randomize_credentials": false
            },
            {
                "name": "onion",
                "limited": true,
                "reachable": false,
                "proxy": "",
                "proxy_randomize_credentials": false
            }
        ],
        "relayfee": 0.00001,
        "minlimitertxfee": "1.0000",
        "maxlimitertxfee": "1.0000",
        "localaddresses": [],
        "thinblockstats": {
            "enabled": true,
            "summary": "0 inbound and 0 outbound thin blocks have saved 0.00B of bandwidth",
            "mempool_limiter": "Thinblock mempool limiting has saved 0.00B of bandwidth",
            "inbound_percent": "Compression for 0 Inbound  thinblocks (last 24hrs): 0.0%",
            "outbound_percent": "Compression for 0 Outbound thinblocks (last 24hrs): 0.0%",
            "response_time": "Response time   (last 24hrs) AVG:0.00, 95th pcntl:0.00",
            "validation_time": "Validation time (last 24hrs) AVG:0.00, 95th pcntl:0.00",
            "outbound_bloom_filters": "Outbound bloom filter size (last 24hrs) AVG: 0.00B",
            "inbound_bloom_filters": "Inbound bloom filter size (last 24hrs) AVG: 0.00B",
            "thin_block_size": "Thinblock size (last 24hrs) AVG: 0.00B",
            "thin_full_tx": "Thinblock full transactions size (last 24hrs) AVG: 0.00B",
            "rerequested": "Tx re-request rate (last 24hrs): 0.0% Total re-requests:0"
        },
        "compactblockstats": {
            "enabled": true,
            "summary": "0 inbound and 0 outbound compactblocks have saved 0.00B of bandwidth",
            "mempool_limiter": "CompactBlock mempool limiting has saved 0.00B of bandwidth",
            "inbound_percent": "Compression for 0 Inbound  compactblocks (last 24hrs): 0.0%",
            "outbound_percent": "Compression for 0 Outbound compactblocks (last 24hrs): 0.0%",
            "response_time": "Response time   (last 24hrs) AVG:0.00, 95th pcntl:0.00",
            "validation_time": "Validation time (last 24hrs) AVG:0.00, 95th pcntl:0.00",
            "compact_block_size": "CompactBlock size (last 24hrs) AVG: 0.00B",
            "compact_full_tx": "compactblock full transactions size (last 24hrs) AVG: 0.00B",
            "rerequested": "Tx re-request rate (last 24hrs): 0.0% Total re-requests:0"
        },
        "grapheneblockstats": {
            "enabled": true,
            "summary": "0 inbound and 0 outbound graphene blocks have saved 0.00B of bandwidth with 0 local decode failures",
            "inbound_percent": "Compression for 0 Inbound graphene blocks (last 24hrs): 0.0%",
            "outbound_percent": "Compression for 0 Outbound graphene blocks (last 24hrs): 0.0%",
            "response_time": "Response time   (last 24hrs) AVG:0.11, 95th pcntl:0.19",
            "validation_time": "Validation time (last 24hrs) AVG:0.00, 95th pcntl:0.00",
            "filter": "Bloom filter size (last 24hrs) AVG: 0.00B",
            "iblt": "IBLT size (last 24hrs) AVG: 0.00B",
            "rank": "Rank size (last 24hrs) AVG: 0.00B",
            "graphene_block_size": "Graphene block size (last 24hrs) AVG: 0.00B",
            "graphene_additional_tx_size": "Graphene size additional txs (last 24hrs) AVG: 0.00B",
            "rerequested": "Tx re-request rate (last 24hrs): 0.0% Total re-requests:0"
        },
        "warnings": ""
    },
    "error": null,
    "id": "1"
}

getpeerinfo [peer IP address]

  • Request parameter
  • peer IP address:Optional, returns all connected network node information if not specified.
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "getpeerinfo",
        "params": []
    }
    
  • Response:
    {
        "result": [
            {
                "id": 10,
                "addr": "194.33.38.214:63335",
                "addrlocal": "218.77.106.151:37951",
                "services": "0000000000000075",
                "relaytxes": true,
                "lastsend": 1563266273,
                "lastrecv": 1563266273,
                "bytessent": 11059,
                "bytesrecv": 8935,
                "conntime": 1563260353,
                "timeoffset": 0,
                "pingtime": 0.292815,
                "minping": 0.177829,
                "version": 80003,
                "subver": "/BUCash:1.6.0(EB32; AD12)/",
                "inbound": false,
                "startingheight": 1514,
                "banscore": 0,
                "synced_headers": 1554,
                "synced_blocks": 1553,
                "inflight": [],
                "whitelisted": false,
                "xversion_map": {
                    "0000000000020001": "04",
                    "0000000000020002": "01",
                    "0000000000020000": "fd67f7",
                    "0000000000020005": "00",
                    "0000000000020003": "02",
                    "0000000000020004": "00"
                }
            },
            {
                "id": 13,
                "addr": "121.28.160.158:63335",
                "addrlocal": "218.77.106.151:21360",
                "services": "0000000000000075",
                "relaytxes": true,
                "lastsend": 1563266225,
                "lastrecv": 1563266273,
                "bytessent": 8259,
                "bytesrecv": 12048,
                "conntime": 1563260360,
                "timeoffset": 0,
                "pingtime": 0.039879,
                "minping": 0.036661,
                "version": 80003,
                "subver": "/BUCash:1.6.0(EB32; AD12)/",
                "inbound": false,
                "startingheight": 1514,
                "banscore": 0,
                "synced_headers": 1554,
                "synced_blocks": 1553,
                "inflight": [],
                "whitelisted": false,
                "xversion_map": {
                    "0000000000020002": "01",
                    "0000000000020001": "04",
                    "0000000000020005": "00",
                    "0000000000020000": "fd67f7",
                    "0000000000020004": "00",
                    "0000000000020003": "02"
                }
            },
            {
                "id": 14,
                "addr": "205.185.120.91:63335",
                "addrlocal": "218.77.106.151:38220",
                "services": "0000000000000075",
                "relaytxes": true,
                "lastsend": 1563266273,
                "lastrecv": 1563266273,
                "bytessent": 10564,
                "bytesrecv": 10712,
                "conntime": 1563260379,
                "timeoffset": 0,
                "pingtime": 0.191049,
                "minping": 0.182475,
                "version": 80003,
                "subver": "/BUCash:1.6.0(EB32; AD12)/",
                "inbound": false,
                "startingheight": 1514,
                "banscore": 0,
                "synced_headers": 1554,
                "synced_blocks": 1552,
                "inflight": [],
                "whitelisted": false,
                "xversion_map": {
                    "0000000000020000": "fd67f7",
                    "0000000000020002": "01",
                    "0000000000020001": "04",
                    "0000000000020004": "00",
                    "0000000000020003": "02",
                    "0000000000020005": "00"
                }
            },
            {
                "id": 15,
                "addr": "124.236.118.112:63335",
                "addrlocal": "218.77.106.151:21148",
                "services": "0000000000000075",
                "relaytxes": true,
                "lastsend": 1563266202,
                "lastrecv": 1563266273,
                "bytessent": 9153,
                "bytesrecv": 9889,
                "conntime": 1563260381,
                "timeoffset": 0,
                "pingtime": 0.042974,
                "minping": 0.040235,
                "version": 80003,
                "subver": "/BUCash:1.6.0(EB32; AD12)/",
                "inbound": false,
                "startingheight": 1514,
                "banscore": 0,
                "synced_headers": 1554,
                "synced_blocks": 1553,
                "inflight": [],
                "whitelisted": false,
                "xversion_map": {
                    "0000000000020001": "04",
                    "0000000000020000": "fd67f7",
                    "0000000000020005": "00",
                    "0000000000020004": "00",
                    "0000000000020002": "01",
                    "0000000000020003": "02"
                }
            },
            {
                "id": 16,
                "addr": "47.91.209.206:63335",
                "addrlocal": "218.77.106.151:21130",
                "services": "0000000000000075",
                "relaytxes": true,
                "lastsend": 1563266264,
                "lastrecv": 1563266273,
                "bytessent": 5845,
                "bytesrecv": 14727,
                "conntime": 1563260383,
                "timeoffset": 0,
                "pingtime": 0.039151,
                "minping": 0.038024,
                "version": 80003,
                "subver": "/BUCash:1.6.0(EB32; AD12)/",
                "inbound": false,
                "startingheight": 1514,
                "banscore": 0,
                "synced_headers": 1554,
                "synced_blocks": 1553,
                "inflight": [],
                "whitelisted": false,
                "xversion_map": {
                    "0000000000020000": "fd67f7",
                    "0000000000020002": "01",
                    "0000000000020001": "04",
                    "0000000000020005": "00",
                    "0000000000020003": "02",
                    "0000000000020004": "00"
                }
            },
            {
                "id": 27,
                "addr": "27.102.134.181:63335",
                "addrlocal": "218.77.106.151:26893",
                "services": "0000000000000075",
                "relaytxes": true,
                "lastsend": 1563266273,
                "lastrecv": 1563266273,
                "bytessent": 3987,
                "bytesrecv": 8615,
                "conntime": 1563263917,
                "timeoffset": 0,
                "pingtime": 0.068714,
                "minping": 0.067235,
                "version": 80003,
                "subver": "/BUCash:1.6.0(EB32; AD12)/",
                "inbound": false,
                "startingheight": 1536,
                "banscore": 0,
                "synced_headers": 1554,
                "synced_blocks": 1553,
                "inflight": [],
                "whitelisted": false,
                "xversion_map": {
                    "0000000000020000": "fd67f7",
                    "0000000000020001": "04",
                    "0000000000020003": "02",
                    "0000000000020002": "01",
                    "0000000000020005": "00",
                    "0000000000020004": "00"
                }
            }
        ],
        "error": null,
        "id": "1"
    }
    

gettrafficshaping

Get the bandwidth setting information sent and received by the network, in units of kb/s. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "gettrafficshaping",
    "params": []
}
- Response:
{
    "result": {
        "recvBurst": 10000,
        "recvAve": 1024
    },
    "error": null,
    "id": "1"
}

ping

Send ping to all other nodes to test the time. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "ping",
    "params": []
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

pushtx "node"

Push unconfirmed transactions to a node. - Request parameter - node:Required, node information - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "pushtx",
    "params": ["124.236.118.112:63335"]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

setban "ip(/netmask)" "add|remove" (bantime) (absolute)

Add or remove nodes from the blacklist. - Request parameter - ip(/netmask):Required, IP information - command:Required, add|remove means add or remove - bantime:Optional parameter, prohibited time (in seconds) - absolute:Optional parameter, true|false, if set, bantime must be an absolute timestamp - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "setban",
    "params": ["192.168.0.6", "add", 86400]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

setexcessiveblock blockSize acceptDepth

Corresponds to getexcessiveblock - Request parameter - blockSize:Required, hexadecimal block data to be verified - acceptDepth:Required, hexadecimal block data to be verified - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "setexcessiveblock",
    "params": [320000000, 10]
}
- Response:
{
    "result": "Excessive Block set to 320000000 bytes.  Accept Depth set to 10 blocks.",
    "error": null,
    "id": "1"
}

settrafficshaping "send|receive" "burstKB" "averageKB"

Corresponding to gettrafficshaping, set the bandwidth setting information sent and received by the network, the unit is kb/s - Request parameter - send|receive:Required, send or receive bandwidth - burst:burst size - average:Average throughput - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "settrafficshaping",
    "params": ["receive", 10000, 1024]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

Rawtransactions

createrawtransaction [{"txid":"id","vout":n},...] {"address":amount,"data":"hex",...} (locktime)

Create a pending transaction - Request parameter - transactions:Required, transaction information, structured as follows:

[
    "txid": "id",
    "vout": n,
    "sequence": n
]
- outputs:Required, input structure
{
    "address": x.xxx,
    "data": "hex",
    ...
}
- Request:

- Response:

decoderawtransaction "hexstring"

  • Request parameter
  • hexstring:Required, hexadecimal encryption data
  • Request:
    
    
  • Response:
    
    

decodescript "hex"

  • Request parameter:
  • hex:Required, hexadecimal encryption script
  • Request:
    
    
  • Response:
    
    

enqueuerawtransaction "hexstring" (options)

  • Request parameter
  • hexstring:Required, trading hexadecimal data
  • options:Optional parameter
  • Request:
    
    
  • Response:
    
    

fundrawtransaction "hexstring" includeWatching

  • Request parameter
  • hexstring:Required, trading hexadecimal data
  • includeWatching:Optional parameter, default is false
  • Request:
    
    
  • Response:
    
    

getrawblocktransactions

  • Request:
    
    
  • Response:
    
    

getrawtransaction "txid" (verbose "blockhash")

Get specific information about the transaction - Request parameter - txid:Required, transaction ID - verbose:Optional parameter, default is false, returning as string, denied is json object - blockhash:Optional parameter, specify the block to find - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getrawtransaction",
    "params": ["7b100c6083f8e6250f9dbc3585653b903cbae81dd7d0012b0be30bc8b3912570", true]
}
- Response:
{
    "result": {
        "txid": "7b100c6083f8e6250f9dbc3585653b903cbae81dd7d0012b0be30bc8b3912570",
        "size": 1431,
        "version": 1,
        "locktime": 2125,
        "vin": [
            {
                "txid": "22431db4891113f329ba9220198a939a15ff6e75a07dfeba7a0f9ee26626b27f",
                "vout": 1,
                "scriptSig": {
                    "asm": "30440220108ff7250b765dc3dd7468b3f4c9a42b86eb5c75fbc0c6eb1e4679bef7d64b590220686efd5868ded0e6ac24a712d86f09e4af9d8be0f82fe8f8a4032ae2d7e70f57[ALL|FORKID]",
                    "hex": "4730440220108ff7250b765dc3dd7468b3f4c9a42b86eb5c75fbc0c6eb1e4679bef7d64b590220686efd5868ded0e6ac24a712d86f09e4af9d8be0f82fe8f8a4032ae2d7e70f5741"
                },
                "sequence": 4294967294
            },
            {
                "txid": "46dab0ef38ff8b8f8a075a7c18bd038ec55676b7b50bdb6e95eb9cdb3af80cb0",
                "vout": 2,
                "scriptSig": {
                    "asm": "3044022051dae81547873cb1876d15a5d66ccd60ab84c90fd88c31ff9e0edb09b5aa7be302202ee792428449d5840030174ea129e0e59b8b24e56d2a3f79843f690d8e0a18e9[ALL|FORKID] 02811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae69",
                    "hex": "473044022051dae81547873cb1876d15a5d66ccd60ab84c90fd88c31ff9e0edb09b5aa7be302202ee792428449d5840030174ea129e0e59b8b24e56d2a3f79843f690d8e0a18e9412102811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae69"
                },
                "sequence": 4294967294
            },
            {
                "txid": "82f042d7f3c92a2430e3f32571984124c0422de9842d1c58c0ca6402fe51579e",
                "vout": 0,
                "scriptSig": {
                    "asm": "3045022100b9bc48c74b076e143d25b2d364a47a07f7171a60cfe442162fd85b89ccb138b602203e2ac4e9bce5f0bb73fdf7ce8138b6b5e953e97cc2b0ca40a0330f9a9bacd3e2[ALL|FORKID] 02811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae69",
                    "hex": "483045022100b9bc48c74b076e143d25b2d364a47a07f7171a60cfe442162fd85b89ccb138b602203e2ac4e9bce5f0bb73fdf7ce8138b6b5e953e97cc2b0ca40a0330f9a9bacd3e2412102811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae69"
                },
                "sequence": 4294967294
            },
            {
                "txid": "82f042d7f3c92a2430e3f32571984124c0422de9842d1c58c0ca6402fe51579e",
                "vout": 1,
                "scriptSig": {
                    "asm": "0 30440220768d5388432dd32f047a66778636621dab1da754b2a5ec186356395147f8787f02206682ee90b13362ba4aa5ca37d4aed98f9475093e52318f681b2a804bc81da015[ALL|FORKID] 30440220526ba2d31d9a7f2aaa6a4f989c756301a16d05bfd755457b9de9b31cca5ba6710220169447a3b46c440eb264a3d685caa1b26ccbfc12975685b93d6909969f2cfa0a[ALL|FORKID] 52210210efa95a1cf54fa8719fd9bed4038ecfbd93890bd2b078475ef312dd0c66965821034bcc067f778129a9140a12c9d17c72b733dc3577e9e99a821746972c9b481ed82102811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae6953ae",
                    "hex": "004730440220768d5388432dd32f047a66778636621dab1da754b2a5ec186356395147f8787f02206682ee90b13362ba4aa5ca37d4aed98f9475093e52318f681b2a804bc81da015414730440220526ba2d31d9a7f2aaa6a4f989c756301a16d05bfd755457b9de9b31cca5ba6710220169447a3b46c440eb264a3d685caa1b26ccbfc12975685b93d6909969f2cfa0a414c6952210210efa95a1cf54fa8719fd9bed4038ecfbd93890bd2b078475ef312dd0c66965821034bcc067f778129a9140a12c9d17c72b733dc3577e9e99a821746972c9b481ed82102811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae6953ae"
                },
                "sequence": 4294967294
            },
            {
                "txid": "2009b1f8c23da950b0a9e57641046ce7902f9bf81a7c9fdf0f00f84d43b2904d",
                "vout": 0,
                "scriptSig": {
                    "asm": "304402207306ea279c3ddd7c772fdbb59ac347be022d17a44969ea6b232004ec5d8c130602201515e418716103d533833b9d60845fd25ea98ebb6bbde8fa55e3e89d19d8befb[ALL|FORKID] 0348e7a0d3ca54077fc46df4642a03153d6677231fbd01fb5f6543b678cbd16c6c",
                    "hex": "47304402207306ea279c3ddd7c772fdbb59ac347be022d17a44969ea6b232004ec5d8c130602201515e418716103d533833b9d60845fd25ea98ebb6bbde8fa55e3e89d19d8befb41210348e7a0d3ca54077fc46df4642a03153d6677231fbd01fb5f6543b678cbd16c6c"
                },
                "sequence": 4294967294
            },
            {
                "txid": "be099aa6f0f5f1d5e01832d58db1c2a6b612acb0d5e64cf51072b0f0e7c4fc69",
                "vout": 1,
                "scriptSig": {
                    "asm": "304402207f84d16e1786e0a8b38ebd08276653f37de1c1fdfdeb53c45346db59482b1b7e02203e4a757313d7dd18e65be28d32ff94cc135c2cda450f141e2b45a97904f230c8[ALL|FORKID]",
                    "hex": "47304402207f84d16e1786e0a8b38ebd08276653f37de1c1fdfdeb53c45346db59482b1b7e02203e4a757313d7dd18e65be28d32ff94cc135c2cda450f141e2b45a97904f230c841"
                },
                "sequence": 4294967294
            },
            {
                "txid": "274ba89adb21f06fec21f44e946979f439f74a53e59f9aed96172efd67a9ab47",
                "vout": 1,
                "scriptSig": {
                    "asm": "3045022100cf4c90d9596acdf88c4f3a0c4cefc7d1ab95da780f00616286203ebcc59552bc02201b6f95d3d41d9a85e1873940a3cd7e105df5428cbc7fab505d8889ef505da1a7[ALL|FORKID]",
                    "hex": "483045022100cf4c90d9596acdf88c4f3a0c4cefc7d1ab95da780f00616286203ebcc59552bc02201b6f95d3d41d9a85e1873940a3cd7e105df5428cbc7fab505d8889ef505da1a741"
                },
                "sequence": 4294967294
            },
            {
                "txid": "f45a7538fc071c84c70d4a7e0d220a3e4b62fcdf4fe8822e5c5ca7ed0a8b4700",
                "vout": 1,
                "scriptSig": {
                    "asm": "3044022058748083d042e8eba80002e0eba186934db13748eb5a79d42090c8075e06dad502202d02807c6f1d617be4255cf98fda98375e0f11826d0fc4559700058949944e3a[ALL|FORKID]",
                    "hex": "473044022058748083d042e8eba80002e0eba186934db13748eb5a79d42090c8075e06dad502202d02807c6f1d617be4255cf98fda98375e0f11826d0fc4559700058949944e3a41"
                },
                "sequence": 4294967294
            },
            {
                "txid": "d1f6185e2793abf916ad86cd4b16fc4d1f0b961a1f70b18cfbca2af21aeb5d48",
                "vout": 1,
                "scriptSig": {
                    "asm": "3044022014b5e094560582787b4304b97d530bae895a0a1e7f52692097bae09be4b4a33802202edc06060221a8f7b4e93865329d0acee35e6bbb1175b428024480e2468981ed[ALL|FORKID]",
                    "hex": "473044022014b5e094560582787b4304b97d530bae895a0a1e7f52692097bae09be4b4a33802202edc06060221a8f7b4e93865329d0acee35e6bbb1175b428024480e2468981ed41"
                },
                "sequence": 4294967294
            }
        ],
        "vout": [
            {
                "value": 50,
                "n": 0,
                "scriptPubKey": {
                    "asm": "OP_DUP OP_HASH160 e156d8f45865a44cc689b4ac5b63d0534be15f21 OP_EQUALVERIFY OP_CHECKSIG",
                    "hex": "76a914e156d8f45865a44cc689b4ac5b63d0534be15f2188ac",
                    "reqSigs": 1,
                    "type": "pubkeyhash",
                    "addresses": [
                        "1MYV5RxyXiPDR7vtdVhUKBXcVzwx5sFoMP"
                    ]
                }
            },
            {
                "value": 0.00000546,
                "n": 1,
                "scriptPubKey": {
                    "asm": "OP_DUP OP_HASH160 e156d8f45865a44cc689b4ac5b63d0534be15f21 OP_EQUALVERIFY OP_CHECKSIG",
                    "hex": "76a914e156d8f45865a44cc689b4ac5b63d0534be15f2188ac",
                    "reqSigs": 1,
                    "type": "pubkeyhash",
                    "addresses": [
                        "1MYV5RxyXiPDR7vtdVhUKBXcVzwx5sFoMP"
                    ]
                }
            },
            {
                "value": 0.17420841,
                "n": 2,
                "scriptPubKey": {
                    "asm": "OP_DUP OP_HASH160 e156d8f45865a44cc689b4ac5b63d0534be15f21 OP_EQUALVERIFY OP_CHECKSIG",
                    "hex": "76a914e156d8f45865a44cc689b4ac5b63d0534be15f2188ac",
                    "reqSigs": 1,
                    "type": "pubkeyhash",
                    "addresses": [
                        "1MYV5RxyXiPDR7vtdVhUKBXcVzwx5sFoMP"
                    ]
                }
            },
            {
                "value": 0,
                "n": 3,
                "scriptPubKey": {
                    "asm": "OP_RETURN 64636f70010001",
                    "hex": "6a0764636f70010001",
                    "type": "nulldata"
                }
            }
        ],
        "blockhash": "5c46d6c84f11fa3730ae82497ae1e26a230f99e561b231a0b3ee4ef0921599f2",
        "confirmations": 31,
        "time": 1563347295,
        "blocktime": 1563347295,
        "hex": "01000000097fb22666e29e0f7abafe7da0756eff159a938a192092ba29f3131189b41d432201000000484730440220108ff7250b765dc3dd7468b3f4c9a42b86eb5c75fbc0c6eb1e4679bef7d64b590220686efd5868ded0e6ac24a712d86f09e4af9d8be0f82fe8f8a4032ae2d7e70f5741feffffffb00cf83adb9ceb956edb0bb5b77656c58e03bd187c5a078a8f8bff38efb0da46020000006a473044022051dae81547873cb1876d15a5d66ccd60ab84c90fd88c31ff9e0edb09b5aa7be302202ee792428449d5840030174ea129e0e59b8b24e56d2a3f79843f690d8e0a18e9412102811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae69feffffff9e5751fe0264cac0581c2d84e92d42c02441987125f3e330242ac9f3d742f082000000006b483045022100b9bc48c74b076e143d25b2d364a47a07f7171a60cfe442162fd85b89ccb138b602203e2ac4e9bce5f0bb73fdf7ce8138b6b5e953e97cc2b0ca40a0330f9a9bacd3e2412102811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae69feffffff9e5751fe0264cac0581c2d84e92d42c02441987125f3e330242ac9f3d742f08201000000fc004730440220768d5388432dd32f047a66778636621dab1da754b2a5ec186356395147f8787f02206682ee90b13362ba4aa5ca37d4aed98f9475093e52318f681b2a804bc81da015414730440220526ba2d31d9a7f2aaa6a4f989c756301a16d05bfd755457b9de9b31cca5ba6710220169447a3b46c440eb264a3d685caa1b26ccbfc12975685b93d6909969f2cfa0a414c6952210210efa95a1cf54fa8719fd9bed4038ecfbd93890bd2b078475ef312dd0c66965821034bcc067f778129a9140a12c9d17c72b733dc3577e9e99a821746972c9b481ed82102811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae6953aefeffffff4d90b2434df8000fdf9f7c1af89b2f90e76c044176e5a9b050a93dc2f8b10920000000006a47304402207306ea279c3ddd7c772fdbb59ac347be022d17a44969ea6b232004ec5d8c130602201515e418716103d533833b9d60845fd25ea98ebb6bbde8fa55e3e89d19d8befb41210348e7a0d3ca54077fc46df4642a03153d6677231fbd01fb5f6543b678cbd16c6cfeffffff69fcc4e7f0b07210f54ce6d5b0ac12b6a6c2b18dd53218e0d5f1f5f0a69a09be010000004847304402207f84d16e1786e0a8b38ebd08276653f37de1c1fdfdeb53c45346db59482b1b7e02203e4a757313d7dd18e65be28d32ff94cc135c2cda450f141e2b45a97904f230c841feffffff47aba967fd2e1796ed9a9fe5534af739f47969944ef421ec6ff021db9aa84b270100000049483045022100cf4c90d9596acdf88c4f3a0c4cefc7d1ab95da780f00616286203ebcc59552bc02201b6f95d3d41d9a85e1873940a3cd7e105df5428cbc7fab505d8889ef505da1a741feffffff00478b0aeda75c5c2e82e84fdffc624b3e0a220d7e4a0dc7841c07fc38755af40100000048473044022058748083d042e8eba80002e0eba186934db13748eb5a79d42090c8075e06dad502202d02807c6f1d617be4255cf98fda98375e0f11826d0fc4559700058949944e3a41feffffff485deb1af22acafb8cb1701f1a960b1f4dfc164bcd86ad16f9ab93275e18f6d10100000048473044022014b5e094560582787b4304b97d530bae895a0a1e7f52692097bae09be4b4a33802202edc06060221a8f7b4e93865329d0acee35e6bbb1175b428024480e2468981ed41feffffff0400f2052a010000001976a914e156d8f45865a44cc689b4ac5b63d0534be15f2188ac22020000000000001976a914e156d8f45865a44cc689b4ac5b63d0534be15f2188ac29d20901000000001976a914e156d8f45865a44cc689b4ac5b63d0534be15f2188ac0000000000000000096a0764636f700100014d080000"
    },
    "error": null,
    "id": "1"
}

getrawtransactionssince

  • Request parameter
  • -v|--verbose:Optional parameter, default is false
  • hashblock:Required, the block hash
  • count:Optional parameter, default is 1
  • protocol_id:Optional parameter
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "getrawtransactionssince",
        "params": ["-v", "79973d51e6004582cc27f34f2ca8354bd5236f8c8322cfad65a760ace04dbc51", 10]
    }
    
  • Response:
    {
        "result": {
            "79973d51e6004582cc27f34f2ca8354bd5236f8c8322cfad65a760ace04dbc51": {
                "d1f9f973d501e0cbe7cc6c5f1a1ca948403bd7f7688678010696f8f15578568e": {
                    "hex": "01000000010000000000000000000000000000000000000000000000000000000000000000ffffffff1402710804f0edb8300b2f454233322f414431322fffffffff02008c86470000000017a914ae6b7287280d25f76c43dab1350b94b6163b63ee870008af2f00000000232103937c40db665c816e18cb5e18d151fa7f1ddbbcea511c8bfb7b37b399417ededaac00000000",
                    "txid": "d1f9f973d501e0cbe7cc6c5f1a1ca948403bd7f7688678010696f8f15578568e",
                    "size": 147,
                    "version": 1,
                    "locktime": 0,
                    "vin": [
                        {
                            "coinbase": "02710804f0edb8300b2f454233322f414431322f",
                            "sequence": 4294967295
                        }
                    ],
                    "vout": [
                        {
                            "value": 12,
                            "n": 0,
                            "scriptPubKey": {
                                "asm": "OP_HASH160 ae6b7287280d25f76c43dab1350b94b6163b63ee OP_EQUAL",
                                "hex": "a914ae6b7287280d25f76c43dab1350b94b6163b63ee87",
                                "reqSigs": 1,
                                "type": "scripthash",
                                "addresses": [
                                    "3HbGDVmFcxCQJGUVQH46fbrwJEk8VBDBU3"
                                ]
                            }
                        },
                        {
                            "value": 8,
                            "n": 1,
                            "scriptPubKey": {
                                "asm": "03937c40db665c816e18cb5e18d151fa7f1ddbbcea511c8bfb7b37b399417ededa OP_CHECKSIG",
                                "hex": "2103937c40db665c816e18cb5e18d151fa7f1ddbbcea511c8bfb7b37b399417ededaac",
                                "reqSigs": 1,
                                "type": "pubkey",
                                "addresses": [
                                    "125iwSheqz1JUmpUVcb53oPD6sjcMkYWVG"
                                ]
                            }
                        }
                    ],
                    "blockhash": "79973d51e6004582cc27f34f2ca8354bd5236f8c8322cfad65a760ace04dbc51",
                    "confirmations": 3,
                    "time": 1563351698,
                    "blocktime": 1563351698
                }
            },
            "164eb4fd56acbe411e1ea1208e4b64f5717c012313e451b1496f8d51356de9c8": {
                "8b3745c5625b1158ddb2dfa3db20451e1be6dcbbacca17b84f706df9b8d09770": {
                    "hex": "01000000010000000000000000000000000000000000000000000000000000000000000000ffffffff15027208058a26b9f7170b2f454233322f414431322fffffffff02008c86470000000017a914ae6b7287280d25f76c43dab1350b94b6163b63ee870008af2f000000002321037ab83fe7aa473dbeefe2eeb26509cdbb84b5022156956c28a5bab9162160e038ac00000000",
                    "txid": "8b3745c5625b1158ddb2dfa3db20451e1be6dcbbacca17b84f706df9b8d09770",
                    "size": 148,
                    "version": 1,
                    "locktime": 0,
                    "vin": [
                        {
                            "coinbase": "027208058a26b9f7170b2f454233322f414431322f",
                            "sequence": 4294967295
                        }
                    ],
                    "vout": [
                        {
                            "value": 12,
                            "n": 0,
                            "scriptPubKey": {
                                "asm": "OP_HASH160 ae6b7287280d25f76c43dab1350b94b6163b63ee OP_EQUAL",
                                "hex": "a914ae6b7287280d25f76c43dab1350b94b6163b63ee87",
                                "reqSigs": 1,
                                "type": "scripthash",
                                "addresses": [
                                    "3HbGDVmFcxCQJGUVQH46fbrwJEk8VBDBU3"
                                ]
                            }
                        },
                        {
                            "value": 8,
                            "n": 1,
                            "scriptPubKey": {
                                "asm": "037ab83fe7aa473dbeefe2eeb26509cdbb84b5022156956c28a5bab9162160e038 OP_CHECKSIG",
                                "hex": "21037ab83fe7aa473dbeefe2eeb26509cdbb84b5022156956c28a5bab9162160e038ac",
                                "reqSigs": 1,
                                "type": "pubkey",
                                "addresses": [
                                    "13xYunxKZcKjtyCsWazm7Z29zL5VmVz2fZ"
                                ]
                            }
                        }
                    ],
                    "blockhash": "164eb4fd56acbe411e1ea1208e4b64f5717c012313e451b1496f8d51356de9c8",
                    "confirmations": 2,
                    "time": 1563351788,
                    "blocktime": 1563351788
                }
            },
            "17ee4f522c7d9f0029bb6f5fd770c349861220d310d2af2c7d6683f58ee934b7": {
                "0e76389c0e16a8c0fdf5ec74e275cd782dbc7b5e5d61552e0c53e8f1bb6054e9": {
                    "hex": "01000000010000000000000000000000000000000000000000000000000000000000000000ffffffff1802730808a1aec8fe4da5e0f90b2f454233322f414431322fffffffff02008c86470000000017a914ae6b7287280d25f76c43dab1350b94b6163b63ee870008af2f00000000232103d06612bab362b6ba3d1d891c1a58425fb38d77397a749489fc53d72d9cd8d0f6ac00000000",
                    "txid": "0e76389c0e16a8c0fdf5ec74e275cd782dbc7b5e5d61552e0c53e8f1bb6054e9",
                    "size": 151,
                    "version": 1,
                    "locktime": 0,
                    "vin": [
                        {
                            "coinbase": "02730808a1aec8fe4da5e0f90b2f454233322f414431322f",
                            "sequence": 4294967295
                        }
                    ],
                    "vout": [
                        {
                            "value": 12,
                            "n": 0,
                            "scriptPubKey": {
                                "asm": "OP_HASH160 ae6b7287280d25f76c43dab1350b94b6163b63ee OP_EQUAL",
                                "hex": "a914ae6b7287280d25f76c43dab1350b94b6163b63ee87",
                                "reqSigs": 1,
                                "type": "scripthash",
                                "addresses": [
                                    "3HbGDVmFcxCQJGUVQH46fbrwJEk8VBDBU3"
                                ]
                            }
                        },
                        {
                            "value": 8,
                            "n": 1,
                            "scriptPubKey": {
                                "asm": "03d06612bab362b6ba3d1d891c1a58425fb38d77397a749489fc53d72d9cd8d0f6 OP_CHECKSIG",
                                "hex": "2103d06612bab362b6ba3d1d891c1a58425fb38d77397a749489fc53d72d9cd8d0f6ac",
                                "reqSigs": 1,
                                "type": "pubkey",
                                "addresses": [
                                    "1LJ9EiaopwLVcvXMzV7DddeJQ7FyarDrFg"
                                ]
                            }
                        }
                    ],
                    "blockhash": "17ee4f522c7d9f0029bb6f5fd770c349861220d310d2af2c7d6683f58ee934b7",
                    "confirmations": 1,
                    "time": 1563351840,
                    "blocktime": 1563351840
                }
            }
        },
        "error": null,
        "id": "1"
    }
    

sendrawtransaction "hexstring" (allowhighfees, allownonstandard)

Send the transaction to local node and network. - Request parameter - hexstring (string, required) The hex string of the raw transaction) - allowhighfees (boolean, optional, default=false) Allow high fees - allownonstandard:('standard', 'nonstandard', 'default') Optional parameter, default is default - Request:


- Response:

signrawtransaction "hexstring" ([{"txid":"id","vout":n,"scriptPubKey":"hex","redeemScript":"hex"},...] ["privatekey1",...] sighashtype)

Sign inputs for raw transaction (serialized, hex-encoded). The second optional argument (may be null) is an array of previous transaction outputs that this transaction depends on but may not yet be in the block chain. The third optional argument (may be null) is an array of base58-encoded private keys that, if given, will be the only keys used to sign the transaction. - Request parameter - hexstring (string, required) The transaction hex string - prevtxs (string, optional) An json array of previous dependent transaction outputs

[
    {
        "txid": "id",
        "vout": n,
        "scriptPubKey": "hex",
        "redeemScript": "hex",
        "amount": value
    },
    ...
]
- privkeys (string, optional) A json array of base58-encoded private keys for signing
[ 
    "privatekey" (string) private key in base58-encoding 
    ,...
] 
- sighashtype (string, optional, default=ALL) The signature hash type. Must be one of:
"ALL" 
"NONE" 
"SINGLE" 
"ALL|ANYONECANPAY" 
"NONE|ANYONECANPAY" 
"SINGLE|ANYONECANPAY"

  • Request:
    
    
  • Response:
    
    

Util

createmultisig nrequired ["key",...]

Create a multi-signed address of n signatures requiring m keys. Return a json object with an address and redeemScript - Request parameter - nrequired (numeric, required) The number of required signatures out of the n keys or addresses. - keys (string, required) A json array of keys which are qtum addresses or hex-encoded public keys - Request:

{
    "jsonrpc":"1.0",
    "id":"1",
    "method":"createmultisig",
    "params":[3,["0210efa95a1cf54fa8719fd9bed4038ecfbd93890bd2b078475ef312dd0c669658","034bcc067f778129a9140a12c9d17c72b733dc3577e9e99a821746972c9b481ed8","02811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae69"]]
}
- Response:
{
    "result": {
        "address": "3LBb4FzY4UosrKkhcbbY2bVbvcbaKN9pGs",
        "redeemScript": "53210210efa95a1cf54fa8719fd9bed4038ecfbd93890bd2b078475ef312dd0c66965821034bcc067f778129a9140a12c9d17c72b733dc3577e9e99a821746972c9b481ed82102811486c03f3a99c5820b43039f72f9e1b728b45c611b860cd994de3c9100ae6953ae"
    },
    "error": null,
    "id": "1"
}

estimatefee nblocks

Estimate transaction fee, unit is KB. - Request parameter - nblocks (numeric, required) - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "estimatefee",
    "params": [6]
}
- Response:
{
    "result": -1,
    "error": null,
    "id": "1"
}

get

Get configuration information, get all by default, or specify specific configuration. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "get",
    "params": []
}
- Response:
{
    "result": {
        "blockchain.checkScriptDays": 30,
        "consensus.enableCanonicalTxOrder": false,
        "consensus.forkMay2019Time": 0,
        "consensus.maxScriptOps": 201,
        "consensus.svForkNov2018Time": 0,
        "maxlimitertxfee": 1,
        "mining.blockSize": 8000000,
        "mining.coinbaseReserve": 1000,
        "mining.comment": "Diskcoin is fundamentally emergent consensus",
        "mining.dataCarrierSize": 223,
        "mining.excessiveSigopsPerMb": 20000,
        "mining.unsafeGetBlockTemplate": false,
        "mining.vote": "",
        "minlimitertxfee": 1,
        "net.blockDownloadWindow": 0,
        "net.blockRetryInterval": 5000000,
        "net.dustThreshold": 546,
        "net.excessiveAcceptDepth": 12,
        "net.excessiveBlock": 32000000,
        "net.excessiveSigopsPerMb": 20000,
        "net.excessiveTx": 1000000,
        "net.grapheneFastFilterCompatibility": 0,
        "net.grapheneMaxVersionSupported": 4,
        "net.grapheneMinVersionSupported": 0,
        "net.ignoreTimeouts": false,
        "net.magic": 0,
        "net.maxBlocksInTransitPerPeer": 0,
        "net.maxConnections": 125,
        "net.maxOutboundConnections": 16,
        "net.minXthinNodes": 8,
        "net.msgHandlerThreads": 2,
        "net.subversionOverride": "",
        "net.txAdmissionThreads": 2,
        "net.txRetryInterval": 5000000,
        "prune.pruneInterval": 100,
        "reindex.typicalBlockSize": 200000,
        "wallet.maxTxFee": 10000000
    },
    "error": null,
    "id": "1"
}

getaddressforms "address"

  • Request parameter
  • address:Required, address information
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "getaddressforms",
        "params": ["1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy"]
    }
    
  • Response:
    {
        "result": {
            "legacy": "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
            "Diskcoincash": "disc:qpejezvuxwer2j7cy36cudalegqv4ea7vuxysq5gtj",
            "bitpay": "CSxsddAJd2sTMT6iADUNjt31G8yXEnNK3k"
        },
        "error": null,
        "id": "1"
    }
    

getstat

  • Request parameter
  • statistic:Required, need to get a specific statistic (get by the getstatlist command)
  • -v|--verbose:Optional parameter, whether all details
  • series:Optional parameter ("total", "now","all", "sec10", "min5", "hourly", "daily","monthly")
  • count:Optional parameter, the number returned
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "getstat",
        "params": ["memPool/size"]
    }
    
  • Response:
    {
        "result": [
            {
                "total": 1272
            }
        ],
        "error": null,
        "id": "1"
    }
    

getstatlist

Return all available statistics on this node. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getstatlist",
    "params": []
}
- Response:
{
    "result": [
        "blockValidationTime",
        "memPool/size",
        "memPool/txAdded",
        "net/recv/msg/Xb",
        "net/recv/msg/Xt",
        "net/recv/msg/addr",
        "net/recv/msg/blacklist",
        "net/recv/msg/block",
        "net/recv/msg/blocktxn",
        "net/recv/msg/buverack",
        "net/recv/msg/buversion",
        "net/recv/msg/cmpctblock",
        "net/recv/msg/filteradd",
        "net/recv/msg/filterclear",
        "net/recv/msg/filterload",
        "net/recv/msg/filtersizext",
        "net/recv/msg/get_grblk",
        "net/recv/msg/get_grblktx",
        "net/recv/msg/get_thin",
        "net/recv/msg/get_xblocktx",
        "net/recv/msg/get_xthin",
        "net/recv/msg/getaddr",
        "net/recv/msg/getblocks",
        "net/recv/msg/getblocktxn",
        "net/recv/msg/getdata",
        "net/recv/msg/getheaders",
        "net/recv/msg/grblk",
        "net/recv/msg/grblktx",
        "net/recv/msg/headers",
        "net/recv/msg/inv",
        "net/recv/msg/mempool",
        "net/recv/msg/merkleblock",
        "net/recv/msg/notfound",
        "net/recv/msg/ping",
        "net/recv/msg/pong",
        "net/recv/msg/reject",
        "net/recv/msg/req_xpedited",
        "net/recv/msg/sendcmpct",
        "net/recv/msg/sendheaders",
        "net/recv/msg/thinblock",
        "net/recv/msg/tx",
        "net/recv/msg/verack",
        "net/recv/msg/version",
        "net/recv/msg/xblocktx",
        "net/recv/msg/xthinblock",
        "net/recv/msg/xupdate",
        "net/recv/msg/xverack",
        "net/recv/msg/xversion",
        "net/recv/total",
        "net/send/msg/Xb",
        "net/send/msg/Xt",
        "net/send/msg/addr",
        "net/send/msg/blacklist",
        "net/send/msg/block",
        "net/send/msg/blocktxn",
        "net/send/msg/buverack",
        "net/send/msg/buversion",
        "net/send/msg/cmpctblock",
        "net/send/msg/filteradd",
        "net/send/msg/filterclear",
        "net/send/msg/filterload",
        "net/send/msg/filtersizext",
        "net/send/msg/get_grblk",
        "net/send/msg/get_grblktx",
        "net/send/msg/get_thin",
        "net/send/msg/get_xblocktx",
        "net/send/msg/get_xthin",
        "net/send/msg/getaddr",
        "net/send/msg/getblocks",
        "net/send/msg/getblocktxn",
        "net/send/msg/getdata",
        "net/send/msg/getheaders",
        "net/send/msg/grblk",
        "net/send/msg/grblktx",
        "net/send/msg/headers",
        "net/send/msg/inv",
        "net/send/msg/mempool",
        "net/send/msg/merkleblock",
        "net/send/msg/notfound",
        "net/send/msg/ping",
        "net/send/msg/pong",
        "net/send/msg/reject",
        "net/send/msg/req_xpedited",
        "net/send/msg/sendcmpct",
        "net/send/msg/sendheaders",
        "net/send/msg/thinblock",
        "net/send/msg/tx",
        "net/send/msg/verack",
        "net/send/msg/version",
        "net/send/msg/xblocktx",
        "net/send/msg/xthinblock",
        "net/send/msg/xupdate",
        "net/send/msg/xverack",
        "net/send/msg/xversion",
        "net/send/total",
        "node/ip121.28.160.158p63335/blocksSent",
        "node/ip121.28.160.158p63335/bytesReceived",
        "node/ip121.28.160.158p63335/bytesSent",
        "node/ip121.28.160.158p63335/firstBlock",
        "node/ip121.28.160.158p63335/firstTx",
        "node/ip121.28.160.158p63335/recvGap",
        "node/ip121.28.160.158p63335/sendGap",
        "node/ip121.28.160.158p63335/txLatency",
        "node/ip121.28.160.158p63335/txsSent",
        "node/ip124.236.118.112p63335/blocksSent",
        "node/ip124.236.118.112p63335/bytesReceived",
        "node/ip124.236.118.112p63335/bytesSent",
        "node/ip124.236.118.112p63335/firstBlock",
        "node/ip124.236.118.112p63335/firstTx",
        "node/ip124.236.118.112p63335/recvGap",
        "node/ip124.236.118.112p63335/sendGap",
        "node/ip124.236.118.112p63335/txLatency",
        "node/ip124.236.118.112p63335/txsSent",
        "node/ip127.0.0.1p0/blocksSent",
        "node/ip127.0.0.1p0/bytesReceived",
        "node/ip127.0.0.1p0/bytesSent",
        "node/ip127.0.0.1p0/firstBlock",
        "node/ip127.0.0.1p0/firstTx",
        "node/ip127.0.0.1p0/recvGap",
        "node/ip127.0.0.1p0/sendGap",
        "node/ip127.0.0.1p0/txLatency",
        "node/ip127.0.0.1p0/txsSent",
        "node/ip194.33.38.214p63335/blocksSent",
        "node/ip194.33.38.214p63335/bytesReceived",
        "node/ip194.33.38.214p63335/bytesSent",
        "node/ip194.33.38.214p63335/firstBlock",
        "node/ip194.33.38.214p63335/firstTx",
        "node/ip194.33.38.214p63335/recvGap",
        "node/ip194.33.38.214p63335/sendGap",
        "node/ip194.33.38.214p63335/txLatency",
        "node/ip194.33.38.214p63335/txsSent",
        "node/ip205.185.120.91p63335/blocksSent",
        "node/ip205.185.120.91p63335/bytesReceived",
        "node/ip205.185.120.91p63335/bytesSent",
        "node/ip205.185.120.91p63335/firstBlock",
        "node/ip205.185.120.91p63335/firstTx",
        "node/ip205.185.120.91p63335/recvGap",
        "node/ip205.185.120.91p63335/sendGap",
        "node/ip205.185.120.91p63335/txLatency",
        "node/ip205.185.120.91p63335/txsSent",
        "node/ip27.102.134.180p63335/blocksSent",
        "node/ip27.102.134.180p63335/bytesReceived",
        "node/ip27.102.134.180p63335/bytesSent",
        "node/ip27.102.134.180p63335/firstBlock",
        "node/ip27.102.134.180p63335/firstTx",
        "node/ip27.102.134.180p63335/recvGap",
        "node/ip27.102.134.180p63335/sendGap",
        "node/ip27.102.134.180p63335/txLatency",
        "node/ip27.102.134.180p63335/txsSent",
        "node/ip27.102.134.181p63335/blocksSent",
        "node/ip27.102.134.181p63335/bytesReceived",
        "node/ip27.102.134.181p63335/bytesSent",
        "node/ip27.102.134.181p63335/firstBlock",
        "node/ip27.102.134.181p63335/firstTx",
        "node/ip27.102.134.181p63335/recvGap",
        "node/ip27.102.134.181p63335/sendGap",
        "node/ip27.102.134.181p63335/txLatency",
        "node/ip27.102.134.181p63335/txsSent",
        "node/ip47.91.209.206p63335/blocksSent",
        "node/ip47.91.209.206p63335/bytesReceived",
        "node/ip47.91.209.206p63335/bytesSent",
        "node/ip47.91.209.206p63335/firstBlock",
        "node/ip47.91.209.206p63335/firstTx",
        "node/ip47.91.209.206p63335/recvGap",
        "node/ip47.91.209.206p63335/sendGap",
        "node/ip47.91.209.206p63335/txLatency",
        "node/ip47.91.209.206p63335/txsSent",
        "reqMgr/dropped",
        "reqMgr/inFlight",
        "reqMgr/pending",
        "reqMgr/received",
        "reqMgr/rejected",
        "txValidationTime"
    ],
    "error": null,
    "id": "1"
}

log "category|all" "on|off"

  • Request parameter
  • category|all:All or some category
  • on|off
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "log",
        "params": ["NET", "off"]
    }
    
  • Response:
    {
        "result": "",
        "error": null,
        "id": "1"
    }
    

logline 'string'

  • Request parameter
  • string:Required, log information
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "logline",
        "params": ["this is a test"]
    }
    
  • Response:
    {
        "result": null,
        "error": null,
        "id": "1"
    }
    

set

Corresponding to the get method, setting configuration information. - Request parameter - <configuration setting name>=<value>:Required, key-value pairs for configuration and values - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "set",
    "params": ["blockchain.checkScriptDays=20", "consensus.maxScriptOps=202"]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

validateaddress "diskcoinaddress"

Return the corresponding information of the Diskcoin address - Request parameter - diskcoinaddress:Required, Diskcoin address to be verified - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "validateaddress",
    "params": ["1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy"]
}
- Response:
{
    "result": {
        "isvalid": true,
        "address": "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
        "scriptPubKey": "76a914732c899c33b2354bd824758e37bfca00cae7be6788ac",
        "ismine": true,
        "iswatchonly": false,
        "isscript": false,
        "pubkey": "03bbcab6f50f0010db37e2d1a74ef6807f722b59c8e62736df1d47b06b5f30393c",
        "iscompressed": true,
        "account": ""
    },
    "error": null,
    "id": "1"
}

validatechainhistory [hash]

  • Request parameter
  • hash:Required, block hash value
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "validatechainhistory",
        "params": ["6e46a54a4ddcb2640796787570f97210daf1f896a38693ecd6c67d49bfb61619"]
    }
    
  • Response:
    {
        "result": "Chain is ok",
        "error": null,
        "id": "1"
    }
    

verifymessage "diskcoinaddress" "signature" "message"

Verify a signed message generated by signmessage - Request parameter - diskcoinaddress:Required, Diskcoin address - signature:Required, signature - message:Required, information to be signed - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "verifymessage",
    "params": ["1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy", "IOMuqLnoFIVWUF94WaAKexX7lj6y09TxmJ09AMgKCsumYJiCK4psvegPIHZJWDKhPAzSTCoj/FkhdA0PN7GptJ8=", "my message"]
}
- Response:
{
    "result": true,
    "error": null,
    "id": "1"
}

Wallet

abandontransaction "txid"

Mark the transaction in the wallet as abandoned, how to find a transaction that meets the criteria? - Request parameter - txid:Required, transaction ID - Request:


- Response:

addmultisigaddress nrequired ["key",...] ("account")

  • Request parameter
  • nrequired:Required, the number of signatures
  • keysboject:Required, Diskcoin address or public key
    [
        "address",
        ...
    ]
    
  • account:Optional parameters
  • Request:
    
    
  • Response:
    
    

backupwallet "destination"

Backup wallet -Request parameter - destination:Required, destination folder or file - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "backupwallet",
    "params": ["backup.dat"]
}
- Response: Will generate a backup.data file in the corresponding path.
{
    "result": null,
    "error": null,
    "id": "1"
}

dumpprivkey "diskcoinaddress"

Return the private key corresponding to the address. - Request parameter - diskcoinaddress:Required, the Diskcoin address corresponding to the private key - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "dumpprivkey",
    "params": ["1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy"]
}
- Response: Return a private key value
{
    "result": "L2gBf1aQTmTBWDm2372tXHuPnEuAyS3G5bL1X7mWQgNTdhNpLr6B",
    "error": null,
    "id": "1"
}

dumpwallet "filename"

  • Request parameter
  • filename:Required, file path
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "dumpwallet",
        "params": ["test"]
    }
    
  • Response: Will generate a test file in the corresponding path
    {
        "result": null,
        "error": null,
        "id": "1"
    }
    

encryptwallet "passphrase"

Encrypt the wallet with the specified password, this command will close the wallet service - Request parameter - passphrase:Required, encrypted wallet key - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "encryptwallet",
    "params": ["my pass phrase"]
}
- Response:
{
    "result": "wallet encrypted; Diskcoin server stopping, restart to run with encrypted wallet. The keypool has been flushed and a new HD seed was generated (if you are using HD). You need to make a new backup.",
    "error": null,
    "id": "1"
}

getaccount "diskcoinaddress"

Return the account bound to the given address - Request parameter - diskcoinaddress:Required, Diskcoin address - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getaccount",
    "params": ["1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy"]
}
- Response:
{
    "result": "",
    "error": null,
    "id": "1"
}

getaccountaddress "account"

Get the current receipt address of the account. - Request parameter - account:Required, account name, can be set to "" to indicate the default account - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getaccountaddress",
    "params": [""]
}
- Response:
{
    "result": "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
    "error": null,
    "id": "1"
}

getaddressesbyaccount "account"

Get all the addresses of the account. - Request parameter - account:Required, account name - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getaddressesbyaccount",
    "params": [""]
}
- Response: Return a list of Diskcoin addresses associated with the account
{
    "result": [
        "1DU8fmXyrbTtRjxKvKu63nDL1hLZH5bRin",
        "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
        "1PdPq6rXijjDtHdPyewcdi6aVvQDteCPto",
        "1BdpB1ptShqGwGuyn3BJ9Dy4ixoWRpwoqy"
    ],
    "error": null,
    "id": "1"
}

getbalance ("account" minconf includeWatchonly)

Get the account balance. - Request parameter - account:Optional parameters, selected account, "*" for the entire wallet, "" for the default account - minconf:Optional parameter, default is 1, the number of confirmations that need to be met - includeWatchonly:Optional parameter, default is false - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getbalance",
    "params": ["*", 5]
}
- Response:
{
    "result": 0.5,
    "error": null,
    "id": "1"
}

getnewaddress ("account")

Generate a new receipt address for the account. - Request parameter - account:Optional parameters, the default account is "" - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getnewaddress",
    "params": []
}
- Response:
{
    "result": "1DU8fmXyrbTtRjxKvKu63nDL1hLZH5bRin",
    "error": null,
    "id": "1"
}

getrawchangeaddress

Return a new address for raw transactions, not commonly used. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getrawchangeaddress",
    "params": []
}
- Response:
{
    "result": "12hSQ349p3yU1gaFqch1t8pazNbJzJaM2f",
    "error": null,
    "id": "1"
}

getreceivedbyaccount "account" (minconf)

  • Request parameter
  • account:Required, default is ""
  • minconf:Optional parameter, default is 1, the number of confirmations of the transaction
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "getreceivedbyaccount",
        "params": [""]
    }
    
  • Response:
    {
        "result": 0.5,
        "error": null,
        "id": "1"
    }
    

getreceivedbyaddress "diskcoinaddress" (minconf)

  • Request parameter
  • diskcoinaddress:Required, the Diskcoin address of the transaction
  • minconf:Optional parameter, default is 1, the number of confirmations of the transaction
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "getreceivedbyaddress",
        "params": ["1PdPq6rXijjDtHdPyewcdi6aVvQDteCPto"]
    }
    
  • Response:
    {
        "result": 0,
        "error": null,
        "id": "1"
    }
    

gettransaction "txid" (includeWatchonly)

Get details of a transaction in wallet - Request parameter - txid:Required, transaction ID - includeWatchonly:Optional parameter, default is false - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "gettransaction",
    "params": ["53fac9b470e646c472948721552214b27bc75e9a0e19265acb5b53d8c7d51c0f"]
}
- Response:
{
    "result": {
        "satoshi": 50000000,
        "amount": 0.5,
        "confirmations": 62,
        "blockhash": "5c46d6c84f11fa3730ae82497ae1e26a230f99e561b231a0b3ee4ef0921599f2",
        "blockindex": 2,
        "blocktime": 1563347295,
        "txid": "53fac9b470e646c472948721552214b27bc75e9a0e19265acb5b53d8c7d51c0f",
        "walletconflicts": [],
        "time": 1563346822,
        "timereceived": 1563346822,
        "details": [
            {
                "account": "",
                "address": "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
                "category": "receive",
                "satoshi": 50000000,
                "amount": 0.5,
                "label": "",
                "vout": 1
            }
        ],
        "hex": "0100000001a8b39257eb3fd0ca72675693b137699f26b9dcdf947b77f43ac84c354feeec71010000004847304402200b8862001cf3d0b9b8e259b28a027c4f680f09f88e87d287b74716cd0a535244022035b35d054300ce19a031d35e36dee9a7c78da13193255096ff320c362dde273941feffffff029756a633000000001976a914e156d8f45865a44cc689b4ac5b63d0534be15f2188ac80f0fa02000000001976a914732c899c33b2354bd824758e37bfca00cae7be6788ac4d080000"
    },
    "error": null,
    "id": "1"
}

getunconfirmedbalance

Get all unconfirmed balances for the server. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getunconfirmedbalance",
    "params": []
}
- Response:
{
    "result": 0.5,
    "error": null,
    "id": "1"
}

getwalletinfo

Get status information about the wallet. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "getwalletinfo",
    "params": []
}
- Response:
{
    "result": {
        "walletversion": 60000,
        "balance": 0,
        "unconfirmed_balance": 0.5,
        "immature_balance": 0,
        "txcount": 1,
        "keypoololdest": 1563271172,
        "keypoolsize": 10001,
        "unlocked_until": 0,
        "paytxfee": 0
    },
    "error": null,
    "id": "1"
}

importaddress "address" ("label" rescan p2sh)

  • Request parameter
  • address:Required, Hexadecimal script or address
  • lable:Optional parameter, default is ""
  • rescan:Optional parameter, default is true, whether to scan the wallet transaction
  • p2sh:Optional parameter, default is false, whether to add P2SH
  • Request:
    
    
  • Response:
    
    

importaddresses [rescan | no-rescan] "address"...

  • Request parameter
  • address:Required
  • rescan|no-rescan:Optional parameter
  • Request:
    
    
  • Response:
    
    

importprivatekeys [rescan | no-rescan] "diskcoinprivatekey"...

Add private key to the wallet - Request parameter - rescan|no-rescan:Optioanl parameter, default is rescan - diskcoinprivatekey:Required, private key (Refer to dumpprivkey) - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "importprivatekeys",
    "params": ["no-rescan", "L2gBf1aQTmTBWDm2372tXHuPnEuAyS3G5bL1X7mWQgNTdhNpLr6B"]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

importprivkey "diskcoinprivkey" ("label" rescan)

  • Request parameter
  • diskcoinprivatekey:Required, private key (Refer to dumpprivkey)
  • label:Optioanl parameter, default is ""
  • rescan:Optioanl parameter, default is true
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "importprivkey",
        "params": ["L2gBf1aQTmTBWDm2372tXHuPnEuAyS3G5bL1X7mWQgNTdhNpLr6B", "my label", false]
    }
    
  • Response:
    {
        "result": null,
        "error": null,
        "id": "1"
    }
    

importpubkey "pubkey" ("label" rescan)

  • Request parameter
  • pubkey: Public key
  • label:Optioanl parameter, default is ""
  • rescan:Optioanl parameter, default is true
  • Request:
    
    
  • Response:
    
    

importwallet "filename"

  • Request parameter
  • filename:Required, wallet file
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "importwallet",
        "params": ["test"]
    }
    
  • Response:
    {
        "result": null,
        "error": null,
        "id": "1"
    }
    

keypoolrefill (newsize)

  • Request parameter
  • newsize:Optional parameter, default is 100, new keypool size
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "keypoolrefill",
        "params": [10000]
    }
    
  • Response:
    {
        "result": null,
        "error": null,
        "id": "1"
    }
    

listaccounts (minconf includeWatchonly)

List all account information - Request parameter - minconf:Optional parameter, the default is 1, the transaction that confirms the times - includeWatchonly:Optional parameter, default is false - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "listaccounts",
    "params": []
}
- Response:
{
    "result": {
        "": 0,
        "my label": 0.5
    },
    "error": null,
    "id": "1"
}

listaddressgroupings

  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "listaddressgroupings",
        "params": []
    }
    
  • Response:
    {
        "result": [
            [
                [
                    "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
                    0.5,
                    "my label"
                ]
            ]
        ],
        "error": null,
        "id": "1"
    }
    

validatechainhistory

  • Request parameter
  • hash:Required, the block hash value
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "validatechainhistory",
        "params": []
    }
    
  • Response:
    {
        "result": "Chain is ok",
        "error": null,
        "id": "1"
    }
    

listlockunspent

  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "listlockunspent",
        "params": []
    }
    
  • Response:
    {
        "result": [],
        "error": null,
        "id": "1"
    }
    

listminedblock (minconf maxconf ["address",...])

  • Request parameter
  • minconf:Optional parameter, default is 1
  • maxconf:Optional parameter, default is 9999999
  • addresses:Address list
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "listminedblock",
        "params": [1, 5]
    }
    
  • Response:
    {
        "result": [],
        "error": null,
        "id": "1"
    }
    

liststake ( inconf maxconf ["address",...]

  • Request parameter
  • minconf:Optional parameter, default is 1
  • maxconf:Optional parameter, default is 9999999
  • addresses:Address list
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "liststake",
        "params": [1, 9999, ["1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy"]]
    }
    
  • Response:
    {
        "result": [],
        "error": null,
        "id": "1"
    }
    

listunstake ( inconf maxconf ["address",...]

  • Request parameter
  • minconf:Optional parameter, default is 1
  • maxconf:Optional parameter, default is 9999999
  • addresses:Address list
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "listunstake",
        "params": [1, 9999, ["1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy"]]
    }
    
  • Response:
    {
        "result": [],
        "error": null,
        "id": "1"
    }
    

listreceivedbyaccount (minconf includeempty includeWatchonly)

  • Request parameter
  • minconf:Optional parameter, default is 1
  • includeempty:Optional parameter, default is false, whether it contains an account without any payment
  • includeWatchonly:Optional parameter, defaults to false, contains watchonly address (see importaddress)
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "listreceivedbyaccount",
        "params": [1, true]
    }
    
  • Response:
    {
        "result": [
            {
                "account": "",
                "satoshi": 0,
                "amount": 0,
                "confirmations": 0
            },
            {
                "account": "my label",
                "satoshi": 50000000,
                "amount": 0.5,
                "confirmations": 66
            }
        ],
        "error": null,
        "id": "1"
    }
    

listreceivedbyaddress (minconf includeempty includeWatchonly)

  • Request parameter
  • minconf:Optional parameter, default is 1
  • includeempty:Optional parameter, default is false, whether it contains an account without any payment
  • includeWatchonly:Optional parameter, default is false, whether contains watchonly address (refer to importaddress)
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "listreceivedbyaddress",
        "params": [1, true]
    }
    
  • Response:
    {
        "result": [
            {
                "address": "1DU8fmXyrbTtRjxKvKu63nDL1hLZH5bRin",
                "account": "",
                "satoshi": 0,
                "amount": 0,
                "confirmations": 0,
                "label": "",
                "txids": []
            },
            {
                "address": "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
                "account": "my label",
                "satoshi": 50000000,
                "amount": 0.5,
                "confirmations": 66,
                "label": "my label",
                "txids": [
                    "53fac9b470e646c472948721552214b27bc75e9a0e19265acb5b53d8c7d51c0f"
                ]
            },
            {
                "address": "1PdPq6rXijjDtHdPyewcdi6aVvQDteCPto",
                "account": "",
                "satoshi": 0,
                "amount": 0,
                "confirmations": 0,
                "label": "",
                "txids": []
            },
            {
                "address": "1BdpB1ptShqGwGuyn3BJ9Dy4ixoWRpwoqy",
                "account": "",
                "satoshi": 0,
                "amount": 0,
                "confirmations": 0,
                "label": "",
                "txids": []
            }
        ],
        "error": null,
        "id": "1"
    }
    

listsinceblock ("blockhash" target-confirmations includeWatchonly)

  • Request parameter
  • blockhash:Optional parameter, block hash
  • target-confirmations:Optional parameter, confirmation number, greater than or equal to 1
  • includeWatchonly:Optional parameter, default is false, whether contains watchonly address (refer to importaddress)
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "listsinceblock",
        "params": []
    }
    
  • Response:
    {
        "result": {
            "transactions": [
                {
                    "account": "my label",
                    "address": "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
                    "category": "receive",
                    "satoshi": 50000000,
                    "amount": 0.5,
                    "label": "my label",
                    "vout": 1,
                    "confirmations": 66,
                    "blockhash": "5c46d6c84f11fa3730ae82497ae1e26a230f99e561b231a0b3ee4ef0921599f2",
                    "blockindex": 2,
                    "blocktime": 1563347295,
                    "txid": "53fac9b470e646c472948721552214b27bc75e9a0e19265acb5b53d8c7d51c0f",
                    "walletconflicts": [],
                    "time": 1563346822,
                    "timereceived": 1563346822
                }
            ],
            "lastblock": "6e6d1c2b0539650d9937691d8dd431c65595a4d7c3229b4f47dd4f786defe3f5"
        },
        "error": null,
        "id": "1"
    }
    

listtransactions ("account" count from includeWatchonly)

List the transaction information of the account - Request parameter - account:Optional parameter, account name, must be "*"? - count:Optional parameter, default is 10, the number of transactions - from:Optional parameter, default is 0, the number of transactions that need to be skipped - includeWatchonly:Optional parameter, default is false, whether contains watchonly address (refer to importaddress) - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "listtransactions",
    "params": ["*", 10]
}
- Response:
{
    "result": [
        {
            "account": "my label",
            "address": "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
            "category": "receive",
            "satoshi": 50000000,
            "amount": 0.5,
            "label": "my label",
            "vout": 1,
            "confirmations": 66,
            "blockhash": "5c46d6c84f11fa3730ae82497ae1e26a230f99e561b231a0b3ee4ef0921599f2",
            "blockindex": 2,
            "blocktime": 1563347295,
            "txid": "53fac9b470e646c472948721552214b27bc75e9a0e19265acb5b53d8c7d51c0f",
            "walletconflicts": [],
            "time": 1563346822,
            "timereceived": 1563346822
        }
    ],
    "error": null,
    "id": "1"
}

listtransactionsfrom ("account" count from includeWatchonly)

List the transaction information of the account - Request parameter - account:Optional parameter, account name, default is "" - count:Optional parameter, default is 10, the number of transactions - from:Optional parameter, default is 0, the number of transactions that need to be skipped - includeWatchonly:Optional parameter, default is false, whether contains watchonly address (refer to importaddress) - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "listtransactionsfrom",
    "params": ["*", 10, 0]
}
- Response:
{
    "result": [
        {
            "account": "my label",
            "address": "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
            "category": "receive",
            "satoshi": 50000000,
            "amount": 0.5,
            "label": "my label",
            "vout": 1,
            "confirmations": 66,
            "blockhash": "5c46d6c84f11fa3730ae82497ae1e26a230f99e561b231a0b3ee4ef0921599f2",
            "blockindex": 2,
            "blocktime": 1563347295,
            "txid": "53fac9b470e646c472948721552214b27bc75e9a0e19265acb5b53d8c7d51c0f",
            "walletconflicts": [],
            "time": 1563346822,
            "timereceived": 1563346822
        }
    ],
    "error": null,
    "id": "1"
}

listunspent (minconf maxconf ["address",...])

  • Request parameter
  • minconf:Optional parameter, default is 1
  • maxconf:Optional parameter, default is 9999999
  • addresses:Address list
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "listunspent",
        "params": []
    }
    
  • Response:
    {
        "result": [
            {
                "txid": "53fac9b470e646c472948721552214b27bc75e9a0e19265acb5b53d8c7d51c0f",
                "vout": 1,
                "address": "1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy",
                "account": "my label",
                "scriptPubKey": "76a914732c899c33b2354bd824758e37bfca00cae7be6788ac",
                "satoshi": 50000000,
                "amount": 0.5,
                "confirmations": 66,
                "spendable": true
            }
        ],
        "error": null,
        "id": "1"
    }
    

lockunspent unlock [{"txid":"txid","vout":n},...]

  • Request parameter
  • unlock:Required, true means unlock, false means lock
  • transactions:Required, the structure is as follows
    [
        {
            "txid": "id",
            "vout": n
        },
        ...
    ]
    
  • Request:
    
    
  • Response:
    
    

move "fromaccount" "toaccount" amount (minconf "comment")

Transfer currency between accounts - Request parameter - fromaccount:Required, source account - toaccount:Required, destination account - amount:Transfer amount - minconf:Optional parameter, default is 1, confirmation number - comment:Optional parameters, comment information - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "move",
    "params": ["my label", "", 0.1, 1, "Transfer 0.1 from my label to default account"]
}
- Response:
{
    "result": true,
    "error": null,
    "id": "1"
}

staketo "diskcoinaddress" amount

Stake to the specified address - Request parameter - diskcoinaddress:Required, Diskcoin address - amount:Required, Staking amount - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "staketo",
    "params": ["1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy", 0.1]
}
- Response: The return value is the transaction ID
{
    "result": "522fa001190e4d5cdec0f3bead4dd0987dc5b80481b4d24585f99538115177e9",
    "error": null,
    "id": "1"
}

removeprunedfunds "txid"

Remove a transaction from wallet - Request parameter - txid:Required, transaction ID - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "removeprunedfunds",
    "params": ["522fa001190e4d5cdec0f3bead4dd0987dc5b80481b4d24585f99538115177e9"]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

sendfrom "fromaccount" "todiskcoinaddress" amount (minconf "comment" "comment-to")

To transfer currency from the account to the specified address, you need to set passphrase with walletpassphrase - Request parameter - fromaccount:Required, source account - toDISCaddress:Required, destination address - amount:Required, transfer amount - minconf:Optional parameter, default is 1, confirmation number - comment:Optional parameter, comment, not part of the transaction, only in the wallet - comment-to:Optional parameter, save the name or organization name of the object that sent the transaction - Request:


- Response:

sendmany "fromaccount" {"address":amount,...} (minconf "comment" ["address",...])

  • Request parameter
  • fromaccount:Required, source account
  • amount:Required, destination address and quantity
    {
        "address": amount,
        ...
    }
    
  • minconf:Optional parameter, default is 1, the number of confirmations that the balance must be met
  • comment:Optional parameters, comments, not part of the transaction, only in the wallet
  • subtractfeefromamount:Optional parameter, address list
  • Request:
    
    
  • Response:
    
    

sendtoaddress "diskcoinaddress" amount ("comment" "comment-to" subtractfeefromamount)

  • Request parameter:
  • diskcoinaddress:Required, destination address
  • amount:Required, the quantity that needs to be sent
  • comment:Optional parameters, comments, not part of the transaction, only in the wallet
  • comment-to:Optional parameter, save the name or organization name of the object that sent the transaction
  • subtractfeefromamount:Optional parameter, default is false
  • Request:
    
    
  • Response:
    
    

setaccount "diskcoinaddress" "account"

Associate an account with an address - Request parameter - diskcoinaddress:Required, Diskcoin address - account:equired, account to be linked - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "setaccount",
    "params": ["1BdpB1ptShqGwGuyn3BJ9Dy4ixoWRpwoqy", ""]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

settxfee amount

Set transaction fee - Request parameter - amount:Required, transaction fee. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "settxfee",
    "params": [0.1]
}
- Response:
{
    "result": true,
    "error": null,
    "id": "1"
}

signdata "diskcoinaddress" "msgFormat" "message"

  • Request parameter
  • diskcoinaddress:Required, Diskcoin address
  • msgFormat:Required, string, hex or hash
  • message:Required, create information for signature
  • verbose:Optional parameter, return some additional information
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "signdata",
        "params": ["1BdpB1ptShqGwGuyn3BJ9Dy4ixoWRpwoqy", "string", "my message", "verbose"]
    }
    
  • Response: Return value is signature information
    {
        "result": {
            "msghash": "ab1bdba540c9da66a96c42de0ab6a3466601145ba8eb216c7e7d76750fe338ea",
            "signature": "3045022100F26EFF47D090F956E1CC5A112702F358D1BF2EAD0FCCD978EA44A643E9D08BBF0220460CA6A6FB265009A4A2F5A4B97361FACB9226EDDEC4DC67EA5B8DE220385DBA",
            "pubkeyhash": "c54707cb3102df4c7a5345530fcfe70d379ca774",
            "pubkey": "03D8B4CE80F25A9EB8BF94D6CB49F017E9ED66D0C70E0486E134D0ED0C81B0EC9F"
        },
        "error": null,
        "id": "1"
    }
    

signmessage "diskcoinaddress" "message"

To sign the information with the private key of the address, need to set passphrase with walletpassphrase - Request parameter - diskcoinaddress:Required, Diskcoin address - message:Required, create information for signature - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "signmessage",
    "params": ["1BVz4apEjytvTKCHUU9TANQye1m7MCqZsy", "my message"]
}
- Response: The return value is the signature of the information
{
    "result": "IOMuqLnoFIVWUF94WaAKexX7lj6y09TxmJ09AMgKCsumYJiCK4psvegPIHZJWDKhPAzSTCoj/FkhdA0PN7GptJ8=",
    "error": null,
    "id": "1"
}

unstake txid

Cancel the staking, the stake command returns a value of txid - Request parameter - Required, transaction ID - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "unstake",
    "params": ["522fa001190e4d5cdec0f3bead4dd0987dc5b80481b4d24585f99538115177e9"]
}
- Response: The return value is the transaction ID
{
    "result": "fca427c96520435f4c9340b7bb116fd9e75bd91627a15c48246d80e187347fcc",
    "error": null,
    "id": "1"
}

walletlock

Remove the private key from memory and lock the wallet. If there is a method call that needs to be unlocked, need to call the walletpassphrase method first. - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "walletlock",
    "params": []
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

walletpassphrase "passphrase" timeout

Store the wallet private key in memory and set the store time. This is a precondition for making a transaction related to a private key. - Request parameter - passphrase:Required, the passphrase of wallet - timeout:Required, the time the provate key stores in memory - Request:

{
    "jsonrpc": "1.0",
    "id": "1",
    "method": "walletpassphrase",
    "params": ["my pass phrase", 120]
}
- Response:
{
    "result": null,
    "error": null,
    "id": "1"
}

walletpassphrasechange "oldpassphrase" "newpassphrase"

  • Request parameter
  • oldpassphrase:Required, current passphrase
  • newpassphrase:Required, new passphrase
  • Request:
    {
        "jsonrpc": "1.0",
        "id": "1",
        "method": "walletpassphrasechange",
        "params": ["my pass phrase", "new pass phrase"]
    }
    
  • Response:
    {
        "result": null,
        "error": null,
        "id": "1"
    }