herow 0.0.12

  • Readme
  • Changelog
  • Example
  • Installing
  • 57

Herow #

A flutter plugin for the Herow SDK, a location based SDK related to the Herow Platform

Getting Started #

The Connecthings Flutter plugin allows you to access to the GDPR methods and In-App actions methods from the Dart code.

Nevertheless, the configuration of the SDK must still be done at the android and iOS app level.

A Flutter application is available on github to show you a concrete implementation.

You just have to clone the plugin repository https://github.com/Connecthings/flutter-connecthings, and open it with an android studio configured for flutter.

Add the plugin to your project #

  • Open the pubspec.yaml
  • add to the dependencies section

Initialize the SDK #

Follow the iOS and Android 5-minutes quickstart to initialize the SDK at the native app level.

Android #

Before following the previous tutorial. You need to open the application build.gradle and change two things :

  • The minSdkVersion need to be at least 19 because the SDK doesn't support lower version
  • You need to add the herow dependency to your application, to be able to initialize the SDK.
implementation "com.connecthings.herow:herow-detection:6.0-BETA-PR2"


On Android, when you extend the default application you must use the FlutterApplication and not the default Application

public class FlutterApp extends FlutterApplication

iOS #

First thing to do is to update the Podfile sources, you can add at the beginning of the file the following URLs:

  • source 'https://github.com/CocoaPods/Specs.git'
  • source 'https://forge.herow.io/pub/Specs'

Then, you also need to set the minimum platform support to 9 :

source 'https://github.com/CocoaPods/Specs.git'
source 'https://forge.herow.io/pub/Specs'

platform :ios, '9.0'

You're ready to follow the iOS tutorial.

If you meet a compilation error about the Flutter.framework duplicated, click on Runner, select Targets>Runner>Build Phases.

Next click on Embed Frameworks and remove the Flutter framework.


On iOS, if you are using cocoapods 1.7.x or higher version, and you encounter an error when runinng pod install command, you will need to follow these steps:

1- Clean your cocoapods cache

rm -Rf ~/.cocoapods/repos/

rm -Rf Pods Podfile.lock

2- Add Herow Specs repository with the following commands

pod repo add herow-pub-specs https://forge.herow.io/pub/Specs master

3- Redo your pod install command

pod install

Enable PUSH #

You have dart Method to registerForPush:

 // ios and android push registration

 // ios appGroupName settings

You can find out more about this by reading our PUSH tutorial for iOS and Android.

Being compliant with GDPR #

The following methods allow your application to be compliant to GDPR.

You can find out more about this by reading our GDPR tutorial for iOS and Android.

try {
//To test if your application has already asked to the user the optins
if (await Herow.optinsNeverAsked) {
//Update the optin
Herow.updateOptin(OPTIN_TYPE.USER_DATA, true);
//Notify the sdk that there is no more optin to update
//To the the status of a given optin
optinUserDataStatus = await Herow.isOptinAuthorized(OPTIN_TYPE.USER_DATA);
} on PlatformException {



Untill the call to the Herow.allOptinsAreUpdated() method, the SDK won't transmit any collected data to the platform.

The In-App actions #

In App Actions are events triggered when the user enter or exit from a place (a geofence zone or beacon configured on the Herow Platform)

These events allow you to realize action depending on the information associated with the place.

For example, your application UI can be updated when your user is detected inside an airport or inside in a pub.

You can find out more about this by reading our In-App actions tutorial for iOS and Android.

Your application can be notified about In App Action events, registering to the In App Action Stream.

Herow herow = Herow();
herow.inAppActionEvents.listen((data) {
//Status allow to determine if it is a "CREATION" or "REMOVE"
print("data is data:" + data.status.toString());
print("data is data:" + data.id);
print("data is data:" + data.title);
print("data is data:" + data.description);
print("data is data:" + data.tag);
}, onDone: () {
print("done is done");
}, onError: (error) {
print("error is error");

Setting custom user ID #

The following method allow you to set a custom user ID.


0.0.12 #

  • Update beta version

0.0.11 #

  • Fix setAppGroupName implementation.

0.0.10 #

  • Update beta version

0.0.9 #

  • Fix iOS push when testing with APNS sandbox mode.

0.0.8 #

  • Update doc

0.0.7 #

  • minor fixes for iOS version

0.0.6 #

  • add push and customID features
  • Update doc

0.0.5 #

  • Update doc

0.0.4 #

  • Minor fix for actions

0.0.3 #

  • Minor adjustments

0.0.2 #

  • Beta of Herow SDK

0.0.1 #

  • Initial version


herow_example #

Demonstrates how to use the herow plugin.

Getting Started #

This project is a starting point for a Flutter application.

A few resources to get you started if this is your first Flutter project:

For help getting started with Flutter, view our online documentation, which offers tutorials, samples, guidance on mobile development, and a full API reference.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:

  herow: ^0.0.12

2. Install it

You can install packages from the command line:

with Flutter:

$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:

import 'package:herow/herow.dart';
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
Learn more about scoring.

We analyzed this package on Nov 11, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.6.0
  • pana: 0.12.21
  • Flutter: 1.9.1+hotfix.6


Detected platforms: Flutter

References Flutter, and has no conflicting libraries.

Health suggestions

Fix lib/herow.dart. (-1 points)

Analysis of lib/herow.dart reported 2 hints:

line 50 col 3: Prefer using /// for doc comments.

line 103 col 3: Prefer using /// for doc comments.

Maintenance suggestions

Package is pre-v0.1 release. (-10 points)

While nothing is inherently wrong with versions of 0.0.*, it might mean that the author is still experimenting with the general direction of the API.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.1.0 <3.0.0
flutter 0.0.0
Transitive dependencies
collection 1.14.11 1.14.12
meta 1.1.7 1.1.8
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies