Skip to content

Commit

Permalink
Merge pull request #470 from AntelopeIO/cleos_get_finalizer_info
Browse files Browse the repository at this point in the history
Add CLEOS support for get_finalizer_info RPC endpoint
  • Loading branch information
linh2931 authored Aug 5, 2024
2 parents d952b77 + bbadb92 commit b8fb378
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions programs/cleos/httpc.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ namespace eosio { namespace client { namespace http {
const string get_raw_code_and_abi_func = chain_func_base + "/get_raw_code_and_abi";
const string get_currency_balance_func = chain_func_base + "/get_currency_balance";
const string get_currency_stats_func = chain_func_base + "/get_currency_stats";
const string get_finalizer_info_func = chain_func_base + "/get_finalizer_info";
const string get_producers_func = chain_func_base + "/get_producers";
const string get_schedule_func = chain_func_base + "/get_producer_schedule";
const string get_required_keys = chain_func_base + "/get_required_keys";
Expand Down
5 changes: 5 additions & 0 deletions programs/cleos/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2988,6 +2988,11 @@ int main( int argc, char** argv ) {
std::cout << fc::json::to_pretty_string(get_info()) << std::endl;
});

// get finalizer info
get->add_subcommand("finalizer_info", localized("Get current finalizer information"))->callback([] {
std::cout << fc::json::to_pretty_string(call(get_finalizer_info_func, fc::mutable_variant_object())) << std::endl;
});

// get transaction status
string status_transaction_id;
auto getTransactionStatus = get->add_subcommand("transaction-status", localized("Get transaction status information"));
Expand Down

0 comments on commit b8fb378

Please sign in to comment.