I ended up implementing a custom application that works very similar to the Nexus Mod Manager. I wrote a C# application that registers a custom Application URI Scheme. Here’s how it works:
- User clicks “Print” on the website.
- Website links user to “CustomURL://Print/{ID}
- Application is launched by windows via the custom uri scheme.
- Application communicates with the pre-configured server to confirm the print request and in my case get the actual print command.
- The application then uses the C# RawPrinterHelper class to send commands directly to the printer.
This approach required an initial download from the user, and a single security prompt from windows when launching the application the first time. I also implemented some Javascript magic to make it detect whether the print job was handled or not. If it wasn’t it asks them to download the application.