Skip to main content

code

Description

Retrieves the code and ABI for an account.

Positionals

  • name TEXT - The name of the account whose code should be retrieved

Options

  • -c,--code TEXT - The name of the file to save the contract .wast to
  • -a,--abi TEXT - The name of the file to save the contract .abi to
  • --wasm Save contract as wasm

Examples

Simply output the hash of sysio.token contract

clio get code sysio.token
code hash: f675e7aeffbf562c033acfaf33eadff255dacb90d002db51c7ad7cbf057eb791

Retrieve and save ABI for sysio.token contract

clio get code sysio.token -a sysio.token.abi
code hash: f675e7aeffbf562c033acfaf33eadff255dacb90d002db51c7ad7cbf057eb791
saving abi to sysio.token.abi

Retrieve and save wast code for sysio.token contract

clio get code sysio.token -c sysio.token.wast
code hash: f675e7aeffbf562c033acfaf33eadff255dacb90d002db51c7ad7cbf057eb791
saving wast to sysio.token.wast