Merchants have been using our POS Admin URL Extension for years now, this link will open a URL in our app that opens a new web browser to access the camera on the POS device.
This extension will be sunsetted by Shopify in February, and we’re looking into creating an equivalent POS Extension - however there doesn’t seem to be an option to open a link from a POS Extension.
This is critical for our merchants, because there is no Camera API supported yet, and we also run A.I. models in the browser as well as part of the image capture process.
The Navigation API doesn’t appear to have any option to open a URL
The Button component doesn’t appear to accept a url parameter
There’s no Link component to open a URL in a browser context
Is there some other option that we’re missing? Or is it truly not possible to open a URL in the POS device’s browser from a POS Extension?
I don’t believe you can from a POS UI Extension.
Merchants can still open your app website from POS tile. You could give them a button in there to trigger the camera etc as it’s a website
Merchants can still open your app website from POS tile. You could give them a button in there to trigger the camera etc as it’s a website
Interesting, I wasn’t aware of the tile URL. But from what I can see in the component documentation, there’s no option to pass your own URL for this preview:
Also the CTA of “Go to app website” doesn’t accurately convey what the merchant is actually doing when they would click that button.
There is a camera scanner in POS UI for use reading barcodes etc, but I guess you’re after more than that CameraScanner
Correct, in this case we actually use the camera feed itself though. The CameraScanner component is limited to only QR codes. Our app needs to capture images, not scan codes.
The other escape hatch we have is to instruct merchants to bookmark our existing Admin Extension URL to their tablet’s home screen as it’s own tile outside of Shopify.
Sorry, what I mean is the App Website is just the URL of your app. The same one that opens in the Admin.
So, when they click add, this adds a tile to POS just with your app name and description. Attached an image of what it looks like.
Then they click on the tile in POS, it just opens up your app, like in Admin.
You might be able to use the UserAgent or something to detect this and display a button to activate the camera and do your browser scanning as normal, as at that point you’re just in a webview.
I’ve tested this and there is Shopify POS in the UserAgent, so you would be able to detect it and use that to do what you need
Ah got it, the part I didn’t understand was that you can add your app’s Admin home URL as a tile itself.
Yes, then we can use the User Agent to redirect to the old Admin Extension Link. We’ll need to test to make sure our functionality is compatible in this WebView, but fingers crossed.
This is short term workaround for sure, and if it works we’ll start advising this to merchants using our POS links.
But there’s a few key problems with this approach:
It’s not an intuitive set up process. A merchant wouldn’t know to add a App Website as tile for an action
The tile description comes from your app listing, which also doesn’t clearly describe what the tile does
You’re limited to a single tile, since there’s only one app admin URL.
So I think this is helpful in the short term, but ideally Shopify’s POS Extension components or hooks should include a way to open a URL in a native browser to fill in functionality that’s missing from the current components.
Do you find any solution? We have an app that works similar. We load a website using POS Link. Then, we use Redirect from Shopify App Bridge and window.location.href to open a link.
But with POS UI extensions, neither Redirect nor window function works.
No, I haven’t yet. I’m trying to get an answer from the POS Extensions team directly.
The banner on the old POS Links documentation only refers to using POS UI Extensions. But unfortunately there’s significant functionality gaps and we need to open an external URL to access browser APIs that POS Extensions don’t offer.
But if I’m able to find a way or hear from the POS UI Extensions team, I’ll certainly report back on this thread.
Hi @Dylan how did you go about adopting this solution with the Tile component? We have 3 old deprecated POS UI Links and need to redirect to these external links related to our app with the order data context. Do you know how to help ? Thanks in advance