| 17 | #include <stdexcept> |
| 18 | |
| 19 | static RPCHelpMan rpcNestedTest_rpc() |
| 20 | { |
| 21 | return RPCHelpMan{ |
| 22 | "rpcNestedTest", |
| 23 | "echo the passed string(s)", |
| 24 | { |
| 25 | {"arg1", RPCArg::Type::STR, RPCArg::Optional::OMITTED, ""}, |
| 26 | {"arg2", RPCArg::Type::STR, RPCArg::Optional::OMITTED, ""}, |
| 27 | {"arg3", RPCArg::Type::STR, RPCArg::Optional::OMITTED, ""}, |
| 28 | }, |
| 29 | RPCResult{RPCResult::Type::ANY, "", ""}, |
| 30 | RPCExamples{""}, |
| 31 | [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue { |
| 32 | return request.params.write(0, 0); |
| 33 | }, |
| 34 | }; |
| 35 | } |
| 36 | |
| 37 | static const CRPCCommand vRPCCommands[] = { |
| 38 | {"rpcNestedTest", &rpcNestedTest_rpc}, |