Closed mflaxman closed 9 years ago
Unfortunately yes, it'd be a bit of a pain. But I've added a 'depth' property on the block that does what your is_latest_block idea would do, but gives you a number. The latest has a depth of 0.
Awesome!
This was implemented :)
Awesome!
@matthieu would it be hard to add next_block (the hash) to this API call?
https://api.blockcypher.com/v1/btc/main/blocks/300000
If not I can do something hackey (height+1), but this will fail on the latest block. To solve that, I can either: 1) Make a separate API call to determine if this is the latest block (slow). Another solution here would be if you returned
is_latest_block
with the API call above. 2) Just always show it and then if you click it and it's more recent than we have, you get an error message "this is the latest block hash. Sorry we can't see into the future.". Kind of a bad UX.