How to encode () type for candid in rust?

I am communicating with my canister using ic-agent and rust and candid. And i have a query method balance, it has the type: balance : () -> (nat) query;, so how can i encode and pass the () parameter to the function in rust?

Related:
Calling canisters without an argument requires a candid-bytes with no values? - Developers - Internet Computer Developer Forum (dfinity.org)

candid::encode_args(()) with the empty tuple.

1 Like