Node api try-run Can the method support a specified height query?

Can the try-run method be supported with a specified height query?
Because there’s some old data that needs to be queried

It’s up to you again :grinning:

The answer is yes - you can specify the block hash on top of which you want to dry-run the transaction. So you will have to translate height into a (key) block hash.

How do you call it directly in a node?
No method was found to pass a hash to a node

Or some other way? I don’t quite understand :sob:

1 Like

Did you click it? There should be an example?!

The endpoint takes a JSON record with three fields, one of them is top if I remember correctly. So if you’d like to run on top of kh_abc123.... then you just say so ({"top": "kh_abc123...", ...}).


A: I see. Thank you :grin:

1 Like

Still not quite OK, after the specified tell will report an error

Data can be retrieved if the latest block is not set or specified

The Tx has to be valid (i.e. the nonce has to be correct, etc) at that block. So probably that nonce isn’t the next one at 399061 but is at 400061?

The error message tx_nonce_too_high_for_account is pretty descriptive me thinks :man_shrugging: