Skip to content

Commit

Permalink
Merge pull request #474 from Bitcoin-com/stage
Browse files Browse the repository at this point in the history
v3.11.7
  • Loading branch information
Gabriel Cardona authored Jun 20, 2019
2 parents e110a32 + 593d573 commit a022b89
Show file tree
Hide file tree
Showing 9 changed files with 56 additions and 73 deletions.
2 changes: 1 addition & 1 deletion dist/public/bitcoin-com-mainnet-rest-v2.json
Original file line number Diff line number Diff line change
Expand Up @@ -1129,7 +1129,7 @@
"openapi": "3.0.0",
"info": {
"description": "rest.bitcoin.com is the REST layer for Bitcoin.com's Cloud. More info: [developer.bitcoin.com/rest](https://developer.bitcoin.com/rest). Chatroom [geni.us/CashDev](http://geni.us/CashDev)",
"version": "3.11.6",
"version": "3.11.7",
"title": "REST",
"license": {
"name": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion dist/public/bitcoin-com-testnet-rest-v2.json
Original file line number Diff line number Diff line change
Expand Up @@ -1129,7 +1129,7 @@
"openapi": "3.0.0",
"info": {
"description": "trest.bitcoin.com is the REST layer for Bitcoin.com's Cloud. More info: [developer.bitcoin.com/rest](https://developer.bitcoin.com/rest). Chatroom [geni.us/CashDev](http://geni.us/CashDev)",
"version": "3.11.6",
"version": "3.11.7",
"title": "REST",
"license": {
"name": "MIT",
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rest.bitcoin.com",
"version": "3.11.6",
"version": "3.11.7",
"description": "REST API for Bitcoin.com's Cloud",
"author": "Gabriel Cardona <gabriel@bitcoin.com>",
"contributors": [
Expand All @@ -24,7 +24,7 @@
},
"dependencies": {
"axios": "^0.19.0",
"bitbox-sdk": "8.3.3",
"bitbox-sdk": "8.4.2",
"bitcoincash-zmq-decoder": "0.1.5",
"body-parser": "^1.18.3",
"cashaccounts": "^0.4.2",
Expand Down
4 changes: 3 additions & 1 deletion src/routes/v2/address.ts
Original file line number Diff line number Diff line change
Expand Up @@ -845,10 +845,12 @@ async function fromXPubSingle(

let cashAddr: string = bitbox.Address.fromXPub(xpub, hdPath)
let legacyAddr: string = bitbox.Address.toLegacyAddress(cashAddr)
let slpAddr: string = SLP.Address.toSLPAddress(cashAddr)
res.status(200)
return res.json({
cashAddress: cashAddr,
legacyAddress: legacyAddr
legacyAddress: legacyAddr,
slpAddress: slpAddr
})
} catch (err) {
// Attempt to decode the error message.
Expand Down
2 changes: 1 addition & 1 deletion swaggerJSONFiles/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"openapi": "3.0.0",
"info": {
"description": "The Bitcoin Cash JSON PRC over HTTP",
"version": "3.11.6",
"version": "3.11.7",
"title": "REST",
"license": {
"name": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion swaggerJSONFilesBuilt/mainnet/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"openapi": "3.0.0",
"info": {
"description": "rest.bitcoin.com is the REST layer for Bitcoin.com's Cloud. More info: [developer.bitcoin.com/rest](https://developer.bitcoin.com/rest). Chatroom [geni.us/CashDev](http://geni.us/CashDev)",
"version": "3.11.6",
"version": "3.11.7",
"title": "REST",
"license": {
"name": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion swaggerJSONFilesBuilt/testnet/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"openapi": "3.0.0",
"info": {
"description": "trest.bitcoin.com is the REST layer for Bitcoin.com's Cloud. More info: [developer.bitcoin.com/rest](https://developer.bitcoin.com/rest). Chatroom [geni.us/CashDev](http://geni.us/CashDev)",
"version": "3.11.6",
"version": "3.11.7",
"title": "REST",
"license": {
"name": "MIT",
Expand Down
3 changes: 3 additions & 0 deletions test/v2/address.js
Original file line number Diff line number Diff line change
Expand Up @@ -1373,6 +1373,9 @@ describe("#AddressRouter", () => {
// Assert that required fields exist in the returned object.
assert.exists(result.legacyAddress);
assert.exists(result.cashAddress);
assert.isTrue(result.cashAddress.includes('bchtest:'))
assert.exists(result.slpAddress);
assert.isTrue(result.slpAddress.includes('slptest:'))
});
});
});
108 changes: 43 additions & 65 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1456,17 +1456,17 @@ bch-wallet-bridge-provider-interface@^0.1.1:
bchaddrjs "^0.2.2"
bitcoincashjs "^0.1.10"

"bchaddrjs-slp@git+https://github.com/simpleledger/bchaddrjs.git":
"bchaddrjs-slp@git://github.com/simpleledger/bchaddrjs.git#master":
version "0.2.6"
resolved "git+https://github.com/simpleledger/bchaddrjs.git#ea05d679783a6737f2f99adc37ebf485dc64f006"
uid ea05d679783a6737f2f99adc37ebf485dc64f006
resolved "git://github.com/simpleledger/bchaddrjs.git#ea05d679783a6737f2f99adc37ebf485dc64f006"
dependencies:
bs58check "^2.1.2"
cashaddrjs-slp "^0.2.11"

"bchaddrjs-slp@git://github.com/simpleledger/bchaddrjs.git#master":
"bchaddrjs-slp@https://github.com/simpleledger/bchaddrjs.git":
version "0.2.6"
uid ea05d679783a6737f2f99adc37ebf485dc64f006
resolved "git://github.com/simpleledger/bchaddrjs.git#ea05d679783a6737f2f99adc37ebf485dc64f006"
resolved "https://github.com/simpleledger/bchaddrjs.git#ea05d679783a6737f2f99adc37ebf485dc64f006"
dependencies:
bs58check "^2.1.2"
cashaddrjs-slp "^0.2.11"
Expand Down Expand Up @@ -1634,13 +1634,13 @@ bip-schnorr@^0.3.0:
random-bytes "^1.0.0"
safe-buffer "^5.0.1"

"bip21@github:Bitcoin-com/bip21":
bip21@Bitcoin-com/bip21, "bip21@github:Bitcoin-com/bip21":
version "2.0.1"
resolved "https://codeload.github.com/Bitcoin-com/bip21/tar.gz/28f8d03a3a16ed11eb5b963248ed1be8c46c6d6f"
dependencies:
qs "^6.3.0"

"bip32-utils@github:Bitcoin-com/bip32-utils#0.13.0":
bip32-utils@Bitcoin-com/bip32-utils#0.13.0:
version "0.13.0"
resolved "https://codeload.github.com/Bitcoin-com/bip32-utils/tar.gz/966fb8f0e0d4c667e4ee89adfa20c2078d66887c"
dependencies:
Expand All @@ -1649,7 +1649,7 @@ bip-schnorr@^0.3.0:
standard "^11.0.1"
tape "*"

"bip32-utils@github:Bitcoin-com/bip32-utils#0.13.1":
bip32-utils@Bitcoin-com/bip32-utils#0.13.1, "bip32-utils@github:Bitcoin-com/bip32-utils#0.13.1":
version "0.13.1"
resolved "https://codeload.github.com/Bitcoin-com/bip32-utils/tar.gz/b8a33ebd0a0ac39de7cd987e5c3f77a8c5d84e58"
dependencies:
Expand Down Expand Up @@ -1726,17 +1726,14 @@ bitbox-sdk@8.1.0:
socket.io-client "^2.1.1"
wif "^2.0.6"

bitbox-sdk@8.3.3:
version "8.3.3"
resolved "https://registry.yarnpkg.com/bitbox-sdk/-/bitbox-sdk-8.3.3.tgz#5fa5d58b47ee2d8f016e864895726f192679195a"
bitbox-sdk@8.4.2:
version "8.4.2"
resolved "https://registry.yarnpkg.com/bitbox-sdk/-/bitbox-sdk-8.4.2.tgz#0d9ebc77f92b7884faae8a1a9ebbabf48315c877"
dependencies:
"@types/bigi" "^1.4.2"
"@types/bip39" "^2.4.2"
"@types/chai" "^4.1.7"
"@types/mocha" "^5.2.6"
"@types/node" "^10.11.7"
"@types/randombytes" "^2.0.0"
"@types/sinon" "^7.0.11"
"@types/wif" "^2.0.1"
assert "^1.4.1"
axios "0.19.0"
Expand Down Expand Up @@ -1819,14 +1816,14 @@ bitcoin-cash-rpc@^0.4.2:
dependencies:
axios "^0.19.0"

bitcoin-ops@Bitcoin-com/bitcoincash-ops#1.5.0:
version "1.5.0"
resolved "https://codeload.github.com/Bitcoin-com/bitcoincash-ops/tar.gz/f1363d462fd044f35f94a220bf9568e25d985646"

bitcoin-ops@^1.3.0:
version "1.4.1"
resolved "https://registry.yarnpkg.com/bitcoin-ops/-/bitcoin-ops-1.4.1.tgz#e45de620398e22fd4ca6023de43974ff42240278"

"bitcoin-ops@github:Bitcoin-com/bitcoincash-ops#1.5.0":
version "1.5.0"
resolved "https://codeload.github.com/Bitcoin-com/bitcoincash-ops/tar.gz/f1363d462fd044f35f94a220bf9568e25d985646"

bitcoin-txdecoder@0.0.3:
version "0.0.3"
resolved "https://registry.yarnpkg.com/bitcoin-txdecoder/-/bitcoin-txdecoder-0.0.3.tgz#f9052d6ea7bb0cbc8f22c024869391296b6c86dd"
Expand All @@ -1844,50 +1841,49 @@ bitcoincash-zmq-decoder@0.1.5:
dependencies:
bitcoinjs-lib "3.3.*"

"bitcoincashjs-lib@git+https://github.com/Bitcoin-com/bitcoincashjs-lib.git":
version "4.0.1"
uid "28447b40a4ccd23913f7ade6589dc7214c99e60a"
resolved "git+https://github.com/Bitcoin-com/bitcoincashjs-lib.git#28447b40a4ccd23913f7ade6589dc7214c99e60a"
bitcoincashjs-lib@Bitcoin-com/bitcoincashjs-lib#3.3.4:
version "3.3.4"
resolved "https://codeload.github.com/Bitcoin-com/bitcoincashjs-lib/tar.gz/12fa5fe9b535816b54b9efedd6caf278d3e55b90"
dependencies:
bech32 "^1.1.2"
bigi "^1.4.0"
bip66 "^1.1.0"
bitcoincash-ops Bitcoin-com/bitcoincash-ops#2.0.0
bitcoin-ops "^1.3.0"
bs58check "^2.0.0"
create-hash "^1.1.0"
create-hmac "^1.1.3"
ecurve "^1.0.0"
merkle-lib "^2.0.10"
pushdata-bitcoin Bitcoin-com/pushdata-bitcoin#1.2.1
pushdata-bitcoin "^1.0.1"
randombytes "^2.0.1"
safe-buffer "^5.0.1"
typeforce "^1.11.3"
varuint-bitcoin "^1.0.4"
wif "^2.0.1"

"bitcoincashjs-lib@github:Bitcoin-com/bitcoincashjs-lib#3.3.4":
version "3.3.4"
resolved "https://codeload.github.com/Bitcoin-com/bitcoincashjs-lib/tar.gz/12fa5fe9b535816b54b9efedd6caf278d3e55b90"
bitcoincashjs-lib@Bitcoin-com/bitcoincashjs-lib#v4.0.0:
version "4.0.0"
resolved "https://codeload.github.com/Bitcoin-com/bitcoincashjs-lib/tar.gz/3d360c780ec7df4a74aea93664c2b5ff8b08949a"
dependencies:
bech32 "^1.1.2"
bigi "^1.4.0"
bip66 "^1.1.0"
bitcoin-ops "^1.3.0"
bitcoincash-ops Bitcoin-com/bitcoincash-ops#2.0.0
bs58check "^2.0.0"
create-hash "^1.1.0"
create-hmac "^1.1.3"
ecurve "^1.0.0"
merkle-lib "^2.0.10"
pushdata-bitcoin "^1.0.1"
pushdata-bitcoin Bitcoin-com/pushdata-bitcoin#1.2.1
randombytes "^2.0.1"
safe-buffer "^5.0.1"
typeforce "^1.11.3"
varuint-bitcoin "^1.0.4"
wif "^2.0.1"

"bitcoincashjs-lib@github:Bitcoin-com/bitcoincashjs-lib#v4.0.0":
version "4.0.0"
resolved "https://codeload.github.com/Bitcoin-com/bitcoincashjs-lib/tar.gz/3d360c780ec7df4a74aea93664c2b5ff8b08949a"
"bitcoincashjs-lib@github:Bitcoin-com/bitcoincashjs-lib#v4.0.1":
version "4.0.1"
resolved "https://codeload.github.com/Bitcoin-com/bitcoincashjs-lib/tar.gz/28447b40a4ccd23913f7ade6589dc7214c99e60a"
dependencies:
bech32 "^1.1.2"
bigi "^1.4.0"
Expand All @@ -1905,9 +1901,9 @@ bitcoincash-zmq-decoder@0.1.5:
varuint-bitcoin "^1.0.4"
wif "^2.0.1"

"bitcoincashjs-lib@github:Bitcoin-com/bitcoincashjs-lib#v4.0.1":
"bitcoincashjs-lib@https://github.com/Bitcoin-com/bitcoincashjs-lib.git":
version "4.0.1"
resolved "https://codeload.github.com/Bitcoin-com/bitcoincashjs-lib/tar.gz/28447b40a4ccd23913f7ade6589dc7214c99e60a"
resolved "https://github.com/Bitcoin-com/bitcoincashjs-lib.git#28447b40a4ccd23913f7ade6589dc7214c99e60a"
dependencies:
bech32 "^1.1.2"
bigi "^1.4.0"
Expand Down Expand Up @@ -1971,9 +1967,9 @@ bitcore-lib-cash@^0.19.0:
inherits "=2.0.1"
lodash "=4.17.11"

"bitcore-lib-cash@git+https://github.com/paOol/bitcore-lib-cash.git":
"bitcore-lib-cash@https://github.com/paOol/bitcore-lib-cash.git":
version "0.20.0"
resolved "git+https://github.com/paOol/bitcore-lib-cash.git#6812d317ee01ae20fcd341ee4ea09a848322c426"
resolved "https://github.com/paOol/bitcore-lib-cash.git#6812d317ee01ae20fcd341ee4ea09a848322c426"
dependencies:
bn.js "=4.11.8"
bs58 "=4.0.1"
Expand Down Expand Up @@ -2848,7 +2844,7 @@ code-point-at@^1.0.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77"

"coininfo@github:Bitcoin-com/coininfo":
coininfo@Bitcoin-com/coininfo, "coininfo@github:Bitcoin-com/coininfo":
version "4.0.0"
resolved "https://codeload.github.com/Bitcoin-com/coininfo/tar.gz/eece2c6141d08c3e7783929f2a1e1e681aa1a82c"
dependencies:
Expand Down Expand Up @@ -3374,7 +3370,7 @@ debug@^4.0.0, debug@^4.1.0, debug@^4.1.1, debug@~4.1.0:
dependencies:
ms "^2.1.1"

debuglog@*, debuglog@^1.0.1:
debuglog@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/debuglog/-/debuglog-1.0.1.tgz#aa24ffb9ac3df9a2351837cfb2d279360cd78492"

Expand Down Expand Up @@ -5373,7 +5369,7 @@ import-lazy@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/import-lazy/-/import-lazy-2.1.0.tgz#05698e3d45c88e8d7e9d92cb0584e77f096f3e43"

imurmurhash@*, imurmurhash@^0.1.4:
imurmurhash@^0.1.4:
version "0.1.4"
resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea"

Expand Down Expand Up @@ -6269,7 +6265,7 @@ libnpm@^2.0.1:
read-package-json "^2.0.13"
stringify-package "^1.0.0"

libnpmaccess@*, libnpmaccess@^3.0.1:
libnpmaccess@^3.0.1:
version "3.0.1"
resolved "https://registry.yarnpkg.com/libnpmaccess/-/libnpmaccess-3.0.1.tgz#5b3a9de621f293d425191aa2e779102f84167fa8"
dependencies:
Expand All @@ -6295,7 +6291,7 @@ libnpmhook@^5.0.2:
get-stream "^4.0.0"
npm-registry-fetch "^3.8.0"

libnpmorg@*, libnpmorg@^1.0.0:
libnpmorg@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/libnpmorg/-/libnpmorg-1.0.0.tgz#979b868c48ba28c5820e3bb9d9e73c883c16a232"
dependencies:
Expand All @@ -6318,15 +6314,15 @@ libnpmpublish@^1.1.0:
semver "^5.5.1"
ssri "^6.0.1"

libnpmsearch@*, libnpmsearch@^2.0.0:
libnpmsearch@^2.0.0:
version "2.0.1"
resolved "https://registry.yarnpkg.com/libnpmsearch/-/libnpmsearch-2.0.1.tgz#eccc73a8fbf267d765d18082b85daa2512501f96"
dependencies:
figgy-pudding "^3.5.1"
get-stream "^4.0.0"
npm-registry-fetch "^3.8.0"

libnpmteam@*, libnpmteam@^1.0.1:
libnpmteam@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/libnpmteam/-/libnpmteam-1.0.1.tgz#ff704b1b6c06ea674b3b1101ac3e305f5114f213"
dependencies:
Expand Down Expand Up @@ -6430,10 +6426,6 @@ lodash._basecopy@^3.0.0:
version "3.0.1"
resolved "https://registry.yarnpkg.com/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz#8da0e6a876cf344c0ad8a54882111dd3c5c7ca36"

lodash._baseindexof@*:
version "3.1.0"
resolved "https://registry.yarnpkg.com/lodash._baseindexof/-/lodash._baseindexof-3.1.0.tgz#fe52b53a1c6761e42618d654e4a25789ed61822c"

lodash._basetostring@^3.0.0:
version "3.0.1"
resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-3.0.1.tgz#d1861d877f824a52f669832dcaf3ee15566a07d5"
Expand All @@ -6449,25 +6441,11 @@ lodash._basevalues@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/lodash._basevalues/-/lodash._basevalues-3.0.0.tgz#5b775762802bde3d3297503e26300820fdf661b7"

lodash._bindcallback@*:
version "3.0.1"
resolved "https://registry.yarnpkg.com/lodash._bindcallback/-/lodash._bindcallback-3.0.1.tgz#e531c27644cf8b57a99e17ed95b35c748789392e"

lodash._cacheindexof@*:
version "3.0.2"
resolved "https://registry.yarnpkg.com/lodash._cacheindexof/-/lodash._cacheindexof-3.0.2.tgz#3dc69ac82498d2ee5e3ce56091bafd2adc7bde92"

lodash._createcache@*:
version "3.1.2"
resolved "https://registry.yarnpkg.com/lodash._createcache/-/lodash._createcache-3.1.2.tgz#56d6a064017625e79ebca6b8018e17440bdcf093"
dependencies:
lodash._getnative "^3.0.0"

lodash._createset@~4.0.0:
version "4.0.3"
resolved "https://registry.yarnpkg.com/lodash._createset/-/lodash._createset-4.0.3.tgz#0f4659fbb09d75194fa9e2b88a6644d363c9fe26"

lodash._getnative@*, lodash._getnative@^3.0.0:
lodash._getnative@^3.0.0:
version "3.9.1"
resolved "https://registry.yarnpkg.com/lodash._getnative/-/lodash._getnative-3.9.1.tgz#570bc7dede46d61cdcde687d65d3eecbaa3aaff5"

Expand Down Expand Up @@ -6553,7 +6531,7 @@ lodash.mergewith@^4.6.1:
version "4.6.1"
resolved "https://registry.yarnpkg.com/lodash.mergewith/-/lodash.mergewith-4.6.1.tgz#639057e726c3afbdb3e7d42741caa8d6e4335927"

lodash.restparam@*, lodash.restparam@^3.0.0:
lodash.restparam@^3.0.0:
version "3.6.1"
resolved "https://registry.yarnpkg.com/lodash.restparam/-/lodash.restparam-3.6.1.tgz#936a4e309ef330a7645ed4145986c85ae5b20805"

Expand Down Expand Up @@ -7544,7 +7522,7 @@ npm-pick-manifest@^2.2.3:
npm-package-arg "^6.0.0"
semver "^5.4.1"

npm-profile@*, npm-profile@^4.0.1:
npm-profile@^4.0.1:
version "4.0.1"
resolved "https://registry.yarnpkg.com/npm-profile/-/npm-profile-4.0.1.tgz#d350f7a5e6b60691c7168fbb8392c3603583f5aa"
dependencies:
Expand Down Expand Up @@ -9013,7 +8991,7 @@ readable-stream@~1.1.10, readable-stream@~1.1.9:
isarray "0.0.1"
string_decoder "~0.10.x"

readdir-scoped-modules@*, readdir-scoped-modules@^1.0.0:
readdir-scoped-modules@^1.0.0:
version "1.0.2"
resolved "https://registry.yarnpkg.com/readdir-scoped-modules/-/readdir-scoped-modules-1.0.2.tgz#9fafa37d286be5d92cbaebdee030dc9b5f406747"
dependencies:
Expand Down

0 comments on commit a022b89

Please sign in to comment.