{"id":51092095,"url":"https://github.com/amdev9/web3override","last_synced_at":"2026-06-24T03:35:36.545Z","repository":{"id":135185915,"uuid":"163093001","full_name":"amdev9/web3override","owner":"amdev9","description":"override web3 signTransaction method to use keychain","archived":false,"fork":false,"pushed_at":"2019-02-18T09:47:36.000Z","size":1360,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-23T18:47:26.497Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/amdev9.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}},"created_at":"2018-12-25T15:19:36.000Z","updated_at":"2019-02-18T09:47:37.000Z","dependencies_parsed_at":"2023-06-14T21:00:44.301Z","dependency_job_id":null,"html_url":"https://github.com/amdev9/web3override","commit_stats":null,"previous_names":["cypherpunk99/web3override"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/amdev9/web3override","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/amdev9%2Fweb3override","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/amdev9%2Fweb3override/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/amdev9%2Fweb3override/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/amdev9%2Fweb3override/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/amdev9","download_url":"https://codeload.github.com/amdev9/web3override/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/amdev9%2Fweb3override/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34716325,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-24T02:00:07.484Z","response_time":106,"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":[],"created_at":"2026-06-24T03:35:35.807Z","updated_at":"2026-06-24T03:35:36.540Z","avatar_url":"https://github.com/amdev9.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n\n[![npm version](https://badge.fury.io/js/web3override.svg)](https://badge.fury.io/js/web3override)\n\n* `bitcoin.js` - extend `bitcoinjs-lib` with keychain related methods `prepareTx`, `buildTxKeychain`\n* `keychain.js` - Keychain class with ws connection initialization\n* `index.js` - override `web3.eth.accounts.signTransaction` method \n* `test.js` - example usage together (`keychain` + `web3`) \n\n**Usage**\n\n* Sign ethereum transaction \n```javascript\n\n  import { web3Override, Keychain } from 'web3override'\n\n  // create new key in Keychain\n  const keyInstance = await Keychain.create();\n   \n  const data = await keyInstance.selectKey();\n  const key = data.result;\n  await keyInstance.term();\n  web3.eth.accounts.signTransaction = web3Override(web3).signTransaction;\n\n  // now we use web3 with keychain\n  await web3.eth.accounts.signTransaction(transactionParams, key); // overriden web3 function usage\n```\n\n* Sign \u0026 build ready for broadcast bitcoin transaction \n\n```javascript\n  // import library\n  import { bitcoin, Keychain } from 'web3override';\n\n  // tx - bitcoin.TransactionBuilder instance with inputs \u0026 outputs\n  const keyInstance = await Keychain.create();\n  const data = await keyInstance.selectKey();\n  const publicKey = data.result;\n  tx.inputs.forEach((input, index) =\u003e {\n    tx.prepareTx(index,  publicKey)\n  });\n  const txRawHex = await tx.buildTxKeychain(keyInstance, publicKey);\n\n```\n\n**Run tests**\n\n```\nnpm run test\n```\nAdd key to your `key_data`:\n```\nkeyname: test1@76de427d42c38be4\npassword: qwe\n```\n\n![alt image](https://raw.githubusercontent.com/cypherpunk99/web3override/master/screencast.gif)\n\n*TODO bitcoin tests*","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Famdev9%2Fweb3override","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Famdev9%2Fweb3override","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Famdev9%2Fweb3override/lists"}