{"id":19119738,"url":"https://github.com/tenderly/devnet-examples","last_synced_at":"2025-09-08T12:30:44.312Z","repository":{"id":153917633,"uuid":"620670104","full_name":"Tenderly/devnet-examples","owner":"Tenderly","description":"This repo provides a collection of resources and examples to help developers leverage DevNets' managed environments and tools for efficient, secure, and independent smart contract development.","archived":false,"fork":false,"pushed_at":"2023-08-14T12:39:54.000Z","size":29689,"stargazers_count":5,"open_issues_count":1,"forks_count":7,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-08T23:04:31.930Z","etag":null,"topics":["devnets","tenderly"],"latest_commit_sha":null,"homepage":"https://docs.tenderly.co/devnets/intro-to-devnets","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Tenderly.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-03-29T06:26:34.000Z","updated_at":"2023-09-28T16:07:35.000Z","dependencies_parsed_at":null,"dependency_job_id":"8f3b32aa-7a04-45bb-b18c-9f29acf9712a","html_url":"https://github.com/Tenderly/devnet-examples","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Tenderly/devnet-examples","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tenderly%2Fdevnet-examples","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tenderly%2Fdevnet-examples/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tenderly%2Fdevnet-examples/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tenderly%2Fdevnet-examples/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Tenderly","download_url":"https://codeload.github.com/Tenderly/devnet-examples/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tenderly%2Fdevnet-examples/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274185339,"owners_count":25237376,"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","status":"online","status_checked_at":"2025-09-08T02:00:09.813Z","response_time":121,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["devnets","tenderly"],"created_at":"2024-11-09T05:10:55.928Z","updated_at":"2025-09-08T12:30:43.093Z","avatar_url":"https://github.com/Tenderly.png","language":"TypeScript","readme":"# Examples for DevNet Local Setup\n\n\u003cdiv align=\"center\"\u003e\n    \u003ca href=\"https://tenderly.co\"\u003e\n        \u003cimg src=\"https://storage.googleapis.com/tenderly-public-assets/tenderly-logo-purple.png\" alt=\"Tenderly\" width=\"100%\" height=\"auto\" style=\"background-color: #ffffffb2; padding: 10px 20px; margin-bottom: 20px; box-sizing: border-box; max-width:200px;\" /\u003e\n    \u003c/a\u003e\n\u003c/div\u003e\n\n\u003cdiv align=\"center\"\u003e\n\n[![Twitter](https://img.shields.io/twitter/follow/TenderlyApp?style=social)](https://twitter.com/intent/follow?screen_name=TenderlyApp)\n[![Github](https://img.shields.io/github/stars/Tenderly/devnet-examples?style=social)](https://github.com/Tenderly/devnet-examples)\n\n\u003c/div\u003e\n\n## Introduction\n\nSetting up DevNets for local development offers several benefits, including faster development and testing, customization of the network state, privacy and security, independence from public testnets, and integration with development tools.\n\n## Prerequisites\n\nBefore setting up a DevNet locally, make sure to:\n\n1. Create a [**Tenderly account**](https://dashboard.tenderly.co/register?redirectTo=devnets).\n2. Set up a [**DevNet Template**](https://dashboard.tenderly.co/register?redirectTo=devnets) on Tenderly Dashboard.\n3. Install the [**Tenderly CLI**](https://docs.tenderly.co/tenderly-cli/installation) and login with your Tenderly credentials.\n\n## Hardhat Setup\n\nTo set up DevNet with Hardhat:\n\n1. Install Hardhat.\n2. Configure `hardhat.config.js` with your DevNet JSON-RPC URL and network name must be either `tenderly` or `devnet`. \n\nAlternatively, use the `spawn-rpc` CLI command to automate the process.\n\nRefer to the [CI-project example](CI-project) for more details.\n\n## Foundry Setup\n\nTo set up DevNet with Foundry:\n\n1. Make sure you have Rust and Foundry.\n   1. [Install Rust](https://www.rust-lang.org/tools/install).\n   2. [Install Foundry](https://github.com/gakonst/foundry/).\n2. Initialize a dummy Foundry project.\n```bash\nforge init\n```\n3. Deploy smart contracts using the forge create command.\n```bash\nforge create --rpc-url=$(tenderly devnet spawnRPC --template \u003cYOUR_TEMPALATE_SLUG\u003e --project \u003cYOUR_PROJECT_SLUG\u003e) ./src/Counter.sol:Counter --unlocked --from 0x0000000000000000000000000000000000000000\n```\n\n## Truffle Setup\n\nTo set up DevNet with Truffle:\n\n1. Install Truffle.\n```bash\nnpm install -g truffle\n```\n2. Configure truffle-config.js with your DevNet JSON-RPC URL and Ethereum address.\n```javascript\nmodule.exports = {\n  networks: {\n    devnet: {\n      host: \"YOUR_DEVNET_JSON_RPC_URL\",\n      network_id: \"*\",\n      gas: 4700000,\n      gasPrice: 20000000000,\n      from: \"YOUR_ETHEREUM_ADDRESS\"\n    }\n  }\n};\n```\n3. Run `truffle migrate` to deploy your contracts.\n```bash\ntruffle migrate --network devnet\n```\n\n## CI Integration\n\nTo integrate DevNet with your CI pipeline, use the `spawn-rpc` CLI command to spawn a DevNet instance and get the JSON-RPC URL.\n\n```bash\ntenderly devnet spawnRPC --template \u003cYOUR_TEMPALATE_SLUG\u003e --project \u003cYOUR_PROJECT_SLUG\u003e\n```\n\nPlease refer to the [CI-project example](CI-project) for more details.\n\n## Further Guidance\n\nFor more information on DevNet, check out the following resources:\n- [DevNet Documentation](https://docs.tenderly.co/devnets)\n- [DevNet Known Issues](https://docs.tenderly.co/devnets/references/known-issues)\n- [Custom RPC Methods](https://docs.tenderly.co/devnets/references/custom-rpc-methods)\n\n## Contributors\n\n\u003ca href=\"https://github.com/Tenderly/devnet-examples/graphs/contributors\"\u003e\n  \u003cimg src=\"https://contrib.rocks/image?repo=Tenderly/devnet-examples\u0026max=100\u0026columns=20\" alt=\"tenderly-contributors\" /\u003e\n\u003c/a\u003e\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftenderly%2Fdevnet-examples","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftenderly%2Fdevnet-examples","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftenderly%2Fdevnet-examples/lists"}