Writing and reading json from the chain using cli

I have been watching some of the IOHK summit videos and evidently there is a way with the Cardano cli to write and read json files currently (before Gogeun). I am running full Cardano node currently. I have tried to look for cli information but a lot of what I am finding is outdated or for Byron. Is there a guide with updated cli documentation that i am missing?


To write and read what in exactly? JSON is just a format

There are few changes in 1.19 (eg: eliminating unused/unimplemented parts of CLI), but most of the CLI endpoints in docs here are valid

I will take a look at the endpoints, thanks… I am in a group of pool owners, SPOCRA. We are trying to come up with an on-chain way to vote before it’s official available . there is a cli command line argument that allows you to write a json file (–metadata-json-file FILE) … one of the operators are trying to hack something together…
There was also a comment by one of the Plutus developers during the IOHK summit that mentioned there is a way to currently write to the blockchain (before Goguen).

I am just trying to figure it all out…


“Operators” are supposed to be more aware about this as they use it to register their metadata hash while registering pools - regardless …
The mentioned command is to extract a hash out of a provided json file, the hash is then included in the stakepool certificate submitted to chain. This does not mean you get to read/store JSON files on chain.

1 Like

I used this to create my hash:

cardano-cli shelley stake-pool metadata-hash --pool-metadata-file poolMetaData.json > poolMetaDataHash.txt

To create a hash from my poolMetaData.json and put it in my poolMetaDataHash.txt file…
I didn’t use the --metadata-json-file FILE to create my hash file.

I appreciate you trying to help. There is some way to do what I am trying to do, if I figure it out, i will post it here…