flutter_install_referer
This package if build for flutter to get install referer, such as channel info, install referer, downlaod time, and any other custom info.
but you need extra steps and combain this package to finish the job. I will put the steps below.
- this package only work in android. *
steps
1. install this package
install this package in you project, and you can get your referer data as Map in this way:
Map<String,String> refererInfo = await FlutterInstallReferer.installReferer;
as you see, the data is a Map.
2. build apk
you can use command methods to build your project to apk file. because we will add extra data to the apk file later. such as :
flutter build apk --split-per-abi
3. add your referer data to apk file
now, we need a command line tool walle-cli
, you can click here to see more info about this tool
frist you need downlaod this tool in here
and then the basic command is :
java -jar walle-cli-all.jar put -c sky -e buildTime=20200620,info=hello /Users/Downloads/app.apk /Users/xxx/Downloads/newAPKFilePath.apk
- -c : channel, you can use as referer.
- -e : extra data, you can add any other data with
key=value
pair. /Users/Downloads/app.apk
:the apk file path you build last step./Users/xxx/Downloads/newAPKFilePath.apk
new apk file path.
this command will complete super fast, actually you can repack the apk file to over 100 channels in milliseconds
4. install or share the new apk file
for test you can run adb install /Users/xxx/Downloads/newAPKFilePath.apk
and then you can get the Map data you need.
you can get something like this.

Libraries
Dart
- dart:ui
- Built-in types and core primitives for a Flutter application. [...]
- dart:async
- Support for asynchronous programming, with classes such as Future and Stream. [...]
- dart:collection
- Classes and utilities that supplement the collection support in dart:core. [...]
- dart:convert
- Encoders and decoders for converting between different data representations, including JSON and UTF-8. [...]
- dart:core
- Built-in types, collections, and other core functionality for every Dart program. [...]
- dart:developer
- Interact with developer tools such as the debugger and inspector. [...]
- dart:math
- Mathematical constants and functions, plus a random number generator. [...]
- dart:typed_data
- Lists that efficiently handle fixed sized data (for example, unsigned 8 byte integers) and SIMD numeric types. [...]
- dart:ffi
- Foreign Function Interface for interoperability with the C programming language. [...]
- dart:io
- File, socket, HTTP, and other I/O support for non-web applications. [...]
- dart:isolate
- Concurrent programming using isolates: independent workers that are similar to threads but don't share memory, communicating only via messages. [...]
- dart:html
- HTML elements and other resources for web-based applications that need to interact with the browser and the DOM (Document Object Model). [...]
- dart:js
- Low-level support for interoperating with JavaScript. [...]
- dart:js_util
-
Utility methods to manipulate
package:js
annotated JavaScript interop objects in cases where the name to call is not known at runtime. [...]