{"id":18964270,"url":"https://github.com/lorransutter/signed-transactions-demo","last_synced_at":"2026-04-02T20:30:15.554Z","repository":{"id":42794836,"uuid":"272558370","full_name":"LorranSutter/Signed-transactions-demo","owner":"LorranSutter","description":"Server side application to perform smart contract transactions","archived":false,"fork":false,"pushed_at":"2023-01-24T02:56:27.000Z","size":829,"stargazers_count":0,"open_issues_count":10,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-01T05:30:02.760Z","etag":null,"topics":["smart-contracts","solidity","web3","web3js"],"latest_commit_sha":null,"homepage":"","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/LorranSutter.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":"2020-06-15T22:40:28.000Z","updated_at":"2021-04-16T21:03:35.000Z","dependencies_parsed_at":"2023-01-28T05:01:18.585Z","dependency_job_id":null,"html_url":"https://github.com/LorranSutter/Signed-transactions-demo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LorranSutter%2FSigned-transactions-demo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LorranSutter%2FSigned-transactions-demo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LorranSutter%2FSigned-transactions-demo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LorranSutter%2FSigned-transactions-demo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LorranSutter","download_url":"https://codeload.github.com/LorranSutter/Signed-transactions-demo/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239959950,"owners_count":19725221,"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":["smart-contracts","solidity","web3","web3js"],"created_at":"2024-11-08T14:23:31.329Z","updated_at":"2026-04-02T20:30:15.475Z","avatar_url":"https://github.com/LorranSutter.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Signed Transactions Demo\n\nServer side signed transactions for Smart Contracts using Solidity, Truffle and Node.js presented as lab assingment for BCDV1011 - Design Patterns for Blockchain from \u003ca href='https://www.georgebrown.ca/programs/blockchain-development-program-t175/'\u003eBlockchain Development\u003c/a\u003e program from \u003ca href='https://www.georgebrown.ca'\u003eGeorge Brown College\u003c/a\u003e.\n\n\u003cp align='center'\u003e\n\u003cimg src='https://res.cloudinary.com/lorransutter/image/upload/v1592316551/Signed_transactions_demo.gif' height=300/\u003e\n\u003c/p\u003e\n\n## :runner: How to run\n\nOpen your terminal in the folder you want to clone the project\n\n```sh\n# Clone this repo\ngit clone https://github.com/LorranSutter/Signed-transactions-demo.git\n\n# Go to the project folder\ncd Signed-transactions-demo\n\n# Install dependencies\nnpm install\n```\n\nNow you will need two opened terminals to run the project. One for truffle to simulate the EVM and another one for the server.\n\nTruffle will run on http://127.0.0.1:9545/\n\nFrontend will run on http://localhost:5000/\n\n```sh\n## In the first terminal ##\n\n# Go to smart contract folder\ncd src/SmartContract\n\n# Init truffle\ntruffle develop\n```\n\nAfter the last command, the RPC URI and a list of account addresses and private keys will be shown in the terminal, you will need one of these (address, PK) pairs to execute transactions. Choose, copy and paste one of these pairs and the RPC URI as the following instructions below.\n\nTo run the application you are will need to set your own configurations of port, RPC uri, account address and private key. Create the following .env file in the indicated path and format with your customized configurations:\n\n```json\n// ./.env\n\nPORT=5000\nRPC_URI=\"http://127.0.0.1:9545/\"\nACCOUNT_ADDRESS=\"0x9103cd7582bee22423648dfe02e4cfcc455e7ead\"\nPRIVATE_KEY=\"22c643e9b3efdf8a055094210e570116b98e619fe92ce5c825810571b3f76707\"\n```\n\nNow you may execute the following command:\n\n```sh\n# Run migrations\nmigrate\n```\n\nThe previous command will generate a new ABI and write contract address in a JSON file. You do not have to worry about importing these info in the backend though. Also you may change the smart contract and run migrations again to see your changes.\n\n```sh\n## In the another terminal ##\n\n# Go to backend application\ncd ..\n\n# Run the project\nnpm run start\n\n# Or to use nodemon\nnpm run dev\n```\n\n## :book: References and technologies :computer:\n\n- [Solidity](https://solidity.readthedocs.io/) - smart contract programming language\n- [Truffle](https://www.trufflesuite.com/) - dApp environment\n- [Ethereumjs-tx](https://www.npmjs.com/package/ethereumjs-tx) - perform smart contract transactions in server side\n- [Web3.js](https://web3js.readthedocs.io/) - interact with smart contracts\n- [Dotenv](https://www.npmjs.com/package/dotenv) - loads environment variables from a .env file\n- [Express.js](http://expressjs.com/) - web application framework\n- [Pug](https://pugjs.org/) - template engine for Node.js and for the browser\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Florransutter%2Fsigned-transactions-demo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Florransutter%2Fsigned-transactions-demo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Florransutter%2Fsigned-transactions-demo/lists"}