Skip to content

Commit

Permalink
added /wapi/chain/info
Browse files Browse the repository at this point in the history
  • Loading branch information
madMAx43v3r committed Oct 2, 2024
1 parent bf45d67 commit 25947a6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/WebAPI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1178,6 +1178,9 @@ void WebAPI::http_request_async(std::shared_ptr<const vnx::addons::HttpRequest>
((WebAPI*)this)->shutdown();
respond_status(request_id, 200);
}
else if(sub_path == "/chain/info") {
respond(request_id, render(params));
}
else if(sub_path == "/node/info") {
node->get_network_info(
[this, request_id](std::shared_ptr<const NetworkInfo> info) {
Expand Down Expand Up @@ -2731,7 +2734,7 @@ void WebAPI::http_request_async(std::shared_ptr<const vnx::addons::HttpRequest>
}
else {
std::vector<std::string> options = {
"config/get", "config/set", "farmer", "farmers",
"config/get", "config/set", "farmer", "farmers", "chain/info",
"node/info", "node/log", "header", "headers", "block", "blocks", "transaction", "transactions", "address", "contract",
"address/history", "wallet/balance", "wallet/contracts", "wallet/address"
"wallet/history", "wallet/history/memo", "wallet/send", "wallet/send_many", "wallet/send_off",
Expand Down

0 comments on commit 25947a6

Please sign in to comment.