{"id":25972153,"url":"https://github.com/mainframeos/contracts-cli","last_synced_at":"2026-06-10T14:31:32.630Z","repository":{"id":57206600,"uuid":"132888811","full_name":"MainframeOS/contracts-cli","owner":"MainframeOS","description":"CLI for interacting with smart contracts","archived":false,"fork":false,"pushed_at":"2019-01-04T15:25:23.000Z","size":162,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-02-28T04:32:46.794Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MainframeOS.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-05-10T11:05:27.000Z","updated_at":"2020-10-31T07:40:20.000Z","dependencies_parsed_at":"2022-09-08T17:01:24.919Z","dependency_job_id":null,"html_url":"https://github.com/MainframeOS/contracts-cli","commit_stats":null,"previous_names":["mainframehq/contracts-cli"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MainframeOS%2Fcontracts-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MainframeOS%2Fcontracts-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MainframeOS%2Fcontracts-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MainframeOS%2Fcontracts-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MainframeOS","download_url":"https://codeload.github.com/MainframeOS/contracts-cli/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241941198,"owners_count":20046026,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-03-05T00:19:47.763Z","updated_at":"2025-12-02T15:01:39.753Z","avatar_url":"https://github.com/MainframeOS.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# contracts-cli\n\nA command line tool for interacting with smart contracts\n\n## Prerequisites\n\n- [Node](https://nodejs.org/en/) v8+\n- [Yarn](https://yarnpkg.com/lang/en/docs/install)\n\n## Setup\n\nfrom inside contracts-cli directory run:\n\n```\n❯ yarn\n❯ yarn build\n❯ yarn link\n```\n\n## Run\n\nto start the cli run `contracts-cli` from the command line passing an Ethereum client JSON-RPC URL and a relative path to a folder containing JSON ABI files of contracts you wish to interact with, e.g:\n\n```\ncontracts-cli --abi-dir=./abi --rpc-url=https://ropsten.infura.io/FWLG9Y\n```\n\nother optional inputs include:\n\n```\n--testnet\n--config-path=\u003cpath to config file, example below\u003e\n```\n\n### Config file (Optional)\n\nHere you can set contract addresses you frequently interact with to save entering them in the cli each time, they just need a mapping to the names of your JSON ABI files, e.g:\n\n```\n{\n  \"contractAddresses\": {\n    \"MyTokenContract\": {\n      \"testnet\": \"0xe16f1563984209fe47f8236f8b01a03f03f957e4\",\n      \"mainnet\": \"0xab2c7238198ad8b389666574f2d8bc411a4b7428\"\n    },\n    \"OtherContract\": {\n      \"testnet\": \"0xcefd4590d131480f100ac58b845314a978b0ec70\",\n      \"mainnet\": \"0xb2d2130530d77418b3e367fe162808887526e74d\"\n    },\n  },\n  rpcUrl: {\n    \"testnet\": \"https://ropsten.infura.io/\u003cKEY\u003e\",\n    \"mainnet\": \"https://mainnet.infura.io/\u003cKEY\u003e\"\n  }\n}\n```\n\n## Usage\n\n**1. Select a wallet provider**\n\n- Keystore JSON file\n- Private key\n- Mnemonic phrase\n- Ledger wallet (ensure ledger is unlocked, eth wallet is selected and browser support set to no)\n\n**2. Select a contract to interact with**\n\n- You can add new contracts by dropping contract abi JSON files into `abi` folder, you can also optionally set addresses for contracts in `config.json`, if no address is set you will be prompted to provide one on contract selection.\n\n**3. Select or set contract address**\n\n**3. Select contract method**\n\n**4. Enter arguments and confirm**\n\n- when passing uint values, you will have the option for unit conversion, possible units can be found [here](https://github.com/ethereum/wiki/wiki/JavaScript-API#web3towei)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmainframeos%2Fcontracts-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmainframeos%2Fcontracts-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmainframeos%2Fcontracts-cli/lists"}