Authy and Two-Factor Authentication with Launch Center Pro

I enabled two-factor authentication in most of my online services. It adds another security layer to your login, prompting you to input a security code given to you in real-time by either a mobile message or an app, such as Authy, which is the one I use. I took the day to play with its URL scheme to ease the app bouncing when logging in your beloved services.

Launch Center Pro offers a sneak peek of Authy's undocumented URL scheme, it gives you the options to launch the app and three services (Dropbox, Facebook and Gmail) to be opened directly from the action. The difference between these kinds of actions is the inclusion of the service name after the open command, like this:


So what if we tweak it to open other services? For example, Cloudflare? authy://open/Cloudflare works. Just add the service as listed in Authy's menu and it is supposed to work, for example, some of my authenticator accounts follow a service:email@login formatting, so I use authy://open/service:email@login and eureka.

As you can expect, we can convert this into a [list] in Launch Center Pro1:

Service=service:email@login| philg]

This is particularly nice when you're trying to log from the desktop, however, what if you're logging from your mobile device? Home button, open Launch Center Pro, run action, pick service, copy security code to clipboard, double press Home, back to browser, paste and log in. It would be so much better if we could just store all this within a bookmarklet. Well, you can and it isn't even that hard.

Did you build the Launch Center Pro action just the way you want? Nice. Now copy it and let's play with the double launchpro://?url trick by Federico Viticci. This is the template for a regular bookmarklet: javascript:window.location=encodeURIComponent('Your action here'), then, right before the encodeURIComponent2 statement, include 'launchpro://?url='+. Notice that we use a plus sign to join both parameters.

javascript:window.location='launchpro://?url='+encodeURIComponent('launchpro://?url=authy://open/[list:Authenticate|Cloudflare|Service=service:emial@login| philg]')

This is how it looks smashed together. If you want to overcomplicate things, I have a trial for you: using Pythonista, grab the current page url with a bookmarklet (use location.href) and open the requested account in Authy without passing through Launch Center Pro. I still prefer the [list] method due to speed, it's one of those moments where a tap isn't worthy, but you're free to play with it to sharpen your python skills.

  1. Try keeping everything clean using key=value when applicable to your list items. 

  2. Just in case you missed this before, encodeURIComponent URL encodes its contents.