Compare commits

...

945 Commits

Author SHA1 Message Date
sairajzero
0c8d78f6ae bug fix
Fixed: 'incomplete' property not returned in /addrs/<addr>/txs API
2023-05-10 03:06:08 +05:30
sairajzero
36d2008962 Fix: option-latest not working in post method 2023-04-27 19:35:04 +05:30
sairajzero
ea4ead21ca Adding option 'before' in address query 2023-04-27 04:02:28 +05:30
sairajzero
e6ced26b51 AddressHistory API: query option 'latest'
- using latest option will query the latest 1000 (MAX_ITEM_LIMIT) of the address
- Allowed values:
0 or false => false (DEFAULT)
1 or true => true
*nothing* => true (ie, just leave the query as ?latest)

- Address history API now also gives initItem (oldest tx in itemlist). initList is undefined if no confirmed tx available in item list
2023-04-27 02:19:47 +05:30
sairajzero
f63922b84e Adding option mempool in /addrs API
/addrs/<addrs>/txs API now supports option mempool.
Available values for mempool option:
- true: [DEFAULT] query from mempool and blocks (ie, confirmed and unconfirmed tx)
- false: do not query from mempool. (ie, confirmed tx only)
- only: query only from mempool (ie, unconfirmed tx only)
2023-04-13 03:58:59 +05:30
sairajzero
503eaf70cf addressSummarySubQuery: API chain-query
- Adding support for API chain-query for addresses with lot of txs
2023-04-11 04:01:15 +05:30
Sai Raj
285ccb1471
Merge pull request #1 from ranchimall/api-improvements
API Improvements
2023-02-06 02:17:40 +05:30
sairajzero
49356ef46c Bug fix
- Fixed: lastItem give tx details instead of txid
2023-02-05 23:36:25 +05:30
sairajzero
20eb50b281 API query options
- Deprecating options (from/to) in API `/addr/:addr`
- Adding option `after` in APIs `/addr/:addr` and  `/addrs/:addrs/txs`,
- Adding response value `lastItem` to API `/addrs/:addrs/txs`
2023-02-05 04:01:04 +05:30
sairajzero
dbb8cafdc3 Minor fixes and binding stop-flag to on-close
- Set flag_stop  when ws or http conn is closed
- Fixed: incorrect order of parameters to ws fns. ie, (ws, req) is the correct order
- Pass noTxList flag to options in show_ws and addressSummarySubQuery
- Fixed: minor typos/misspellings
2023-02-04 17:53:50 +05:30
sairajzero
f4029eaf88 Update package.json 2023-01-27 22:20:43 +05:30
sairajzero
ad9fe0c80a Fixed: sub-query APIs value conversion
- Fixed: Sat-to-Coin conversion applied over Coin value
- Fixed: totalReceived and totalSent APIs returning Sat instead of Coin value
2023-01-27 18:21:04 +05:30
sairajzero
79ed3ad330 Adding websocket api calls
The following api now have ws support for large data transmission
- /addr/:addr/
- /addrs/:addrs/txs
2023-01-27 18:05:48 +05:30
Vivek Teega
da5c5143ba Added regtest 2022-09-12 13:55:19 +05:30
KsaRedFx
823cee2d50 Correct merge conflicts to pull from master 2021-05-09 21:17:38 -04:00
Sky Young
b93f96f0a6
Merge pull request #4 from oipwg/return-floData-in-api
Return floData properly in api
2019-09-10 09:46:44 -06:00
Sky Young
cf32836440 Fix other locations that used strFloData 2019-09-10 08:41:36 -06:00
Sky Young
b76c39403c Grab floData from the correct variable 2019-09-10 08:37:57 -06:00
Sky Young
77eac048ea
Merge pull request #3 from oipwg/network-specific-addresses
Fix address returns for non-mainnet addresses
2019-08-15 16:50:22 -06:00
Sky Young
c1ad375aa7 Use network for address 2019-08-15 16:00:49 -06:00
Sky Young
1169352233
Merge pull request #2 from oipwg/update-fcoin
Update fcoin to 1.1.0
2019-07-25 10:47:54 -06:00
Sky Young
4948e4e265 Update fcoin version 2019-07-25 10:45:30 -06:00
Sky Young
e6f902dada Add a couple pools 2019-07-25 10:43:24 -06:00
Sky Young
9c0b36b965 Get the hex version of the blocks merkle root 2019-07-23 12:23:15 -06:00
Sky Young
db1152fed9 Verify merkle root exists before matching on it 2019-07-23 12:20:48 -06:00
Sky Young
474685d7c1 Use correct bcoin Block export 2019-07-23 12:07:15 -06:00
Sky Young
4804e44446 Increase flocore-lib version 2019-07-22 17:23:52 -06:00
Sky Young
ab7579ccac Update fcoin 2019-07-19 14:51:58 -06:00
bitspill
9d4a3be785
Update MLG pool info 2019-05-29 12:54:43 -07:00
Matias Alejo Garcia
34a4b3585c
Update README.md 2019-01-15 17:56:20 -03:00
Sky Young
a5ac973395 Add new Pools
Added Medici Land Governance and OIP Historian
2019-01-04 16:09:06 -06:00
Jeremiah Buddenhagen
3ceed65fa5 add Coinfoundry pool info 2018-11-26 09:55:28 -08:00
Matias Alejo Garcia
a6d4d5a1b7
Merge pull request #915 from micahriggan/feature/express-redirect-hash
Redirect /tx -> /#/tx
2018-08-30 11:46:22 -03:00
Sky Young
a4428714e0
Update README.md 2018-08-21 10:46:25 -07:00
Sky Young
cf65f963c8 Lodash any -> some
https://lodash.com/docs/3.10.1#some
2018-07-30 09:53:16 -07:00
Sky Young
5eb0687586 Swap lodash pluck to map 2018-07-30 09:49:06 -07:00
Darren Nelsen
d20425963b
Merge branch '16abhimasani-bugfix/index-highlighting' 2018-06-18 17:23:54 -04:00
Darren Nelsen
aea5e02e61
merge outpoints 2018-06-18 17:22:48 -04:00
Ash Bhimasani
651629bd5d Cleaning up Transaction Component 2018-06-08 10:29:30 -04:00
Justin Langston
1e122db75a
Merge branch 'SonicWizard-master' 2018-06-06 14:35:56 -04:00
Darren Nelsen
80c5dc1561 add toast for bad query 2018-06-05 15:08:59 -04:00
Ash Bhimasani
75e951dcc1 fix 2018-06-01 15:16:43 -04:00
Ash Bhimasani
d021d51837 Fixed Problems 2018-06-01 14:57:33 -04:00
Ash Bhimasani
7297a232bc Removed logging and comments 2018-06-01 11:11:12 -04:00
Ash Bhimasani
8734cf618a fixed lint + cleaning up 2018-06-01 11:02:01 -04:00
Ash Bhimasani
64aa9445de added index highlighting on input-output pages 2018-06-01 10:30:16 -04:00
Ash Bhimasani
7bdd0fa187 Index Highlighting 2018-05-31 14:35:37 -04:00
Darren Nelsen
67166fe5b6 fix bug that crashes block page with unparsed addresses (because of trying to split scriptSig.asm that is not present) 2018-05-23 15:58:30 -04:00
Sky Young
dda7bacca7 Don't send if headers have already been sent 2018-05-22 14:36:33 -07:00
Sky Young
5522c5649a Flip merkleRoot on transform data 2018-05-22 13:50:46 -07:00
Sky Young
9c0f824ad7 Add errors for block header undefined results 2018-05-22 13:33:20 -07:00
Sky Young
ad123dd415 Update pools info 2018-05-22 11:27:17 -07:00
Sky Young
5a1ebc74c0 Don't crash on Genesis block search 2018-05-21 17:05:51 -07:00
Sky Young
996b85883e Update fcoin version 2018-05-21 13:35:29 -07:00
Sky Young
be455b2e55 Update fcoin version 2018-05-21 13:12:03 -07:00
Sky Young
881f539fad Update supernova url 2018-05-21 13:11:52 -07:00
Sky Young
95af97b34f Update version 2018-05-21 09:13:45 -07:00
Sky Young
7f985b63bc Specify URL's to be to Flo specific links 2018-05-21 09:12:59 -07:00
Sky Young
9a83209551 Get floData from live fcoin tx object 2018-05-21 09:12:44 -07:00
Sky Young
f1166ec420 add tPool 2018-05-18 18:14:32 -07:00
Sky Young
11c3233c56 Add floData to mempool forwarded transactions 2018-05-18 18:14:28 -07:00
Sky Young
c3fa6c822e Update fcoin 2018-05-18 17:52:17 -07:00
Sky Young
d71c891add use includes instead of match 2018-05-18 16:05:51 -07:00
Sky Young
240e05a211 Grab floData correctly 2018-05-18 15:57:52 -07:00
Sky Young
582dc351f7 Set strFloData to default empty string 2018-05-18 15:56:32 -07:00
Sky Young
a4404e432a Update pool matching 2018-05-18 15:53:45 -07:00
Sky Young
b3348c4cce Update Version & packages 2018-05-18 15:23:39 -07:00
Sky Young
afb86aad20 Update status name 2018-05-18 15:23:30 -07:00
Sky Young
a51ed583fa Fix currency endpoint 2018-05-18 15:22:16 -07:00
Sky Young
5fc20a59a1 correctly return block time 2018-05-18 15:20:15 -07:00
Sky Young
6089e3b7b7 Return floData on transactions API requests 2018-05-18 15:20:10 -07:00
Justin Langston
ed642d1ff7
Merge branch 'SonicWizard-master' 2018-05-18 16:50:33 -04:00
Darren Nelsen
3026c0c3fc fix address layout 2018-05-18 14:27:28 -04:00
Darren Nelsen
1b3ef26cb6 update package info 2018-05-18 14:13:40 -04:00
Darren Nelsen
314659f9db use blocks string for deeplink and change blocks segment to fix invalid views error 2018-05-18 14:13:17 -04:00
Darren Nelsen
c88671d284 change push to use deeplink strings 2018-05-18 14:01:35 -04:00
Sky Young
e963fd25d5 Update flocore lib version 2018-05-17 10:44:21 -07:00
Sky Young
39cdb89540 Update flocore message version 2018-05-16 10:37:15 -07:00
Sky Young
3ae1f03776 Remove Bitcoin Cash stuff 2018-05-15 15:14:06 -07:00
Sky Young
9162a7f01f Add fcoin instead of bcoin :) 2018-05-10 09:30:02 -07:00
Justin Langston
b024e7e2d0
Merge pull request #925 from SonicWizard/master
fix memory leak by clearing interval on destroy hook
2018-05-02 10:19:04 -04:00
Sky Young
87bd8fa36f Remove bcoin 2018-04-30 12:23:44 -07:00
Sky Young
e1c95d0576 Update packages & Version 2018-04-30 11:11:17 -07:00
Darren Nelsen
31de1cb133 fix memory leak by clearing interval on destroy hook 2018-04-26 15:37:46 -04:00
Justin Langston
92a31e3e3b
Merge branch 'SonicWizard-master' 2018-04-25 10:23:50 -04:00
Darren Nelsen
ca69a445ff added description of blocks spec and removed console logs 2018-04-23 14:35:53 -04:00
Darren Nelsen
ddcbeba327 changed locationStrategy in order to remove hash from urls 2018-04-23 14:15:16 -04:00
Micah Riggan
cbc684ac93
Removing path redirect 2018-04-11 16:31:47 -04:00
Micah Riggan
18df6d7878
Redirect /tx to /#/tx 2018-04-11 16:23:29 -04:00
Darren Nelsen
e438c546a7 fixed tslint errors 2018-03-30 15:13:02 -04:00
Darren Nelsen
ed665a52af added block provider spec 2018-03-30 14:10:07 -04:00
Jason Dreyzehner
30852fd11c
Merge pull request #909 from SonicWizard/next
Added blockchain switcher and broadcast transaction page
2018-03-27 11:59:36 -04:00
Darren Nelsen
24e5b376ab dismiss toast if present 2018-03-26 16:18:07 -04:00
Darren Nelsen
2ac3ac8cd3 added error messaging to toast 2018-03-23 17:15:09 -04:00
Darren Nelsen
d74ca064d2 Added toast to display feedback from transaction submission 2018-03-23 15:56:01 -04:00
Darren Nelsen
055a76e7ba Added cli generated broadcast-tx page 2018-03-22 16:55:32 -04:00
Darren Nelsen
87b8319bf3 moved explorers call back into currency provider so that explorers data is available when denomination component is instantiated 2018-03-20 11:51:34 -04:00
Darren Nelsen
a345269a8d put loading flag back in; readded click on denomination selection 2018-03-16 17:54:35 -04:00
Darren Nelsen
82d5641468 moved call to explorers 2018-03-16 16:23:33 -04:00
Darren Nelsen
a2ad7e4327 Merge branch 'next' into switcher 2018-03-16 14:46:45 -04:00
Jason Dreyzehner
b4a8ddd86a
Merge pull request #906 from SonicWizard/next
Enable compatibility with insight-api and bitcore
2018-03-15 18:07:54 -04:00
Darren Nelsen
301eb5cd67 remove yarn.lock; add package-locks 2018-03-15 14:22:37 -04:00
Darren Nelsen
f23e619222 change docker image 2018-03-15 10:11:17 -04:00
Darren Nelsen
0506845c2a run ci tests headless 2018-03-14 16:45:39 -04:00
Darren Nelsen
24eda77855 changed working directory 2018-03-14 15:24:05 -04:00
Darren Nelsen
34e6089be9 udpated scripts 2018-03-14 15:12:00 -04:00
Darren Nelsen
b6c521479b updated test:ci script 2018-03-14 14:58:39 -04:00
Darren Nelsen
ad21b42b68 configure package.json test:ci script to call app/package.json test:ci script 2018-03-14 14:47:55 -04:00
Darren Nelsen
ff97b5d4fa remove e2e to try to debug circle ci 2018-03-14 13:46:49 -04:00
Darren Nelsen
f10694f8b0 remove code coverage to make circle happy? 2018-03-14 13:39:17 -04:00
Darren Nelsen
b0f659b818 remove cd from script 2018-03-14 13:28:53 -04:00
Darren Nelsen
279980ce49 add ng cli to root package.json 2018-03-14 13:06:43 -04:00
Darren Nelsen
2162e38c1a add test:ci script to root package.json 2018-03-14 12:55:34 -04:00
Darren Nelsen
dbc0690265 udpated circle config; fixed e2e test errors 2018-03-14 12:48:36 -04:00
Darren Nelsen
9ddc406b75 fixed errors in circle config 2018-03-12 17:51:24 -04:00
Darren Nelsen
065a1c7b45 added circle ci config 2018-03-12 16:37:15 -04:00
Darren Nelsen
264a379285 removed old blocks page; udpated tests; added test script 2018-03-12 13:54:22 -04:00
Darren Nelsen
3b2e65e5ad removed console logs; added jscs and jshint resource files 2018-03-09 13:48:45 -05:00
Darren Nelsen
d014ee2d6f put bitcoreNode attr in package json to enable bitcore to find scripts 2018-03-09 13:18:59 -05:00
Darren Nelsen
0473d96ab8 moved bitcoreNode to parent package.json; changed apiPrefix 2018-03-08 13:55:33 -05:00
Darren Nelsen
12775d3170 added bitcore-node dir with dependent js files 2018-03-07 15:43:45 -05:00
Darren Nelsen
84541a166d Merge branch 'next' into switcher 2018-02-13 11:57:02 -05:00
Darren Nelsen
d5b3705389 added call to explorers api for explorer switcher 2018-02-12 11:17:56 -05:00
Darren Nelsen
4e9c9f5451 added rudimentary blockchain switcher 2018-02-08 17:47:59 -05:00
Jason Dreyzehner
ab9e4de749
Merge pull request #892 from SonicWizard/next
added fee rate in sats/byte
2018-02-06 11:12:14 -05:00
Darren Nelsen
0ca9271a70 added fee rate in sats/byte 2018-02-05 17:51:46 -05:00
Jason Dreyzehner
feb5bdd9c4
Merge pull request #889 from bitjson/next
theme, polish for first release
2018-02-02 20:08:01 -05:00
Jason Dreyzehner
7dfd544992 theme, polish for first release 2018-02-02 20:06:37 -05:00
Jason Dreyzehner
468c2618b6
Merge pull request #888 from SonicWizard/next
fixed uncaught promise error when clicking back from see-all-blocks to block detail
2018-02-02 20:06:16 -05:00
Darren Nelsen
b8fdb18915 changed setRoot to push on navCtrl 2018-02-02 16:44:09 -05:00
Darren Nelsen
19a9ec567f fixed uncaught promise error when clicking back from see-all-blocks > block detail 2018-02-02 16:35:12 -05:00
Jason Dreyzehner
42f5c848db
Merge pull request #887 from bitjson/next
rm server
2018-02-02 12:11:00 -05:00
Jason Dreyzehner
39906629a6
Merge pull request #886 from SonicWizard/next
added chips on transaction component
2018-02-02 12:10:04 -05:00
Jason Dreyzehner
92db0697d7 rm server 2018-02-02 12:08:34 -05:00
Jason Dreyzehner
51199e4d87
Merge pull request #808 from SonicWizard/next
BEM-ified some of the styles
2018-02-01 15:32:37 -05:00
Darren Nelsen
7fef8d340f added chips on transaction component 2018-02-01 15:19:04 -05:00
Darren Nelsen
432f920e16 changed getConversion to getConvertedNumber on address page 2018-01-30 17:49:20 -05:00
Darren Nelsen
a8e604c9cf set currency properly when converting to USD; use number formatting on block detail for block reward 2018-01-30 17:42:45 -05:00
Darren Nelsen
d7f2b20ee1 removed console log 2018-01-30 17:31:24 -05:00
Darren Nelsen
b233467c6e completed popover with appropriate denomination units 2018-01-30 17:04:25 -05:00
Darren Nelsen
66e8cbc911 replace actionsheet with popover 2018-01-30 16:01:31 -05:00
Darren Nelsen
bcf5c54121 change proxyUrl back to local 2018-01-26 16:28:46 -05:00
Darren Nelsen
c83e16f98e Fixed denomination units with ability to change default currency (ie. BTC to BCH); Fixed bug with obtaining exchange rate (for BCH); Added number pipe on transactions component 2018-01-26 16:22:49 -05:00
Darren Nelsen
c02dd53fc5 replaced hard-coded BTC strings in currency selector to allow for other default currencies (ie. BCH); updated ionic version 2018-01-25 14:31:29 -05:00
OstlerDev
aafc5911f4 BTC -> Flo 2018-01-15 16:35:41 -08:00
Chris Kleeschulte
79855ff4c2
Bumped version. 2017-11-22 16:03:48 -05:00
Chris Kleeschulte
e07dda5031
Bumped version. 2017-11-13 14:24:26 -05:00
Chris Kleeschulte
1b86e3636f Merge branch 'master' of github.com:kleetus/insight-api 2017-11-13 14:14:24 -05:00
Chris Kleeschulte
d2ae088d8e
Removed utxo cache and removed max addresses limiting. 2017-11-13 14:13:22 -05:00
Chris Kleeschulte
e86411a6c8
Bumped version. 2017-11-13 09:55:18 -05:00
Chris Kleeschulte
3c1f4d7ef9
Merge remote-tracking branch 'upstream/feat/addr-translator' 2017-11-13 09:49:49 -05:00
Matias Alejo Garcia
72827b12a6 fix data. handling 2017-11-13 11:32:07 -03:00
Matias Alejo Garcia
136755fcda fix /addr/<1xxx> translation 2017-11-13 01:21:02 -03:00
Matias Alejo Garcia
ef451f8342 fix utxo cache 2017-11-13 01:10:28 -03:00
Matias Alejo Garcia
d3267f47ef update readme 2017-11-13 00:10:07 -03:00
Matias Alejo Garcia
5a61a2e34a translate address for inputs and outputs 2017-11-12 05:05:39 -03:00
Chris Kleeschulte
41b304c5a5
Completed websocket tests. 2017-11-10 16:54:54 -05:00
Chris Kleeschulte
de19a464b4
Bumped version. 2017-11-09 22:00:16 -05:00
Chris Kleeschulte
2e7ee86ff5
Bumped version. 2017-11-09 17:15:52 -05:00
Chris Kleeschulte
15fe096a07 wip on changing subsciption endpoints. 2017-11-09 11:42:57 -05:00
Chris Kleeschulte
5a8e1d0980
Bumped version. 2017-11-08 09:40:37 -05:00
Chris Kleeschulte
d07b5d2e9f
Bumped version. 2017-11-07 21:41:31 -05:00
Chris Kleeschulte
a51171eef1
Added a regtest for addrs/txs. 2017-11-07 21:36:18 -05:00
Chris Kleeschulte
be40b10ae9
Refectoring regtests. 2017-11-07 19:56:38 -05:00
Chris Kleeschulte
f50a7f52b2
Bumped version. 2017-11-07 15:42:29 -05:00
Chris Kleeschulte
d0d5959dce
Bumped version. 2017-11-07 13:26:18 -05:00
Chris Kleeschulte
a0c5110517
Bumped version. 2017-11-06 19:36:23 -05:00
Chris Kleeschulte
3c44ba45a1
Bumped version. 2017-11-06 19:17:20 -05:00
Chris Kleeschulte
2ef46aa5fc
Bumped version. 2017-11-05 18:39:23 -05:00
Chris Kleeschulte
80d4c0838e
Bumped version. 2017-11-02 17:45:56 -04:00
Chris Kleeschulte
18ffbfcf86
Bumped version. 2017-11-02 13:50:50 -04:00
Chris Kleeschulte
eea99afaee
Bumped version. 2017-11-02 12:05:02 -04:00
Chris Kleeschulte
dd24d8d90f
bumped version. 2017-11-01 16:04:41 -04:00
Chris Kleeschulte
9378bb1853
Bumped version. 2017-10-30 15:42:10 -04:00
Chris Kleeschulte
d8a3e80e07
Bumped version. 2017-10-26 17:54:38 -04:00
Chris Kleeschulte
7706ca4a08
Bumped version. 2017-10-26 17:14:09 -04:00
Chris Kleeschulte
bdea9e8517
Added a utxo cache. 2017-10-25 17:52:36 -04:00
Chris Kleeschulte
95d5441031
Bumped version. 2017-10-24 17:50:29 -04:00
Chris Kleeschulte
19615ea0db
Fixed test. 2017-10-24 17:41:11 -04:00
Chris Kleeschulte
533aefe07e
Bumped version. 2017-10-24 14:29:43 -04:00
Chris Kleeschulte
7809b84d55
Fixed streaming of multiutxos. 2017-10-24 14:17:47 -04:00
Chris Kleeschulte
6f9305c49f
Bump version. 2017-10-20 13:19:56 -04:00
Chris Kleeschulte
877012d992
Fixed tests. 2017-10-20 13:05:49 -04:00
Chris Kleeschulte
9e216a818a Streamed multiutxos. 2017-10-20 10:42:47 -04:00
Chris Kleeschulte
f862a7696b
Bumped version. 2017-10-18 19:20:45 -04:00
Chris Kleeschulte
2f4c55bb58
Fixed test. 2017-10-18 19:12:49 -04:00
Chris Kleeschulte
c87e676ca8
Changed back to getDetailedTransaction. 2017-10-18 19:05:54 -04:00
Chris Kleeschulte
201a0c4bcd
Adding in spent status. 2017-10-17 19:40:01 -04:00
Chris Kleeschulte
9225739901
Bumped version. 2017-10-12 19:09:58 -04:00
Chris Kleeschulte
57fe37cbe5
Bumped version. 2017-10-12 18:01:31 -04:00
Chris Kleeschulte
9b3d716618
Bumped version. 2017-10-12 15:09:12 -04:00
Chris Kleeschulte
ce59c975b1
Bumped version. 2017-10-11 17:23:30 -04:00
Chris Kleeschulte
5efc55aef3
Bumped version. 2017-10-11 16:40:34 -04:00
Chris Kleeschulte
8a6edc5ec6
Fixed regtest for reorg. 2017-10-11 16:35:31 -04:00
Chris Kleeschulte
1103eb9dd8
Mainchain will always be true. 2017-10-10 14:11:21 -04:00
Chris Kleeschulte
8196b1e081
Added check for missing header. 2017-10-10 09:27:50 -04:00
Chris Kleeschulte
61da556645
Bumped version. 2017-10-09 17:55:40 -04:00
Chris Kleeschulte
01fafcf066
Fixed regtest for reorg. 2017-10-09 17:23:10 -04:00
Chris Kleeschulte
89d8da3a67
Fixed tests. 2017-10-09 10:23:03 -04:00
Chris Kleeschulte
5be6d0d724
Fixed response for not returning a header. 2017-10-09 09:49:31 -04:00
Chris Kleeschulte
0fe9d92663
Bumped version. 2017-10-08 15:41:29 -04:00
Chris Kleeschulte
efa8bc01c1
Fixed variable name. 2017-10-08 14:16:06 -04:00
Chris Kleeschulte
3923f260e8
Minor fixes. 2017-10-06 14:50:32 -04:00
Chris Kleeschulte
fbef2d85fa
Removed console.log. 2017-10-04 18:08:21 -04:00
Chris Kleeschulte
adffdd5401
Added more reorg tests. 2017-10-04 18:01:03 -04:00
Chris Kleeschulte
b6b730ea2a
Fixing recently sent txs. 2017-10-04 08:33:42 -04:00
Chris Kleeschulte
d3515e12c9
Bumped version. 2017-10-02 16:35:33 -04:00
Chris Kleeschulte
9cbc66743d
Fixed fake bitcoind to return the correct headers when asked. 2017-10-02 16:34:15 -04:00
Darren Nelsen
26571f0f43 fixed datetime format and font size on transaction component 2017-10-02 16:18:53 -04:00
Chris Kleeschulte
34928cac18
Added more reorg regtests. 2017-10-01 19:12:25 -04:00
Chris Kleeschulte
d93fc791e3
Fixed tests. 2017-09-28 21:59:45 -04:00
Chris Kleeschulte
ed1ed7b8b9
Fixed incoming req.addrs checking. 2017-09-27 19:20:42 -04:00
Chris Kleeschulte
6ba483d2b4
Bumped version. 2017-09-27 14:21:42 -04:00
Chris Kleeschulte
430956ad1e
Added a log about which bitcored you are using during the test run. 2017-09-27 10:20:09 -04:00
Chris Kleeschulte
110ee2ded3
Added block listener back in. 2017-09-26 19:38:13 -04:00
Darren Nelsen
1fefd25a87 minor code formatting/whitespace 2017-09-26 16:28:31 -04:00
Darren Nelsen
e74ca5ee57 replaced spans with ion-notes; changed font size of ion-items 2017-09-26 13:02:41 -04:00
Chris Kleeschulte
bf56ace9f9
Bumped version. 2017-09-26 12:27:35 -04:00
Chris Kleeschulte
827470fd71
Fixed tests for network type. 2017-09-26 11:02:18 -04:00
Chris Kleeschulte
4f6eb68c50
Fixed transaction transformation. 2017-09-25 21:21:54 -04:00
Chris Kleeschulte
e31ec2f276
Chnaged ui to pull from p2p for txs and not the mempool service. 2017-09-25 16:18:17 -04:00
Darren Nelsen
1efdaca2e8 moved search call to form ngSubmit event 2017-09-25 14:13:38 -04:00
Darren Nelsen
f0dbd5b5d6 used semantic ion-note tag for block data fields; fixed spacing of merkle root field 2017-09-25 11:10:28 -04:00
Chris Kleeschulte
f48bf8f246
Bumped version. 2017-09-24 12:37:05 -04:00
Chris Kleeschulte
76b9ff5042
Added more tests. 2017-09-24 12:32:41 -04:00
Chris Kleeschulte
423eb31992
Regtest for reorg. 2017-09-19 08:50:12 -04:00
Chris Kleeschulte
0f9e13c7d4
Updated regtests. 2017-09-12 09:17:36 -04:00
Chris Kleeschulte
7de52afbe6
Fixed reorg. 2017-09-08 14:11:25 -04:00
Chris Kleeschulte
ee1ea93195
Added performance tests.
Changed getInfo from header service to block service.
2017-09-07 18:59:15 -04:00
Darren Nelsen
2ae129fd94 styled the fee and confirmation row in the grid of the transaction component 2017-09-05 17:22:53 -04:00
Darren Nelsen
dd99426add minor styling changes on transaction component 2017-08-31 12:54:44 -04:00
Darren Nelsen
3091810320 more BEM-ification 2017-08-31 12:40:01 -04:00
Darren Nelsen
93ad3534f6 BEM-ified the lastest-blocks and latest-transactions components 2017-08-31 11:20:15 -04:00
Chris Kleeschulte
27b32efbf0
Bumped version. 2017-08-29 16:23:42 -04:00
Justin Langston
389e752096 Merge pull request #806 from SonicWizard/next
added proxy to pull data from proper url
2017-08-29 16:12:32 -04:00
Justin Langston
9e2a875027 Merge pull request #805 from tenthirtyone/next-merge
Next-merge API updates
2017-08-29 16:12:00 -04:00
Chris Kleeschulte
4563a8ffaa
Fixed network for bcoin. 2017-08-29 16:09:31 -04:00
Chris Kleeschulte
07430955bd
Fixed totalsent. 2017-08-28 17:09:51 -04:00
Chris Kleeschulte
32155cead7
Added regtests for all routes. 2017-08-28 14:00:32 -04:00
tenthirtyone
2146ff290b index block on tx model 2017-08-28 12:49:46 -04:00
tenthirtyone
ee0d5595b3 move models into lib 2017-08-28 00:38:48 -04:00
tenthirtyone
1a18a369c1 Save logic moved to models. Parsers removed 2017-08-27 23:44:08 -04:00
tenthirtyone
b836390b22 remove sockets 2017-08-27 22:53:39 -04:00
tenthirtyone
56078e2487 move cors to middleware 2017-08-27 22:38:40 -04:00
tenthirtyone
5f7e2b7613 removed old audit code 2017-08-27 22:30:41 -04:00
tenthirtyone
4ba24bba25 input sanitization moved to middleware 2017-08-27 21:58:04 -04:00
tenthirtyone
e7fd05afe9 Merge remote-tracking branch 'upstream/next' into next-merge 2017-08-27 21:55:41 -04:00
tenthirtyone
cbcd42c096 remove tx.size until bcoin pr is merged 2017-08-27 21:53:42 -04:00
Chris Kleeschulte
da8920c4dc
Fixed block responses. 2017-08-25 17:35:43 -04:00
tenthirtyone
df2beddf16 Better input handling. Huge increase in performance and accuracy. 2017-08-25 17:27:15 -04:00
tenthirtyone
afc063fb97 sync & async saving. Bleh 2017-08-25 10:47:03 -04:00
Darren Nelsen
45a8c809a3 added proxy to pull data from proper url 2017-08-24 16:48:22 -04:00
tenthirtyone
12cb8a0c29 Graceful Shutdown for mongodb 2017-08-24 15:26:57 -04:00
tenthirtyone
333eec3dd8 Reset Bcoin chain if blocks are missing from mongo. 2017-08-24 14:42:50 -04:00
tenthirtyone
2ccaf2fce0 Reliably update inputs. Self-healing. Audit Mongo blockheights 2017-08-24 14:28:21 -04:00
Chris Kleeschulte
5e5a58db19 Fixed tests. 2017-08-24 09:38:07 -04:00
tenthirtyone
a3941f75ef Update inputs 2017-08-23 23:25:36 -04:00
Jason Dreyzehner
fbfd9ecb34 Merge pull request #804 from SonicWizard/next
Completed Latest Transactions
2017-08-23 13:43:56 -04:00
Darren Nelsen
ccf681dda7 added input parm for refresh timer seconds on latest-transactions component 2017-08-23 11:42:38 -04:00
tenthirtyone
c560ae3cff fix bestHeight bug 2017-08-23 11:17:49 -04:00
Darren Nelsen
2ac2822257 removed console logs; added a seconds var for latest transactions refresh 2017-08-23 10:41:10 -04:00
Darren Nelsen
07cd0cbd8f added refresh timer to latest transactions; styled latest transactions grid 2017-08-22 17:17:13 -04:00
Justin Langston
421d0ef8f4 Merge pull request #801 from tenthirtyone/next-merge
Next merge
2017-08-22 15:50:21 -04:00
Darren Nelsen
9848b17fc1 added call to new txs endpoint; changed html to reflect txid and valueOut in transactions grid 2017-08-22 14:34:24 -04:00
Darren Nelsen
b9de71862d Merge branch 'next-merge' of https://github.com/tenthirtyone/insight into next 2017-08-22 14:11:10 -04:00
tenthirtyone
52ebe7dde0 bugfix, return array instead of object 2017-08-22 14:10:19 -04:00
Darren Nelsen
b21e11b8fb Merge branch 'next-merge' of https://github.com/tenthirtyone/insight into next 2017-08-22 13:44:36 -04:00
Darren Nelsen
8a1d8e6df2 pull in transactions from new endpoint 2017-08-22 13:30:01 -04:00
tenthirtyone
d86cdd3678 Fix /txs default return to return the properly transformed response 2017-08-22 10:34:55 -04:00
Darren Nelsen
201a3871a0 Merge branch 'next-merge' of https://github.com/tenthirtyone/insight into next 2017-08-22 10:15:24 -04:00
Darren Nelsen
c6b0e66a42 Merge branch 'next' of https://github.com/bitpay/insight into next 2017-08-22 10:08:50 -04:00
tenthirtyone
067592df50 helmet and static expires header 2017-08-22 01:44:51 -04:00
tenthirtyone
a9493190c2 fix max tx 2017-08-22 01:23:12 -04:00
tenthirtyone
479d55de4a check for findOne null 2017-08-22 01:17:44 -04:00
tenthirtyone
c2c51e709a more cleaning up 2017-08-22 00:29:10 -04:00
tenthirtyone
e5ad52f55d fixed search by addr checking for address. Eventually move these to middleware 2017-08-21 22:57:43 -04:00
tenthirtyone
98164e4447 paging added back. Going over max config limit will default to config limit and still support paging. 2017-08-21 22:53:04 -04:00
tenthirtyone
cae4a45572 Massive debug/dev code cleanup. Most db logic moved to models. 2017-08-21 22:38:20 -04:00
tenthirtyone
050f45015a cleaned up tx db. Moved logic to models. API next 2017-08-21 21:55:09 -04:00
tenthirtyone
efe19444d5 getTxById added to model 2017-08-21 21:08:41 -04:00
Darren Nelsen
743c060463 added ion-grid to latest-transactions component 2017-08-21 18:00:39 -04:00
Chris Kleeschulte
a1ca054fb8 Fixed tests. 2017-08-21 17:13:49 -04:00
tenthirtyone
801fbf62e8 Change FE to relative request paths. 2017-08-21 14:01:08 -04:00
tenthirtyone
e3d6ef0039 Merge remote-tracking branch 'upstream/next' into next-merge 2017-08-21 10:19:52 -04:00
Justin Langston
a66573dbc1 Merge pull request #800 from SonicWizard/next
Added Home page with latest blocks and latest transactions (placeholder)
2017-08-20 10:54:48 -04:00
tenthirtyone
37744ec85a mongo fixed up 2017-08-19 21:03:54 -04:00
tenthirtyone
968ab3c103 merge mongo changes 2017-08-19 20:59:37 -04:00
tenthirtyone
46842c9cc5 tx by address wired up 2017-08-19 04:07:09 -04:00
tenthirtyone
697388f1ce pre cleanup. Running entirely on mongo. 2017-08-19 03:15:17 -04:00
Jason Dreyzehner
8f4029b3e5 chore(release): 5.0.0-beta.1 2017-08-18 18:31:53 -04:00
Darren Nelsen
d4d5e500d6 hide the "mined by" column when in "portrait" mode 2017-08-18 18:00:17 -04:00
Darren Nelsen
d5adf90a9b added input parms for latest-blocks component; replaced block grid on blocks page with latest-blocks component 2017-08-18 17:08:58 -04:00
Chris Kleeschulte
794ae55610 Fixed status 2017-08-18 20:09:11 +00:00
Darren Nelsen
5e79d1d4f3 wrapped setInterval in ngZone to make e2e tests work properly 2017-08-18 15:59:57 -04:00
Justin Langston
9026a3d27f Merge pull request #799 from tenthirtyone/next-merge
Changes for next branch
2017-08-18 15:31:14 -04:00
Chris Kleeschulte
3287af4974 Merge pull request #517 from unusualbob/feature/blockStream
Use transform stream instead of async for /blocks
2017-08-18 15:28:41 -04:00
Rob Riddle
2122b01023 Use transform stream instead of async for /blocks 2017-08-18 15:22:47 -04:00
Darren Nelsen
44e85f0dec added See All Blocks button to latest-blocks component; created new BlocksPage with ionic convention; deprecated previous BlocksPage; fixed e2e tests 2017-08-18 15:08:36 -04:00
tenthirtyone
14cb4e3332 clean up console log and fix return statements 2017-08-18 14:19:10 -04:00
tenthirtyone
8231ed6a1e clean up console log and fix return statements 2017-08-18 14:17:15 -04:00
Darren Nelsen
722eb21cfb Added interval to get latest blocks and styled latest blocks grid 2017-08-18 11:33:41 -04:00
tenthirtyone
805e5ec0c3 top n txs setup 2017-08-17 17:49:54 -04:00
tenthirtyone
9b7336b066 New models and parser up 2017-08-17 17:44:47 -04:00
tenthirtyone
d2f68fefe9 need new mongo models from another branch 2017-08-17 17:41:07 -04:00
Darren Nelsen
cdbc84e93a added loading spinner and links to block detail 2017-08-17 16:42:09 -04:00
tenthirtyone
898e373b77 Add util to other routes for input validation. 2017-08-17 16:28:30 -04:00
Darren Nelsen
f2196bc297 added angular2-moment library; added a BlocksProvider; added latest blocks grid to home page 2017-08-17 16:20:40 -04:00
Alex
3f7ad54b2e Merge pull request #1 from unusualbob/feature/txEndpointValidation
transaction.js validation
2017-08-17 15:20:09 -04:00
Alex
5d91e48afa Merge branch 'next-merge' into feature/txEndpointValidation 2017-08-17 15:19:50 -04:00
tenthirtyone
d148b5ec77 updated readme instructions 2017-08-17 15:17:23 -04:00
tenthirtyone
4b6482e0ad add scriptsigs to txs for circle-plus info on tx lists 2017-08-17 14:37:08 -04:00
Darren Nelsen
879b87f2a6 added LatestTransactions and LatestBlocks components with simple placeholders 2017-08-17 11:47:31 -04:00
tenthirtyone
5a89cf17d2 All routes replaced. Stable but no tx inputs working. 2017-08-17 11:25:58 -04:00
Darren Nelsen
e2c69203ec Fixed e2e tests 2017-08-17 11:03:08 -04:00
tenthirtyone
31eecc5afe reduced block model and parsing. 2017-08-17 00:44:50 -04:00
tenthirtyone
8d733df278 Tx Parsing and updating input values 2017-08-17 00:26:32 -04:00
tenthirtyone
a5d74393d1 tx size, tx parser, mongo replies for tx by hash 2017-08-16 23:07:06 -04:00
tenthirtyone
1b0c1b1250 Bringing back other parsers 2017-08-16 22:49:13 -04:00
tenthirtyone
3e7f263e18 bestBlockHeight set by node now. Less cb Hell. 2017-08-16 21:56:56 -04:00
tenthirtyone
1cb0a6b385 indexes and experimenting with mem db 2017-08-16 21:23:29 -04:00
Darren Nelsen
1f974e5176 styled the About section 2017-08-16 17:23:21 -04:00
Darren Nelsen
05503371cf add "powered by" icons 2017-08-16 16:51:09 -04:00
Darren Nelsen
0cbff08f59 added HomePage 2017-08-16 16:33:45 -04:00
Rob Riddle
1218726ffc This adds some basic regex validation on query parameters to harden against attacks and reduce time to error. Address validation could likely be improved beyond just regex, but this will do for now 2017-08-16 16:31:57 -04:00
tenthirtyone
2ac70bc9a2 Fixed Bcoin error returned as data, fixed dead /txs endpoint missing error, added ttl to bcoin requests but large addrs still take too long 2017-08-16 16:30:33 -04:00
Darren Nelsen
c817f5e62c update ionic-cli 2017-08-16 15:10:18 -04:00
Jason Dreyzehner
9a80486227 Merge pull request #798 from SonicWizard/ionic
Added Search toggle and loading spinners for pages and transaction component
2017-08-16 14:13:44 -04:00
tenthirtyone
c47f58f8e8 Clean up eslint complaints 2017-08-16 14:13:18 -04:00
tenthirtyone
e5b608809b Fix Coinbase in blocks and address. Remove console log from compiled js (removed from temp previousl) 2017-08-16 12:49:37 -04:00
Darren Nelsen
c9a1b6b153 added spinners to transaction and address pages and transaction list component 2017-08-16 12:46:08 -04:00
tenthirtyone
515884bf63 Fix isCoinBase typo and add comments 2017-08-16 12:39:12 -04:00
Darren Nelsen
90379522fe added spinner to block detail 2017-08-16 11:11:20 -04:00
tenthirtyone
958fc79204 Fix return val in transactions.js for bestBlockHeight 2017-08-16 10:40:50 -04:00
tenthirtyone
ad39b6337c comment updates 2017-08-16 02:02:19 -04:00
tenthirtyone
06b0e108d5 socket reworking to reduce coupling 2017-08-16 01:47:30 -04:00
tenthirtyone
2f4533e057 getBestHeight added to db api 2017-08-16 01:13:30 -04:00
tenthirtyone
3b8b900405 More cleanup, naming fixes and comments 2017-08-16 01:08:05 -04:00
tenthirtyone
e3b8413eee Moved db configs to config file. Dropped time from log files. Simple commenting 2017-08-16 00:52:11 -04:00
tenthirtyone
2eac46fdb5 transactions added to db api 2017-08-16 00:17:45 -04:00
tenthirtyone
1d029fcf7f getBlocks completely in db api 2017-08-16 00:00:52 -04:00
tenthirtyone
b0f95d93ab All API but tx & socket cleaned up, blocks db api done 2017-08-15 23:14:24 -04:00
tenthirtyone
ecee54c10b Address API cleaned up. Unnecessary db calls removed 2017-08-15 21:55:48 -04:00
tenthirtyone
d278dbdb7c Blocks DB API up 2017-08-15 21:29:59 -04:00
tenthirtyone
1777be323c Message verification and bitcore-message added 2017-08-15 20:29:38 -04:00
tenthirtyone
0c04a55fd0 use app 404 page and clean up console log 2017-08-15 20:15:01 -04:00
Chris Kleeschulte
5bcfd8fcd8 Fixed current difficulty. 2017-08-15 17:05:04 -04:00
Darren Nelsen
7d2b27be7d added toggle to searchbar; made text selectable 2017-08-15 16:36:11 -04:00
Chris Kleeschulte
21e30645cd Various repairs. 2017-08-15 15:43:13 -04:00
tenthirtyone
afd68116e7 broadcast tx 2017-08-15 15:41:25 -04:00
Justin Langston
ec208e93ab Merge pull request #797 from SonicWizard/ionic
Updates and bug fixes to TransactionComponent
2017-08-15 14:36:01 -04:00
Chris Kleeschulte
d866dd7a65 Retrofitting for new bitcore-node. 2017-08-15 13:31:42 -04:00
tenthirtyone
358662fb84 add tx paging and protections 2017-08-15 11:38:40 -04:00
Darren Nelsen
cf4d45cf59 fixed responsiveness in the transaction grid 2017-08-15 11:15:10 -04:00
tenthirtyone
6659148d4b fix bad txid 2017-08-15 10:59:40 -04:00
tenthirtyone
bf26304746 Remove index from txs. Explicit return and fix spent and received in addr. 2017-08-15 10:42:36 -04:00
tenthirtyone
a3e4e19a9d address summary finished 2017-08-15 04:37:53 -04:00
tenthirtyone
17acbdda6d messiest yet, bump confs by 1 2017-08-15 04:11:22 -04:00
tenthirtyone
2b8eee6e03 Confirmations wired up for blocks txs and addr views 2017-08-15 04:09:28 -04:00
tenthirtyone
dd0e0bedf0 update tx fees div 1e8 2017-08-15 03:19:21 -04:00
tenthirtyone
69538704f6 sync, status and last block hash finished 2017-08-15 03:12:23 -04:00
tenthirtyone
4b71ae91ae moved rpc settings to config. Little confusing as is. Needs improvement 2017-08-15 02:24:30 -04:00
tenthirtyone
b1e540c8df RPC hookups fill the gaps way better than mongo in some places. See changes 2017-08-15 02:00:04 -04:00
tenthirtyone
90adbf3ece remove Block from status 2017-08-14 22:10:00 -04:00
Darren Nelsen
0fe359bd1f get scriptSigs working again in expanded view 2017-08-14 18:44:57 -04:00
tenthirtyone
9045eacccd Fixed txs per request to only save block w/ subdocs 2017-08-14 17:58:12 -04:00
tenthirtyone
e210e34dbc Merge branch 'txs-by-address' into next-merge 2017-08-14 17:19:14 -04:00
tenthirtyone
5a78d523a8 Merge branch 'turn-off-tx-saving' into next-merge 2017-08-14 17:19:10 -04:00
Darren Nelsen
a554e43c07 Added aggregateItems 2017-08-14 17:01:19 -04:00
tenthirtyone
ba1333f84f PR review catches and cleanups 2017-08-14 02:02:28 -04:00
Justin Langston
5e1e80a858 Merge pull request #793 from SonicWizard/ionic
Update CurrencyProvider with USD. Enable denomination changes on all the things.
2017-08-12 08:57:53 -04:00
Darren Nelsen
34792d5d65 fixed bug where block detail did not retain data after leaving view and coming back 2017-08-11 17:29:29 -04:00
Justin Langston
5b919a6dc5 Merge pull request #790 from tenthirtyone/next
Merging last commits & clean up logs/readme
2017-08-11 11:52:45 -04:00
Darren Nelsen
2226a2cc18 fixed lint warnings and tests 2017-08-11 10:42:34 -04:00
Darren Nelsen
1dfe384271 added USD conversion; added conversion to address page 2017-08-11 10:33:44 -04:00
tenthirtyone
e27c7bcf87 Address page working. Address details stubbed 2017-08-11 00:18:03 -04:00
tenthirtyone
741a234c76 Removing saving from tx parser. Only use for emitting block txs for now. Increase tx socket delay 2017-08-10 23:41:59 -04:00
tenthirtyone
4ef0949061 returning data 2017-08-10 23:39:08 -04:00
tenthirtyone
4a0138b666 Remove console logs. Fix cors 2017-08-10 23:05:48 -04:00
tenthirtyone
68af224331 Merge remote-tracking branch '1031/master' into next 2017-08-10 21:07:28 -04:00
Chris Kleeschulte
b63a2208fc Fixes to allow bcoin to work with Transaction controller. 2017-08-10 18:56:13 -04:00
tenthirtyone
301e36b5c4 CORS added 2017-08-10 17:56:57 -04:00
tenthirtyone
46c9027bdb Fixed tx value out on home page 2017-08-10 17:56:21 -04:00
Jason Dreyzehner
0ffef469df chore: rm the old, in with the new 2017-08-10 17:53:53 -04:00
Darren Nelsen
8ba0a07772 fixed tslint issues 2017-08-10 17:48:48 -04:00
Darren Nelsen
3bc5959075 Added currency conversion to transaction component 2017-08-10 17:44:51 -04:00
Darren Nelsen
db5bf4420a fixed e2e tests by adding provider dependencies 2017-08-10 17:35:17 -04:00
Darren Nelsen
ac656802c9 fixed lint warnings; renamed action sheet title 2017-08-10 17:30:46 -04:00
Darren Nelsen
5a551a5e3b add currency conversion button and action sheet 2017-08-10 17:19:31 -04:00
Jason Dreyzehner
2d1f504a3f Add 'server/' from commit 'eb7e5d10c97aafa302dfd4e7fd67a6bc2938c0a1'
git-subtree-dir: server
git-subtree-mainline: f35d7dd960
git-subtree-split: eb7e5d10c9
2017-08-10 17:08:14 -04:00
Darren Nelsen
1fc35956cb style the summary items and labels 2017-08-10 16:12:06 -04:00
Jason Dreyzehner
f35d7dd960 Merge pull request #787 from SonicWizard/ionic
Add Address and Transaction pages; Refactor TransactionsComponent to TransactionListComponent
2017-08-10 15:05:11 -04:00
Darren Nelsen
4c3a28c780 added CurrencyProvider and associated spec 2017-08-10 14:39:35 -04:00
tenthirtyone
eb7e5d10c9 block & tx throttling through the sockets. Blocks emits every 10s. Tx every 100 tx 2017-08-10 14:20:13 -04:00
tenthirtyone
bdbb086e10 socket moved to api level and socket block refresh signal set to 5s 2017-08-10 13:29:35 -04:00
tenthirtyone
923128de59 Socket architecture change. More maleable/easier to wire up events with the node 2017-08-10 13:16:55 -04:00
tenthirtyone
22c2642653 Added insight ui to sub folder, build there move to top level public - hack. Wired Socket listener 2017-08-10 12:33:11 -04:00
tenthirtyone
8d70c017ed update readme, config defaults 2017-08-10 00:00:02 -04:00
tenthirtyone
83a9388e99 Set bcoin prefix to cwd and add chain.ldb to gitignore 2017-08-09 23:18:13 -04:00
Chris Kleeschulte
5a49f5c6c2 Added fixes for blocks route. 2017-08-09 19:41:50 -04:00
Chris Kleeschulte
c61490ed62 WIP changes for next version 2017-08-09 18:11:03 -04:00
Darren Nelsen
5667e0b12e fix ellipsis on vin.scriptSig 2017-08-09 17:15:32 -04:00
Darren Nelsen
f6c4ff0990 move ellipsis to wrapping (block level) elements 2017-08-09 17:01:57 -04:00
Darren Nelsen
60914a1358 add qrcode generator 2017-08-09 16:38:50 -04:00
Darren Nelsen
402006f835 move ellipsis to global styles 2017-08-09 15:29:04 -04:00
tenthirtyone
7f87a3a9d7 Updated readme 2017-08-09 00:02:21 -04:00
tenthirtyone
7beb1867d7 block limits added, currency fixed, FE routes added 2017-08-08 23:52:39 -04:00
Darren Nelsen
4473bfd5df added Split pipe 2017-08-08 17:37:40 -04:00
Darren Nelsen
7e55c1b6f8 add vin expanded values 2017-08-08 14:08:51 -04:00
Darren Nelsen
269bbfe549 add expand toggle; add expanded output attributes 2017-08-08 13:11:36 -04:00
tenthirtyone
0174fd5226 socket added but not wired up with front ent 2017-08-08 01:40:12 -04:00
tenthirtyone
1ad21a667c block txs partially wired up 2017-08-08 00:58:09 -04:00
tenthirtyone
8d676886de Insight Ui wired up 2017-08-07 23:57:20 -04:00
tenthirtyone
fc1284b374 sync mocked readme updated. 2017-08-07 22:09:56 -04:00
tenthirtyone
5bf176485b logging out inputs and outputs for parsing & attaching to addresses 2017-08-07 15:28:58 -04:00
tenthirtyone
1143bd803a Move tx subdocs into their own files 2017-08-07 10:34:04 -04:00
tenthirtyone
3efd16c6af Stubbing status, prepping txs for blockhash and addr 2017-08-07 09:13:36 -04:00
tenthirtyone
23d858f4b3 Uncoupled tx parsing from block parsing inside the bcoin node 2017-08-06 20:53:43 -04:00
tenthirtyone
f7bdf8d0a9 removed test 2017-08-06 20:51:13 -04:00
tenthirtyone
d7a70d5456 blocks & tx routes mostly complete updating models for need 2017-08-05 20:36:17 -04:00
tenthirtyone
7948a63875 curren api finished. parser json var names normalized. Switched to express 4 router 2017-08-05 15:03:48 -04:00
tenthirtyone
b74e98c381 fix txJSON naming. 2017-08-05 13:26:59 -04:00
tenthirtyone
a038159526 Models updated to match bcoin data 2017-08-05 02:13:36 -04:00
tenthirtyone
d9a9b64650 block model mirroring bcoin toJson. Indexes removed for dev work. 2017-08-05 00:58:03 -04:00
tenthirtyone
b13d8df2de Parsers moved to their own files, full node added to config. 2017-08-05 00:41:26 -04:00
Darren Nelsen
3b873f4841 put vins and vouts into ion-lists; add fee, confirmation, and value data 2017-08-04 17:41:29 -04:00
Darren Nelsen
b48ff0adfa replace grids with lists in summaries 2017-08-04 17:11:07 -04:00
Alex
434b077467 Merge pull request #1 from tj-bitpay/new_branch
first alteration and find
2017-08-04 17:02:39 -04:00
Thomas Bright
1d160803c3
first alteration and find 2017-08-04 16:59:58 -04:00
Darren Nelsen
abb65a4394 put block data in ion-list 2017-08-04 16:45:36 -04:00
Darren Nelsen
dfccb2ea72 started putting data items in ion-grid 2017-08-04 15:56:45 -04:00
tenthirtyone
6e70484362 Block API dried up and mostly complete. Blocks still needs date params support 2017-08-04 15:39:04 -04:00
tenthirtyone
7afbdb41b1 Block API made more dry, rawblocks added to model 2017-08-04 14:29:10 -04:00
Darren Nelsen
0c7bb4d1f6 Added HeadNavComponent to use on all pages 2017-08-04 14:04:20 -04:00
tenthirtyone
e5ab809026 House cleaning, var names, package.json updates, config modifications 2017-08-04 12:35:59 -04:00
Darren Nelsen
aac27ff520 add more fields to blocksPage; add link to block 2017-08-04 11:23:58 -04:00
tenthirtyone
045c53accb Handling Mongo connection errors and starting bcoin once the db connects 2017-08-04 10:53:00 -04:00
tenthirtyone
63f60d06eb README formatting 2017-08-04 10:32:17 -04:00
tenthirtyone
857d56aa74 fixed first install and startup problem from logs folder not being stored in git 2017-08-04 10:31:38 -04:00
tenthirtyone
0c6868564f Cleaned up Readme and moved json spaces to config 2017-08-04 00:45:02 -04:00
tenthirtyone
0bbf9119e2 Prettied require statements 2017-08-03 23:10:03 -04:00
tenthirtyone
591d904212 Route functions named. Node & Parsers moved to their own files 2017-08-03 22:52:58 -04:00
tenthirtyone
836a2c4457 Config renamed to index.js for implicit importing. Moved routes to their own files 2017-08-03 22:18:12 -04:00
tenthirtyone
a5528e49d8 db connection moved to index.js to be a little more explicit. Cleaned up some comments and console logs 2017-08-03 21:45:35 -04:00
Darren Nelsen
b274b363ff added search by block hash 2017-08-03 18:24:48 -04:00
tenthirtyone
43b23b80dc Transaction, Input and Output models are wired or stubbed. Tomorrow/Tonight I wire up the API 2017-08-03 18:08:04 -04:00
Darren Nelsen
c1523966f8 added transaction and address search to blocksPage 2017-08-03 17:58:11 -04:00
Darren Nelsen
8a0d065296 Added ApiProvider to test.ts in order to make tests pass 2017-08-03 16:26:49 -04:00
tenthirtyone
7d5cade288 Transactions syncing, inputs and outputs mocked up. Bcoin data for tx, inputs and outputs varies depending on the vanilla object vs the object.toJSON() method Bcoin attaches to its primitives. Will likely need to redress this as Bcoin changes but for now this is how we move forward. 2017-08-03 16:19:53 -04:00
Darren Nelsen
440a007915 Moved apiPrefix into api provider; put transaction list into ion-grid 2017-08-03 15:43:47 -04:00
tenthirtyone
ea7e7aae34 Processing tx, input and output. About to refactor tx models to fit insight 2017-08-03 15:21:07 -04:00
Darren Nelsen
9f3a5d2bc8 fix lint warnings 2017-08-03 12:17:51 -04:00
tenthirtyone
8c5f296980 Input/Output moved back inside Transaction model file 2017-08-03 11:52:23 -04:00
tenthirtyone
3bf0fe7328 Transaction Models and updated config requires 2017-08-03 11:42:24 -04:00
Darren Nelsen
263933efcd Add transaction component to transaction page to show transaction details 2017-08-03 11:27:06 -04:00
Darren Nelsen
b656fb55d5 Moved transaction code from transaction-list to transaction component 2017-08-03 11:17:36 -04:00
Darren Nelsen
736b85e9df replaced TransactionsComponent with TransactionListComponent; added TransactionComponent placeholder 2017-08-03 10:45:55 -04:00
Darren Nelsen
a0930bd71b update versions of ionic-cli, cordova plugin, and ionic-angular 2017-08-03 10:23:10 -04:00
Darren Nelsen
3f1332ffca rename transaction object to tx in transaction page 2017-08-03 10:20:19 -04:00
tenthirtyone
5d7957c5fb updated configs and added nginx note in readme 2017-08-03 03:22:06 -04:00
tenthirtyone
06b24d85b7 node start wired up 2017-08-03 03:13:55 -04:00
tenthirtyone
aaef1c7273 bcoin node moved to its own file 2017-08-03 03:08:11 -04:00
tenthirtyone
3ee90bdbef Reverted async await to promise. 2017-08-03 01:46:47 -04:00
tenthirtyone
ad5c2dae93 Added Readme. 2 command install 2017-08-02 18:36:01 -04:00
tenthirtyone
71a24237f2 Stubbed insight API
Server changed to API
cleaned up some console.log

Insight UI does not use the entire API. Those are high priority
2017-08-02 18:23:27 -04:00
tenthirtyone
ee160d9e7b Added Utils, db, and updated block schema 2017-08-02 17:02:01 -04:00
Darren Nelsen
290e53f697 Added transaction page 2017-08-02 16:28:54 -04:00
tenthirtyone
6b7496e0c7 changed mongo config stanza. 2017-08-02 15:42:34 -04:00
tenthirtyone
767fc7e98a Bcoin config moved to config file 2017-08-02 14:55:55 -04:00
tenthirtyone
b028dead40 Initial Commit
Changelog:
Setup & Foundation
- bcoin
- express
- mongo
- eslint
- logging

Status: Bcoin syncs over network, uses a local leveldb to store blocks and checkpoints. Block event saves data to mongo. Express endpoint for block hashes, stubbed to reply with blockhashes until mongo models are finalized.

ToDo:
Move config out of code
2017-08-02 14:51:06 -04:00
Darren Nelsen
866b45457d replace address page placeholders with real data 2017-08-02 14:26:41 -04:00
Darren Nelsen
22351df704 refactored TransactionsComponent to allow for passed in query types and values 2017-08-02 11:20:16 -04:00
Alex
09804961c7 Initial commit 2017-08-02 00:40:46 -04:00
Darren Nelsen
f02fd3c01f refactored TransactionsComponent to accept blockHash or address 2017-07-31 17:54:32 -04:00
Darren Nelsen
25a83b546b put address fields and placeholders in ion-grid 2017-07-31 16:08:31 -04:00
Darren Nelsen
07d7fb3537 added address page 2017-07-31 15:38:47 -04:00
Jason Dreyzehner
8852924a14 Merge pull request #782 from SonicWizard/ionic
Ionic updates; block height search and block detail
2017-07-29 01:18:11 -04:00
Darren Nelsen
583139ca2c display transactions with vins/vouts 2017-07-28 17:05:25 -04:00
Darren Nelsen
6f99a2f881 Added TransactionsComponent 2017-07-27 16:38:56 -04:00
Darren Nelsen
de09b9056d pipe timestamp; add poolInfo; add block reward denomination 2017-07-27 15:06:33 -04:00
Darren Nelsen
877c5cfbc7 update ionic 2017-07-27 15:05:20 -04:00
Darren Nelsen
0d7e4783e7 took out some console logs and removed unneeded method 2017-07-26 17:05:38 -04:00
Darren Nelsen
04c4a71f14 cleaned up tslint warnings 2017-07-26 16:52:34 -04:00
Darren Nelsen
ccc5f8868a add loading indication 2017-07-26 16:05:10 -04:00
Darren Nelsen
2bc629cac5 added previous and next block links 2017-07-26 15:31:16 -04:00
Darren Nelsen
a3071d5ec6 added more block data 2017-07-26 14:26:40 -04:00
Darren Nelsen
9cfef6b834 use dynamic link for blockHash in block detail page; retrieve block data 2017-07-26 14:17:02 -04:00
Darren Nelsen
013358a69c pass blockHash to block detail page 2017-07-25 15:59:47 -04:00
Darren Nelsen
a6ab615a96 added block detail page (placeholder) 2017-07-25 15:21:58 -04:00
Darren Nelsen
b5a76aee44 Added addr and block-index searches 2017-07-25 13:04:37 -04:00
Darren Nelsen
9334b13a0d enabled search in blocksPage; removed package-lock.json from source control 2017-07-25 10:00:51 -04:00
Darren Nelsen
b8df8bcec4 added search field that accepts input 2017-07-14 17:07:11 -04:00
Darren Nelsen
a2c650b2a0 updated ionic cli and associated dependencies 2017-07-14 17:03:56 -04:00
Darren Nelsen
2f3207babe added spy in test to ensure coverage, even though send is a stub for now 2017-07-14 15:58:53 -04:00
Darren Nelsen
cf1ea86f7d cleaned up two e2e warnings 2017-07-14 13:12:26 -04:00
Darren Nelsen
53c9d82bd1 added package-lock.json, and added mynode to gitignore 2017-07-14 13:03:45 -04:00
Darren Nelsen
615ffc59db Added form validation to broadcast transaction 2017-07-13 17:20:29 -04:00
Jason Dreyzehner
7d21c310b1 Merge pull request #781 from SonicWizard/ionic
Headers and placeholders
2017-07-12 14:19:51 -04:00
Darren Nelsen
130b7a7022 Updated broadcast test to check for existance of input field 2017-07-12 14:12:15 -04:00
Darren Nelsen
8abeb5eb8e Added placeholder text and fields for verify and broadcast pages 2017-07-11 16:38:38 -04:00
Darren Nelsen
e9881777b2 Added fields to verify message page 2017-07-11 16:01:44 -04:00
Darren Nelsen
8f27d671f3 Added headers to blocks page 2017-07-11 15:29:13 -04:00
Jason Dreyzehner
f1994947b9 fix ci: avoid GitHub download, rate limit 2017-07-11 11:57:32 -04:00
Jason Dreyzehner
0608159096 convenience script to open coverage 2017-07-11 10:57:13 -04:00
Jason Dreyzehner
e624721fe3 lint corrections 2017-07-11 10:50:43 -04:00
Jason Dreyzehner
57ec79a46a continue scaffolding, add blocksService 2017-07-07 16:46:53 -04:00
Jason Dreyzehner
d784be5d7e scaffold top-level pages 2017-07-05 14:36:31 -04:00
Jason Dreyzehner
60d9d546a2 update to latest deps 2017-07-05 12:34:18 -04:00
Jason Dreyzehner
a801427e99 add package-lock 2017-06-16 14:01:34 -04:00
Jason Dreyzehner
f1fafaadf2 scaffold blocks view 2017-06-16 14:00:24 -04:00
Jason Dreyzehner
8f295786bc add ionic config 2017-06-15 17:59:07 -04:00
Jason Dreyzehner
95388ad451 fix chrome addon config for Travis 2017-06-15 17:46:19 -04:00
Jason Dreyzehner
8688f2fc80 remove extraneous 'npm install' from Travis build 2017-06-15 17:19:40 -04:00
Jason Dreyzehner
c979260395 add MIT license 2017-06-15 17:15:01 -04:00
Jason Dreyzehner
db4319d8e2 init Travis, add insight-ui to build matrix 2017-06-15 17:12:24 -04:00
Jason Dreyzehner
adf9376590 clicker -> insight-ui 2017-06-15 17:10:50 -04:00
Jason Dreyzehner
ff9f4cdae2 fork lathonez/clicker at b2c7d6a 2017-06-13 15:48:52 -04:00
Jason Dreyzehner
340decd978 Route caching bug fix, simplify routing (#763)
* move window.apiPrefix into Angular service

* avoid routing by accept headers, integrate api service

* Revert "Fixed over-matching of index route."

This reverts commit 62e1225dd3.

* better name for index template file
2017-05-04 12:42:17 -04:00
Matias Alejo Garcia
cc7c6f81d4 Merge pull request #766 from dabura667/fix-BTC-places
Fix Fee Rate to 8 decimal places
2017-04-10 13:59:58 +02:00
Dabura667
d0a8b123d2 Fix Fee Rate to 8 decimal places
Transaction details page when set to BTC has 19 decimal places

> 0.0014707499999999998 BTC per kB
2017-04-09 11:05:06 +09:00
Dabura667
d8fea29125 Merge pull request #1 from bitpay/master
Update master from bitpay
2017-04-09 11:01:35 +09:00
Chris Kleeschulte
795b5182fc Merge pull request #764 from kleetus/bug/index
Fixed over-matching of index route.
2017-04-03 20:32:00 -04:00
k
62e1225dd3 Fixed over-matching of index route. 2017-04-03 20:04:16 -04:00
Braydon Fuller
95bcad836c Bump package version to 0.4.3 2016-07-20 12:56:50 -04:00
Matias Alejo Garcia
802aae237e Merge pull request #488 from braydonf/trim-tx
address: include options to trim transaction results
2016-07-20 13:35:49 -03:00
Braydon Fuller
5eb32cf64c test: address trim transform options 2016-07-20 10:54:28 -04:00
Braydon Fuller
5e72240be9 docs: add address trimmed txs options to README 2016-07-20 10:45:23 -04:00
Braydon Fuller
67fc186293 test: address txs trim results 2016-07-20 10:38:43 -04:00
Matias Alejo Garcia
5e54eac89b Update README.md 2016-07-20 07:24:18 -03:00
Matias Alejo Garcia
4c980e0177 Update README.md 2016-07-20 07:23:46 -03:00
Braydon Fuller
38e061e0c5 address: include options to trim transaction results 2016-07-19 20:33:31 -04:00
Braydon Fuller
967445c14f Bump package version to 0.4.2 2016-06-13 10:26:38 -04:00
Matias Alejo Garcia
7db7b1214b Merge pull request #484 from braydonf/ratelimiter-options
index: configurable ratelimiter options
2016-06-11 11:25:36 -03:00
Braydon Fuller
57e65010f1 index: add option to disable rate limiter entirely
for the case that insight-api is used in an internal network
where rate limiting isn't necessary
2016-06-07 11:02:58 -04:00
Braydon Fuller
b9c909ad40 index: configurable ratelimiter options 2016-06-01 15:02:11 -04:00
Braydon Fuller
299344cf87 Bump package version to 0.4.1 2016-05-31 14:06:45 -04:00
Matias Alejo Garcia
ef85ba4a08 Merge pull request #481 from braydonf/cors
index: respond 204 to OPTIONS requests
2016-05-31 14:18:05 -03:00
Braydon Fuller
77211dbaf7 index: respond 204 to OPTIONS requests 2016-05-31 12:31:06 -04:00
Braydon Fuller
ce7de0b63c Bump package version to 0.4.0 2016-05-27 14:27:57 -04:00
Braydon Fuller
ddcd05cbc2 Bump package version to 0.4.0 2016-05-27 14:24:15 -04:00
Chris Kleeschulte
692578fd12 Merge pull request #467 from braydonf/bitcoind
bitcoind address index
2016-05-27 14:20:40 -04:00
Chris Kleeschulte
df19530235 Merge pull request #718 from braydonf/bitcoind
bitcoind: change to use bitcoind/addresstxid event
2016-05-27 14:19:37 -04:00
Braydon Fuller
667a38053b block: check block argument and fix caching
Checks that the argument sent to the endpoint for /block/ and /rawblock/ is
a 64 character hexadecimal string (blockHash), otherwise will return 404.

Uses a long cache header for for the /rawblock/ endpoint since the result will not
change, and a short cache header for the /block/ endpoint since this data references
other blocks in the chain that can change.
2016-05-26 11:21:36 -04:00
Braydon Fuller
4317f67a2b addresses: add coverage to address controller show
covers bug fixed in commit 72fe25aff9
2016-05-26 09:17:01 -04:00
Braydon Fuller
2448ad1779 index: log remote connecting ip address 2016-05-25 17:16:11 -04:00
Braydon Fuller
72fe25aff9 Fix bug with var self = this; 2016-05-25 16:03:36 -04:00
Braydon Fuller
d7c161d7b6 Update compiled files 2016-05-18 10:19:52 -04:00
Braydon Fuller
ffed19b8b3 Unsubscribe to address event, and update addresstxid data format 2016-05-18 10:19:36 -04:00
Braydon Fuller
0a06f9aba9 Update compiled files 2016-05-17 22:58:20 -04:00
Braydon Fuller
f50abae460 Fix url to transaciton sound 2016-05-17 21:00:36 -04:00
Braydon Fuller
3532cd25a1 Change to use bitcoind/addresstxid event 2016-05-17 20:17:04 -04:00
Braydon Fuller
61f0c3063a bitcoind: fix error handling bug 2016-05-16 18:32:08 -04:00
Braydon Fuller
11874a1957 blocks: handle out of range height as 404 not found 2016-05-16 18:27:27 -04:00
Braydon Fuller
0465179a93 transaction: switch to use bitcore node getDetailedTransaction 2016-05-13 18:22:28 -04:00
Braydon Fuller
ae9f6a2c2f test: add ratelimiter middleware unit test 2016-05-11 14:17:47 -04:00
Braydon Fuller
9eacb3dedc docs: add notes about block order sorting 2016-05-11 13:36:27 -04:00
Braydon Fuller
285e3550f5 status: camelCase adjustments for bitcore node 2016-05-11 11:54:29 -04:00
Braydon Fuller
c6bd150bd9 blocks: camelCase adjustments for bitcore node 2016-05-11 11:54:08 -04:00
Braydon Fuller
351c315736 common: improve error logging 2016-05-10 19:26:10 -04:00
Braydon Fuller
ebcc3607c2 ratelimiter: rename every to interval and add tests 2016-05-10 17:40:07 -04:00
Braydon Fuller
98d5314ef2 transactions: switch to use req.param
so that the last argument is the next callback
2016-05-10 16:55:16 -04:00
Braydon Fuller
7973e2398a blocks: switch to use req.param
so that the last argument is the next callback
2016-05-10 16:50:28 -04:00
Braydon Fuller
310dd99086 blocks: rename moreTs -> moreTimestamp for clarity 2016-05-10 16:24:37 -04:00
Braydon Fuller
0ba78e7180 docs: update documentation with address endpoint query optinos 2016-05-10 15:57:38 -04:00
Braydon Fuller
29e96e83ae address: pass "from" and "to" options 2016-05-10 13:52:01 -04:00
Braydon Fuller
4e54d195b9 blocks: add configurable option for caches 2016-05-09 17:54:57 -04:00
Braydon Fuller
b446f6733c transaction: handle error 2016-05-09 17:54:08 -04:00
Matias Alejo Garcia
80549ff1a7 Merge pull request #464 from slush0/master
Update SlushPool entry
2016-05-05 09:21:05 -03:00
Braydon Fuller
87643fba45 docs: update upgrade notes with additional differences 2016-04-25 12:42:45 -04:00
Braydon Fuller
923c596b74 Merge pull request #713 from Gitju/master
sed -i 's#github.com/bitpay/insight#github.com/bitpay/insight-ui#g' package.json
2016-04-25 10:25:43 -04:00
Braydon Fuller
92ac2155d4 Merge pull request #478 from Gitju/master
sed -i 's#github.com/bitpay/insight#github.com/bitpay/insight-ui#g'
2016-04-25 10:07:00 -04:00
Cryptoanarchist
f002131366 sed -i 's#github.com/bitpay/insight#github.com/bitpay/insight-ui#g'
and adding https where necessary
2016-04-24 16:24:23 +02:00
Cryptoanarchist
d104af895f sed -i 's#github.com/bitpay/insight#github.com/bitpay/insight-ui#g' 2016-04-24 15:59:16 +02:00
Cryptoanarchist
3ff860c483 sed -i 's#github.com/bitpay/insight#github.com/bitpay/insight-ui#g' 2016-04-24 14:57:34 +02:00
Braydon Fuller
c83842eb60 addresses: parseInt from and to 2016-04-22 17:29:26 -04:00
Braydon Fuller
f890daa108 docs: update readme to include blocks endpoint 2016-04-22 17:24:32 -04:00
Braydon Fuller
203df0d736 docs: fix confirmations in example for utxo 2016-04-22 15:30:58 -04:00
Braydon Fuller
2efa5562be docs: remove nolonger relevant noCache query from readme 2016-04-22 15:27:57 -04:00
Braydon Fuller
95b2a04937 docs: add rawblock endpoint to docs 2016-04-22 15:26:20 -04:00
Braydon Fuller
465b14a0dd docs: fix formatting in readme 2016-04-22 15:20:54 -04:00
Braydon Fuller
bc9bb10ea7 docs: remove json markdown 2016-04-22 15:15:07 -04:00
Braydon Fuller
36ad6ebbbe docs: include rawblock in readme 2016-04-22 15:13:44 -04:00
Braydon Fuller
3e40d71c51 addresses: update utxo response format 2016-04-22 14:46:51 -04:00
Braydon Fuller
6e5dbfd22a utils: update estimatefee 2016-04-20 14:07:29 -04:00
Braydon Fuller
e1df171f95 blocks: cache block header info with next block with 6 confirmations 2016-04-20 10:54:10 -04:00
Braydon Fuller
b686c5bea9 blocks: fix null prevhash issue 2016-04-15 15:50:14 -04:00
Braydon Fuller
6ec263692b test: run node v4 with travis ci 2016-04-15 15:02:28 -04:00
Braydon Fuller
c68b9e143e test: update transaction tests 2016-04-15 14:56:54 -04:00
Braydon Fuller
f87bdea8fb test: update status tests 2016-04-15 14:03:57 -04:00
Braydon Fuller
29faace44a test: standardize quote formatting and fix missing semis 2016-04-15 13:54:23 -04:00
Braydon Fuller
13532666c3 test: update block tests 2016-04-15 13:45:58 -04:00
Braydon Fuller
2ff77801b0 test: update address test and test upgrades 2016-04-15 13:14:52 -04:00
Braydon Fuller
bb901b91bc test: standardize indentation to two spaces 2016-04-15 12:05:44 -04:00
Braydon Fuller
332fd2a012 test: update address utxo test 2016-04-15 12:02:22 -04:00
Braydon Fuller
d47527e7d0 transaction: update error handling with codes 2016-04-15 11:48:56 -04:00
Braydon Fuller
04b0b39049 transaction: include height in spent info 2016-04-12 15:30:47 -04:00
Braydon Fuller
38bbbc07dc transaction: spent info api updates 2016-04-12 15:01:27 -04:00
Braydon Fuller
7ded22fb2c block: add raw block endpoint 2016-04-11 15:40:55 -04:00
Braydon Fuller
19c5b617d1 block: only cache block summary with height if confirmed >= 6
- update api with changes in bitcore node
- add block event
2016-04-11 10:39:46 -04:00
Braydon Fuller
9d78188f64 index: add not found 2016-04-11 10:33:53 -04:00
Braydon Fuller
491a5cb846 index: start of rate limiter 2016-04-11 10:33:53 -04:00
Braydon Fuller
0957f2301e index: add compression to responses 2016-04-11 10:33:53 -04:00
Braydon Fuller
8280d7a628 index: added response logging 2016-04-11 10:33:53 -04:00
Braydon Fuller
de4a87e5f8 index: update bitcoind tx event handler 2016-04-11 10:33:53 -04:00
Braydon Fuller
b18dc95755 address: update utxos 2016-04-11 10:33:53 -04:00
Braydon Fuller
78870fc56e fixed bug that was removing transactions from the cached block 2016-04-11 10:33:53 -04:00
Braydon Fuller
3c355c30a9 blocks: added lru cache 2016-04-11 10:33:53 -04:00
Braydon Fuller
13efeec84b blocks: fix for getBlockHashesByTimestamp 2016-04-11 10:29:50 -04:00
Braydon Fuller
e4f585ad15 general: updated controllers for new api from bitcoind 2016-04-11 10:28:49 -04:00
Joel Kaartinen
c42b8d9d91 Optimize block list page to not parse all transactions from a block when
the only data that is interesting is number of transactions. Fixes 100%
CPU while building block list.
2016-03-29 12:16:14 +03:00
slush0
f5acc2f564 Update SlushPool entry 2016-03-16 20:06:04 +01:00
Matias Alejo Garcia
e3ef214b21 Merge pull request #691 from braydonf/readme2
Docs: Update documentation with the most recent commands.
2016-02-17 13:47:00 -03:00
Braydon Fuller
653fd60a24 Bump package version to 0.3.1 2016-02-08 12:43:23 -05:00
Matias Alejo Garcia
d16892d7af Merge pull request #703 from braydonf/network
Show network name instead of testnet boolean
2016-02-05 12:52:06 -03:00
Braydon Fuller
2e013122db Show network name instead of testnet boolean 2016-02-05 10:40:26 -05:00
Braydon Fuller
133c2321f9 Bump package version to 0.3.2 2016-01-28 15:01:20 -05:00
Matias Alejo Garcia
f4baed5c37 Merge pull request #447 from braydonf/bug/sequencenum
Fixed bug with sequence number for rbf
2016-01-28 16:58:02 -03:00
Braydon Fuller
e790622df6 Fixed bug with sequence number for rbf
See: dfdeaba729 (commitcomment-14937962)
2016-01-28 14:42:16 -05:00
Matias Alejo Garcia
44014b5bcb Merge pull request #434 from hyzhak/feature/block-height-in-transaction
add block height to transaction response
2016-01-07 14:20:14 -03:00
Matias Alejo Garcia
0c7f572030 Merge pull request #427 from braydonf/polmine-link
Fixed issue with polmine.pl link.
2016-01-07 14:17:04 -03:00
Matias Alejo Garcia
d9fe157f41 Merge pull request #422 from braydonf/urlencoded
Fixed bug with parsing urlencoded post data.
2016-01-07 14:16:44 -03:00
Matias Alejo Garcia
ea57755c0b Merge pull request #435 from isocolsky/rbf
Detect RBF transactions on 'tx' event
2015-11-30 15:16:40 -03:00
Ivan Socolsky
dfdeaba729 detect RBF transactions on 'tx' event 2015-11-30 13:58:06 -03:00
Eugene Krevenets
2282d231bd add block height to transaction response 2015-11-25 23:37:30 +01:00
Braydon Fuller
840fd0db21 Docs: Update documentation with the most recent commands. 2015-11-12 17:22:35 -05:00
Braydon Fuller
b3111721b6 Merge pull request #426 from mikaelw/master
Add BTCC Pool.
2015-11-12 15:45:36 -05:00
Braydon Fuller
4d24f4620a Fixed issue with polmine.pl link. 2015-11-12 15:44:32 -05:00
Mikael Wang
287611dd2c Add BTCC Pool. 2015-11-11 14:29:14 +08:00
Braydon Fuller
1cb2e79998 Merge pull request #424 from bitcoinsSG/master
updated README api lnks to insight-api
2015-11-04 14:56:51 -05:00
Gaurav Rana
931d295f2a updated README api lnks to insight-api
Installation instructions should be as frictionless as possible for new users, none the example links work because of /api/ instead of the /insight-api/, and there is no base url (separate issue). Additionally changed the getting started instructions to reflect install instead of add.
2015-11-04 14:47:58 -05:00
Braydon Fuller
27ee62b755 Fixed bug with parsing urlencoded post data. 2015-11-04 12:26:20 -05:00
Braydon Fuller
22f3ba9405 Fix test to pull version from package.json 2015-11-02 14:42:51 -05:00
Braydon Fuller
8c6f7c8aef Bump package version to 0.3.1 2015-11-02 14:32:25 -05:00
Patrick Nagurny
abe5075dd3 Merge pull request #412 from braydonf/feature/cache
Added configurable caching.
2015-10-28 15:18:42 -04:00
Braydon Fuller
94f584f792 Added configurable caching. 2015-10-23 15:20:20 -04:00
Braydon Fuller
2a14955d74 Merge pull request #410 from pnagurny/bug/sync-percentage
Fix sync percentage
2015-10-22 14:37:01 -04:00
Patrick Nagurny
496349d4b5 fix sync percentage 2015-10-22 14:28:28 -04:00
Stephen Pair
7c5a79c80a Merge pull request #670 from bitpay/v0.3.0
v0.3.0
2015-10-16 20:51:18 -04:00
Stephen Pair
d806500b38 Merge pull request #382 from bitpay/v0.3.0
v0.3.0
2015-10-16 20:51:05 -04:00
Stephen Pair
24c3f466c0 Merge pull request #409 from braydonf/bclib
bitcore -> bitcore-lib
2015-10-16 20:50:18 -04:00
Braydon Fuller
3dfc1bc9e3 Switch to use bitcore-lib. 2015-10-16 18:14:38 -04:00
Patrick Nagurny
4606e6e953 Merge pull request #406 from braydonf/v0.3.0-cors
Add CORS support
2015-10-14 13:14:26 -04:00
Braydon Fuller
efdb2487e4 Add CORS support 2015-10-14 12:52:25 -04:00
Patrick Nagurny
7d68b0cc82 Merge pull request #678 from braydonf/feature/configurable-routes
Added ability to configure HTTP route prefixes.
2015-10-13 11:20:38 -04:00
Patrick Nagurny
de6a44d14e Merge pull request #403 from braydonf/feature/configurable-routes
Added ability to configure HTTP route prefixes.
2015-10-13 11:20:06 -04:00
Braydon Fuller
e006e5cbcd Remove unnecessary line. 2015-10-13 11:19:35 -04:00
Braydon Fuller
7ec3124d82 Fix bug with trailing /. 2015-10-13 11:16:12 -04:00
Braydon Fuller
cc1cbc12ad Move undefined check to the constructor. 2015-10-13 11:15:46 -04:00
Braydon Fuller
db2ee2ab27 Added ability to configure HTTP route prefixes. 2015-10-13 10:52:02 -04:00
Braydon Fuller
c45a0edd60 Added ability to configure HTTP route prefixes. 2015-10-13 10:49:44 -04:00
Patrick Nagurny
933c378a8d Merge pull request #672 from braydonf/v0.3.0-buttons
Removed href="#" that was redirecting the the landing page.
2015-10-02 14:21:35 -04:00
Patrick Nagurny
de6ccd6969 Merge pull request #393 from braydonf/v0.3.0-changelog
Include notes when upgrading from v0.2
2015-10-02 14:11:41 -04:00
Braydon Fuller
12b33a5c37 Include notes when upgrading from v0.2 2015-10-02 14:11:10 -04:00
Patrick Nagurny
7bc78928b1 Merge pull request #392 from braydonf/v0.3.0-currency
Added currency controller and endpoint.
2015-10-02 14:09:34 -04:00
Braydon Fuller
85b51a378a Switched to use Date.now() 2015-10-02 14:08:52 -04:00
Braydon Fuller
accff4e43c Removed href="#" that was redirecting the the landing page. 2015-10-02 13:14:30 -04:00
Braydon Fuller
f96d8f3f8b Added currency controller and endpoint. 2015-10-02 12:27:02 -04:00
Patrick Nagurny
df574bfffd Merge pull request #391 from braydonf/v0.3.0-spenttx
Added spentTxId and spentIndex
2015-10-02 10:58:35 -04:00
Braydon Fuller
fe6a441a52 Added spentTxId and spentIndex 2015-10-01 23:49:28 -04:00
Braydon Fuller
dcabaeba8c Include ASM in transaction endpoints. 2015-09-30 23:02:29 -04:00
Patrick Nagurny
2a1f9706e3 Merge pull request #383 from braydonf/bug/estimatefee
Fix bug with satoshis being returned instead of bitcoin.
2015-09-30 10:14:24 -04:00
Braydon Fuller
3f76e8a9dc Fix bug with satoshis being returned instead of bitcoin. 2015-09-29 18:04:54 -04:00
Matias Alejo Garcia
8625c23e81 Merge pull request #381 from kleetus/feature/remove_getTxOutSetInfo
Removed unneeded and slow getTxOutSetInfo
2015-09-25 12:51:44 -03:00
Matias Alejo Garcia
fb43ff70d4 Merge pull request #669 from kleetus/feature/remove_getTxOutInfo
Removed button and div for Show Transaction Output Data
2015-09-25 12:51:27 -03:00
Chris Kleeschulte
19974a7d3d Removed button and div for Show Transaction Output Data 2015-09-25 11:26:21 -04:00
Chris Kleeschulte
999a669c53 Removed unneeded and slow getTxOutSetInfo 2015-09-25 11:17:20 -04:00
Chris Kleeschulte
bb0412f1c8 Merge pull request #380 from braydonf/bug/null-vout
Fix bug with null in vouts array.
2015-09-25 10:36:11 -04:00
Braydon Fuller
7b74045ff4 Fix bug with null in vouts array. 2015-09-24 18:20:37 -04:00
Chris Kleeschulte
a73cd731d9 Merge pull request #378 from braydonf/feature/pool-info
Include mining pool information.
2015-09-22 13:47:48 -04:00
Braydon Fuller
c7054051e3 Include mining pool information. 2015-09-22 13:32:41 -04:00
Chris Kleeschulte
4684224a53 Merge pull request #668 from braydonf/bug/tx-mined-time
Fix bug with displaying mined time for mempool transactions.
2015-09-22 13:17:47 -04:00
Chris Kleeschulte
4a850e2758 Merge pull request #379 from braydonf/mempool-mined-time
Only include blocktime if transaction is in a block.
2015-09-22 13:03:34 -04:00
Chris Kleeschulte
52b02eda14 Merge pull request #376 from braydonf/bug/block-txs-paging
Fix bug where page 0 is falsy and pagination would not be enabled.
2015-09-22 12:45:51 -04:00
Chris Kleeschulte
778c09b96d Merge pull request #377 from braydonf/feature/next-block
Added bindings for getNextBlockHash
2015-09-22 12:13:06 -04:00
Braydon Fuller
dc791a2f24 Only include blocktime if transaction is in a block. 2015-09-21 17:22:09 -04:00
Braydon Fuller
b5251849a0 Fix bug with displaying mined time for mempool transactions. 2015-09-21 17:21:11 -04:00
Braydon Fuller
b49f1505eb Added bindings for getNextBlockHash 2015-09-21 14:37:13 -04:00
Braydon Fuller
8a21f48d2a Fix bug where page 0 is falsy and pagination would not be enabled. 2015-09-21 14:13:48 -04:00
Braydon Fuller
b32eeec4d6 Merge pull request #375 from pnagurny/feature/estimateFee
v0.3.0 add estimateFee route
2015-09-21 13:19:24 -04:00
Braydon Fuller
4b1b929cff Merge pull request #371 from pnagurny/enhance/address-summary
v0.3.0 Faster address summary
2015-09-21 12:56:32 -04:00
Patrick Nagurny
2105492ff9 Merge pull request #666 from braydonf/verify-message
Fix for Messages URL
2015-09-18 14:00:36 -04:00
Patrick Nagurny
9070b74653 expose estimateFee route 2015-09-18 13:58:46 -04:00
Braydon Fuller
e45396435b Add updated generate files until we have a better solution. 2015-09-18 13:58:05 -04:00
Patrick Nagurny
d869be5208 Merge pull request #372 from braydonf/message-verification
Added message verification endpoint.
2015-09-18 13:52:44 -04:00
Patrick Nagurny
d1f7349ac5 Merge pull request #373 from braydonf/statusinfo
Added handlers for getting status of the block chain.
2015-09-18 13:20:59 -04:00
Braydon Fuller
8c605047c3 Added handlers for getting status of the block chain.
- getTxOutSetInfo
- getLastBlockHash
- getBestBlockHash
2015-09-17 18:45:53 -04:00
Braydon Fuller
fc15f2982f Update link to messages. 2015-09-17 17:00:59 -04:00
Braydon Fuller
cf58b69bbf Added message verification endpoint. 2015-09-17 16:57:03 -04:00
Braydon Fuller
af08592d01 Fix for Messages URL 2015-09-17 15:51:31 -04:00
Patrick Nagurny
2ec8d1f447 use faster getAddressSummary() 2015-09-17 10:42:35 -04:00
Braydon Fuller
83c8f9c5ac Merge pull request #365 from pnagurny/enhance/history-pagination
address history pagination
2015-09-16 14:02:55 -04:00
Braydon Fuller
c0e4a07bad Merge pull request #368 from pnagurny/feature/blocks-by-timestamp
Get blocks by date
2015-09-16 13:55:33 -04:00
Patrick Nagurny
f359a96f9e check for valid date 2015-09-16 12:08:41 -04:00
Patrick Nagurny
3d713224bf no longer need to reverse 2015-09-15 18:23:27 -04:00
Patrick Nagurny
65b302c7af Merge pull request #358 from Kefkius/patch-1
Fix typo in raw transaction API
2015-09-15 17:01:43 -04:00
Patrick Nagurny
bc4672760c get blocks by date 2015-09-15 16:51:54 -04:00
Patrick Nagurny
9485398879 address history pagination 2015-09-15 14:32:34 -04:00
Braydon Fuller
2ae1cdbec2 Merge pull request #359 from pnagurny/feature/main-chain
add isMainChain to block
2015-09-09 11:20:46 -04:00
Braydon Fuller
4be08c7be8 Merge pull request #362 from pnagurny/bug/inv-tx
Make bitcore node inv tx output match insight's
2015-09-09 11:19:30 -04:00
Patrick Nagurny
1199618471 make bitcore node inv tx output match insight's 2015-09-09 11:15:37 -04:00
Braydon Fuller
97255a525f Merge pull request #361 from pnagurny/feature/difficulty
Get block difficulty
2015-09-09 10:33:40 -04:00
Patrick Nagurny
0e538f2e06 get block difficulty 2015-09-09 10:31:09 -04:00
Patrick Nagurny
300bf67414 add isMainChain to block 2015-09-09 10:21:04 -04:00
Kefkius
daf9546e75 Fix typo in raw transaction API 2015-09-08 13:28:29 -04:00
Braydon Fuller
bd8ed3bddf Merge pull request #357 from pnagurny/feature/block-reward
Implement block reward
2015-09-04 14:29:48 -04:00
Patrick Nagurny
3bcb0426c3 get block reward 2015-09-04 14:06:04 -04:00
Patrick Nagurny
dd3d590a44 Merge pull request #659 from braydonf/readme
Update README to reflect running as a Bitcore Node service.
2015-09-03 18:19:03 -04:00
Patrick Nagurny
e4eb09f87f update css 2015-09-03 18:16:34 -04:00
Braydon Fuller
36f5c75880 Update README to reflect running as a Bitcore Node service. 2015-09-03 18:15:52 -04:00
Braydon Fuller
5ab366465b Merge pull request #356 from pnagurny/feature/inv-subscription
Inv subscription + more tests
2015-09-03 17:58:25 -04:00
Patrick Nagurny
546c4a3345 remove apiPrefix 2015-09-03 17:44:19 -04:00
Patrick Nagurny
a9828d8539 change name to insight-ui, remove dependency on insight-api 2015-09-03 17:33:59 -04:00
Patrick Nagurny
69c536be7d fix date bug, add inv subscription 2015-09-03 16:40:23 -04:00
Patrick Nagurny
d67950145c add status tests 2015-09-03 12:15:33 -04:00
Patrick Nagurny
1d70f0196c add bitcore-node service and make everything relative paths 2015-09-03 11:39:21 -04:00
Patrick Nagurny
bf604e0a8f Merge pull request #353 from braydonf/package
Include main in package.json and other updates.
2015-09-03 10:19:25 -04:00
Braydon Fuller
c917118d97 Include main in package.json and other updates. 2015-09-02 13:08:20 -04:00
Braydon Fuller
adacd21e57 Merge pull request #352 from pnagurny/v3/remove-files
Remove files
2015-09-02 11:59:33 -04:00
Patrick Nagurny
5bddb0b047 Merge pull request #1 from braydonf/v3/remove-files
Update README to reflect insight-api as a bitcore-node service.
2015-09-02 11:57:39 -04:00
Braydon Fuller
80ab08d3b9 Update README to reflect insight-api as a bitcore-node service. 2015-09-02 11:54:22 -04:00
Patrick Nagurny
6c276ada49 update path 2015-09-02 11:49:32 -04:00
Patrick Nagurny
54462019be remove files 2015-09-02 11:45:51 -04:00
Patrick Nagurny
f9fd3c0488 change prefix to insight-api 2015-09-02 11:23:40 -04:00
Patrick Nagurny
9cc0c401f0 update version 2015-09-02 11:23:31 -04:00
Patrick Nagurny
ed0a46a525 add tests 2015-09-02 11:23:22 -04:00
Patrick Nagurny
e4992a6dfb bitcore node service 2015-09-02 11:22:25 -04:00
Gustavo Maximiliano Cortez
038eb401db Merge pull request #347 from matiu/emailstore
rm parts of the unused emailstore
2015-08-13 11:12:48 -03:00
Matias Alejo Garcia
bea9ec0727 rm old code 2015-08-13 11:04:32 -03:00
Matias Alejo Garcia
6d64f64da0 rm parts of the unused emailstore 2015-08-13 10:58:42 -03:00
Matias Alejo Garcia
483dde1d81 Merge pull request #346 from isocolsky/estimate_multi_fee
Get multiple values for estimatefee on single request
2015-08-13 10:04:00 -03:00
Ivan Socolsky
c1210ce7da get multiple values for estimatefee on single request 2015-08-12 18:12:59 -03:00
Matias Alejo Garcia
4253de1ed4 Update index.html 2015-08-05 14:48:28 -03:00
Gustavo Maximiliano Cortez
74c27b284f Merge pull request #341 from isocolsky/feat/estimatefee
Feat/estimatefee
2015-07-22 15:22:36 -03:00
Gustavo Maximiliano Cortez
74a96e98b3 Merge pull request #342 from matiu/feat/tx-order2
better ordering of txs
2015-07-17 18:39:48 -03:00
Matias Alejo Garcia
1735552a2f bump version 2015-07-17 18:38:17 -03:00
Matias Alejo Garcia
b9ad26ab7e rm broken dontFillSpend option 2015-07-17 18:35:44 -03:00
Matias Alejo Garcia
270599597e better ordering of txs 2015-07-17 16:52:03 -03:00
Ivan Socolsky
876b2e31de update bitcore dependency 2015-07-16 17:18:31 -03:00
Ivan Socolsky
360f743f8f bump bitcore ^0.1.41 2015-07-15 16:41:24 -03:00
Ivan Socolsky
6886441b0b update README.md 2015-07-15 16:23:28 -03:00
Ivan Socolsky
df17d26d10 add estimatefee endpoint to REST api 2015-07-15 16:20:27 -03:00
Matias Alejo Garcia
d98757125e bump version 2015-07-15 12:58:08 -03:00
Ivan Socolsky
52b1d658f0 Merge pull request #340 from matiu/feat/handle-d-spends
handle double spends in /txs
2015-07-15 10:30:06 -03:00
Matias Alejo Garcia
ab6564eca5 handle double spends in /txs 2015-07-15 09:57:08 -03:00
Matias Alejo Garcia
bdb35b3b5f Merge pull request #339 from matiu/feat/firstSeenTs
add firstSeenTs for sorting
2015-07-14 20:36:45 -03:00
Matias Alejo Garcia
b452f76250 filter out utxo without scriptpubkey 2015-07-14 20:33:23 -03:00
Matias Alejo Garcia
90d5e57e7a add firstSeenTs for sorting 2015-07-14 19:36:49 -03:00
Gustavo Maximiliano Cortez
b799cc7d6d Merge pull request #338 from matiu/bug/handle-double-spend-in-history
skip double spends in /txs
2015-07-14 17:11:22 -03:00
Matias Alejo Garcia
c5c23dfa48 skip double spends in /txs 2015-07-14 17:06:02 -03:00
Matias Alejo Garcia
443507c6bd Merge pull request #644 from cmgustavo/fix/bundles-angular
Update bundles
2015-07-14 13:03:38 -03:00
Gustavo Maximiliano Cortez
52b665e79a
Update bundles 2015-07-14 13:01:02 -03:00
Matias Alejo Garcia
c2a0dee752 update bundles 2015-07-13 19:20:21 -03:00
Matias Alejo Garcia
aae6847235 bump version 2015-07-10 18:06:43 -03:00
Gustavo Maximiliano Cortez
805099de1b Merge pull request #643 from matiu/feat/unconfirmed-input
add unconfirmed input banner
2015-07-10 18:02:46 -03:00
Matias Alejo Garcia
53d8cd4412 add unconfirmed input banner 2015-07-10 17:41:26 -03:00
Gustavo Maximiliano Cortez
aaa21faae5 Merge pull request #641 from bitpay/revert-640-addfeeperkb
Revert "Fix max decimal place + trailing zeroes when in BTC"
2015-07-08 10:13:11 -03:00
Gustavo Maximiliano Cortez
ea0adc1d9e Merge pull request #640 from dabura667/addfeeperkb
Fix max decimal place + trailing zeroes when in BTC
2015-07-08 09:56:39 -03:00
dabura667
4d3e71a346 Fix max decimal place + trailing zeroes when in BTC 2015-07-08 21:15:29 +09:00
Gustavo Maximiliano Cortez
81c71415ed Revert "Fix max decimal place + trailing zeroes when in BTC" 2015-07-08 07:11:20 -03:00
Matias Alejo Garcia
07d8dddfb3 Merge pull request #639 from matiu/version
bump version
2015-07-07 20:50:04 -03:00
Matias Alejo Garcia
8241dfe9ba Merge pull request #638 from dabura667/addfeeperkb
Fix fee per kb
2015-07-07 20:48:51 -03:00
Matias Alejo Garcia
d188b2512c bump version 2015-07-07 20:47:34 -03:00
dabura667
1423811d4e Fix fee per kb 2015-07-08 08:38:12 +09:00
Matias Alejo Garcia
9183ffcf10 Merge pull request #636 from dabura667/addfeeperkb
Add fee per kB to transaction view
2015-07-07 11:59:33 -03:00
dabura667
245e52d6fb Add fee per kB to transaction view
https://www.reddit.com/r/Bitcoin/comments/3ceyaz/block_explorers_please_display_feeperkb/
2015-07-07 23:50:50 +09:00
Gustavo Maximiliano Cortez
76e47fd077 Merge pull request #625 from saschad/master
German Translation
2015-06-09 17:16:59 -03:00
Sascha Dückers
d91894e0ea Add German translation. 2015-06-09 15:25:44 +02:00
Matias Alejo Garcia
9e7ff7e092 Merge pull request #623 from thesoftwarejedi/patch-1
Update README.md
2015-05-29 14:49:06 -03:00
Dana Hanna
1a821f9c2a Update README.md
fix typo
2015-05-29 02:38:14 -04:00
Gustavo Maximiliano Cortez
79341717ec Merge pull request #588 from cmgustavo/bug/footer-01
Fix footer. Update angularjs-all
2014-11-30 19:37:47 -03:00
Gustavo Maximiliano Cortez
af028e41e6 Fix footer. Update angularjs-all 2014-11-30 19:31:12 -03:00
Gustavo Maximiliano Cortez
51a6ff9e85 Update README.md
fixes #580
2014-11-22 13:43:10 -03:00
Manuel Aráoz
7d4014f573 Merge pull request #584 from BlaiseExpMore25/bug/545-unit-translation
issue 545 - added unit change for transactions on homepage
2014-11-10 18:37:03 -03:00
BlaiseExpMore25
e4a82a838b issue 545 - added unit change for transactions on homepage 2014-11-10 22:07:31 +01:00
Matias Alejo Garcia
f29f5a8f4a Merge pull request #581 from visvirial/translate-ja
Add Japanese translation.
2014-11-10 15:59:57 -03:00
Vis Virial
5435744f05 Add Japanese translation. 2014-11-10 02:01:51 +09:00
Manuel Aráoz
94faf2d9f9 Merge pull request #579 from koirikivi/verifymessage-broadcasttx
Add support for verifymessage and sendrawtransaction
2014-11-06 15:09:21 -03:00
Rainer Koirikivi
f20550259f Add support for broadcasting a raw transaction 2014-11-05 00:32:16 +02:00
Rainer Koirikivi
f47133cd4b Add support for verifying messages
/messages/verify contains a view that utilizes the API method of
verifying Bitcoin messages. A link to the page is also added to the
footer.
2014-11-05 00:32:16 +02:00
Matias Alejo Garcia
594216e998 Merge pull request #578 from andrewfhart/feature/add-robots-txt
Add robots.txt
2014-11-02 08:43:43 -03:00
Andrew Hart
8bde44134b Add initial robots.txt with rules from #544 2014-11-01 20:48:56 -07:00
Gustavo Maximiliano Cortez
2852afc12b Merge pull request #572 from cmgustavo/feature/angular-ammoment
Changing deprecated value "changeLanguage" by "changeLocale"
2014-10-27 11:43:41 -03:00
Gustavo Maximiliano Cortez
c1d14c6652 display languages if available 2014-10-27 11:40:59 -03:00
Gustavo Maximiliano Cortez
40411ca2aa Change deprecated value "changeLanguage" by "changeLocale" 2014-10-27 11:37:24 -03:00
Matias Alejo Garcia
adc3f2ade4 Merge pull request #573 from andrewfhart/fix-blocks-length
Fix $scope.blocksLength assignment in index controller
2014-10-26 19:57:07 -03:00
Andrew Hart
5b48e4444d Update generated files with fix from 7698739 2014-10-26 10:34:13 -07:00
Andrew Hart
7698739215 Fix typo (lenght) in index controller 2014-10-26 10:31:41 -07:00
Gustavo Maximiliano Cortez
0b255f5f32 Merge pull request #570 from andrewfhart/feature/unify-search
Unify Search
2014-10-23 23:46:49 -03:00
Andrew Hart
dd2d32a06a Add mobile-specific attributes to the mobile-visible search form reference 2014-10-22 12:56:42 -07:00
Andrew Hart
67ff2cd06a Reference the views/includes/search.html template in header.html 2014-10-22 12:55:09 -07:00
Andrew Hart
d6b90fe871 Remove mobile-specific attributes in the search form snippet 2014-10-22 12:49:40 -07:00
Andrew Hart
9e6fccc554 Add placeholder translation in mobile search input 2014-10-22 12:10:35 -07:00
Gustavo Maximiliano Cortez
4225e59ae0 Merge pull request #569 from andrewfhart/feature/generated-files-for-567
Add generated JavaScript files pertaining to #567
2014-10-22 14:52:19 -03:00
Andrew Hart
5217763a1e Add updated angular-all generated javascript 2014-10-22 10:15:25 -07:00
Andrew Hart
b1cb8d7209 Add compiled files generated as a result of #567 2014-10-22 09:53:37 -07:00
Matias Alejo Garcia
3c2add5f36 Merge pull request #567 from andrewfhart/master
Give automatic focus to the header search box on page load
2014-10-22 12:41:45 -03:00
Andrew Hart
f7bec5285a Merge remote-tracking branch 'upstream/master'
Conflicts:
	public/views/includes/header.html
2014-10-22 07:52:22 -07:00
Matias Alejo Garcia
9945a0bdc9 Merge pull request #568 from cmgustavo/bug/03-layout
fix layout for small devices
2014-10-22 09:57:54 -03:00
Matias Alejo Garcia
253ea739d7 Merge pull request #563 from cmgustavo/feature/bits-support-storage
feature/bits support
2014-10-22 09:56:40 -03:00
Gustavo Maximiliano Cortez
793fc4216a fix layout for small devices 2014-10-22 09:23:59 -03:00
Gustavo Maximiliano Cortez
8ea1d1e9c4 bits support. using local storage to remember selected currency 2014-10-22 09:01:48 -03:00
Matias Alejo Garcia
56c0660c87 Merge pull request #562 from cmgustavo/feature/spanish-example-support
Feature/spanish example support
2014-10-22 07:50:36 -03:00
Andrew Hart
9e33a4abd8 Add focus directive to search box text input 2014-10-21 16:44:12 -07:00
Andrew Hart
beee5a3003 Add focus directive to be used to give input elements focus 2014-10-21 16:42:40 -07:00
Gustavo Maximiliano Cortez
2341dcc12f Spanish timestamp format (using angular-moment) 2014-10-13 01:48:43 -03:00
Gustavo Maximiliano Cortez
4d8068301a Example support for spanish language 2014-10-13 01:35:59 -03:00
Manuel Aráoz
b8f624f1e0 Merge pull request #556 from pierrerochard/patch-1
Small typo
2014-09-29 15:08:14 -03:00
Pierre Rochard
a4465279f1 Small typo 2014-09-29 13:10:59 -04:00
Matias Alejo Garcia
26f24480fd 0.2.5 2014-09-22 18:16:05 -03:00
Matias Alejo Garcia
2a048cdd64 update api version 2014-09-22 18:16:03 -03:00
Matias Alejo Garcia
bd51c9575a Merge pull request #551 from cmgustavo/bug/mobile-wrap
Bug/mobile wrap
2014-09-22 18:11:59 -03:00
Gustavo Maximiliano Cortez
33c9120991 wording fixes 2014-09-12 19:04:06 -03:00
Gustavo Maximiliano Cortez
c788ef0c2f Fixes mobile version. Fix #550 2014-09-12 18:48:14 -03:00
Matias Alejo Garcia
cab5dd438b Merge pull request #537 from cmgustavo/feature/multi-language-support
Feature/multi language support
2014-09-08 14:13:47 -03:00
Gustavo Maximiliano Cortez
5e058c2f6f Fix Conflicts:
public/js/angularjs-all.min.js
	public/js/main.min.js
2014-09-03 16:35:11 -03:00
Yemel Jardi
bee6de08a4 Merge pull request #546 from maraoz/version/0.2.4
Version 0.2.4
2014-09-01 14:19:25 -03:00
Manuel Araoz
7681797b90 update version 2014-09-01 13:09:54 -03:00
Manuel Araoz
f2b8fd3531 new insight version 2014-09-01 13:00:19 -03:00
Gustavo Maximiliano Cortez
72028e4314 update README 2014-08-24 03:10:29 -03:00
Gustavo Maximiliano Cortez
c94765bca5 minified files with multi language support (used for easier starter) 2014-08-24 02:46:13 -03:00
Gustavo Maximiliano Cortez
a8aebfe14a multi language support 2014-08-24 02:45:10 -03:00
Gustavo Maximiliano Cortez
48cdac80fb Required packages, gruntConfig updated and gitignore for pot files. 2014-08-24 02:44:28 -03:00
Gustavo Maximiliano Cortez
d8712e7a83 Merge pull request #518 from matiu/feature/fix-link
Feature/fix link
2014-06-18 17:22:20 -03:00
Matias Alejo Garcia
45caf5a40a fix abs link 2014-06-18 17:18:06 -03:00
Matias Alejo Garcia
9f3f0bfd09 add logo svg 2014-06-18 17:16:16 -03:00
Matias Alejo Garcia
d8936051aa Merge pull request #512 from drak/patch-2
Add a note about Nginx setup
2014-06-09 11:05:54 -03:00
Drak
4f9216969d Add a note about Nginx setup 2014-06-09 15:03:43 +01:00
Matias Alejo Garcia
22df1545e4 Merge pull request #510 from sandakersmann/patch-1
Updated README.md with correct link
2014-06-08 11:17:57 -03:00
sandakersmann
9c2a3b1981 Updated README.md with correct link
Updated README.md with correct insight's project homepage link
2014-06-08 04:45:42 +02:00
Matias Alejo Garcia
c1e06dd5df Merge pull request #508 from drak/patch-1
Correct grammar.
2014-06-05 18:21:17 -03:00
Drak
8d54e087f0 Correct grammar. 2014-06-05 22:17:09 +01:00
Gustavo Maximiliano Cortez
7a0f62eeff Merge pull request #504 from matiu/feature/api-dep
Feature/api dep
2014-06-03 11:04:20 -03:00
Matias Alejo Garcia
aa74f13a24 add more msg error 2014-06-03 10:41:31 -03:00
Matias Alejo Garcia
7cde324aac hide block in unconfirmed txs 2014-06-03 10:32:04 -03:00
Matias Alejo Garcia
f18dc83cd6 Merge pull request #503 from colkito/fix/hide-loading-search
removed loading images in the search field
2014-06-02 13:23:17 -03:00
Mario Colque
e5f7327d1f removed loading images in the search field 2014-06-02 13:12:41 -03:00
Matias Alejo Garcia
e09d0643dc Merge pull request #502 from matiu/feature/api-dep
.
2014-06-02 10:37:46 -03:00
Matias Alejo Garcia
4b149c87bf . 2014-06-02 10:35:22 -03:00
Matias Alejo Garcia
b27b01215f Merge pull request #501 from matiu/feature/v0.2.3
Feature/v0.2.3
2014-06-02 10:32:31 -03:00
Matias Alejo Garcia
9694e415d1 0.2.3 2014-06-02 10:30:01 -03:00
Matias Alejo Garcia
99afc7e187 add npm ignore 2014-06-02 10:29:48 -03:00
Matias Alejo Garcia
c4a3b874d5 v0.2.3 2014-06-02 10:29:08 -03:00
Matias Alejo Garcia
1aa7dde498 Merge pull request #500 from matiu/v0.2.2
V0.2.2
2014-06-02 10:20:13 -03:00
Matias Alejo Garcia
cc6c077678 0.2.2 2014-06-02 10:19:14 -03:00
Matias Alejo Garcia
19a907aed3 v0.2.2 2014-06-02 10:18:58 -03:00
Mario Colque
fca0ccc0ec Merge pull request #498 from cmgustavo/bug/minor-details
Fixes: removed white spaces. Changed loader gif
2014-05-30 16:26:43 -03:00
Gustavo Cortez
58b7b67103 Fixes: removed white spaces. Changed loader gif 2014-05-30 16:12:19 -03:00
Mario Colque
f55ece0642 Merge pull request #495 from cmgustavo/bug/currency-values
Bug/currency values
2014-05-30 13:25:34 -03:00
Gustavo Cortez
f5c930adef Fix Conflicts:
public/js/main.min.js
2014-05-30 13:09:56 -03:00
Gustavo Maximiliano Cortez
6aa38d2046 Merge pull request #496 from matiu/feature/blockspager
add pager to blocks within certain date
2014-05-30 11:53:55 -03:00
Matias Alejo Garcia
d28d83b90a add pager to blocks within certain date 2014-05-30 11:50:18 -03:00
Gustavo Cortez
d82b0ecebd re-compile files dependences 2014-05-30 11:34:32 -03:00
Gustavo Cortez
3604ff8651 Fixes: currency values (output, input, fee) 2014-05-30 11:33:48 -03:00
Gustavo Maximiliano Cortez
36b183f26d Merge pull request #493 from colkito/fix/66-show-coinbase-info
showed coinbase info in the tx symmary
2014-05-27 11:36:28 -03:00
Mario Colque
ae839a0fc8 showed coinbase info in the tx symmary 2014-05-27 10:39:28 -03:00
Mario Colque
91b00a0088 Merge pull request #491 from cmgustavo/bug/01-ui
Bug/01 ui
2014-05-27 10:17:22 -03:00
Gustavo Cortez
fd23d9c722 Fixes: transaction list. Buttons with bootstrap styles 2014-05-26 17:57:13 -03:00
Gustavo Cortez
29c24884e5 Fix scroll position after changing view. 2014-05-26 17:32:15 -03:00
Gustavo Cortez
e0e6c94ae7 Removed unnecessary ng-cloak 2014-05-26 17:30:00 -03:00
Gustavo Cortez
7b6986e46b Fix secondary navbar from tx page 2014-05-26 16:02:43 -03:00
Gustavo Cortez
8baf5dd691 Removed size column on last transactions (home) 2014-05-26 15:36:12 -03:00
Gustavo Maximiliano Cortez
eefaf0ae6a Merge pull request #489 from matiu/feature/tx01
show blockhash in tx
2014-05-26 10:15:21 -03:00
Matias Alejo Garcia
e273ec998c update deps 2014-05-25 23:55:13 -03:00
Matias Alejo Garcia
a48a611de5 0.2.1 2014-05-25 23:54:28 -03:00
Matias Alejo Garcia
bb4bf112d9 show blockhash in tx 2014-05-25 22:14:12 -03:00
Matias Alejo Garcia
77dfa2fdc6 Merge pull request #483 from matiu/v0.1.12
V0.1.12
2014-05-17 19:02:40 -03:00
Matias Alejo Garcia
83a4adf570 update deps 2014-05-17 19:00:02 -03:00
Matias Alejo Garcia
9729af93bb 0.1.12 2014-05-17 18:56:19 -03:00
Matias Alejo Garcia
a1599b16b6 Merge pull request #481 from matiu/features/package-improvements
mv bin to .bin
2014-05-17 13:12:55 -03:00
Matias Alejo Garcia
da8f3d2473 mv bin to .bin 2014-05-17 12:54:23 -03:00
Ryan X. Charles
85cb296950 Merge pull request #479 from matiu/bug/fixes-sci-notation
fix sci notation
2014-05-17 04:57:36 -04:00
Matias Alejo Garcia
62e4a3c714 fix sci notation 2014-05-17 00:23:13 -03:00
Gustavo Maximiliano Cortez
40e7491234 Merge pull request #477 from matiu/feature/v0.1.10
v0.1.10
2014-05-13 18:02:15 -03:00
Matias Alejo Garcia
4d76f1c6f4 v0.1.10 2014-05-13 18:01:06 -03:00
Gustavo Maximiliano Cortez
39f23f75b5 Merge pull request #466 from matiu/bug/dependencies
Bug/dependencies
2014-04-17 10:59:16 -03:00
Gustavo Maximiliano Cortez
c36618a445 Merge pull request #465 from matiu/feature/v0.1.8
update version
2014-04-17 10:58:47 -03:00
Matias Alejo Garcia
4ed93d9105 update dependencies 2014-04-17 10:46:46 -03:00
Matias Alejo Garcia
112e1427bd update version 2014-04-17 09:40:18 -03:00
Matias Alejo Garcia
62d0bde1cb Merge pull request #464 from matiu/feature/readme
update version to 0.1.7
2014-04-17 07:50:25 -03:00
Matias Alejo Garcia
4f13a1c463 update version to 0.1.7 2014-04-17 07:48:19 -03:00
Matias Alejo Garcia
b41de7ac78 Merge pull request #452 from jyap808/patch-1
Update README.md
2014-04-07 10:06:59 -03:00
Matias Alejo Garcia
b6d8aa4d6e Merge pull request #456 from Lennie/patch-1
Possible broken link and suggested fix
2014-04-07 07:26:05 -03:00
Lennie
d6f9d84248 Possible broken link and suggested fix
http://insight.bitcore.io/ seems to point to some non-existent Github page. Could it be you wanted to point it to http://live.insight.is/ ?
2014-04-07 07:09:24 +02:00
Julian Yap
c2e267e6d6 Update README.md
Fix the Git clone URL since regular users can't clone as user 'git'.
2014-04-05 08:27:25 -10:00
Mario Colque
0cf6d8e722 Merge pull request #449 from cmgustavo/bug/update-js-files
Updated compiled js files.
2014-04-04 11:38:06 -03:00
Gustavo Cortez
b121081042 Updated compiled js files. 2014-04-03 17:31:55 -03:00
Mario Colque
f6d56cba21 Merge pull request #448 from cmgustavo/bug/03-missing-swf
Fix: missing swf file for copy button. Copied/renamed zeroclipboard.swf
2014-04-03 16:21:44 -03:00
Gustavo Cortez
ccf1d04449 Ignore only this file: ZeroClipboard.swf 2014-04-03 16:15:28 -03:00
Gustavo Cortez
c6d69324b0 Fix: missing swf file for copy button. Copied/renamed zeroclipboard.swf 2014-04-03 16:10:16 -03:00
Gustavo Maximiliano Cortez
48cbe43d42 Merge pull request #445 from cmgustavo/bug/missing-swf
Missing swf file for copy button
2014-04-03 14:31:36 -03:00
Gustavo Cortez
246948f6fd Missing swf file for copy button 2014-04-03 14:26:08 -03:00
Matias Alejo Garcia
b482e4d021 Merge pull request #440 from cmgustavo/bug/copy-script
Fixed copy value for scriptPubKey on tx list
2014-03-31 15:33:15 -03:00
Matias Alejo Garcia
e3ac30bb18 Merge pull request #435 from cmgustavo/bug/speed-up-address
Load the list of transactions until the Addr/Block Info are loaded
2014-03-31 15:32:59 -03:00
Gustavo Cortez
63b6edba33 Fixed copy value for scriptPubKey on tx list 2014-03-28 02:53:29 -03:00
Matias Alejo Garcia
1ccd161979 Merge pull request #438 from matiu/feature/readme
update version
2014-03-22 01:44:21 -03:00
Matias Alejo Garcia
370a89631c update version 2014-03-22 01:19:21 -03:00
Gustavo Cortez
ff01374e5a Fix name: s/getBalance/noTxList/g 2014-03-21 09:52:48 -03:00
Gustavo Cortez
6d99920d1b Load the list of transactions until the Addr/Block Info are loaded 2014-03-20 16:51:37 -03:00
Gustavo Maximiliano Cortez
47486b73db Merge pull request #434 from matiu/bug/sockets
Bug/sockets
2014-03-20 14:32:02 -03:00
Matias Alejo Garcia
bc0aff684b rm log 2014-03-20 14:30:52 -03:00
Matias Alejo Garcia
0a477d71be fix typo 2014-03-20 14:30:06 -03:00
Matias Alejo Garcia
abb35aa575 updates package version 2014-03-20 14:10:30 -03:00
Matias Alejo Garcia
6eff53b379 fix many socket related issuers 2014-03-20 14:06:05 -03:00
Matias Alejo Garcia
ec3f05cb75 add monitoring to Gruntfile. updates README 2014-03-20 12:34:35 -03:00
Matias Alejo Garcia
fcf6d72fa4 Merge pull request #433 from cmgustavo/bug/search-box-navbar
Bug/search box navbar
2014-03-19 15:46:08 -03:00
Matias Alejo Garcia
f7fbbf512d Update README.md 2014-03-18 17:33:09 -03:00
Matias Alejo Garcia
fe09824a68 Update README.md 2014-03-18 17:31:20 -03:00
Gustavo Cortez
87dd9a7159 fix navbar. hide status if screen is small 2014-03-17 15:18:11 -03:00
Gustavo Cortez
2fa72b83bb Merge branch 'master' of https://github.com/cmgustavo/insight
Conflicts:
	config/config.js
2014-03-17 12:06:31 -03:00
Matias Alejo Garcia
f368789f98 Merge pull request #429 from matiu/feature/new-bitcore
change insight-api dep to github
2014-03-10 17:48:32 -02:00
Matias Alejo Garcia
42d8b4a0ca change insight-api dep to github 2014-03-10 16:48:05 -03:00
Mario Colque
7c5c90b258 Merge pull request #428 from matiu/feature/new-bitcore
Feature/new bitcore
2014-03-10 16:12:58 -02:00
Matias Alejo Garcia
cbe3e2c29e fix package json 2014-03-10 15:08:00 -03:00
Matias Alejo Garcia
7b3e682dbb update versions 2014-03-10 13:04:11 -03:00
Gustavo Maximiliano Cortez
993013c7ee Merge pull request #427 from colkito/bug/qrcode-scanner-css-fix
fix of CSS for QR code scanner button
2014-03-10 10:56:01 -02:00
Mario Colque
0d4b9ddfc0 fix of CSS for QR code scanner button 2014-03-10 09:54:24 -03:00
Matias Alejo Garcia
ac7b2373b0 Merge pull request #424 from colkito/feature/mobile-qrcode-scanner
Feature/mobile qrcode scanner
2014-03-08 04:40:21 -02:00
Mario Colque
6fa244dd7d merge 2014-03-08 03:26:03 -03:00
Mario Colque
a60abd9793 added a new library for fir canvas on ios/safari 2014-03-08 03:24:28 -03:00
Mario Colque
83681967df added a new way to scan qr codes from mobile browsers 2014-03-08 03:23:42 -03:00
Matias Alejo Garcia
8ceae3683d Merge pull request #423 from wozz/patch-1
Add LockTime visibility for transactions
2014-03-07 18:53:19 -02:00
wozz
378943f94d Add LockTime visibility for transactions
For transactions without default locktime, show the locktime value.
2014-03-07 15:22:43 -05:00
Mario Colque
dac2f8b949 Update README.md 2014-02-28 19:10:04 -02:00
Gustavo Maximiliano Cortez
e66461cb1c Merge pull request #420 from colkito/bug/missing-angular-module
adde angular-ui-utils. CSS fix
2014-02-28 18:25:56 -02:00
Gustavo Maximiliano Cortez
29b79e9ca9 Merge pull request #419 from colkito/bug/insight-api-dependency
added insight-bitcore-api dependency form github insight repo
2014-02-28 18:24:33 -02:00
Mario Colque
ef2cb2c055 adde angular-ui-utils. CSS fix 2014-02-28 17:22:24 -03:00
Mario Colque
45f8ff9ea0 Merge pull request #416 from bechi/feature/05-layout-details
Feature/05 layout details
2014-02-28 17:53:32 -02:00
Bechi
92cf4e82a3 fix conflict 2014-02-28 16:52:51 -03:00
Mario Colque
284ff9eecc added insight-bitcore-api dependency form github insight repo 2014-02-28 16:34:38 -03:00
Matias Alejo Garcia
2dbcb3588a Merge pull request #418 from colkito/feature/qr-reader
412 New feature: qr code scanner
2014-02-28 17:26:11 -02:00
Mario Colque
8200f2121b solve conflicts 2014-02-28 16:20:31 -03:00
Mario Colque
df1778fd54 added qr code scanner support 2014-02-28 16:18:06 -03:00
Bechi
fb8c2e98e3 fix tx details 2014-02-28 10:26:38 -03:00
Mario Colque
6486d9a741 Merge pull request #414 from cmgustavo/bug/scriptsig-front-end
scriptsig is an array in the front-end. It 's for designing.
2014-02-27 11:52:24 -02:00
Bechi
c97289a4cd fix conflict 2014-02-27 10:47:44 -03:00
Bechi
a4d09fa089 tx details 2014-02-27 10:07:29 -03:00
Gustavo Cortez
fd6d06d115 scriptsig is an array in the front-end. It 's for designing. 2014-02-26 19:03:48 -03:00
Mario Colque
b0f4deb0d8 Update README.md 2014-02-26 18:54:03 -02:00
Mario Colque
68ed982992 Update package.json 2014-02-26 17:55:45 -02:00
Matias Alejo Garcia
ebfa84b9d2 Merge pull request #413 from colkito/insight-bitcore-client
removed insight-api files
2014-02-26 17:52:47 -02:00
Mario Colque
d4c40355f8 removed insight-api files 2014-02-26 16:50:10 -03:00
Matias Alejo Garcia
cdfd851573 Update README.md 2014-02-26 17:48:40 -02:00
Matias Alejo Garcia
b67b59e298 Merge pull request #411 from martindale/sync-icon
Sync Icon
2014-02-26 15:56:41 -02:00
Eric Martindale
8cf992dd1c Remove extra classes. 2014-02-26 17:36:13 +00:00
Eric Martindale
6648d73ab8 Change from text to icon for sync completion. 2014-02-26 17:06:11 +00:00
Gustavo Cortez
d9020ca104 fixed environment variable for set port of bitcoind and p2p 2014-02-25 19:03:45 -03:00
311 changed files with 35185 additions and 53543 deletions

29
.circleci/config.yml Normal file
View File

@ -0,0 +1,29 @@
# Javascript Node CircleCI 2.0 configuration file
# Check https://circleci.com/docs/2.0/language-javascript/ for more details
version: 2
jobs:
build-and-test:
docker:
- image: circleci/node:8.10-browsers
working_directory: ~/insight
steps:
- checkout
# Download and cache dependencies
- restore_cache:
keys:
- dependency-cache-{{ checksum "package.json" }}
- run: npm install
- save_cache:
paths:
- node_modules
key: dependency-cache-{{ checksum "package.json" }}
# run tests
- run: npm run test:ci
workflows:
version: 2
build_and_test:
jobs:
- build-and-test

31
.gitignore vendored
View File

@ -1,31 +1,6 @@
# from https://github.com/github/gitignore/blob/master/Node.gitignore
lib-cov
*.seed
*.log
*.csv
*.dat
*.out
*.pid
*.gz
*.swp
tags
pids
logs
results
build
node_modules node_modules
yarn.lock
# extras *.log
*.swp
*.swo
*~
.project
peerdb.json
npm-debug.log
.nodemonignore
.DS_Store .DS_Store
db/txs/* db/txs/*
db/txs db/txs
@ -38,3 +13,5 @@ db/testnet/blocks
README.html README.html
public public
package-lock.json

65
.jscsrc Executable file
View File

@ -0,0 +1,65 @@
{
"excludeFiles": ["node_modules/**", "mynode/**"],
"requireCurlyBraces": [
"if",
"else",
"for",
"while",
"do",
"try",
"catch"
],
"requireOperatorBeforeLineBreak": true,
"requireCamelCaseOrUpperCaseIdentifiers": true,
"maximumLineLength": {
"value": 200,
"allowComments": true,
"allowRegex": true
},
"validateIndentation": 2,
"validateQuoteMarks": "'",
"disallowMultipleLineStrings": true,
"disallowMixedSpacesAndTabs": true,
"disallowTrailingWhitespace": true,
"disallowSpaceAfterPrefixUnaryOperators": true,
"disallowMultipleVarDecl": null,
"requireSpaceAfterKeywords": [
"if",
"else",
"for",
"while",
"do",
"switch",
"return",
"try",
"catch"
],
"requireSpaceBeforeBinaryOperators": [
"=", "+=", "-=", "*=", "/=", "%=", "<<=", ">>=", ">>>=",
"&=", "|=", "^=", "+=",
"+", "-", "*", "/", "%", "<<", ">>", ">>>", "&",
"|", "^", "&&", "||", "===", "==", ">=",
"<=", "<", ">", "!=", "!=="
],
"requireSpaceAfterBinaryOperators": true,
"requireSpacesInConditionalExpression": true,
"requireSpaceBeforeBlockStatements": true,
"disallowSpacesInsideObjectBrackets": "all",
"disallowSpacesInsideArrayBrackets": "all",
"disallowSpacesInsideParentheses": true,
"disallowMultipleLineBreaks": true,
"disallowCommaBeforeLineBreak": null,
"disallowDanglingUnderscores": null,
"disallowEmptyBlocks": null,
"disallowTrailingComma": null,
"requireCommaBeforeLineBreak": null,
"requireDotNotation": null,
"requireMultipleVarDecl": null,
"requireParenthesesAroundIIFE": true
}

View File

@ -1,4 +1,8 @@
sudo: false
language: node_js language: node_js
node_js: node_js:
- '0.10' - 'v8'
install: npm install install:
- npm install
after_success:
- yarn send-coverage

View File

@ -1,94 +0,0 @@
'use strict';
module.exports = function(grunt) {
//Load NPM tasks
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-mocha-test');
grunt.loadNpmTasks('grunt-nodemon');
grunt.loadNpmTasks('grunt-concurrent');
grunt.loadNpmTasks('grunt-env');
grunt.loadNpmTasks('grunt-markdown');
// Project Configuration
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
watch: {
readme: {
files: ['README.md'],
tasks: ['markdown']
},
js: {
files: ['Gruntfile.js', 'insight.js', 'app/**/*.js'],
options: {
livereload: true,
},
},
test: {
files: ['test/**/*.js', 'test/*.js','app/**/*.js'],
tasks: ['test'],
}
},
jshint: {
all: {
src: ['Gruntfile.js', 'insight.js', 'app/**/*.js', 'lib/*.js', 'config/*.js'],
options: {
jshintrc: true
}
}
},
mochaTest: {
options: {
reporter: 'spec',
},
src: ['test/**/*.js'],
},
nodemon: {
dev: {
script: 'insight.js',
options: {
args: [],
ignore: ['test/**/*', 'util/**/*', 'dev-util/**/*'],
// nodeArgs: ['--debug'],
delayTime: 1,
env: {
PORT: 3000
},
cwd: __dirname
}
}
},
concurrent: {
tasks: ['nodemon', 'watch'],
options: {
logConcurrentOutput: true
}
},
env: {
test: {
NODE_ENV: 'test'
}
},
markdown: {
all: {
files: [
{
expand: true,
src: 'README.md',
dest: '.',
ext: '.html'
}
]
}
}
});
//Making grunt default to force in order not to break the project.
grunt.option('force', true);
//Default task(s).
grunt.registerTask('default', ['concurrent']);
//Test task.
grunt.registerTask('test', ['env:test', 'mochaTest']);
};

21
LICENSE Normal file
View File

@ -0,0 +1,21 @@
MIT License
Copyright (c) 2013-2017 BitPay, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

396
README.md
View File

@ -1,185 +1,135 @@
# Flosight API
# *insight API* A Florincoin blockchain REST and web socket API service for [Flocore Node](https://github.com/bitpay/flocore-node).
*insight API* is an open-source bitcoin blockchain REST This is a backend-only service. If you're looking for the web frontend application, take a look at https://github.com/bitpay/flosight-ui.
and websocket API. Insight API runs in NodeJS and uses LevelDB for storage.
This is a backend-only service. If you're looking for the web frontend application, ## Getting Started
take a look at https://github.com/bitpay/insight.
*Insight API* allows to develop bitcoin-related applications (such as wallets) that ```bashl
require certain information from the blockchain that bitcoind does not provide. npm install -g flocore@latest
flocore create mynode
cd mynode
flocore install flosight-api
flocore start
```
A blockchain explorer front-end has been developed on top of *Insight API*. It can The API endpoints will be available by default at: `http://localhost:3001/flosight-api/`
be downloaded at [Github Insight Repository](https://github.com/bitpay/insight).
## Warning
Insight file sync does not work with **bitcoind** v0.10
In order to use Insigtht you must set the environment variable INSIGHT_FORCE_RPC_SYNC = 1
We are working on `bitcore-node` to replace Insight-api. Check `bitcore-node` on [github](https://github.com/bitpay/bitcore-node).
## Prerequisites ## Prerequisites
* **bitcoind** - Download and Install [Bitcoin](http://bitcoin.org/en/download) - [Flocore 5.x](https://github.com/bitpay/flocore)
*insight API* needs a *trusted* bitcoind node to run. *insight API* will connect to the node **Note:** You can use an existing Florincoin data directory, however `txindex`, `addressindex`, `timestampindex` and `spentindex` needs to be set to true in `florincoin.conf`, as well as a few other additional fields.
through the RPC API, bitcoin peer-to-peer protocol, and will even read its raw block .dat files for syncing.
Configure bitcoind to listen to RPC calls and set `txindex` to true. ## Notes on Upgrading from v0.3
The easiest way to do this is by copying `./etc/bitcoind/bitcoin.conf` to your
bitcoin data directory (usually `~/.bitcoin` on Linux, `%appdata%\Bitcoin\` on Windows,
or `~/Library/Application Support/Bitcoin` on Mac OS X).
bitcoind must be running and must have finished downloading the blockchain **before** running *insight API*.
* **Node.js v0.10.x** - Download and Install [Node.js](http://www.nodejs.org/download/).
* **NPM** - Node.js package manager, should be automatically installed when you get node.js.
## Quick Install
Check the Prerequisites section above before installing.
To install Insight API, clone the main repository:
$ git clone https://github.com/bitpay/insight-api && cd insight-api
Install dependencies:
$ npm install
Run the main application:
$ node insight.js
Then open a browser and go to:
http://localhost:3001
Please note that the app will need to sync its internal database
with the blockchain state, which may take some time. You can check
sync progress at http://localhost:3001/api/sync.
## Configuration
All configuration is specified in the [config](config/) folder, particularly the [config.js](config/config.js) file. There you can specify your application name and database name. Certain configuration values are pulled from environment variables if they are defined:
The unspent outputs format now has `satoshis` and `height`:
``` ```
BITCOIND_HOST # RPC bitcoind host [
BITCOIND_PORT # RPC bitcoind Port {
BITCOIND_P2P_HOST # P2P bitcoind Host (will default to BITCOIND_HOST, if specified) "address":"mo9ncXisMeAoXwqcV5EWuyncbmCcQN4rVs",
BITCOIND_P2P_PORT # P2P bitcoind Port "txid":"d5f8a96faccf79d4c087fa217627bb1120e83f8ea1a7d84b1de4277ead9bbac1",
BITCOIND_USER # RPC username "vout":0,
BITCOIND_PASS # RPC password "scriptPubKey":"76a91453c0307d6851aa0ce7825ba883c6bd9ad242b48688ac",
BITCOIND_DATADIR # bitcoind datadir. 'testnet3' will be appended automatically if testnet is used. NEED to finish with '/'. e.g: `/vol/data/` "amount":0.000006,
INSIGHT_NETWORK [= 'livenet' | 'testnet'] "satoshis":600,
INSIGHT_PORT # insight api port "confirmations":0,
INSIGHT_DB # Path where to store insight's internal DB. (defaults to $HOME/.insight) "ts":1461349425
INSIGHT_SAFE_CONFIRMATIONS=6 # Nr. of confirmation needed to start caching transaction information },
INSIGHT_IGNORE_CACHE # True to ignore cache of spents in transaction, with more than INSIGHT_SAFE_CONFIRMATIONS confirmations. This is useful for tracking double spents for old transactions. {
ENABLE_CURRENCYRATES # if "true" will enable a plugin to obtain historic conversion rates for various currencies "address": "mo9ncXisMeAoXwqcV5EWuyncbmCcQN4rVs",
ENABLE_RATELIMITER # if "true" will enable the ratelimiter plugin "txid": "bc9df3b92120feaee4edc80963d8ed59d6a78ea0defef3ec3cb374f2015bfc6e",
LOGGER_LEVEL # defaults to 'info', can be 'debug','verbose','error', etc. "vout": 1,
ENABLE_HTTPS # if "true" it will server using SSL/HTTPS "scriptPubKey": "76a91453c0307d6851aa0ce7825ba883c6bd9ad242b48688ac",
ENABLE_EMAILSTORE # if "true" will enable a plugin to store data with a validated email address "amount": 0.12345678,
INSIGHT_EMAIL_CONFIRM_HOST # Only meanfull if ENABLE_EMAILSTORE is enable. Hostname for the confirm URLs. E.g: 'https://insight.bitpay.com' "satoshis: 12345678,
"confirmations": 1,
"height": 300001
}
]
```
The `timestamp` property will only be set for unconfirmed transactions and `height` can be used for determining block order. The `confirmationsFromCache` is nolonger set or necessary, confirmation count is only cached for the time between blocks.
There is a new `GET` endpoint or raw blocks at `/rawblock/<blockHash>`:
Response format:
```
{
"rawblock": "blockhexstring..."
}
``` ```
Make sure that bitcoind is configured to [accept incoming connections using 'rpcallowip'](https://en.bitcoin.it/wiki/Running_Bitcoin). There are a few changes to the `GET` endpoint for `/addr/[:address]`:
In case the network is changed (testnet to livenet or vice versa) levelDB database needs to be deleted. This can be performed running: - The list of txids in an address summary does not include orphaned transactions
```util/sync.js -D``` and waiting for *insight* to synchronize again. Once the database is deleted, the sync.js process can be safely interrupted (CTRL+C) and continued from the synchronization process embedded in main app. - The txids will be sorted in block order
- The list of txids will be limited at 1000 txids
- There are two new query options "from" and "to" for pagination of the txids (e.g. `/addr/[:address]?from=1000&to=2000`)
## Synchronization Some additional general notes:
- The transaction history for an address will be sorted in block order
- The response for the `/sync` endpoint does not include `startTs` and `endTs` as the sync is no longer relevant as indexes are built in florincoind.
- The endpoint for `/peer` is no longer relevant connection to florincoind is via ZMQ.
- `/tx` endpoint results will now include block height, and spentTx related fields will be set to `null` if unspent.
- `/block` endpoint results does not include `confirmations` and will include `poolInfo`.
The initial synchronization process scans the blockchain from the paired bitcoind server to update addresses and balances. *insight-api* needs exactly one trusted bitcoind node to run. This node must have finished downloading the blockchain before running *insight-api*. ## Notes on Upgrading from v0.2
While *insight* is synchronizing the website can be accessed (the sync process is embedded in the webserver), but there may be missing data or incorrect balances for addresses. The 'sync' status is shown at the `/api/sync` endpoint. Some of the fields and methods are not supported:
The blockchain can be read from bitcoind's raw `.dat` files or RPC interface. The `/tx/<txid>` endpoint JSON response will not include the following fields on the "vin"
Reading the information from the `.dat` files is much faster so it's the object:
recommended (and default) alternative. `.dat` files are scanned in the default - `doubleSpentTxId` // double spends are not currently tracked
location for each platform (for example, `~/.bitcoin` on Linux). In case a - `isConfirmed` // confirmation of the previous output
non-standard location is used, it needs to be defined (see the Configuration section). - `confirmations` // confirmations of the previous output
As of June 2014, using `.dat` files the sync process takes 9 hrs. - `unconfirmedInput`
for livenet and 30 mins. for testnet.
While synchronizing the blockchain, *insight-api* listens for new blocks and The `/tx/<txid>` endpoint JSON response will not include the following fields on the "vout"
transactions relayed by the bitcoind node. Those are also stored on *insight-api*'s database. object.
In case *insight-api* is shutdown for a period of time, restarting it will trigger - `spentTs`
a partial (historic) synchronization of the blockchain. Depending on the size of
that synchronization task, a reverse RPC or forward `.dat` syncing strategy will be used.
If bitcoind is shutdown, *insight-api* needs to be stopped and restarted The `/status?q=getTxOutSetInfo` method has also been removed due to the query being very slow and locking florincoind.
once bitcoind is restarted.
### Syncing old blockchain data manually Plug-in support for Flosight API is also no longer available, as well as the endpoints:
- `/email/retrieve`
- `/rates/:code`
Old blockchain data can be manually synced issuing: Caching support has not yet been added in the v0.3 upgrade.
$ util/sync.js ## Query Rate Limit
Check util/sync.js --help for options, particulary -D to erase the current DB. To protect the server, flosight-api has a built it query rate limiter. It can be configurable in `flocore-node.json` with:
``` json
"servicesConfig": {
"flosight-api": {
"rateLimiterOptions": {
"whitelist": ["::ffff:127.0.0.1"]
}
}
}
```
With all the configuration options available: https://github.com/bitpay/flosight-api/blob/master/lib/ratelimiter.js#L10-17
*NOTE*: there is no need to run this manually since the historic synchronization Or disabled entirely with:
is built in into the web application. Running *insight-api* normally will trigger ``` json
the historic sync automatically. "servicesConfig": {
"flosight-api": {
"disableRateLimiter": true
### DB storage requirement }
}
To store the blockchain and address related information, *insight-api* uses LevelDB. ```
Two DBs are created: txs and blocks. By default these are stored on
``~/.insight/``
Please note that some older versions of Insight-API store that on `<insight's root>/db`.
This can be changed at config/config.js. As of June 2014, storing the livenet blockchain takes ~35GB of disk space (2GB for the testnet).
## Development
To run insight locally for development with grunt:
```$ NODE_ENV=development grunt```
To run the tests
```$ grunt test```
Contributions and suggestions are welcome at [insight-api github repository](https://github.com/bitpay/insight-api).
## Caching schema
Since v0.2 a new cache schema has been introduced. Only information from transactions with
INSIGHT_SAFE_CONFIRMATIONS settings will be cached (by default SAFE_CONFIRMATIONS=6). There
are 3 different caches:
* Number of confirmations
* Transaction output spent/unspent status
* scriptPubKey for unspent transactions
Cache data is only populated on request, i.e., only after accessing the required data for
the first time, the information is cached, there is not pre-caching procedure. To ignore
cache by default, use INSIGHT_IGNORE_CACHE. Also, address related calls support `?noCache=1`
to ignore the cache in a particular API request.
## API
By default, insight provides a REST API at `/api`, but this prefix is configurable from the var `apiPrefix` in the `config.js` file.
The end-points are:
## API HTTP Endpoints
### Block ### Block
``` ```
/api/block/[:hash] /api/block/[:hash]
/api/block/00000000a967199a2fad0877433c93df785a8d8ce062e5f9b451cd1397bdbf62 /api/block/00000000a967199a2fad0877433c93df785a8d8ce062e5f9b451cd1397bdbf62
``` ```
### Block index
### Block Index
Get block hash by height Get block hash by height
``` ```
/api/block-index/[:height] /api/block-index/[:height]
@ -187,22 +137,77 @@ Get block hash by height
``` ```
This would return: This would return:
``` ```
{"blockHash":"000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f"} {
"blockHash":"000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f"
}
``` ```
which is the hash of the Genesis block (0 height) which is the hash of the Genesis block (0 height)
### Raw Block
```
/api/rawblock/[:blockHash]
/api/rawblock/[:blockHeight]
```
This would return:
```
{
"rawblock":"blockhexstring..."
}
```
### Block Summaries
Get block summaries by date:
```
/api/blocks?limit=3&blockDate=2016-04-22
```
Example response:
```
{
"blocks": [
{
"height": 408495,
"size": 989237,
"hash": "00000000000000000108a1f4d4db839702d72f16561b1154600a26c453ecb378",
"time": 1461360083,
"txlength": 1695,
"poolInfo": {
"poolName": "BTCC Pool",
"url": "https://pool.btcc.com/"
}
}
],
"length": 1,
"pagination": {
"next": "2016-04-23",
"prev": "2016-04-21",
"currentTs": 1461369599,
"current": "2016-04-22",
"isToday": true,
"more": true,
"moreTs": 1461369600
}
}
```
### Transaction ### Transaction
``` ```
/api/tx/[:txid] /api/tx/[:txid]
/api/tx/525de308971eabd941b139f46c7198b5af9479325c2395db7f2fb5ae8562556c /api/tx/525de308971eabd941b139f46c7198b5af9479325c2395db7f2fb5ae8562556c
/api/raw/[:rawid] /api/rawtx/[:rawid]
/api/raw/525de308971eabd941b139f46c7198b5af9479325c2395db7f2fb5ae8562556c /api/rawtx/525de308971eabd941b139f46c7198b5af9479325c2395db7f2fb5ae8562556c
``` ```
### Address ### Address
``` ```
/api/addr/[:addr][?noTxList=1&noCache=1] /api/addr/[:addr][?noTxList=1][&from=&to=]
/api/addr/mmvP3mTe53qxHdPqXEvdu8WdC7GfQ2vmx5?noTxList=1 /api/addr/mmvP3mTe53qxHdPqXEvdu8WdC7GfQ2vmx5?noTxList=1
/api/addr/mmvP3mTe53qxHdPqXEvdu8WdC7GfQ2vmx5?from=1000&to=2000
``` ```
### Address Properties ### Address Properties
``` ```
/api/addr/[:addr]/balance /api/addr/[:addr]/balance
@ -211,39 +216,38 @@ which is the hash of the Genesis block (0 height)
/api/addr/[:addr]/unconfirmedBalance /api/addr/[:addr]/unconfirmedBalance
``` ```
The response contains the value in Satoshis. The response contains the value in Satoshis.
### Unspent Outputs ### Unspent Outputs
``` ```
/api/addr/[:addr]/utxo[?noCache=1] /api/addr/[:addr]/utxo
``` ```
Sample return: Sample return:
``` json ```
[ [
{ {
"address": "n2PuaAguxZqLddRbTnAoAuwKYgN2w2hZk7", "address":"mo9ncXisMeAoXwqcV5EWuyncbmCcQN4rVs",
"txid": "dbfdc2a0d22a8282c4e7be0452d595695f3a39173bed4f48e590877382b112fc", "txid":"d5f8a96faccf79d4c087fa217627bb1120e83f8ea1a7d84b1de4277ead9bbac1",
"vout": 0, "vout":0,
"ts": 1401276201, "scriptPubKey":"76a91453c0307d6851aa0ce7825ba883c6bd9ad242b48688ac",
"scriptPubKey": "76a914e50575162795cd77366fb80d728e3216bd52deac88ac", "amount":0.000006,
"amount": 0.001, "satoshis":600,
"confirmations": 3 "confirmations":0,
}, "ts":1461349425
{ },
"address": "n2PuaAguxZqLddRbTnAoAuwKYgN2w2hZk7", {
"txid": "e2b82af55d64f12fd0dd075d0922ee7d6a300f58fe60a23cbb5831b31d1d58b4", "address": "mo9ncXisMeAoXwqcV5EWuyncbmCcQN4rVs",
"vout": 0, "txid": "bc9df3b92120feaee4edc80963d8ed59d6a78ea0defef3ec3cb374f2015bfc6e",
"ts": 1401226410, "vout": 1,
"scriptPubKey": "76a914e50575162795cd77366fb80d728e3216bd52deac88ac", "scriptPubKey": "76a91453c0307d6851aa0ce7825ba883c6bd9ad242b48688ac",
"amount": 0.001, "amount": 0.12345678,
"confirmation": 6, "satoshis: 12345678,
"confirmationsFromCache": true "confirmations": 1,
} "height": 300001
}
] ]
``` ```
Please note that in case confirmations are cached (which happens by default when the number of confirmations is bigger that INSIGHT_SAFE_CONFIRMATIONS) the response will include the pair confirmationsFromCache:true, and confirmations will equal INSIGHT_SAFE_CONFIRMATIONS. See noCache and INSIGHT_IGNORE_CACHE options for details.
### Unspent Outputs for Multiple Addresses
### Unspent Outputs for multiple addresses
GET method: GET method:
``` ```
/api/addrs/[:addrs]/utxo /api/addrs/[:addrs]/utxo
@ -271,7 +275,7 @@ addrs: 2NF2baYuJAkCKo5onjUKEPdARQkZ6SYyKd5,2NAre8sX2povnjy4aeiHKeEh97Qhn97tB1f
/api/txs/?address=mmhmMNfBiZZ37g1tgg2t8DDbNoEdqKVxAL /api/txs/?address=mmhmMNfBiZZ37g1tgg2t8DDbNoEdqKVxAL
``` ```
### Transactions for multiple addresses ### Transactions for Multiple Addresses
GET method: GET method:
``` ```
/api/addrs/[:addrs]/txs[?from=&to=] /api/addrs/[:addrs]/txs[?from=&to=]
@ -288,6 +292,9 @@ POST params:
addrs: 2NF2baYuJAkCKo5onjUKEPdARQkZ6SYyKd5,2NAre8sX2povnjy4aeiHKeEh97Qhn97tB1f addrs: 2NF2baYuJAkCKo5onjUKEPdARQkZ6SYyKd5,2NAre8sX2povnjy4aeiHKeEh97Qhn97tB1f
from (optional): 0 from (optional): 0
to (optional): 20 to (optional): 20
noAsm (optional): 1 (will omit script asm from results)
noScriptSig (optional): 1 (will omit the scriptSig from all inputs)
noSpent (option): 1 (will omit spent information per output)
``` ```
Sample output: Sample output:
@ -320,8 +327,7 @@ Sample output:
Note: if pagination params are not specified, the result is an array of transactions. Note: if pagination params are not specified, the result is an array of transactions.
### Transaction Broadcasting
### Transaction broadcasting
POST method: POST method:
``` ```
/api/tx/send /api/tx/send
@ -348,17 +354,17 @@ POST response:
} }
``` ```
### Historic blockchain data sync status ### Historic Blockchain Data Sync Status
``` ```
/api/sync /api/sync
``` ```
### Live network p2p data sync status ### Live Network P2P Data Sync Status
``` ```
/api/peer /api/peer
``` ```
### Status of the bitcoin network ### Status of the Florincoin Network
``` ```
/api/status?q=xxx /api/status?q=xxx
``` ```
@ -367,16 +373,22 @@ Where "xxx" can be:
* getInfo * getInfo
* getDifficulty * getDifficulty
* getTxOutSetInfo
* getBestBlockHash * getBestBlockHash
* getLastBlockHash * getLastBlockHash
### Utility Methods
```
/api/utils/estimatefee[?nbBlocks=2]
```
## Web Socket API ## Web Socket API
The web socket API is served using [socket.io](http://socket.io). The web socket API is served using [socket.io](http://socket.io).
The following are the events published by insight: The following are the events published by flosight:
'tx': new transaction received from network. This event is published in the 'inv' room. Data will be a app/models/Transaction object. `tx`: new transaction received from network. This event is published in the 'inv' room. Data will be a app/models/Transaction object.
Sample output: Sample output:
``` ```
{ {
@ -387,7 +399,7 @@ Sample output:
``` ```
'block': new block received from network. This event is published in the 'inv' room. Data will be a app/models/Block object. `block`: new block received from network. This event is published in the `inv` room. Data will be a app/models/Block object.
Sample output: Sample output:
``` ```
{ {
@ -397,9 +409,9 @@ Sample output:
} }
``` ```
'<bitcoinAddress>': new transaction concerning <bitcoinAddress> received from network. This event is published in the '<bitcoinAddress>' room. `<florincoinAddress>`: new transaction concerning <florincoinAddress> received from network. This event is published in the `<florincoinAddress>` room.
'status': every 1% increment on the sync task, this event will be triggered. This event is published in the 'sync' room. `status`: every 1% increment on the sync task, this event will be triggered. This event is published in the `sync` room.
Sample output: Sample output:
``` ```
@ -417,18 +429,18 @@ Sample output:
### Example Usage ### Example Usage
The following html page connects to the socket.io insight API and listens for new transactions. The following html page connects to the socket.io flosight API and listens for new transactions.
html html
``` ```
<html> <html>
<body> <body>
<script src="http://<insight-server>:<port>/socket.io/socket.io.js"></script> <script src="http://<flosight-server>:<port>/socket.io/socket.io.js"></script>
<script> <script>
eventToListenTo = 'tx' eventToListenTo = 'tx'
room = 'inv' room = 'inv'
var socket = io("http://<insight-server>:<port>/"); var socket = io("http://<flosight-server>:<port>/");
socket.on('connect', function() { socket.on('connect', function() {
// Join the room. // Join the room.
socket.emit('subscribe', room); socket.emit('subscribe', room);

62
app/.angular-cli.json Normal file
View File

@ -0,0 +1,62 @@
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"project": {
"name": "insight-ui"
},
"apps": [
{
"root": "src",
"outDir": "dist",
"assets": [
"assets",
"favicon.ico"
],
"index": "index.html",
"main": "app/main.ts",
"polyfills": "polyfills.ts",
"test": "test.ts",
"tsconfig": "tsconfig.app.json",
"testTsconfig": "tsconfig.spec.json",
"prefix": "app",
"scripts": [],
"environmentSource": "environments/environment.ts",
"environments": {
"dev": "environments/environment.ts",
"prod": "environments/environment.prod.ts"
}
}
],
"e2e": {
"protractor": {
"config": "./protractor.conf.js"
}
},
"lint": [
{
"project": "src/tsconfig.app.json"
},
{
"project": "src/tsconfig.spec.json"
},
{
"project": "e2e/tsconfig.e2e.json"
}
],
"test": {
"karma": {
"config": "./karma.conf.js"
},
"codeCoverage": {
"exclude": [
"src/polyfills.ts",
"src/test.ts",
"src/mocks.ts",
"**/*.mock.ts"
]
}
},
"defaults": {
"styleExt": "css",
"component": {}
}
}

40
app/.gitignore vendored Normal file
View File

@ -0,0 +1,40 @@
# Specifies intentionally untracked files to ignore when using Git
# http://git-scm.com/docs/gitignore
*~
*.sw[mnpcod]
*.log
*.tmp
*.tmp.*
log.txt
*.sublime-project
*.sublime-workspace
.vscode/
npm-debug.log*
.sourcemaps/
.idea/
.sass-cache/
.tmp/
.versions/
coverage/
dist/
node_modules/
tmp/
temp/
hooks/
platforms/
plugins/
plugins/android.json
plugins/ios.json
www/
$RECYCLE.BIN/
# e2e
/e2e/*.js
/e2e/*.map
.DS_Store
Thumbs.db
UserInterfaceState.xcuserstate

24
app/README.md Normal file
View File

@ -0,0 +1,24 @@
[![Build Status](https://travis-ci.org/bitpay/insight-ui.svg?branch=ionic)](https://travis-ci.org/bitpay/insight-ui)
[![codecov.io](https://codecov.io/github/bitpay/insight-ui/coverage.svg?branch=ionic)](https://codecov.io/github/bitpay/insight-ui?branch=ionic)
# Insight UI
## Install & Start
You need to be running [the latest node LTS](https://nodejs.org/en/download/) or newer.
```bash
git clone https://github.com/bitpay/insight-ui.git
cd insight-ui/app
npm install
npm start
```
## Run Unit Tests
```bash
npm test
```
## Run E2E
```
npm run e2e
```

View File

@ -1,266 +0,0 @@
'use strict';
/**
* Module dependencies.
*/
var _ = require('lodash');
var Address = require('../models/Address');
var common = require('./common');
var async = require('async');
var MAX_BATCH_SIZE = 100;
var RPC_CONCURRENCY = 5;
var tDb = require('../../lib/TransactionDb').default();
var checkSync = function(req, res) {
if (req.historicSync) {
var i = req.historicSync.info()
if (i.status !== 'finished') {
common.notReady(req, res, i.syncPercentage);
return false;
}
}
return true;
};
var getAddr = function(req, res, next) {
var a;
try {
var addr = req.param('addr');
a = new Address(addr);
} catch (e) {
common.handleErrors({
message: 'Invalid address:' + e.message,
code: 1
}, res, next);
return null;
}
return a;
};
var getAddrs = function(req, res, next) {
var as = [];
try {
var addrStrs = req.param('addrs');
var s = addrStrs.split(',');
if (s.length === 0) return as;
for (var i = 0; i < s.length; i++) {
var a = new Address(s[i]);
as.push(a);
}
} catch (e) {
common.handleErrors({
message: 'Invalid addrs param:' + e.message,
code: 1
}, res, next);
return null;
}
return as;
};
exports.show = function(req, res, next) {
if (!checkSync(req, res)) return;
var a = getAddr(req, res, next);
if (a) {
a.update(function(err) {
if (err) {
return common.handleErrors(err, res);
} else {
return res.jsonp(a.getObj());
}
}, {
txLimit: req.query.noTxList ? 0 : -1,
ignoreCache: req.param('noCache')
});
}
};
exports.utxo = function(req, res, next) {
if (!checkSync(req, res)) return;
var a = getAddr(req, res, next);
if (a) {
a.update(function(err) {
if (err)
return common.handleErrors(err, res);
else {
return res.jsonp(a.unspent);
}
}, {
onlyUnspent: 1,
ignoreCache: req.param('noCache')
});
}
};
exports.multiutxo = function(req, res, next) {
if (!checkSync(req, res)) return;
var as = getAddrs(req, res, next);
if (as) {
var utxos = [];
async.eachLimit(as, RPC_CONCURRENCY, function(a, callback) {
a.update(function(err) {
if (err) callback(err);
utxos = utxos.concat(a.unspent);
callback();
}, {
onlyUnspent: 1,
ignoreCache: req.param('noCache')
});
}, function(err) { // finished callback
if (err) return common.handleErrors(err, res);
res.jsonp(utxos);
});
}
};
exports.multitxs = function(req, res, next) {
if (!checkSync(req, res)) return;
function processTxs(txs, from, to, cb) {
txs = _.uniq(_.flatten(txs), 'txid');
var nbTxs = txs.length;
if (_.isUndefined(from) && _.isUndefined(to)) {
from = 0;
to = MAX_BATCH_SIZE;
}
if (!_.isUndefined(from) && _.isUndefined(to))
to = from + MAX_BATCH_SIZE;
if (!_.isUndefined(from) && !_.isUndefined(to) && to - from > MAX_BATCH_SIZE)
to = from + MAX_BATCH_SIZE;
if (from < 0) from = 0;
if (to < 0) to = 0;
if (from > nbTxs) from = nbTxs;
if (to > nbTxs) to = nbTxs;
txs.sort(function(a, b) {
return (b.ts || b.ts) - (a.ts || a.ts);
});
txs = txs.slice(from, to);
var txIndex = {};
_.each(txs, function(tx) {
txIndex[tx.txid] = tx;
});
async.eachLimit(txs, RPC_CONCURRENCY, function(tx, callback) {
tDb.fromIdWithInfo(tx.txid, function(err, tx) {
if (err) {
console.log(err);
return common.handleErrors(err, res);
}
if (tx && tx.info) {
txIndex[tx.txid].info = tx.info;
}
callback();
});
}, function(err) {
if (err) return cb(err);
var transactions = _.pluck(txs, 'info');
transactions = {
totalItems: nbTxs,
from: +from,
to: +to,
items: transactions,
};
return cb(null, transactions);
});
};
var from = req.param('from');
var to = req.param('to');
var as = getAddrs(req, res, next);
if (as) {
var txs = [];
async.eachLimit(as, RPC_CONCURRENCY, function(a, callback) {
a.update(function(err) {
if (err) callback(err);
txs.push(a.transactions);
callback();
}, {
ignoreCache: req.param('noCache'),
includeTxInfo: true,
dontFillSpent: true,
});
}, function(err) { // finished callback
if (err) return common.handleErrors(err, res);
processTxs(txs, from, to, function(err, transactions) {
if (err) return common.handleErrors(err, res);
res.jsonp(transactions);
});
});
}
};
exports.balance = function(req, res, next) {
if (!checkSync(req, res)) return;
var a = getAddr(req, res, next);
if (a)
a.update(function(err) {
if (err) {
return common.handleErrors(err, res);
} else {
return res.jsonp(a.balanceSat);
}
}, {
ignoreCache: req.param('noCache')
});
};
exports.totalReceived = function(req, res, next) {
if (!checkSync(req, res)) return;
var a = getAddr(req, res, next);
if (a)
a.update(function(err) {
if (err) {
return common.handleErrors(err, res);
} else {
return res.jsonp(a.totalReceivedSat);
}
}, {
ignoreCache: req.param('noCache')
});
};
exports.totalSent = function(req, res, next) {
if (!checkSync(req, res)) return;
var a = getAddr(req, res, next);
if (a)
a.update(function(err) {
if (err) {
return common.handleErrors(err, res);
} else {
return res.jsonp(a.totalSentSat);
}
}, {
ignoreCache: req.param('noCache')
});
};
exports.unconfirmedBalance = function(req, res, next) {
if (!checkSync(req, res)) return;
var a = getAddr(req, res, next);
if (a)
a.update(function(err) {
if (err) {
return common.handleErrors(err, res);
} else {
return res.jsonp(a.unconfirmedBalanceSat);
}
}, {
ignoreCache: req.param('noCache')
});
};

View File

@ -1,173 +0,0 @@
'use strict';
/**
* Module dependencies.
*/
var common = require('./common');
var async = require('async');
var bdb = require('../../lib/BlockDb').default();
var tdb = require('../../lib/TransactionDb').default();
/**
* Find block by hash ...
*/
exports.block = function(req, res, next, hash) {
bdb.fromHashWithInfo(hash, function(err, block) {
if (err || !block)
return common.handleErrors(err, res, next);
else {
tdb.getPoolInfo(block.info.tx[0], function(info) {
block.info.poolInfo = info;
req.block = block.info;
return next();
});
}
});
};
/**
* Show block
*/
exports.show = function(req, res) {
if (req.block) {
res.jsonp(req.block);
}
};
/**
* Show block by Height
*/
exports.blockindex = function(req, res, next, height) {
bdb.blockIndex(height, function(err, hashStr) {
if (err) {
console.log(err);
res.status(400).send('Bad Request'); // TODO
} else {
res.jsonp(hashStr);
}
});
};
var getBlock = function(blockhash, cb) {
bdb.fromHashWithInfo(blockhash, function(err, block) {
if (err) {
console.log(err);
return cb(err);
}
// TODO
if (!block.info) {
console.log('Could not get %s from RPC. Orphan? Error?', blockhash); //TODO
// Probably orphan
block.info = {
hash: blockhash,
isOrphan: 1,
};
}
tdb.getPoolInfo(block.info.tx[0], function(info) {
block.info.poolInfo = info;
return cb(err, block.info);
});
});
};
/**
* List of blocks by date
*/
var DFLT_LIMIT=200;
// in testnet, this number is much bigger, we dont support
// exploring blocks by date.
exports.list = function(req, res) {
var isToday = false;
//helper to convert timestamps to yyyy-mm-dd format
var formatTimestamp = function(date) {
var yyyy = date.getUTCFullYear().toString();
var mm = (date.getUTCMonth() + 1).toString(); // getMonth() is zero-based
var dd = date.getUTCDate().toString();
return yyyy + '-' + (mm[1] ? mm : '0' + mm[0]) + '-' + (dd[1] ? dd : '0' + dd[0]); //padding
};
var dateStr;
var todayStr = formatTimestamp(new Date());
if (req.query.blockDate) {
// TODO: Validate format yyyy-mm-dd
dateStr = req.query.blockDate;
isToday = dateStr === todayStr;
} else {
dateStr = todayStr;
isToday = true;
}
var gte = Math.round((new Date(dateStr)).getTime() / 1000);
//pagination
var lte = parseInt(req.query.startTimestamp) || gte + 86400;
var prev = formatTimestamp(new Date((gte - 86400) * 1000));
var next = lte ? formatTimestamp(new Date(lte * 1000)) :null;
var limit = parseInt(req.query.limit || DFLT_LIMIT) + 1;
var more;
bdb.getBlocksByDate(gte, lte, limit, function(err, blockList) {
if (err) {
res.status(500).send(err);
} else {
var l = blockList.length;
if (l===limit) {
more = true;
blockList.pop;
}
var moreTs=lte;
async.mapSeries(blockList,
function(b, cb) {
getBlock(b.hash, function(err, info) {
if (err) {
console.log(err);
return cb(err);
}
if (b.ts < moreTs) moreTs = b.ts;
return cb(err, {
height: info.height,
size: info.size,
hash: b.hash,
time: b.ts || info.time,
txlength: info.tx.length,
poolInfo: info.poolInfo
});
});
}, function(err, allblocks) {
// sort blocks by height
allblocks.sort(
function compare(a,b) {
if (a.height < b.height) return 1;
if (a.height > b.height) return -1;
return 0;
});
res.jsonp({
blocks: allblocks,
length: allblocks.length,
pagination: {
next: next,
prev: prev,
currentTs: lte - 1,
current: dateStr,
isToday: isToday,
more: more,
moreTs: moreTs,
}
});
});
}
});
};

View File

@ -1,19 +0,0 @@
'use strict';
exports.notReady = function (err, res, p) {
res.status(503).send('Server not yet ready. Sync Percentage:' + p);
};
exports.handleErrors = function (err, res) {
if (err) {
if (err.code) {
res.status(400).send(err.message + '. Code:' + err.code);
}
else {
res.status(503).send(err.message);
}
}
else {
res.status(404).send('Not found');
}
};

View File

@ -1,60 +0,0 @@
'use strict';
var config = require('../../config/config');
// Set the initial vars
var timestamp = +new Date(),
delay = config.currencyRefresh * 60000,
bitstampRate = 0;
exports.index = function(req, res) {
var _xhr = function() {
if (typeof XMLHttpRequest !== 'undefined' && XMLHttpRequest !== null) {
return new XMLHttpRequest();
} else if (typeof require !== 'undefined' && require !== null) {
var XMLhttprequest = require('xmlhttprequest').XMLHttpRequest;
return new XMLhttprequest();
}
};
var _request = function(url, cb) {
var request;
request = _xhr();
request.open('GET', url, true);
request.onreadystatechange = function() {
if (request.readyState === 4) {
if (request.status === 200) {
return cb(false, request.responseText);
}
return cb(true, {
status: request.status,
message: 'Request error'
});
}
};
return request.send(null);
};
// Init
var currentTime = +new Date();
if (bitstampRate === 0 || currentTime >= (timestamp + delay)) {
timestamp = currentTime;
_request('https://www.bitstamp.net/api/ticker/', function(err, data) {
if (!err) bitstampRate = parseFloat(JSON.parse(data).last);
res.jsonp({
status: 200,
data: { bitstamp: bitstampRate }
});
});
} else {
res.jsonp({
status: 200,
data: { bitstamp: bitstampRate }
});
}
};

View File

@ -1,26 +0,0 @@
'use strict';
var config = require('../../config/config');
var _getVersion = function() {
var pjson = require('../../package.json');
return pjson.version;
};
exports.render = function(req, res) {
if (config.publicPath) {
return res.sendfile(config.publicPath + '/index.html');
}
else {
var version = _getVersion();
res.send('insight API v' + version);
}
};
exports.version = function(req, res) {
var version = _getVersion();
res.json({
version: version
});
};

View File

@ -1,27 +0,0 @@
'use strict';
var common = require('./common');
var Rpc = require('../../lib/Rpc');
exports.verify = function(req, res) {
var address = req.param('address'),
signature = req.param('signature'),
message = req.param('message');
if(typeof(address) == 'undefined'
|| typeof(signature) == 'undefined'
|| typeof(message) == 'undefined') {
return common.handleErrors({
message: 'Missing parameters (expected "address", "signature" and "message")',
code: 1
}, res);
}
Rpc.verifyMessage(address, signature, message, function(err, result) {
if (err) {
return common.handleErrors(err, res);
}
res.json({'result' : result});
});
};

View File

@ -1,80 +0,0 @@
'use strict';
// server-side socket behaviour
var ios = null; // io is already taken in express
var util = require('bitcore').util;
var logger = require('../../lib/logger').logger;
module.exports.init = function(io_ext) {
ios = io_ext;
if (ios) {
// when a new socket connects
ios.sockets.on('connection', function(socket) {
logger.verbose('New connection from ' + socket.id);
// when it subscribes, make it join the according room
socket.on('subscribe', function(topic) {
logger.debug('subscribe to ' + topic);
socket.join(topic);
socket.emit('subscribed');
});
// disconnect handler
socket.on('disconnect', function() {
logger.verbose('disconnected ' + socket.id);
});
});
}
return ios;
};
var simpleTx = function(tx) {
return {
txid: tx
};
};
var fullTx = function(tx) {
var t = {
txid: tx.txid,
size: tx.size,
};
// Outputs
var valueOut = 0;
tx.vout.forEach(function(o) {
valueOut += o.valueSat;
});
t.valueOut = (valueOut.toFixed(8) / util.COIN);
try {
t.vout = tx.vout.map(function(o) {
var r = {};
r[o.scriptPubKey.addresses] = o.valueSat;
return r;
});
} catch (e) {};
return t;
};
module.exports.broadcastTx = function(tx) {
if (ios) {
var t = (typeof tx === 'string') ? simpleTx(tx) : fullTx(tx);
ios.sockets.in('inv').emit('tx', t);
}
};
module.exports.broadcastBlock = function(block) {
if (ios)
ios.sockets.in('inv').emit('block', block);
};
module.exports.broadcastAddressTx = function(txid, address) {
if (ios) {
ios.sockets.in(address).emit(address, txid);
}
};
module.exports.broadcastSyncInfo = function(historicSync) {
if (ios)
ios.sockets.in('sync').emit('status', historicSync);
};

View File

@ -1,55 +0,0 @@
'use strict';
/**
* Module dependencies.
*/
var Status = require('../models/Status'),
common = require('./common');
/**
* Status
*/
exports.show = function(req, res) {
var option = req.query.q;
var statusObject = new Status();
var returnJsonp = function (err) {
if (err || ! statusObject)
return common.handleErrors(err, res);
else {
res.jsonp(statusObject);
}
};
switch(option) {
case 'getDifficulty':
statusObject.getDifficulty(returnJsonp);
break;
case 'getTxOutSetInfo':
statusObject.getTxOutSetInfo(returnJsonp);
break;
case 'getLastBlockHash':
statusObject.getLastBlockHash(returnJsonp);
break;
case 'getBestBlockHash':
statusObject.getBestBlockHash(returnJsonp);
break;
case 'getInfo':
default:
statusObject.getInfo(returnJsonp);
}
};
exports.sync = function(req, res) {
if (req.historicSync)
res.jsonp(req.historicSync.info());
};
exports.peer = function(req, res) {
if (req.peerSync) {
var info = req.peerSync.info();
res.jsonp(info);
}
};

View File

@ -1,197 +0,0 @@
'use strict';
/**
* Module dependencies.
*/
var Address = require('../models/Address');
var async = require('async');
var common = require('./common');
var util = require('util');
var Rpc = require('../../lib/Rpc');
var imports = require('soop').imports();
var bitcore = require('bitcore');
var RpcClient = bitcore.RpcClient;
var config = require('../../config/config');
var bitcoreRpc = imports.bitcoreRpc || new RpcClient(config.bitcoind);
var tDb = require('../../lib/TransactionDb').default();
var bdb = require('../../lib/BlockDb').default();
exports.send = function(req, res) {
Rpc.sendRawTransaction(req.body.rawtx, function(err, txid) {
if (err) {
var message;
if(err.code == -25) {
message = util.format(
'Generic error %s (code %s)',
err.message, err.code);
} else if(err.code == -26) {
message = util.format(
'Transaction rejected by network (code %s). Reason: %s',
err.code, err.message);
} else {
message = util.format('%s (code %s)', err.message, err.code);
}
return res.status(400).send(message);
}
res.json({'txid' : txid});
});
};
exports.rawTransaction = function (req, res, next, txid) {
bitcoreRpc.getRawTransaction(txid, function (err, transaction) {
if (err || !transaction)
return common.handleErrors(err, res);
else {
req.rawTransaction = { 'rawtx': transaction.result };
return next();
}
});
};
/**
* Find transaction by hash ...
*/
exports.transaction = function(req, res, next, txid) {
tDb.fromIdWithInfo(txid, function(err, tx) {
if (err || ! tx)
return common.handleErrors(err, res);
bdb.fillVinConfirmations(tx.info, function(err) {
if (err)
return common.handleErrors(err, res);
req.transaction = tx.info;
return next();
});
});
};
/**
* Show transaction
*/
exports.show = function(req, res) {
if (req.transaction) {
res.jsonp(req.transaction);
}
};
/**
* Show raw transaction
*/
exports.showRaw = function(req, res) {
if (req.rawTransaction) {
res.jsonp(req.rawTransaction);
}
};
var getTransaction = function(txid, cb) {
tDb.fromIdWithInfo(txid, function(err, tx) {
if (err) console.log(err);
if (!tx || !tx.info) {
console.log('[transactions.js.48]:: TXid %s not found in RPC. CHECK THIS.', txid);
return ({ txid: txid });
}
return cb(null, tx.info);
});
};
/**
* List of transaction
*/
exports.list = function(req, res, next) {
var bId = req.query.block;
var addrStr = req.query.address;
var page = req.query.pageNum;
var pageLength = 10;
var pagesTotal = 1;
var txLength;
var txs;
if (bId) {
bdb.fromHashWithInfo(bId, function(err, block) {
if (err) {
console.log(err);
return res.status(500).send('Internal Server Error');
}
if (! block) {
return res.status(404).send('Not found');
}
txLength = block.info.tx.length;
if (page) {
var spliceInit = page * pageLength;
txs = block.info.tx.splice(spliceInit, pageLength);
pagesTotal = Math.ceil(txLength / pageLength);
}
else {
txs = block.info.tx;
}
async.mapSeries(txs, getTransaction, function(err, results) {
if (err) {
console.log(err);
res.status(404).send('TX not found');
}
res.jsonp({
pagesTotal: pagesTotal,
txs: results
});
});
});
}
else if (addrStr) {
var a = new Address(addrStr);
a.update(function(err) {
if (err && !a.totalReceivedSat) {
console.log(err);
res.status(404).send('Invalid address');
return next();
}
txLength = a.transactions.length;
if (page) {
var spliceInit = page * pageLength;
txs = a.transactions.splice(spliceInit, pageLength);
pagesTotal = Math.ceil(txLength / pageLength);
}
else {
txs = a.transactions;
}
async.mapSeries(txs, getTransaction, function(err, results) {
if (err) {
console.log(err);
res.status(404).send('TX not found');
}
res.jsonp({
pagesTotal: pagesTotal,
txs: results
});
});
});
}
else {
res.jsonp({
txs: []
});
}
};

32
app/e2e/app.e2e-spec.ts Normal file
View File

@ -0,0 +1,32 @@
import { browser, element, by } from 'protractor';
describe('InsightApp', () => {
beforeEach(() => {
browser.get('');
});
it('should have a title', () => {
expect(browser.getTitle()).toEqual('Insight');
});
it('should have {nav}', () => {
expect(element(by.css('ion-navbar')).isPresent()).toEqual(true);
});
it('has a menu button that displays the left menu', () => {
element(by.css('.bar-button-menutoggle')).click()
.then(() => {
browser.driver.sleep(2000); // wait for the animation
expect(element(by.css('ion-menu')).isPresent()).toEqual(true);
});
});
it('the left menu has a link with title Home', () => {
element(by.css('.bar-button-menutoggle')).click()
.then(() => {
browser.driver.sleep(2000); // wait for the animation
expect(element.all(by.css('ion-label')).first().getText()).toEqual('Home');
});
});
});

View File

@ -0,0 +1,22 @@
import { browser, element, by, ElementFinder } from 'protractor';
describe('BroadcastTxPage', () => {
beforeEach(() => {
browser.get('');
});
it('should have an input field', () => {
element(by.css('.bar-button-menutoggle')).click().then(() => {
browser.driver.sleep(2000); // wait for the animation
element.all(by.className('input-wrapper')).then((items) => {
items[2].click();
browser.driver.sleep(2000); // wait for the animation
let theElem = element.all(by.css('ion-label')).first;
console.log(theElem);
expect(element.all(by.css('ion-input')).first().isPresent()).toEqual(true);
return items[1];
});
});
});
});

12
app/e2e/tsconfig.e2e.json Normal file
View File

@ -0,0 +1,12 @@
{
"extends": "../tsconfig.ng-cli.json",
"compilerOptions": {
"outDir": "../out-tsc/e2e",
"module": "commonjs",
"target": "es5",
"types": [
"jasmine",
"node"
]
}
}

14
app/ionic.config.json Normal file
View File

@ -0,0 +1,14 @@
{
"name": "insight",
"app_id": "",
"type": "ionic-angular",
"integrations": {
"cordova": {}
},
"proxies": [
{
"path": "/api",
"proxyUrl": "https://bch-insight.bitpay.com/api"
}
]
}

44
app/karma.conf.js Normal file
View File

@ -0,0 +1,44 @@
// Karma configuration file, see link for more information
// https://karma-runner.github.io/0.13/config/configuration-file.html
module.exports = function (config) {
config.set({
basePath: '',
frameworks: ['jasmine', '@angular/cli'],
plugins: [
require('karma-jasmine'),
require('karma-chrome-launcher'),
require('karma-jasmine-html-reporter'),
require('karma-coverage-istanbul-reporter'),
require('@angular/cli/plugins/karma')
],
client:{
clearContext: false // leave Jasmine Spec Runner output visible in browser
},
files: [
{ pattern: './src/test.ts', watched: false }
],
preprocessors: {
'./src/test.ts': ['@angular/cli']
},
mime: {
'text/x-typescript': ['ts','tsx']
},
coverageIstanbulReporter: {
reports: [ 'html', 'lcovonly' ],
fixWebpackSourcePaths: true
},
angularCli: {
environment: 'dev'
},
reporters: config.angularCli && config.angularCli.codeCoverage
? ['progress', 'coverage-istanbul']
: ['progress', 'kjhtml'],
port: 9876,
colors: true,
logLevel: config.LOG_INFO,
autoWatch: true,
browsers: ['Chrome'],
singleRun: false
});
};

View File

@ -1,213 +0,0 @@
'use strict';
var imports = require('soop').imports();
var async = require('async');
var bitcore = require('bitcore');
var BitcoreAddress = bitcore.Address;
var BitcoreTransaction = bitcore.Transaction;
var BitcoreUtil = bitcore.util;
var Parser = bitcore.BinaryParser;
var Buffer = bitcore.Buffer;
var TransactionDb = imports.TransactionDb || require('../../lib/TransactionDb').default();
var BlockDb = imports.BlockDb || require('../../lib/BlockDb').default();
var config = require('../../config/config');
var CONCURRENCY = 5;
function Address(addrStr) {
this.balanceSat = 0;
this.totalReceivedSat = 0;
this.totalSentSat = 0;
this.unconfirmedBalanceSat = 0;
this.txApperances = 0;
this.unconfirmedTxApperances = 0;
this.seen = {};
// TODO store only txids? +index? +all?
this.transactions = [];
this.unspent = [];
var a = new BitcoreAddress(addrStr);
a.validate();
this.addrStr = addrStr;
Object.defineProperty(this, 'totalSent', {
get: function() {
return parseFloat(this.totalSentSat) / parseFloat(BitcoreUtil.COIN);
},
set: function(i) {
this.totalSentSat = i * BitcoreUtil.COIN;
},
enumerable: 1,
});
Object.defineProperty(this, 'balance', {
get: function() {
return parseFloat(this.balanceSat) / parseFloat(BitcoreUtil.COIN);
},
set: function(i) {
this.balance = i * BitcoreUtil.COIN;
},
enumerable: 1,
});
Object.defineProperty(this, 'totalReceived', {
get: function() {
return parseFloat(this.totalReceivedSat) / parseFloat(BitcoreUtil.COIN);
},
set: function(i) {
this.totalReceived = i * BitcoreUtil.COIN;
},
enumerable: 1,
});
Object.defineProperty(this, 'unconfirmedBalance', {
get: function() {
return parseFloat(this.unconfirmedBalanceSat) / parseFloat(BitcoreUtil.COIN);
},
set: function(i) {
this.unconfirmedBalanceSat = i * BitcoreUtil.COIN;
},
enumerable: 1,
});
}
Address.prototype.getObj = function() {
// Normalize json address
return {
'addrStr': this.addrStr,
'balance': this.balance,
'balanceSat': this.balanceSat,
'totalReceived': this.totalReceived,
'totalReceivedSat': this.totalReceivedSat,
'totalSent': this.totalSent,
'totalSentSat': this.totalSentSat,
'unconfirmedBalance': this.unconfirmedBalance,
'unconfirmedBalanceSat': this.unconfirmedBalanceSat,
'unconfirmedTxApperances': this.unconfirmedTxApperances,
'txApperances': this.txApperances,
'transactions': this.transactions
};
};
Address.prototype._addTxItem = function(txItem, txList, includeInfo) {
function addTx(data) {
if (!txList) return;
if (includeInfo) {
txList.push(data);
} else {
txList.push(data.txid);
}
};
var add = 0,
addSpend = 0;
var v = txItem.value_sat;
var seen = this.seen;
// Founding tx
if (!seen[txItem.txid]) {
seen[txItem.txid] = 1;
add = 1;
addTx({
txid: txItem.txid,
ts: txItem.ts
});
}
// Spent tx
if (txItem.spentTxId && !seen[txItem.spentTxId]) {
addTx({
txid: txItem.spentTxId,
ts: txItem.spentTs
});
seen[txItem.spentTxId] = 1;
addSpend = 1;
}
if (txItem.isConfirmed) {
this.txApperances += add;
this.totalReceivedSat += v;
if (!txItem.spentTxId) {
//unspent
this.balanceSat += v;
} else if (!txItem.spentIsConfirmed) {
// unspent
this.balanceSat += v;
this.unconfirmedBalanceSat -= v;
this.unconfirmedTxApperances += addSpend;
} else {
// spent
this.totalSentSat += v;
this.txApperances += addSpend;
}
} else {
this.unconfirmedBalanceSat += v;
this.unconfirmedTxApperances += add;
}
};
// opts are
// .onlyUnspent
// .txLimit (=0 -> no txs, => -1 no limit)
// .includeTxInfo
//
Address.prototype.update = function(next, opts) {
var self = this;
if (!self.addrStr) return next();
opts = opts || {};
if (!('ignoreCache' in opts))
opts.ignoreCache = config.ignoreCache;
// should collect txList from address?
var txList = opts.txLimit === 0 ? null : [];
var tDb = TransactionDb;
var bDb = BlockDb;
tDb.fromAddr(self.addrStr, opts, function(err, txOut) {
if (err) return next(err);
bDb.fillConfirmations(txOut, function(err) {
if (err) return next(err);
tDb.cacheConfirmations(txOut, function(err) {
// console.log('[Address.js.161:txOut:]',txOut); //TODO
if (err) return next(err);
if (opts.onlyUnspent) {
txOut = txOut.filter(function(x) {
return !x.spentTxId;
});
tDb.fillScriptPubKey(txOut, function() {
self.unspent = txOut.map(function(x) {
return {
address: self.addrStr,
txid: x.txid,
vout: x.index,
ts: x.ts,
scriptPubKey: x.scriptPubKey,
amount: x.value_sat / BitcoreUtil.COIN,
confirmations: x.isConfirmedCached ? (config.safeConfirmations) : x.confirmations,
confirmationsFromCache: !!x.isConfirmedCached,
};
});
return next();
});
} else {
txOut.forEach(function(txItem) {
self._addTxItem(txItem, txList, opts.includeTxInfo);
});
if (txList)
self.transactions = txList;
return next();
}
});
});
});
};
module.exports = require('soop')(Address);

View File

@ -1,105 +0,0 @@
'use strict';
//var imports = require('soop').imports();
var async = require('async');
var bitcore = require('bitcore');
var RpcClient = bitcore.RpcClient;
var config = require('../../config/config');
var rpc = new RpcClient(config.bitcoind);
var bDb = require('../../lib/BlockDb').default();
function Status() {}
Status.prototype.getInfo = function(next) {
var that = this;
async.series([
function (cb) {
rpc.getInfo(function(err, info){
if (err) return cb(err);
that.info = info.result;
return cb();
});
},
], function (err) {
return next(err);
});
};
Status.prototype.getDifficulty = function(next) {
var that = this;
async.series([
function (cb) {
rpc.getDifficulty(function(err, df){
if (err) return cb(err);
that.difficulty = df.result;
return cb();
});
}
], function (err) {
return next(err);
});
};
Status.prototype.getTxOutSetInfo = function(next) {
var that = this;
async.series([
function (cb) {
rpc.getTxOutSetInfo(function(err, txout){
if (err) return cb(err);
that.txoutsetinfo = txout.result;
return cb();
});
}
], function (err) {
return next(err);
});
};
Status.prototype.getBestBlockHash = function(next) {
var that = this;
async.series([
function (cb) {
rpc.getBestBlockHash(function(err, bbh){
if (err) return cb(err);
that.bestblockhash = bbh.result;
return cb();
});
},
], function (err) {
return next(err);
});
};
Status.prototype.getLastBlockHash = function(next) {
var that = this;
bDb.getTip(function(err,tip) {
that.syncTipHash = tip;
async.waterfall(
[
function(callback){
rpc.getBlockCount(function(err, bc){
if (err) return callback(err);
callback(null, bc.result);
});
},
function(bc, callback){
rpc.getBlockHash(bc, function(err, bh){
if (err) return callback(err);
callback(null, bh.result);
});
}
],
function (err, result) {
that.lastblockhash = result;
return next();
}
);
});
};
module.exports = require('soop')(Status);

14361
app/package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

70
app/package.json Normal file
View File

@ -0,0 +1,70 @@
{
"name": "insight-app",
"private": true,
"insightConfig": {
"apiPrefix": "api",
"routePrefix": ""
},
"scripts": {
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"ionic:build": "ionic-app-scripts build",
"ionic:serve": "ionic-app-scripts serve",
"e2e": "ionic-app-scripts build && protractor",
"postinstall": "webdriver-manager update --gecko false",
"start": "ionic serve",
"test": "ng test --code-coverage",
"test:unit-e2e": "ng test --watch=false --code-coverage --browsers ChromeHeadless && npm run e2e --browsers ChromeHeadless",
"test:ci": "ng test --watch=false --code-coverage --browsers ChromeHeadless",
"cov": "opn coverage/index.html"
},
"dependencies": {
"@angular/common": "4.1.3",
"@angular/compiler": "4.1.3",
"@angular/compiler-cli": "4.1.3",
"@angular/core": "4.1.3",
"@angular/forms": "4.1.3",
"@angular/http": "4.1.3",
"@angular/platform-browser": "4.1.3",
"@angular/platform-browser-dynamic": "4.1.3",
"@angular/router": "4.1.3",
"@ionic-native/core": "3.10.2",
"@ionic-native/splash-screen": "3.10.2",
"@ionic-native/status-bar": "3.10.2",
"@ionic/storage": "2.0.1",
"angular2-moment": "^1.6.0",
"angular2-qrcode": "^2.0.1",
"ionic-angular": "3.4.2",
"ionicons": "3.0.0",
"rxjs": "5.4.0",
"sw-toolbox": "3.6.0",
"zone.js": "0.8.12"
},
"devDependencies": {
"@angular/cli": "^1.1.2",
"@ionic/app-scripts": "1.3.7",
"@types/jasmine": "2.5.41",
"@types/node": "7.0.4",
"codecov": "2.2.0",
"ionic": "3.20.0",
"jasmine-core": "2.5.2",
"jasmine-spec-reporter": "3.2.0",
"karma": "1.4.1",
"karma-chrome-launcher": "2.1.1",
"karma-cli": "1.0.1",
"karma-coverage-istanbul-reporter": "1.2.1",
"karma-jasmine": "1.1.0",
"karma-jasmine-html-reporter": "0.2.2",
"opn-cli": "^3.1.0",
"protractor": "5.1.2",
"serve-static": "1.12.3",
"ts-node": "3.0.4",
"tslint": "5.3.2",
"tslint-eslint-rules": "4.1.1",
"typescript": "2.3.3"
},
"engines": {
"node": ">=8"
},
"license": "MIT"
}

33
app/protractor.conf.js Normal file
View File

@ -0,0 +1,33 @@
// Protractor configuration file, see link for more information
// https://github.com/angular/protractor/blob/master/lib/config.ts
const { SpecReporter } = require('jasmine-spec-reporter');
exports.config = {
allScriptsTimeout: 11000,
specs: [
'./e2e/**/*.e2e-spec.ts'
],
capabilities: {
'browserName': 'chrome'
},
directConnect: true,
baseUrl: 'http://localhost:4200/',
framework: 'jasmine',
jasmineNodeOpts: {
showColors: true,
defaultTimeoutInterval: 30000,
print: function() {}
},
useAllAngular2AppRoots: true,
beforeLaunch: function() {
require('ts-node').register({
project: 'e2e/tsconfig.e2e.json'
});
require('connect')().use(require('serve-static')('www')).listen(4200);
},
onPrepare() {
jasmine.getEnv().addReporter(new SpecReporter({ spec: { displayStacktrace: true } }));
}
};

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
app/resources/icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 59 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 818 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 100 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 97 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 KiB

BIN
app/resources/splash.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

View File

@ -0,0 +1,62 @@
import { Component, ViewChild } from '@angular/core';
import { Platform, MenuController, Nav } from 'ionic-angular';
import { StatusBar } from '@ionic-native/status-bar';
import { SplashScreen } from '@ionic-native/splash-screen';
import {
HomePage
} from '../pages';
@Component({
templateUrl: './app.html'
})
export class InsightApp {
@ViewChild(Nav) public nav: Nav;
private menu: MenuController;
private platform: Platform;
private splash: SplashScreen;
private status: StatusBar;
public rootPage: any;
public pages: Array<{ title: string; component: any }>;
constructor(
platform: Platform,
menu: MenuController,
splash: SplashScreen,
status: StatusBar
) {
this.menu = menu;
this.platform = platform;
this.splash = splash;
this.status = status;
this.rootPage = HomePage;
this.initializeApp();
// set our app's pages
this.pages = [
{ title: 'Home', component: HomePage },
{ title: 'Blocks', component: 'blocks' },
{ title: 'Broadcast Transaction', component: 'BroadcastTxPage' }
// { title: 'Verify Signed Message', component: VerifyMessagePage },
// { title: 'Node Status', component: NodeStatusPage }
];
}
private initializeApp(): void {
this.platform.ready().then(() => {
// Okay, so the platform is ready and our plugins are available.
// Here you can do any higher level native things you might need.
this.status.styleDefault();
this.splash.hide();
});
}
public openPage(page: any): void {
// close the menu when clicking a link from the menu
this.menu.close();
// navigate to the new page if it is not the current page
this.nav.setRoot(page.component);
}
}

13
app/src/app/app.html Normal file
View File

@ -0,0 +1,13 @@
<ion-menu [content]="content">
<ion-content>
<ion-list>
<button ion-item *ngFor="let p of pages" (click)="openPage(p)">
{{p.title}}
</button>
</ion-list>
</ion-content>
</ion-menu>
<ion-nav [root]="rootPage" #content swipeBackEnabled="false"></ion-nav>

44
app/src/app/app.module.ts Normal file
View File

@ -0,0 +1,44 @@
import { HttpModule } from '@angular/http';
import { NgModule, ErrorHandler } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { IonicApp, IonicModule, IonicErrorHandler } from 'ionic-angular';
import { StatusBar } from '@ionic-native/status-bar';
import { SplashScreen } from '@ionic-native/splash-screen';
import { InsightApp } from './app.component';
import { PagesModule, HomePage, BlocksPage, NodeStatusPage, VerifyMessagePage } from '../pages';
import { BlocksService, StorageService } from '../services';
import { ApiProvider } from '../providers/api/api';
import { CurrencyProvider } from '../providers/currency/currency';
import { BlocksProvider } from '../providers/blocks/blocks';
@NgModule({
declarations: [
InsightApp
],
imports: [
BrowserModule,
HttpModule,
PagesModule,
IonicModule.forRoot(InsightApp)
],
bootstrap: [IonicApp],
entryComponents: [
InsightApp,
HomePage,
BlocksPage,
NodeStatusPage,
VerifyMessagePage
],
providers: [
StatusBar,
SplashScreen,
StorageService,
BlocksService,
{provide: ErrorHandler, useClass: IonicErrorHandler},
ApiProvider,
CurrencyProvider,
BlocksProvider
]
})
export class AppModule {}

84
app/src/app/app.scss Normal file
View File

@ -0,0 +1,84 @@
// http://ionicframework.com/docs/v2/theming/
// App Global Sass
// --------------------------------------------------
// Put style rules here that you want to apply globally. These
// styles are for the entire app and not just one component.
// Additionally, this file can be also used as an entry point
// to import other Sass files to be included in the output CSS.
body {
user-select: text;
}
a {
cursor: pointer;
}
.ellipsis {
display: block;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.item-hash {
@extend .ellipsis;
opacity: 0.7;
}
.list--summary {
ion-label {
color: #334;
font-weight: bold;
}
ion-item {
color: #99a;
font-size: 1.125rem;
@media screen and (min-width: $desktop-min-width) {
font-size: 1.4rem;
}
padding: 0;
}
ion-note {
color: #99a;
max-width: 80%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
}
.grid--table {
margin: 10px 0 20px;
.col {
padding: 1em 0.6em;
}
ion-row {
border-top: 1px solid #dde;
&:first-child {
background-color: #fff;
border-top: none;
}
&:nth-child(even) {
background-color: #f8f8f9;
}
&:last-child {
background-color: #fff;
}
}
}
// Shared Sass variables, which can be used to adjust Ionic's
// default Sass variables, belong in "theme/variables.scss".
//
// To declare rules for a specific mode, create a child rule
// for the .md, .ios, or .wp mode classes. The mode class is
// automatically applied to the <body> element in the app.

44
app/src/app/app.spec.ts Normal file
View File

@ -0,0 +1,44 @@
import { InsightApp } from './app.component';
import { TestBed, getTestBed } from '@angular/core/testing';
import { Platform } from 'ionic-angular';
import { NavMock } from '../mocks';
import { PopoverController, MenuController } from 'ionic-angular';
import { StatusBar } from '@ionic-native/status-bar';
import { SplashScreen } from '@ionic-native/splash-screen';
describe('InsightApp', () => {
let injector: TestBed;
let app: InsightApp;
beforeEach(() => {
TestBed.configureTestingModule({
providers: [
PopoverController,
InsightApp,
Platform,
MenuController,
SplashScreen,
StatusBar
]
});
injector = getTestBed();
app = injector.get(InsightApp);
app['nav'] = (<any>new NavMock());
});
it('initializes with three possible pages', () => {
expect(app['pages'].length).toEqual(3);
});
it('initializes with a root page', () => {
expect(app['rootPage']).not.toBe(null);
});
it('opens a page', () => {
spyOn(app['menu'], 'close');
spyOn(app['nav'], 'setRoot');
app.openPage(app['pages'][1]);
expect(app['menu']['close']).toHaveBeenCalled();
});
});

5
app/src/app/main.ts Normal file
View File

@ -0,0 +1,5 @@
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { AppModule } from './app.module';
platformBrowserDynamic().bootstrapModule(AppModule);

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 15 KiB

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg width="49px" height="30px" viewBox="0 0 49 30" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- Generator: Sketch 46.2 (44496) - http://www.bohemiancoding.com/sketch -->
<title>cash</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Symbols" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<g id="Invoice---Details---toggle-13" transform="translate(-15.000000, -66.000000)" fill-rule="nonzero" fill="#70C559">
<g id="cash" transform="translate(15.000000, 66.000000)">
<path d="M13.8417063,-9.23705556e-14 C10.3638666,2.45824779 7.71855988,6.11178429 6.60498615,10.5439372 C4.70445891,18.0998581 7.80802299,25.7315444 13.8323317,30 L0,30 L0,6.67235157e-12 L13.8417063,6.67174941e-12 L13.8417063,-9.23705556e-14 Z M35.4255188,2.16006456e-11 L49,2.16000551e-11 L49,30 L35.4177702,30 C38.8953546,27.5421934 41.5405004,23.8894637 42.6545185,19.458134 C44.5543534,11.900549 41.4505764,4.26854241 35.4255188,2.1236346e-11 L35.4255188,2.16006456e-11 Z M39.3004107,18.6286839 C37.2802686,26.6643836 29.0735016,31.5548028 20.9697739,29.5509168 C12.8693548,27.5474997 7.93811007,19.4082073 9.95919725,11.3729763 C11.9783938,3.33633912 20.185161,-1.55454875 28.2865254,0.448868418 C36.3897804,2.45228559 41.3205524,10.5925155 39.3004107,18.6286839 Z M25.404827,8.31840135 L24.822017,5.61021006 L23.1646362,5.95837059 L23.7321322,8.59517337 C23.2964321,8.68671195 22.8528909,8.78878287 22.412286,8.89047021 L21.8413778,6.23613729 L20.1848384,6.58389075 L20.7668159,9.29144802 C20.4095444,9.37407702 20.0585751,9.45469416 19.7150084,9.52706466 L17.4268281,9.99789864 L17.8061139,11.7584155 C17.8061139,11.7584155 19.0250623,11.4782322 19.0095416,11.5049211 C19.6809284,11.3641687 19.9828396,11.7059324 20.1183742,12.0270932 L21.7146405,19.4461225 C21.7303963,19.6624491 21.6782983,20.0235742 21.2094313,20.1228629 C21.2346595,20.1370971 20.0045444,20.375508 20.0045444,20.375508 L20.0988542,22.4133317 L22.2557355,21.9603946 C22.6572213,21.8765944 23.053614,21.8004421 23.44186,21.7214914 L24.0319506,24.4603751 L25.6876485,24.1130287 L25.1044355,21.4029588 C25.5610391,21.31686 26.0017437,21.2280845 26.4311504,21.1375167 L27.0109069,23.835262 L28.6682877,23.4871014 L28.0804623,20.7528244 C30.8327059,20.0087698 32.6327287,18.9010983 32.3148875,16.247723 C32.0594765,14.1110581 30.8671217,13.3840872 29.2040862,13.3384078 C30.0603063,12.6499773 30.4765778,11.6663412 30.0286414,10.2671807 C29.4197843,8.35437249 27.5843909,8.05563042 25.404827,8.31840135 Z M28.8925748,16.4400896 C29.3339492,18.4867945 25.7599728,18.9938427 24.6369247,19.2307446 L23.8564384,15.6015987 C24.9801043,15.3659532 28.4333066,14.3051001 28.8925748,16.4400896 Z M23.3654016,14.0925774 L22.6572494,10.8011688 C23.5928708,10.6046501 26.4682721,9.69163557 26.886443,11.6339622 C27.2866494,13.4963329 24.3010229,13.8960587 23.3654016,14.0925774 Z" id="Cash"></path>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.0 KiB

View File

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg width="30px" height="30px" viewBox="0 0 30 30" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- Generator: Sketch 46.2 (44496) - http://www.bohemiancoding.com/sketch -->
<title>bitcoin</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Symbols" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<g id="Invoice---Details---toggle-12" transform="translate(-14.000000, -65.000000)" fill-rule="nonzero">
<g id="bitcoin" transform="translate(14.000000, 65.000000)">
<path d="M29.488125,18.7144615 C27.4907812,26.6007692 19.3776562,31.4141538 11.3475,29.448 C3.3384375,27.4813846 -1.550625,19.4930769 0.44671875,11.6067692 C2.44359375,3.72092308 10.5571875,-1.09246154 18.56625,0.873692308 C26.5964062,2.81953846 31.485,10.8286154 29.488125,18.7144615" id="Shape" fill="#F8AE2A"></path>
<path d="M18.8160938,13.2456923 C18.3792187,15.0687692 15.508125,14.1876923 14.5720313,13.9624615 L15.3628125,10.7261538 C16.2778125,10.9513846 19.2735937,11.3409231 18.8160937,13.2456923 L18.8160938,13.2456923 Z M18.358125,18.4689231 C17.88,20.4761538 14.42625,19.4316923 13.32375,19.1653846 L14.176875,15.6013846 C15.3,15.8676923 18.8573438,16.3592308 18.358125,18.4689231 Z M22.06125,13.2456923 C22.3317187,11.2790769 20.8129687,10.2549231 18.7326562,9.55846154 L19.3776562,6.89584615 L17.7342188,6.50676923 L17.1103125,9.108 C16.6734375,9.00553846 16.2365625,8.90307692 15.7996875,8.82138462 L16.4235937,6.21969231 L14.7595313,5.83061538 L14.1145313,8.49369231 C13.760625,8.41153846 13.4071875,8.35015385 13.0532813,8.268 L10.7859375,7.73584615 L10.3696875,9.45646154 C10.3696875,9.45646154 11.5973438,9.72230769 11.555625,9.74307692 C12.22125,9.90692308 12.3459375,10.3370769 12.3253125,10.6647692 L11.5973438,13.6961538 C11.6385938,13.7169231 11.7014063,13.7169231 11.76375,13.7575385 C11.7014063,13.7372308 11.6596875,13.7372308 11.5973438,13.7169231 L10.5984375,17.9566154 C10.5154688,18.1615385 10.3073438,18.4481538 9.84984375,18.3461538 C9.87046875,18.3664615 8.64328125,18.0590769 8.64328125,18.0590769 L7.8525,19.9232308 L9.99515625,20.4147692 C10.3907812,20.5172308 10.7859375,20.5989231 11.1604687,20.7013846 L10.5154688,23.3847692 L12.1589062,23.7738462 L12.8039062,21.1112308 C13.2614063,21.234 13.6982813,21.3364615 14.1145312,21.4389231 L13.4695312,24.0812308 L15.1129687,24.4703077 L15.7579687,21.7873846 C18.56625,22.2789231 20.6671875,22.0532308 21.5203125,19.5341538 C22.2070312,17.5264615 21.4579687,16.3795385 19.9603125,15.6216923 C21.0628125,15.3756923 21.853125,14.6796923 22.06125,13.2456923 L22.06125,13.2456923 Z" id="Shape" fill="#FFFFFF"></path>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.7 KiB

View File

@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg width="30px" height="30px" viewBox="0 0 30 30" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- Generator: Sketch 46.2 (44496) - http://www.bohemiancoding.com/sketch -->
<title>litecoin</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Exploration" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<g id="select-currency" transform="translate(-135.000000, -516.000000)" fill-rule="nonzero" fill="#BEBEBE">
<g id="LTC" transform="translate(135.000000, 514.000000)">
<g id="litecoin" transform="translate(0.000000, 2.000000)">
<path d="M14.9978166,0.0793957695 C6.7571516,0.0793957695 0.076944392,6.75969362 0.076944392,15.0002674 C0.076944392,23.240932 6.7571516,29.9213166 14.9978166,29.9213166 C23.2383906,29.9213166 29.9186882,23.240932 29.9186882,15.0002674 C29.9186882,6.75969362 23.2383,0.0793957695 14.9978166,0.0793957695 Z M12.6942498,6.99841486 L17.3093483,6.99841486 L15.6819997,13.1259761 L17.9406036,12.3008837 L17.9600755,12.35399 L17.3893613,14.4987689 L15.0948236,15.3369607 L14.1258136,18.986236 L21.793452,18.986236 L21.0060653,21.9194637 L8.72315148,21.9194637 L9.97751782,17.2066495 L8.20200344,17.8552523 L8.78918003,15.6440909 L10.5659338,14.9949571 L12.6942498,6.99841486 Z" id="Fill-1"></path>
</g>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

View File

@ -0,0 +1,19 @@
import { NgModule } from '@angular/core';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { IonicModule } from 'ionic-angular';
@NgModule({
declarations: [
],
imports: [
FormsModule,
IonicModule,
ReactiveFormsModule
],
exports: [
],
entryComponents: [],
providers: []
})
export class ComponentsModule {}

View File

@ -0,0 +1,21 @@
<ion-list radio-group [(ngModel)]="currencyProvider.currencySymbol" (ionChange)="currencyProvider.setCurrency(currencyProvider.currencySymbol)">
<ion-list-header *ngIf="switcherOn">
Blockchain
</ion-list-header>
<ion-row *ngIf="switcherOn">
<ion-col *ngFor="let explorer of currencyProvider.explorers">
<button (click)="changeExplorer(explorer)" ion-item detail-none class="text-button" text-center>
<img src="assets/img/currency_logos/{{ explorer.ticker.toLowerCase() }}.svg" class="logo"/></button>
</ion-col>
</ion-row>
<ion-list-header>
Units
</ion-list-header>
<ion-item *ngFor="let unit of units">
<ion-label color="dark">{{ unit }}</ion-label>
<ion-radio value="{{ unit }}" (click)="close()"></ion-radio>
</ion-item>
</ion-list>

View File

@ -0,0 +1,19 @@
import { NgModule } from '@angular/core';
import { IonicModule } from 'ionic-angular';
import { DenominationComponent } from './denomination';
@NgModule({
declarations: [
DenominationComponent
],
imports: [
IonicModule
],
exports: [
DenominationComponent
],
entryComponents: [
DenominationComponent
]
})
export class DenominationComponentModule {}

View File

@ -0,0 +1,3 @@
denomination {
}

View File

@ -0,0 +1,41 @@
import { Component } from '@angular/core';
import { CurrencyProvider } from '../../providers/currency/currency';
import { ViewController } from 'ionic-angular';
import { Http } from '@angular/http';
import { ApiProvider } from '../../providers/api/api';
@Component({
selector: 'denomination',
templateUrl: 'denomination.html'
})
export class DenominationComponent {
public switcherOn: boolean;
public units: any = [];
constructor(
public currencyProvider: CurrencyProvider,
public viewCtrl: ViewController,
public http: Http,
public api: ApiProvider
) {
this.units = [
'USD',
this.currencyProvider.defaultCurrency,
'm' + this.currencyProvider.defaultCurrency,
'bits'
];
this.switcherOn = currencyProvider.explorers.length > 1;
}
public close(): void {
this.viewCtrl.dismiss();
}
public changeExplorer(explorer: any): void {
this.close();
let theUrl: string = explorer.url;
window.location.href = theUrl;
}
}

View File

@ -0,0 +1,19 @@
<ion-navbar color="brand">
<button ion-button menuToggle>
<ion-icon name="menu"></ion-icon>
</button>
<ion-title>{{title}}</ion-title>
<ion-buttons end>
<button ion-button (click)="changeCurrency($event)">
<ion-icon name="logo-bitcoin" *ngIf="currency.currencySymbol !== 'USD'"></ion-icon>
<ion-icon name="logo-usd" *ngIf="currency.currencySymbol === 'USD'"></ion-icon>&nbsp;{{ currency.currencySymbol }}
</button>
<button ion-button icon-only (click)="toggleSearch()">
<ion-icon name="search"></ion-icon>
</button>
</ion-buttons>
</ion-navbar>
<form (ngSubmit)="search($event)">
<ion-searchbar [hidden]="!showSearch" placeholder="{{ 'Search for block, transaction or address' }}" [(ngModel)]="q" name="search"></ion-searchbar>
</form>

View File

@ -0,0 +1,18 @@
import { NgModule } from '@angular/core';
import { IonicModule } from 'ionic-angular';
import { HeadNavComponent } from './head-nav';
import { DenominationComponentModule } from '../denomination/denomination.module';
@NgModule({
declarations: [
HeadNavComponent
],
imports: [
IonicModule,
DenominationComponentModule
],
exports: [
HeadNavComponent
]
})
export class HeadNavComponentModule {}

View File

@ -0,0 +1,3 @@
head-nav {
}

View File

@ -0,0 +1,125 @@
import { Component } from '@angular/core';
import { Input } from '@angular/core';
import { NavController } from 'ionic-angular';
import { Http } from '@angular/http';
import { ApiProvider } from '../../providers/api/api';
import { CurrencyProvider } from '../../providers/currency/currency';
import { ActionSheetController } from 'ionic-angular';
import { PopoverController } from 'ionic-angular';
import { ToastController } from 'ionic-angular';
import { DenominationComponent } from '../denomination/denomination';
/**
* Generated class for the HeadNavComponent component.
*
* See https://angular.io/docs/ts/latest/api/core/index/ComponentMetadata-class.html
* for more info on Angular Components.
*/
@Component({
selector: 'head-nav',
templateUrl: 'head-nav.html'
})
export class HeadNavComponent {
public showSearch: boolean = false;
public loading: boolean;
@Input() public title: string;
public q: string;
constructor(
private navCtrl: NavController,
private http: Http,
private api: ApiProvider,
public currency: CurrencyProvider,
public actionSheetCtrl: ActionSheetController,
public popoverCtrl: PopoverController,
public toastCtrl: ToastController
) {
}
public search(): void {
this.showSearch = false;
let apiPrefix: string = this.api.apiPrefix;
this.http.get(apiPrefix + 'block/' + this.q).subscribe(
function (data: any): void {
this.resetSearch();
console.log('block', data);
let parsedData: any = JSON.parse(data._body);
this.navCtrl.push('block-detail', {
'blockHash': parsedData.hash
});
}.bind(this),
() => {
this.http.get(apiPrefix + 'tx/' + this.q).subscribe(
function (data: any): void {
this.resetSearch();
console.log('tx', data);
let parsedData: any = JSON.parse(data._body);
this.navCtrl.push('transaction', {
'txId': parsedData.txid
});
}.bind(this),
() => {
this.http.get(apiPrefix + 'addr/' + this.q).subscribe(
function (data: any): void {
this.resetSearch();
console.log('addr', data);
let parsedData: any = JSON.parse(data._body);
this.navCtrl.push('address', {
'addrStr': parsedData.addrStr
});
}.bind(this),
() => {
this.http.get(apiPrefix + 'block-index/' + this.q).subscribe(
function (data: any): void {
this.resetSearch();
let parsedData: any = JSON.parse(data._body);
this.navCtrl.push('block-detail', {
'blockHash': parsedData.blockHash
});
}.bind(this),
function (): void {
this.loading = false;
this.reportBadQuery();
}.bind(this)
);
}
);
}
);
}
);
}
/* tslint:disable:no-unused-variable */
private reportBadQuery(): void {
this.presentToast();
}
private presentToast(): void {
const toast: any = this.toastCtrl.create({
message: 'No matching records found!',
duration: 3000,
position: 'top'
});
toast.present();
}
private resetSearch(): void {
this.q = '';
this.loading = false;
}
/* tslint:enable:no-unused-variable */
public changeCurrency(myEvent: any): void {
let popover: any = this.popoverCtrl.create(DenominationComponent);
popover.present({
ev: myEvent
});
}
public toggleSearch(): void {
this.showSearch = !this.showSearch;
}
}

Some files were not shown because too many files have changed in this diff Show More