{"id":22122947,"url":"https://github.com/telemetrydeck/fluttersdk","last_synced_at":"2025-10-08T18:20:36.017Z","repository":{"id":221133958,"uuid":"739445785","full_name":"TelemetryDeck/FlutterSDK","owner":"TelemetryDeck","description":"Flutter SDK for TelemetryDeck, a privacy-conscious analytics service for apps and websites.","archived":false,"fork":false,"pushed_at":"2024-08-02T11:41:37.000Z","size":327,"stargazers_count":3,"open_issues_count":3,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-08-22T23:43:40.714Z","etag":null,"topics":["analytics","flutter","tracking","usage-data"],"latest_commit_sha":null,"homepage":"https://telemetrydeck.com/","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TelemetryDeck.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-01-05T15:30:15.000Z","updated_at":"2024-08-02T11:41:37.000Z","dependencies_parsed_at":"2024-02-06T12:38:06.249Z","dependency_job_id":"960b45a7-6abb-4e16-b92f-beebf5589a61","html_url":"https://github.com/TelemetryDeck/FlutterSDK","commit_stats":null,"previous_names":["telemetrydeck/fluttersdk"],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TelemetryDeck%2FFlutterSDK","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TelemetryDeck%2FFlutterSDK/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TelemetryDeck%2FFlutterSDK/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TelemetryDeck%2FFlutterSDK/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TelemetryDeck","download_url":"https://codeload.github.com/TelemetryDeck/FlutterSDK/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227584817,"owners_count":17789758,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["analytics","flutter","tracking","usage-data"],"created_at":"2024-12-01T15:28:30.169Z","updated_at":"2025-10-08T18:20:30.975Z","avatar_url":"https://github.com/TelemetryDeck.png","language":"Dart","readme":"\u003ca href=\"https://pub.dev/packages/telemetrydecksdk\"\u003e\u003cimg src=\"https://img.shields.io/pub/v/telemetrydecksdk.svg\" alt=\"Pub\"\u003e\u003c/a\u003e\n\n\n# TelemetryDeck SDK for Flutter\n\nThis package allows your app to send signals to [TelemetryDeck](https://telemetrydeck.com/) using the native TelemetryDeck libraries for [Kotlin](https://github.com/TelemetryDeck/KotlinSDK) and [iOS](https://github.com/TelemetryDeck/SwiftSDK).\n\n## Getting started\n\n- Obtain your TelemetryDeck App ID from the [Dashboard](https://dashboard.telemetrydeck.com/)\n\n- Follow the installing instructions on [pub.dev](https://pub.dev/packages/telemetrydecksdk/install).\n\n- Initialize the client:\n\n```dart\nvoid main() {\n  // ensure the platform channels are available\n  WidgetsFlutterBinding.ensureInitialized();\n  // configure and start the client\n  Telemetrydecksdk.start(\n    const TelemetryManagerConfiguration(\n      appID: \"XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX\",\n    ),\n  );\n\n  runApp(const MyApp());\n}\n```\n\n### Permission for internet access\n\nSending signals requires access to the internet so the following permissions should be granted. For more information, you can check [Flutter Cross-platform HTTP networking ](https://docs.flutter.dev/data-and-backend/networking).\n\n#### Android\n\nChange the app's `AndroidManifest.xml` to include:\n\n```xml\n\u003cuses-permission android:name=\"android.permission.INTERNET\" /\u003e\n```\n\n#### macOS\n\nSet the `com.apple.security.network.client` entitlement to `true` in the `macos/Runner/DebugProfile.entitlements` and `macos/Runner/Release.entitlements` files. You can also do this in Xcode by selecting the `macos` target, then the `Signing \u0026 Capabilities` tab, and checking `Outgoing connections (Client)` for both the Release and Debug targets of your app.\n\n## Sending signals\n\nSend a signal using the following method:\n\n```dart\nTelemetrydecksdk.send(\"signal_type\")\n```\n\n## Signals with additional attributes\n\nAppend any number of custom attributes to a signal:\n\n```dart\nTelemetrydecksdk.send(\n  \"signal_type\",\n  additionalPayload: {\"attributeName\": \"value\"},\n);\n```\n\n## Environment Parameters\n\nThe Flutter SDK uses the native SDKs for Android and iOS which offer a number of built-in attributes which are submitted with every signal.\n\nFor more information on how each value is calcualted, check the corresponding platform library.\n\nThe Flutter SDK adds the following additional attributes:\n\n| Parameter name                  | Description                                 |\n| ------------------------------- | ------------------------------------------- |\n| `TelemetryDeck.SDK.dartVersion` | The Dart language version used during build |\n\n## Stop sending signals\n\nPrevent signals from being sent using the stop method:\n\n```dart\nTelemetrydecksdk.stop()\n```\n\nThis also prevents previously cached signals from being sent. In order to restart sending events, you will need to call the `start` method again.\n\n## Default Parameters\n\nIf there are parameters you would like to include with every outgoing signal, you can configure `Telemetrydecksdk` to do so instead of passing them with every call:\n\n```dart\nconst TelemetryManagerConfiguration(\n  // ...\n        defaultParameters: {\"ParameterName\": \"ParameterValue\"}\n        ),\n```\n\n## Default Prefix\n\nIf you find yourself prepending the same prefix for to your custom signals or parameters,\nyou can optionally configure `Telemetrydecksdk` to do this for you:\n\n```dart\nconst TelemetryManagerConfiguration(\n  // ...\n        defaultParameterPrefix: \"DemoApp.Parameter.\",\n        defaultSignalPrefix: \"DemoApp.Signal.\",\n        ),\n```\n\n## Duration Signals\n\nThe SDK offers convenience methods to facilitate tracking the duration of specific objects or events.\n\nOnce started, a duration signal will be tracked internally by the SDK and upon completion, it will send the signal while also adding a `TelemetryDeck.Signal.durationInSeconds` parameter.\n\n```dart\n// start tracking, without sending a signal\nTelemetryDeck.startDurationSignal(\"wizard_step1\")\n\n// end tracking, sends the signal including the total duration (excluding background time)\nTelemetryDeck.stopAndSendDurationSignal(\"wizard_step1\")\n```\n\n## Navigation signals\n\nA navigation signal is a regular TelemetryDeck signal of type `TelemetryDeck.Navigation.pathChanged`. Automatic navigation tracking is available using the `navigate` and `navigateToDestination` methods:\n\n```dart\nTelemetrydecksdk.navigate(\"screen1\", \"screen2\");\n\nTelemetrydecksdk.navigateToDestination(\"screen3\");\n```\n\nBoth methods allow for a custom `clientUser` to be passed as an optional parameter:\n\n```dart\nTelemetrydecksdk.navigate(\"screen1\", \"screen2\",\n                      clientUser: \"custom_user\");\n```\n\nFor more information, please check [this post](https://telemetrydeck.com/docs/articles/navigation-signals/).\n\n## Test mode\n\nIf your app's build configuration is set to \"Debug\", all signals sent will be marked as testing signals. In the Telemetry Viewer app, activate **Test Mode** to see those.\n\nIf you want to manually control whether test mode is active, you can set the `testMode` field:\n\n```dart\nTelemetrydecksdk.start(\n  TelemetryManagerConfiguration(\n    appID: \"XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX\",\n    testMode: true,\n  ),\n);\n```\n\n[Getting started with Test Mode](https://telemetrydeck.com/docs/articles/test-mode/)\n\n## Custom Salt\n\nBy default, user identifiers are hashed by the TelemetryDeck SDK, and then sent to the Ingestion API, where we'll add a salt to the received identifier and hash it again.\n\nThis is enough for most use cases, but if you want to extra privacy conscious, you can add in you own salt on the client side. The TelemetryDeck SDK will append the salt to all user identifers before hashing them and sending them to us.\n\nIf you'd like to use a custom salt, you can do so by passing it on to the starting `TelemetryManagerConfiguration`:\n\n```dart\nTelemetrydecksdk.start(\n  TelemetryManagerConfiguration(\n    appID: \"XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX\",\n    salt: \"\u003cA RANDOM STRING\u003e\",\n  ),\n);\n```\n\n## Custom Server\n\nA very small subset of our customers will want to use a custom signal ingestion server or a custom proxy server. To do so, you can pass the URL of the custom server to the `TelemetryManagerConfiguration`:\n\n```dart\nTelemetrydecksdk.start(\n  TelemetryManagerConfiguration(\n    appID: \"XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX\",\n    apiBaseURL: \"https://nom.telemetrydeck.com\",\n  ),\n);\n```\n\n## Logging output\n\nBy default, some logs helpful for monitoring TelemetryDeck are printed out to the console. You can enable additional logs by setting the `debug` field to `true`:\n\n```dart\nvoid main() {\n  Telemetrydecksdk.start(\n    TelemetryManagerConfiguration(\n      appID: \"XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX\",\n      debug: true,\n    ),\n  );\n}\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftelemetrydeck%2Ffluttersdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftelemetrydeck%2Ffluttersdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftelemetrydeck%2Ffluttersdk/lists"}