Open a filled Payment Form with a URL

in utopian-io •  7 years ago  (edited)

Steem Condensor Improvement: Open a filled Payment Form with a URL

Let's Give Steem users the ability to pay with two clicks. Why do we need click to pay feature for paying? There are several reasons. For one thing, although the feature that allows you to pay to a name makes sending payments to a given user makes getting the destination easy to get right, presently merchants also require a unique memo field. Why? If a user using say Steemfiles.com orders socks in one order and starts another session and orders a hat and then makes only a single payment, the software needs to know what the money is for when it is received. Indeed a server may have dozens of users accessing the site at the same time. Without a memo, normally we wouldn't know whether the payment was for one of the orders made from one browser or from another browser in some other country. There may be two people who have not bothered logging in, buying different products at the same time. The website needs to know where to upload the file to. Should it upload to the user in Africa or the one in Asia? The transaction is read by the web server via the blockchain and the transaction is often not enough information to determine which browser's user sent the funds. By challenging the user with a unique memo we know which order each payment is for.The use of unique memos ensures the user of the web-browser is indeed the person sending the funds.

When the user pays, this user must set the currency; and enter the user id of the merchant, the amount, and the memo. Here the user must switch back and forth between wallet and website with some combination of copy and paste and manually typing in this information. It sounds cumbersome only because it is. To avoid switching from merchant website browser tab to wallet a user might introduce typographical errors and send the wrong amount, the wrong currency or even worse to the wrong user.

If the user only needed to copy and paste a single string, or better yet just point and click, this user wouldn't be mistyping destinations or amounts. Since the user will already probably need to copy and paste the normally hard to remember memo, changing this to a single string wold be a big improvement. I was thinking of a format similar to the BIP proposal used in Bitcoin and posted about it here. One day after, I read a post on a much more flexible proposal that goes way beyond what BIP21 does here

Links that begin with "steem:" are called links of the "steem protocol". Links with this scheme have the following form:

steem:sign/tx/W1sndHJhbnNmZXInLCB7J2Zyb20nOiAnJywgJ3RvJzogJ3N0ZWVtZmlsZXMnLCAnYW1vdW50Jzog
JzAuMTAgU0JEJywgJ21lbW8nOiAnZGFrbGhhZmh3ZWloMjM0NTEnfV1dCg==

Users could set preferences in the blockchain according to whether they want automatically see links that use the steem protocol changed to steemit.com URLs. It would be up to the application developers to honor these preferences and decide on defaults.

Although adapting clients to use the steem protocol is out of the scope of a web application, the part condenser should handle is the part after "steem:". A tiny program can be written that will convert steem protocol requests to https protocol requests under www.steemit.com to provide a bridge. So condenser itself, needs only to deal with HTTPS URLs like this https://www.steemit.com/sign/tx/W1sndHJhbnNmZXInLCB7J2Zyb20nOiAnJywgJ3RvJzogJ3N0ZWVtZmlsZXMnLCAnYW1vdW50Jzog JzAuMTAgU0JEJywgJ21lbW8nOiAnZGFrbGhhZmh3ZWloMjM0NTEnfV1dCg== .

Example #1:

Over on say steemfiles.com, the user decides he wants to download an original e-book. The Steemfiles website just has a "click here" button to pay say 0.10 Steem dollars. A steem protocol link is clicked and that causes a program to open https://www.steemit.com/sign/tx/W1sndHJhbnNmZXInLCB7J2Zyb20nOiAnJywgJ3RvJzogJ3N0ZWVtZmlsZXMnLCAnYW1vdW50Jzog JzAuMTAgU0JEJywgJ21lbW8nOiAnZGFrbGhhZmh3ZWloMjM0NTEnfV1dCg==. So, steemit.com opens with the memo filled in, the amount filled in, and if the user is already logged into steemit.com, the username filled in. It's another click to confirm and one more for entering the active key. Depending on the password manager in use and its settings the user may not need to enter the active key.

Example #2:

Also steemfiles.com, another user decides she wants to download the same original e-book. The Steemfiles website just has a "click here" button to pay say 0.10 Steem dollars. This user has logged in to steemfiles via SteemConnect, and because she has set her preferences to use steemit.com the linked URL is directly set to https://www.steemit.com/sign/tx/W1sndHJhbnNmZXInLCB7J2Zyb20nOiAnc3dlZXRzc3NqJywgJ3RvJzogJ3N0ZWVtZmlsZXMnLCAn YW1vdW50JzogJzAuMTAgU0JEJywgJ21lbW8nOiAnc2RqYWplZmpma2pxeDEnfV1dCg==. The user clicks on that and steemit.com opens with the memo filled in, the amount filled in, and the username filled in. It's another click to confirm and one more for entering the active key. Depending on the password manager in use and its settings the user may not need to enter the active key.

Example #3:

This time on steemfiles.com, a third user decides he wants to download the same original e-book. The Steemfiles website just has a "click here" button to pay say 0.10 Steem dollars. This user has logged in to steemfiles via SteemConnect, and because he has set his preferences to some other condensor using site steemalternative.com the linked URL is thus https://www.steemalternative.com/sign/tx/W1sndHJhbnNmZXInLCB7J2Zyb20nOiAnbGVwcmVjaGF1bicsICd0byc6ICdzdGVlbWZpbGVzJywg J2Ftb3VudCc6ICcwLjEwIFNCRCcsICdtZW1vJzogJzc1MzRoZmRyaHFrcmgnfV1dCg==. The user clicks on that and steemit.com opens with the memo filled in, the amount filled in, and the username filled in. It's another click to confirm and one more for entering the active key. Depending on the password manager in use and its settings the user may not need to enter the active key.

Example #4

In some centralized exchange, the user decides he wants to convert Steem dollars to say Nubits. The user's account name on Steem is registered with the said exchange. Now, it just provides a link for the transfer of Steem dollars to the exchange. The centralized exchange can look to see whether the user perfers to use steemit.com or some other site.

https://www.steemit.com/sign/tx/W1sndHJhbnNmZXInLCB7J2Zyb20nOiAnJywgJ3RvJzogJ3N0ZWVtZmlsZXMnLCAnYW1vdW50Jzog
JzAuMTAgU0JEJywgJ21lbW8nOiAnZGFrbGhhZmh3ZWloMjM0NTEnfV1dCg==

Example #5

On steemfiles.com, a user decides he wants to download some original music. The Steemfiles website just has a "click here" button to pay say 5.00 Steem dollars. A steem protocol link is clicked and a desktop wallet opens with the memo filled in, the amount filled in, and the username filled in. It's another click to confirm. The URL is just:

steem:sign/tx/W1sndHJhbnNmZXInLCB7J2Zyb20nOiAnJywgJ3RvJzogJ3N0ZWVtZmlsZXMnLCAnYW1vdW50Jzog
JzAuMTAgU0JEJywgJ21lbW8nOiAnZGFrbGhhZmh3ZWloMjM0NTEnfV1dCg==

Vessel

As mentioned before, Vessel's author has implementing this:
You can join the ChainBB forum here about Vessel. You can see its source code here and file bug reports. Releases are executable binaries.

QR Codes

You can even use QR codes in combination. Scan a QR code and the wallet should open with everything filled in.

qr.png

In addition, by turning this into a QR code a user could use a website on one device and pay from a smart phone or tablet; or even pay or make donations from paper pictures posted outside. It would also make keeping the active key only on one device more convenient.



Posted on Utopian.io - Rewarding Open Source Contributors

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!
Sort Order:  

Hey @leprechaun I am @utopian-io. I have just upvoted you!

Achievements

  • Seems like you contribute quite often. AMAZING!

Suggestions

  • Contribute more often to get higher and higher rewards. I wish to see you often!
  • Work on your followers to increase the votes/rewards. I follow what humans do and my vote is mainly based on that. Good luck!

Get Noticed!

  • Did you know project owners can manually vote with their own voting power or by voting power delegated to their projects? Ask the project owner to review your contributions!

Community-Driven Witness!

I am the first and only Steem Community-Driven Witness. Participate on Discord. Lets GROW TOGETHER!

mooncryption-utopian-witness-gif

Up-vote this comment to grow my power and help Open Source contributions like this one. Want to chat? Join me on Discord https://discord.gg/Pc8HG9x

Thank you for the contribution. It has been approved.

I'm not sure if the bot will upvote this before 7 days pass, if not, please contact us on discord to resolve this issue.

You can contact us on Discord.
[utopian-moderator]

Hello @leprechaun,
Your contribution can not be approved yet, please kindly remove the following

  1. All wallet addresses for tip
  2. All images at the end of your contribution.
  3. Also, remove the sub-heading "See my other recent articles"

Please kindly do this to reapply for approval. Thank you.

[utopian-moderator]

Done

As you didn't respond to the update (I'm not sure if you're on vacation or not!) I will take over and accept this post - it's 6 days old already.

It turns out steemconnect already has this kind of thing.
https://steemconnect.com/sign/transfer?from=user&to=leprechaun&amount=123.000%20SBD&memo=open-a-filled-payment-form-with-a-url

I would like to see other wallets that do this.

Hey @leprechaun I'm new to Steemit. I found this post just searching around for answers. If you don't mind me asking, where would I find a list of parameters that steemconnect urls can hold?

I would start at http://steemconnect.com . Unfortunately developers seem to have an aversion to documenting their stuff or making it easy to find. Do a Google search like this 'site:steemconnect.com transfer sign' and see what comes out.