Skip to content

Commit fe8e8ef

Browse files
committed
[rpc] Add incremental relay fee to getnetworkinfo
1 parent 6b331e6 commit fe8e8ef

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/rpc/net.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
#include "net.h"
1111
#include "net_processing.h"
1212
#include "netbase.h"
13+
#include "policy/policy.h"
1314
#include "protocol.h"
1415
#include "sync.h"
1516
#include "timedata.h"
@@ -417,6 +418,7 @@ UniValue getnetworkinfo(const JSONRPCRequest& request)
417418
" ,...\n"
418419
" ],\n"
419420
" \"relayfee\": x.xxxxxxxx, (numeric) minimum relay fee for non-free transactions in " + CURRENCY_UNIT + "/kB\n"
421+
" \"incrementalfee\": x.xxxxxxxx, (numeric) minimum fee increment for mempool limiting or BIP 125 replacement in " + CURRENCY_UNIT + "/kB\n"
420422
" \"localaddresses\": [ (array) list of local addresses\n"
421423
" {\n"
422424
" \"address\": \"xxxx\", (string) network address\n"
@@ -447,6 +449,7 @@ UniValue getnetworkinfo(const JSONRPCRequest& request)
447449
}
448450
obj.push_back(Pair("networks", GetNetworksInfo()));
449451
obj.push_back(Pair("relayfee", ValueFromAmount(::minRelayTxFee.GetFeePerK())));
452+
obj.push_back(Pair("incrementalfee", ValueFromAmount(::incrementalRelayFee.GetFeePerK())));
450453
UniValue localAddresses(UniValue::VARR);
451454
{
452455
LOCK(cs_mapLocalHost);

src/wallet/rpcwallet.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2652,8 +2652,8 @@ UniValue bumpfee(const JSONRPCRequest& request)
26522652
"By default, the new fee will be calculated automatically using estimatefee.\n"
26532653
"The user can specify a confirmation target for estimatefee.\n"
26542654
"Alternatively, the user can specify totalFee, or use RPC setpaytxfee to set a higher fee rate.\n"
2655-
"At a minimum, the new fee rate must be high enough to pay a new relay fee over the original fee\n"
2656-
"to enter the node's mempool.\n"
2655+
"At a minimum, the new fee rate must be high enough to pay an additional new relay fee (incrementalfee\n"
2656+
"returned by getnetworkinfo) to enter the node's mempool.\n"
26572657
"\nArguments:\n"
26582658
"1. txid (string, required) The txid to be bumped\n"
26592659
"2. options (object, optional)\n"

0 commit comments

Comments
 (0)