Post
Topic
Board Development & Technical Discussion
Re: pushing BIP70 Payment Requests to customers using WebFinger
by
paulej
on 06/04/2014, 05:42:29 UTC
This can work.  I noted you specify how to use WebFist as the way to publish the JRD.  However, you don't need to do that unless your email provider does not support WebFinger.  I run my own WebFinger server and could just publish the JRD directly myself.  In fact, I do. You can query my WebFinger server like this:

$ curl https://packetizer.com/.well-known/webfinger?resource=paulej@packetizer.com

You'll see I have a couple of bitcoin-related entries in mine already (and I show one more below):

Code:
     {
         "rel" : "http://bitcoin.org/rel/address",
         "href" : "bitcoin:17XoqvUCrf12H7Vc7c7uDxib8FDMXFx2p6"
      },
      {
         "rel" : "http://bitcoin.org/rel/payments",
         "href" : "https://secure.packetizer.com/bitcoin_address/?account=paulej",
         "type" : "text/plain"
      },
      {
         "rel" : "http://bitcoin.org/rel/payments",
         "href" : "bitcoin:17XoqvUCrf12H7Vc7c7uDxib8FDMXFx2p6?request=https%3A%2F%2Fblockchain.info%2Fr%3Fid%3Dpaulej"
      }

One of those is just a Bitcoin address.  The other two are Bitcoin payments URIs, though I suspect the latter is more along the lines of what you're expecting to use.  The URIs I use as the link relation types ("rel") are made up, since there is not standard specified for those.  However, I think those are reasonable ones to use and follow standard conventions.

I'm not terribly familiar with BIP70.  I can understand how you might publish a URI to which a payment is made, but how would you receive notifications of payment requests?  Does the wallet poll some location from time-to-time to see if there are requests?