{"id":21697375,"url":"https://github.com/web3space/web3t","last_synced_at":"2025-04-12T12:20:54.518Z","repository":{"id":34075412,"uuid":"145350359","full_name":"web3space/web3t","owner":"web3space","description":"[W3W Backend] Unified Hybrid Web3 Interface  (Same interface for all possible coins, tokens)","archived":false,"fork":false,"pushed_at":"2022-12-11T09:14:56.000Z","size":5764,"stargazers_count":34,"open_issues_count":9,"forks_count":13,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-04-24T13:27:48.422Z","etag":null,"topics":["coins","cryptocurrency","standard"],"latest_commit_sha":null,"homepage":"https://web3.space","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/web3space.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-08-20T01:13:58.000Z","updated_at":"2023-03-09T10:38:09.000Z","dependencies_parsed_at":"2023-01-15T04:26:52.740Z","dependency_job_id":null,"html_url":"https://github.com/web3space/web3t","commit_stats":null,"previous_names":["ethnamed/web3t"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3space%2Fweb3t","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3space%2Fweb3t/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3space%2Fweb3t/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3space%2Fweb3t/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/web3space","download_url":"https://codeload.github.com/web3space/web3t/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248565179,"owners_count":21125435,"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":["coins","cryptocurrency","standard"],"created_at":"2024-11-25T19:25:21.254Z","updated_at":"2025-04-12T12:20:54.490Z","avatar_url":"https://github.com/web3space.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://res.cloudinary.com/nixar-work/image/upload/v1537612969/Screen_Shot_2018-09-22_at_13.41.49.png\"\u003e\n\u003c/p\u003e\n\n\nImplementation of web3 protocol\n\n#### Demo\n----\n\n[WEB3 Wallet](https://chrome.google.com/webstore/detail/web3-wallet/ifagkkjladbaocinenklelnaailedikm)\n\n#### Install\n----\n\n```\nnpm i web3t\n```\n\n#### Benefits\n----\n\n* Web3t is open source free covered by test library available for everyone and can be used to build an exchange, wallet and other crypto systems.\n* Opened Standard. Everyone can contribute to add his coin.\n* Used by [WEB3 Wallet](https://chrome.google.com/webstore/detail/web3-wallet/ifagkkjladbaocinenklelnaailedikm)\n* Partially Compatible with [WEB3 Wallet](https://chrome.google.com/webstore/detail/web3-wallet/ifagkkjladbaocinenklelnaailedikm)\n* Compatible with MetaMask Web3 Standard for Ethereum\n\n#### Support\n----\n\n* BTC (Bitcoin)\n* LTC (Litecoin)\n* ETH (Ethereum)\n* DASH \n* XEM (NEM)\n* XRP (Ripple)\n* [ANY_COIN]\n\n#### Init Builder\n----\n\n```Javascript\n\nvar buildWeb3t = require('web3t');\n\n```\n\n#### Build Testnet\nJust pass the `testnet` word into constructor.\n\n----\n\n```Javascript \nfunction testnet(err, web3t) {\n    ... \n\n}\n\nbuildWeb3t(\"testnet\", testnet);\n\n```\n\nThere are other advanced possible ways to build the web3 object for case when you need to define a special testnet. It is useful for case when you have a lot of faucets of special testnet and write unit tests.\n\n```Javascript \nfunction testnet(err, web3t) {\n    ... \n\n}\n\nbuildWeb3t(\"testnet, ropsten for eth\", testnet);\n\n```\n\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/yw5lj63igd4r)\n\n\n#### Build Mainnet\n----\n\n```Javascript \nfunction mainnet(err, web3t) {\n    ... \n}\n\nbuildWeb3t(\"mainnet\", mainnet);\n\n```\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/myx74ap01ge6)\n\n\n#### Advanced Builder\n----\n\n```Javascript \nfunction mainnet(err, web3t) {\n    ... \n}\n\nvar config = {\n   mode: \"mainnet\"\n   plugins: {},\n   providers: {}\n}\n\nbuildWeb3t(config, mainnet);\n\n```\n\n#### Example\n----\n\n```Javascript\n\nweb3t.eth.sendTransaction({ to, amount }, cb);\n\nweb3t.btc.sendTransaction({ to, amount }, cb);\n\nweb3t.zec.sendTransaction({ to, amount }, cb);\n\nweb3t.[ANY_COIN].sendTransaction({ to, amount }, cb);\n  \n```\n\n#### Send All Funds\n----\nSimplified Method to Send All Funds. Wrapper on `sendTransaction`\n\n```Javascript\n\nvar cb =\u003e (err, tx) {\n  \n}\n\nweb3t.[ANY_COIN].sendAllFunds({ to, data }, cb);\n  \n```\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/myx74ap01ge6)\n\n\n#### Create Account\n----\nYou can create a lot of addresses by providing different index\n\n```Javascript\n\nvar cb =\u003e (err, { address, privateKey, publicKey }) {\n  \n}\n\nweb3t.[ANY_COIN].createAccount({ mnemonic, index }, cb);\n  \n```\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/myx74ap01ge6)\n\n\n#### Get Balance\n----\nGet Balance by account object ({ address, privateKey })\nUsually it does not need the private key but coins like monero needs decrypt data to read the balance\n\n```Javascript  \n\n  var cb =\u003e (err, balance) {\n  \n  }\n\n  web3t.[ANY_COIN].getBalance({ account }, cb);\n  \n```\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/myx74ap01ge6)\n\n\n#### Get History of Transactions\n----\nList of all transactions. Same result structure for all coins\n\n```Javascript \n  \n  var cb =\u003e (err, transactions) {\n  \n  }\n  \n  web3t.[ANY_COIN].getHistory({ account }, cb);\n  \n```\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/myx74ap01ge6)\n\n\n#### Calc Fee \n----\nYou need to define the default fee in `plugin` but for NEM, Monero and other coins you need to calculate the fee\n\n```Javascript   \n  \n  var cb =\u003e (err, amountFee) {\n  \n  }\n  \n  web3t.[ANY_COIN].calcFee({ account, to, amount, data}, cb); // =\u003e fee\n  \n```\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/myx74ap01ge6)\n\n\n#### Create and Send Transaction\n----\nThis transaction consists of `create`, `sign`, `push` transaction\n\n```Javascript   \n\n  var cb =\u003e (err, receipt) {\n  \n  }\n\n  web3t.[ANY_COIN].createTransaction({ account, to, amount, data}, cb); // =\u003e tx\n\n```\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/myx74ap01ge6)\n\n\n#### Create and Sign Transaction\n----\nIn some cases you need to have the hex of transaction before for some reason before you push it\n\n```Javascript   \n\n  var cb =\u003e (err, rawtx) {\n  \n  }\n\n  web3t.[ANY_COIN].signTransaction({ account, to, amount, data}, cb); // =\u003e rawtx\n\n```\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/myx74ap01ge6)\n\n\n#### Broadcast the Signed Transaction\n----\nPush the signed transaction (hex) into blockchain\n\n```Javascript   \n\n  var cb =\u003e (err, receipt) {\n  \n  }\n\n  web3t.[ANY_COIN].pushTransaction(rawtx, cb); // =\u003e rawtx\n\n```\n[![button](https://res.cloudinary.com/nixar-work/image/upload/v1537609862/button_run-it.png)](https://runkit.com/embed/myx74ap01ge6)\n\n\n\n#### Compatibility\n----\n\n`sendTransaction` and `getBalance` are compatible with [WEB3 Wallet](https://chrome.google.com/webstore/detail/web3-wallet/ifagkkjladbaocinenklelnaailedikm)\n\n\n#### How to Contibute\n----\n\nYou can find issues but we improve it daily.\nPlease do not judge but help.\n\n1. Please modify only `plugins`, `providers`, `package.json`\n2. `plugin` should consists only network information and implements `Interfaces/coin-interface.ts`\n3. `provider` should implements `Interfaces/protocol-interface.ts`\n4. Send a pull request\n5. Any question `a.stegno@gmail.com`\n\n#### Simple Summary\n----\n\nThe management of different coins should be similar, so that there is no need for each to develop a new infrastructure, and connect it to the existing one\n\n\n#### Abstract\n----\n\nWeb 3.0 is an inclusive set of protocols to provide building blocks for application makers. These building blocks take the place of traditional web technologies like HTTP, AJAX and MySQL, but present a whole new way of creating applications. These technologies give the user strong and verifiable guarantees about the information they are receiving, what information they are giving away, and what they are paying and what they are receiving in return. By empowering users to act for themselves within low-barrier markets, we can ensure censorship and monopolization have fewer places to hide. Consider Web 3.0 to be an executable Magna Carta — “the foundation of the freedom of the individual against the arbitrary authority of the despot.”\n\nPlease read more here [article](https://medium.com/@gavofyork/why-we-need-web-3-0-5da4f2bf95ab)\n\n#### Motivation\n----\n\nThere was already implemented solution Web 3.0 in Metamask Wallet and used by dozen of dapps.\nIt is great. But it is available only for ETH.\nWe would like to extend the same protocol for other coins\nIt will help to \n\n* connect different coins to existent web 2.0\n* quickly create a list of supported crypto currency for exchanges, multicurrency wallets and help new projects get the existing infrastructure instantly and effortlessly\n* develop the cross-chain interface\n\n#### Copyright\n----\n\nCopyright and related rights waived via CC0.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://res.cloudinary.com/nixar-work/image/upload/v1537613131/Screen_Shot_2018-09-22_at_13.45.07.png\"\u003e\n\u003c/p\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweb3space%2Fweb3t","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fweb3space%2Fweb3t","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweb3space%2Fweb3t/lists"}