{"_id":"@aloe2/bitgo","name":"@aloe2/bitgo","dist-tags":{"aloe-bbc82c9c9":"14.2.20228282226","latest":"14.2.20228282226"},"versions":{"14.2.20228282226":{"name":"@aloe2/bitgo","version":"14.2.20228282226","description":"BitGo JavaScript SDK","main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","keywords":["bitgo","bitcoin","bitgojs"],"repository":{"type":"git","url":"git+https://github.com/BitGo/BitGoJS.git","directory":"modules/bitgo"},"license":"Apache-2.0","engines":{"node":">=14 <17","npm":">=3.10.10"},"scripts":{"compile":"yarn webpack-prod","compile-dbg":"yarn webpack-dev","compile-test":"yarn webpack-dev","webpack-dev":"cross-env NODE_ENV=development webpack","webpack-prod":"cross-env NODE_ENV=production webpack","test":"npm run coverage","unit-test":"mocha","coverage":"nyc -- npm run unit-test","integration-test":"nyc -- mocha \"test/v2/integration/**/*.ts\"","browser-test":"karma start karma.conf.js","lint":"eslint --quiet .","audit":"if [ \"$(npm --version | cut -d. -f1)\" -ge \"6\" ]; then npm audit; else echo \"npm >= 6 required to perform audit. skipping...\"; fi","clean":"rm -r dist/*","build":"yarn tsc --build --incremental --verbose .","prepare":"npm run build","prepublishOnly":"npm run compile","upload-artifacts":"node scripts/upload-test-reports.js","check-fmt":"prettier --check '{src,test}/**/*.{ts,js,json}'","unprettied":"grep -R -L --include '*.ts' --include '*.js' --include '*.json' '@prettier' src test","fmt":"prettier --write '{src,test}/**/*.{ts,js,json}'","upload-docs":"node scripts/upload-docs.js","gen-docs":"typedoc"},"dependencies":{"@aloe2/abstract-utxo":"^1.1.20228282226","@aloe2/account-lib":"^2.20.20228282226","@aloe2/blockapis":"^1.0.20228282226","@aloe2/sdk-api":"^1.1.20228282226","@aloe2/sdk-coin-ada":"^1.1.20228282226","@aloe2/sdk-coin-algo":"^1.1.20228282226","@aloe2/sdk-coin-avaxc":"^1.1.20228282226","@aloe2/sdk-coin-avaxp":"^2.0.20228282226","@aloe2/sdk-coin-bch":"^1.1.20228282226","@aloe2/sdk-coin-bcha":"^1.1.20228282226","@aloe2/sdk-coin-bsc":"^1.0.20228282226","@aloe2/sdk-coin-bsv":"^1.1.20228282226","@aloe2/sdk-coin-btc":"^1.0.20228282226","@aloe2/sdk-coin-btg":"^1.1.20228282226","@aloe2/sdk-coin-celo":"^1.1.20228282226","@aloe2/sdk-coin-cspr":"^1.0.20228282226","@aloe2/sdk-coin-dash":"^1.1.20228282226","@aloe2/sdk-coin-doge":"^1.0.20228282226","@aloe2/sdk-coin-dot":"^1.0.20228282226","@aloe2/sdk-coin-eos":"^1.0.20228282226","@aloe2/sdk-coin-etc":"^1.0.20228282226","@aloe2/sdk-coin-eth":"^1.1.20228282226","@aloe2/sdk-coin-eth2":"^1.0.20228282226","@aloe2/sdk-coin-ethw":"^1.0.20228282226","@aloe2/sdk-coin-hbar":"^1.0.20228282226","@aloe2/sdk-coin-ltc":"^1.1.20228282226","@aloe2/sdk-coin-near":"^1.1.20228282226","@aloe2/sdk-coin-polygon":"^1.0.20228282226","@aloe2/sdk-coin-rbtc":"^1.1.20228282226","@aloe2/sdk-coin-sol":"^1.0.20228282226","@aloe2/sdk-coin-stx":"^1.1.20228282226","@aloe2/sdk-coin-trx":"^1.0.20228282226","@aloe2/sdk-coin-xlm":"^1.0.20228282226","@aloe2/sdk-coin-xrp":"^1.1.20228282226","@aloe2/sdk-coin-xtz":"^1.1.20228282226","@aloe2/sdk-coin-zec":"^1.1.20228282226","@aloe2/sdk-core":"^1.1.20228282226","@aloe2/sjcl":"^1.0.20228282226","@aloe2/statics":"^7.0.20228282226","@aloe2/unspents":"^0.8.20228282226","@aloe2/utxo-lib":"^2.4.20228282226","@types/bluebird":"^3.5.25","@types/superagent":"^4.1.3","bignumber.js":"^8.0.1","bitcoinjs-message":"^2.0.0","bluebird":"^3.5.3","fs-extra":"^9.1.0","lodash":"^4.17.14","openpgp":"5.1.0","stellar-sdk":"^10.0.1","superagent":"^3.8.3","@ethereumjs/common":"^2.4.0","@ethereumjs/tx":"^3.3.0","ethereumjs-abi":"^0.6.5","ethereumjs-util":"7.1.5"},"devDependencies":{"@bitgo/sdk-test":"^1.0.1","@types/create-hmac":"^1.1.0","@types/debug":"^4.1.4","@types/jasmine":"^3.5.12","@types/lodash":"^4.14.121","aws-sdk":"^2.1155.0","karma":"^5.1.1","karma-chrome-launcher":"^3.1.0","karma-jasmine":"^4.0.0","karma-typescript":"^5.0.3","libsodium-wrappers-sumo":"^0.7.9","puppeteer":"2.1.1","q":"^1.1.2","request":"^2.88.0","request-promise":"^4.2.2"},"optionalDependencies":{"@ethereumjs/common":"^2.4.0","@ethereumjs/tx":"^3.3.0","ethereumjs-abi":"^0.6.5","ethereumjs-util":"7.1.5"},"nyc":{"extension":[".ts"]},"lint-staged":{"*.{js,ts}":["yarn prettier --write","yarn eslint --fix"]},"publishConfig":{"access":"public"},"gitHead":"ff34e1949ea30d3016d4a8e17d459eee4436eda5","bugs":{"url":"https://github.com/BitGo/BitGoJS/issues"},"homepage":"https://github.com/BitGo/BitGoJS#readme","_id":"@aloe2/bitgo@14.2.20228282226","_nodeVersion":"14.18.0","_npmVersion":"lerna/5.5.0/node@v14.18.0+x64 (darwin)","dist":{"integrity":"sha512-pDpeXgaqoAzdPoJhDaSefZKuqrD+IL2L6MfxOWe87BTXEfynVlzwd/6bVEnnhbazVJeirscIY+4gP7Mc3hpGUQ==","shasum":"682981edebb82c2bc0c997492f8c3de6155f98f8","tarball":"https://registry.npmjs.org/@aloe2/bitgo/-/bitgo-14.2.20228282226.tgz","fileCount":50,"unpackedSize":26398011,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFpq2altvCb8lDdLgzTND8VlRpuNvHFx6HNpe1GnN/jNAiAe+TxPeW6qWPZfeX2I9laF/3ZgOYFYhueX8ZXc3d7b1Q=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjNS5uACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq+DQ/+PgdNmiq/kt66sl+LLVxKYY0C0t0FPM7IFzWbYd/X9Ud0M2xT\r\nulMXQuli4HW3zxE2Gp+vthhz1eP+UAwc7H4B2gZLidLnfUnmiDA7Y/5kdwY9\r\ng6YjZ1kZvRMmZKhrCPtGQxJi8SLKUh2hkiLUFUDiaM5R3dsCIzD6xRiOPF3v\r\nVo3MZV+UEq0g1n0kPH1VlzSUBOGRD06PExSnWWdDy/mWKN1oT0X7CcsuAWRL\r\nC/jNKo//SVfvw/jIewnDSSPcwnthVsYiaLs7SY1J5ww92ph51tyvSNQyNkLF\r\n3kb9KJZIss/Qb/kdq+hK63W3Nts2NoQoG2pHxWILvAJsoQTZhT+XAg4HxdpX\r\nBMMFhdc9EIryUR0wHc+aez+0O8UjAbg+lRg/nUV8o6IUzOo430zXa07/tL4M\r\nPptdH94vC6BA1uQ/MxD08IUEviHGANCrDFopC8ktoR42bl3Krh4FnThPod6Q\r\nxvrJC3bgdRgOz47U+kUtNOty2+wAzQ9Y82E+FwDqNgff/hu0cGOh44kpDvrJ\r\nPaFCcK/gWFMUEBYvzR1goBO34xjhGULo2ZByt88G0PYVYF8RXPfdWxkUbSZF\r\nuTqVLIWRTHjyGyIC/53H7hRvNvd63kyrIov7xEoshBQ/eFskZMNeG+zagUxu\r\nmItSEcU0u+K7h0RzKZcigqHjeLVmRSkbRyg=\r\n=polj\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"aaronloe","email":"aaronloe@gmail.com"},"directories":{},"maintainers":[{"name":"aaronloe","email":"aaronloe@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/bitgo_14.2.20228282226_1664429678512_0.5372972406584899"},"_hasShrinkwrap":false}},"time":{"created":"2022-09-29T05:34:38.455Z","14.2.20228282226":"2022-09-29T05:34:38.848Z","modified":"2022-09-29T05:34:38.984Z"},"maintainers":[{"name":"aaronloe","email":"aaronloe@gmail.com"}],"description":"BitGo JavaScript SDK","homepage":"https://github.com/BitGo/BitGoJS#readme","keywords":["bitgo","bitcoin","bitgojs"],"repository":{"type":"git","url":"git+https://github.com/BitGo/BitGoJS.git","directory":"modules/bitgo"},"bugs":{"url":"https://github.com/BitGo/BitGoJS/issues"},"license":"Apache-2.0","readme":"# BitGo JavaScript SDK\n\nThe BitGo Platform and SDK makes it easy to build multi-signature crypto-currency applications today with support for Bitcoin, Ethereum and many other coins.\nThe SDK is fully integrated with the BitGo co-signing service for managing all of your BitGo wallets.\n\nIncluded in the SDK are examples for how to use the API to manage your multi-signature wallets.\n\nPlease email us at support@bitgo.com if you have questions or comments about this API.\n\n[![Known Vulnerabilities](https://snyk.io/test/github/BitGo/BitGoJS/badge.svg)](https://snyk.io/test/github/BitGo/BitGoJS) [![Build Status](https://cloud.drone.io/api/badges/BitGo/BitGoJS/status.svg)](https://cloud.drone.io/BitGo/BitGoJS)\n\n# Installation\n\nPlease make sure you are running at least Node version 8 (the latest LTS release is recommended) and NPM version 6.\nWe recommend using `nvm`, the [Node Version Manager](https://github.com/creationix/nvm/blob/master/README.markdown#installation), for setting your Node version.\n\n`npm install --save bitgo`\n\n# Full Documentation\n\nPlease see our [SDK Documentation](https://bitgo-sdk-docs.s3.amazonaws.com/core/11.3.0/index.html) for detailed information about the TypeScript SDK and functionality.\n\nFor more general information about the BitGo API, please see our [REST API Documentation](https://www.bitgo.com/api/v2).\n\n# Release Notes\n\nYou can find the complete release notes (since version 4.44.0) [here](https://github.com/BitGo/BitGoJS/blob/master/modules/bitgo/RELEASE_NOTES.md).\n\n# Example Usage\n\n## Initialize SDK\nCreate an access token by logging into your bitgo account, going to the API access tab [in the settings area](https://www.bitgo.com/settings) and making a developer token.\n```js\nconst BitGo = require('bitgo');\nconst bitgo = new BitGo.BitGo({ accessToken: ACCESS_TOKEN }); // defaults to testnet. add env: 'prod' if you want to go against mainnet\nconst result = await bitgo.session();\nconsole.dir(result);\n```\n\n## Create Wallet\n```js\nconst params = {\n  \"passphrase\": \"replaceme\",\n  \"label\": \"firstwallet\"\n};\nconst { wallet } = await bitgo.coin('tbtc').wallets().generateWallet(params);\nconsole.dir(wallet);\n```\n\n## Create new address\n```js\nconst address = await wallet.createAddress();\nconsole.dir(address);\n```\n\n## View wallet transfers\n```js\nconst transfers = await wallet.transfers();\n```\n\n## Send coins\n```js\nconst result = await wallet.sendCoins({\n  address: \"2NEe9QhKPB2gnQLB3hffMuDcoFKZFjHYJYx\",\n  amount: 0.01 * 1e8,\n  walletPassphrase:  \"replaceme\"\n});\nconsole.dir(result);\n```\n\n## More examples\nFurther demos and examples in both JavaScript and TypeScript can be found in the [example](example) directory.\n\n# Enabling additional debugging output\n\n`bitgo` uses the `debug` package to emit extra information, which can be useful when debugging issues with BitGoJS or BitGo Express.\n\nWhen using the `bitgo` npm package, the easiest way to enable debug output is by setting the `DEBUG` environment variable to one or more of the debug namespaces in the table below. Multiple debug namespaces can be enabled by giving a comma-separated list or by using `*` as a wildcard. See the [debug package documentation](https://github.com/visionmedia/debug#readme) for more details.\n\n## Available Debug Namespaces\n| Namespace | Description |\n| --- | --- |\n| `bitgo:index` | Core BitGo object. Currently only constant fetch failures and HMAC response failures will emit debug information for this namespace. |\n| `bitgo:v1:txb` | Version 1 (legacy) transaction builder |\n| `bitgo:v2:pendingapprovals` | Pending approval operations. Currently only wallet fetch errors will emit debug information for this namespace. |\n| `bitgo:v2:wallet` | Wallet operations including transaction prebuild, sendMany calls and consolidation transactions |\n| `bitgo:v2:utxo` | Low level operations for UTXO coins, including transaction parsing, verification, signing and explanations |\n| `bitgo:v2:eth` | Ethereum specific output. Currently only failures to require the optional Ethereum libraries are reported |\n| `bitgo:v2:util` | SDK utilities specific output. Currently only failures to require the optional Ethereum libraries are reported |\n\nAnother debug namespace which is not provided by BitGoJS but is helpful nonetheless is the `superagent` namespace, which will output all HTTP requests and responses (only the URL, not bodies).\n\n## Example\n\nTo run an SDK script with debug output enabled, export the DEBUG environment variable before running.\n```shell script\nexport DEBUG='bitgo:*' # enable all bitgo debug namespaces\nnode myScript.js\n```\n\nTo set debug namespaces in the browser, you should set `localStorage.debug` property instead of the `DEBUG` environment variable using your browser's development tools console.\n\n```js\nlocalStorage.debug = 'bitgo:*'; // enable all bitgo debug namespaces\n```\n\n# Using with TypeScript\n\n`bitgo` is not yet compatible with the `noImplicitAny` compiler option. If you want to use this option in your project (and we recommend that you do), you must set the `skipLibCheck` option to supress errors about missing type definitions for dependencies of `bitgo`.\n\n# Usage in Browser\n\nSince version 6, `bitgo` includes a minified, browser-compatible bundle by default at `dist/browser/BitGoJS.min.js`. It can be copied from there directly into your project.\n\nBitGoJS can also be bundled with any module bundler. There is a Webpack configuration file already included, which can be triggered with package scripts.\n\nFor a production build: `npm run-script compile`\n\nFor a development (non-minified) build: `npm run-script compile-dbg`\n\nTo build the test suite into a single test file: `npm run-script compile-test`\n","readmeFilename":"README.md"}