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

FIX: Follow developer practices for use of SDK #2

Open
jacks205 opened this issue Oct 27, 2017 · 0 comments
Open

FIX: Follow developer practices for use of SDK #2

jacks205 opened this issue Oct 27, 2017 · 0 comments
Assignees

Comments

@jacks205
Copy link
Contributor

jacks205 commented Oct 27, 2017

Overview

  • Follow dev guidelines for handling Nearby Messages for handling behavior

Resource

Respect user privacy

  • Help the user understand what data your app will expose to nearby users.
  • Don't publish sensitive information such as passwords and credit card numbers. Instead, pass authorization tokens or transaction identifiers.

Require an explicit user-initiated action to start Nearby

  • Don’t surprise the user. Require the user to perform an explicit action (a button tap, going to a section in your app, a special switch, etc) to activate Nearby.
    On both iOS and Android, calling Nearby for the first time will trigger a permission dialog from Nearby. Waiting for an explicit user action before invoking Nearby will help the user contextualize the dialog and associate it with your app's proximity-based feature.

Be mindful of battery consumption

Nearby's use of radios and sensors will cause your app to consume battery at 2.5-3.5 times the normal rate. To reduce battery usage, observe the following recommendations.

  • On Android, when publishing or subscribing with non-BLE devices, only invoke the Nearby Messages API from an Activity, and only keep that Activity running when the screen is on and your app is in the foreground. To do this, pass the Activity (or FragmentActivity) as an argument to the Context parameter of GoogleApiClient.Builder(). Invoking Nearby from a Service is only supported when subscribing to Bluetooth Low Energy (BLE) beacon messages.
  • On Android, in your app's Activity.onStop() callback, call Nearby.Messages.unpublish() and Nearby.Messages.unsubscribe() on any active publishes or subscribes, and then call GoogleApiClient.disconnect(). On iOS no action is necessary as this is handled automatically.
  • Make it easy for the user to stop active publishes and subscribes.
  • Do not publish or subscribe in the background without the user's knowledge.
    Use the right branding

We’ve provided a set of standard assets that you can use to represent Nearby in your app. Use only the following approved icons when referring to Nearby.

@jacks205 jacks205 self-assigned this Oct 27, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant