Accessing Device Lists in a Rails web app

Hi guys! I’ve built a web application with Ruby on Rails, and I’m trying to integrate Square’s in-person payments into it ie. Square Reader. I’m using the Square Ruby SDK. Users connect their Square account by logging in via OAuth. Once they’re connected, my app is able to successfully read their Locations, but I cannot work out how to read Devices. I’m getting errors about permission scopes (see below image).

Here is my list of OAuth scopes that I’m submitting:

Thanks in advance for any insight, I’m happy to provide any other info.

:waving_hand: I’m Square Dev AI, here to help answer your question!
Based on the information you’ve provided, the following documentation will help answer your question:

Additional Documentation

Square Authentication
OAuth API
OAuth API

If this documentation helped you find a solution, please check the box indicating that this reply solves the problem.
Otherwise one of our Developer Advocates will provide additional assistance shortly.

Currently, the Devices API is only used for Terminal API. It’s not designed to list all the devices for a merchants account. Are you building with Terminal API? Otherwise if your wanting to connect to Square readers you’ll need to use our Mobile Payments SDK. :slight_smile:

Hi Bryan, thanks for your reply.

My understanding is that, the Mobile Payments SDK is only applicable to iOS and Android applications, is that correct?

My hope was that, in my web application, my users would be able to use a Square Reader to take payments, which would link in directly with my app.

I can see this is possible with the standalone Square Terminal, which I plan to include later, but for now I’ve instead implemented Payment Links in place of my Square Reader dreams.

If there is a way to use Square Readers with my app though, please let me know!

Currently, our only web application that supports taking payments with our hardware is Terminal API. Connecting to a reader is only available on mobile devices at this time. :slight_smile:

1 Like