Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve visibility of "discovery method" #855

Closed
leggomuhgreggo opened this issue Nov 18, 2024 · 6 comments
Closed

Improve visibility of "discovery method" #855

leggomuhgreggo opened this issue Nov 18, 2024 · 6 comments

Comments

@leggomuhgreggo
Copy link

leggomuhgreggo commented Nov 18, 2024

Overview

We're testing the beta feature support for iOS + USB connections, on M2 Readers.

It would be very useful if the "current connection type" were represented more definitively within the reader data.

Looking at the existing interfaces, it seems like this is currently supported for Android but not iOS:

image

Additional Context

We're persisting device / connection information to local storage, in order to facilitate automatic reconnection of "known devices".

We encountered an issue where our workflow for re-establishing connections to "known devices" was defaulting as BlueTooth instead of USB.

We can patch on our end, but it would be useful to have some additional validation around connection type within the Stripe terminal's connection state.

Thanks!

EDIT: clarity

@nazli-stripe
Copy link
Collaborator

We don't currently officially support usb for iOS, we are working to add it in early 2025.

@leggomuhgreggo
Copy link
Author

Totally fair!

Yeah I guess I was just thinking about "beta" support?

In our preliminary testing it seems to be working, but wouldn't want to jump the gun.

@nazli-stripe
Copy link
Collaborator

Is the ask adding usb to the DiscoveryMethod enum for iOS, or actually having a connectionType field, value, something etc available via the SDK for the currently connected reader?

@leggomuhgreggo
Copy link
Author

leggomuhgreggo commented Nov 19, 2024

It's a matter of keeping reader state in sync with app state.

We want to be able to check current connection type via the SDK, to ensure that it matches what the app is expecting

It would be cool if this information were included along with other reader state — perhaps the methods through which Reader.Type can be accessed? But could understand if it's not as simple as that.

So, in response to your question, not just the type definition — ideally we can check the state and see the actual value.

@leggomuhgreggo
Copy link
Author

leggomuhgreggo commented Nov 20, 2024

Wanted to share an update, further to this:

In our preliminary testing it seems to be working, but wouldn't want to jump the gun.

It appears as though this was a false positive. We thought it was connecting via USB but it was just reverting to the Bluetooth connection method.

When we tried with USB we got this message (as expected)
image

Regrets for the misunderstanding!

@nazli-stripe
Copy link
Collaborator

Ah yeah I recommend waiting till official support for USB.

Connection type support is something that's not available on the native SDKs so we won't be supporting it here either. We recommend keeping track of it by tracking the discovery method used during the connection flow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants