A partial archive of discourse.wicg.io as of Saturday February 24, 2024.

Bitcoin Wallet API

yrashk
2014-07-25

Hi,

I am working on a project called Bitcoin Wallet API that is aimed to provide a uniform, privacy-oriented, restricted access to user’s Bitcoin wallets to enable web applications seamless integration with the Bitcoin infrastructure. Think geolocation or camera API for HTML5, but for Bitcoin.

The project is still in its early days and I’ve published a rough spec draft, made a timestamping demo (you can find a screencast on the homepage) and released the first proof-of-concept browser extension (Chrome-only) for an API polyfill.

The reason why I started this project was a realization that often, in order to provide non-standard transaction features, web app developers have to go as far as developing a new wallet app so just that their users can sign those transactions. What if there was a way to securely connect web apps and wallets (without exposing private keys)? Would that help new, sophisticated bitcoin web apps go to market faster and have much easier onboarding strategy?

I’m looking forward to your feedback and I’ll be happy to answer questions, if any.

Thanks!

Niaccurshi
2014-07-25

Just a quick question/comment: Is there any way of this being more standardised/abstracted to deal with eCurrency wallets in general? I understand Bitcoin is the stand out currency right now, but we obviously don’t know what others may come along and be adopted.

yrashk
2014-07-26

Great question. I’ve thought about this. The reason why the proposal doesn’t standardize over “e-currency wallets in general” is because all of them are not just currencies, but also technologies. Some are closer to Bitcoin (forks), some aren’t. And we can’t really standardize over different technologies as the underlying objects a web app would manipulate are way too different.

That said, I can see one minor improvement. For all the altcoins that are not materially different from Bitcoin, the getWallet() method can be extended to have an optional argument, like getWallet(‘dogecoin’), for example. This way the application will request a specific type of bitcoin-style wallet.

Does this make sense?

ahopebailie
2014-07-28

Have you looked at the work done by the W3C Web Payments Community Group? https://web-payments.org/ Some similarities and ideas there.

yrashk
2014-07-28

Hi Adrian,

Yes, I’ve seen some of their work. They are working with a different layer, though. What they are dealing is payments. Bitcoin Wallet API allows web developers to deal with a much lower level of Bitcoin’s transacting capability. Due to the nature of Bitcoin technnology, it is not only possible to send payments, but also construct a limited set of interpretable contracts (scripts). This allows Bitcoin transactions to be more than just payments, therefore you can’t really put them into the “payments” baskets as a whole.

Bitcoin Wallet API enables web applications to work with transactions on a binary data level, while being able to request user’s signature from their wallet software in a simple and secure way. As you can see, even the name of the proposal focuses on that. It doesn’t say Bitcoin Wallet Payments API or something like that. Its only about a secure, authorized access to bitcoin wallets.

jokeyrhyme
2014-09-25

Related discussion about Web Payments and emerging W3C proposals: http://5by5.tv/webahead/82