How to query the nonce of an account

How to query the nonce of an account?
Similar to eth’s eth_getTransactionCount

The node exposes the account nonce over this interface:
https://developer.concordium.software/concordium-grpc-api/#concordium.v2.NextAccountSequenceNumber

Depending on if you are using a specific SDK, this functionality is usually exposed e.g.:

    let nonce = node_client
        .get_next_account_sequence_number(&keys.address)
        .await
        .context("Could not query the account nonce.")?
        .nonce;
1 Like