CLI Cheat Sheet

scrypto Cheat Sheet

Action

Command

To create a new package

scrypto new-package <package_name>

To build a package

scrypto build

To test a package

scrypto test

To run a test with standard output

scrypto test - <test_name> -- --nocapture

resim Cheat Sheet

Action

Command

To create an account

resim new-account

To change the default account

resim set-default-account <account_address> <account_private_key> <owner_badge>

To get a new key-pair, without creating an account component

resim generate-key-pair

To create a token with fixed supply

resim new-token-fixed <amount>

To create a token with mutable supply

resim new-token-mutable <minter_badge_address>

To create a badge with fixed supply

resim new-badge-fixed <amount>

To create a badge with mutable supply

resim new-badge-mutable <minter_badge_address>

To create a simple NFT badge

resim new-simple-badge

To mint resource

resim mint <amount> <resource_address> <minter_badge_address>

To transfer resource

resim transfer <resource_address>:<amount_or_comma_separated_nf_ids> <recipient_address>

To publish a package

resim publish <path_to_package_dir>

To call a function

resim call-function <package_address> <blueprint_name> <function> <args>

To call a method

resim call-method <component_address> <method> <args>

To export the ABI of a blueprint

resim export-abi <package_address> <blueprint_name>

To show info about an address

resim show <address>

To run a transaction manifest file

resim run <path_to_manifest_file>

To set the current epoch

resim set-current-epoch

To set the current time (UTC date time in ISO-8601 format, up to second precision, such as 2011-12-03t10:15:30Z).

resim set-current-time

Other Useful Commands

Action

Command

To overwrite a deployed package

resim publish <path_to_package_dir> --package-address <existing_address>

To list all entities in simulator

resim show-ledger