{"id":18683036,"url":"https://github.com/numbersprotocol/android-info-snapshot","last_synced_at":"2026-05-01T00:31:51.482Z","repository":{"id":50219793,"uuid":"223569882","full_name":"numbersprotocol/android-info-snapshot","owner":"numbersprotocol","description":"A simple library to capture information of an Android smartphone at a certain time.","archived":false,"fork":false,"pushed_at":"2021-06-01T16:31:02.000Z","size":196,"stargazers_count":1,"open_issues_count":2,"forks_count":3,"subscribers_count":10,"default_branch":"master","last_synced_at":"2025-05-18T17:10:03.320Z","etag":null,"topics":["android","android-library","data-collection","sensor","sensor-data","sensors"],"latest_commit_sha":null,"homepage":"","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/numbersprotocol.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}},"created_at":"2019-11-23T10:21:13.000Z","updated_at":"2020-10-21T15:21:24.000Z","dependencies_parsed_at":"2022-09-05T21:01:01.362Z","dependency_job_id":null,"html_url":"https://github.com/numbersprotocol/android-info-snapshot","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/numbersprotocol/android-info-snapshot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/numbersprotocol%2Fandroid-info-snapshot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/numbersprotocol%2Fandroid-info-snapshot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/numbersprotocol%2Fandroid-info-snapshot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/numbersprotocol%2Fandroid-info-snapshot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/numbersprotocol","download_url":"https://codeload.github.com/numbersprotocol/android-info-snapshot/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/numbersprotocol%2Fandroid-info-snapshot/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32481553,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"ssl_error","status_checked_at":"2026-04-30T13:12:06.837Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["android","android-library","data-collection","sensor","sensor-data","sensors"],"created_at":"2024-11-07T10:13:34.032Z","updated_at":"2026-05-01T00:31:51.419Z","avatar_url":"https://github.com/numbersprotocol.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Android Information Snapshot\n\n[![build](https://github.com/numbersprotocol/android-info-snapshot/workflows/build/badge.svg)](https://github.com/numbersprotocol/android-info-snapshot/actions?query=workflow%3Abuild)\n[![Codacy Badge](https://app.codacy.com/project/badge/Grade/d068d34827ff436ebb7dac9208e9154a)](https://www.codacy.com/gh/numbersprotocol/android-info-snapshot/dashboard?utm_source=github.com\u0026amp;utm_medium=referral\u0026amp;utm_content=numbersprotocol/android-info-snapshot\u0026amp;utm_campaign=Badge_Grade)\n[![JitPack version](https://jitpack.io/v/numbersprotocol/android-info-snapshot.svg)](https://jitpack.io/#numbersprotocol/android-info-snapshot)\n\nA simple library to capture information of an Android smartphone at a certain time.\n\n## Usage\n\nCreate `InfoSnapshotBuilder` with `duration` setting.\n\n``` kotlin\nval snapshotBuilder = InfoSnapshotBuilder(this).apply {\n    duration = 2000\n}\n```\n\nYou can specify which information to collect when creating `snapshotBuilder`. The default values of `enable*Info` are all `true`s.\n\n``` kotlin\nval snapshotBuilder = InfoSnapshotBuilder(this).apply {\n    duration = 2000\n    enableDeviceInfo = true\n    enableLocaleInfo = true\n    enableLocationInfo = true  // require [ACCESS_FINE_LOCATION] permission\n    enableSensorInfo = true\n    enableSettingsInfo = true\n}\n```\n\nLaunch a Kotlin coroutine to gather information.\n\n``` kotlin\nlaunch {\n    val snapshot = snapshotBuilder.snap()\n\n    Log.i(TAG, \"$snapshot\")  // Print out the snapshot directly.\n    Log.i(TAG, snapshot.toJson()) // Serialize the snapshot to JSON format.\n}\n```\n\n\u003e Remember to give permissions (e.g. `Manifest.permission.ACCESS_FINE_LOCATION`) before calling `snap()` to avoid security exception.\n\nYou can see an Android example project [here](./app/src/main/java/io/numbers/infosnapshot/MainActivity.kt).\n\n## Installation\n\nAdd the JitPack repository to your build file. Add it in your root build.gradle at the end of repositories.\n\n``` gradle\nallprojects {\n  repositories {\n    ...\n    maven { url \"https://jitpack.io\" }\n  }\n}\n```\n\nAdd the dependency.\n\n``` gradle\ndependencies {\n  implementation \"com.github.numbersprotocol:android-info-snapshot:[release-version]\"\n}\n```\n\n## Snapshot Example\n\n``` json\n{\n  \"deviceInfo\": {\n    \"value\": {\n      \"board\": \"sdm845\",\n      \"bootloader\": \"1.0.0.0000\",\n      \"brand\": \"htc\",\n      \"device\": \"htc_exodugl\",\n      \"display\": \"OPR1.170623.032 release-keys\",\n      \"fingerprint\": \"htc\\/exodugl_00709\\/htc_exodugl:8.0.0\\/OPR1.170623.032\\/1091479.2:user\\/release-keys\",\n      \"hardware\": \"htc_exo\",\n      \"host\": \"ABM124\",\n      \"id\": \"OPR1.170623.032\",\n      \"manufacturer\": \"HTC\",\n      \"model\": \"EXODUS 1\",\n      \"product\": \"exodugl_00709\",\n      \"supportedAbis\": [\n        \"arm64-v8a\",\n        \"armeabi-v7a\",\n        \"armeabi\"\n      ],\n      \"tags\": \"release-keys\",\n      \"buildTime\": 1568020752000,\n      \"type\": \"user\",\n      \"user\": \"buildteam\"\n    }\n  },\n  \"localeInfo\": {\n    \"value\": {\n      \"country\": \"United States\",\n      \"variant\": \"\",\n      \"language\": \"English\",\n      \"script\": \"\",\n      \"name\": \"English (United States)\"\n    }\n  },\n  \"locationInfo\": {\n    \"value\": {\n      \"lastKnown\": {\n        \"value\": {\n          \"accuracy\": 29.555,\n          \"altitude\": 26.30000114440918,\n          \"bearing\": 311.93915,\n          \"bearingAccuracyDegrees\": {\n            \"value\": 0\n          },\n          \"latitude\": 25.0360848,\n          \"longitude\": 121.5579271,\n          \"provider\": \"fused\",\n          \"speed\": 0.25277704,\n          \"speedAccuracyMetersPerSecond\": {\n            \"value\": 0\n          },\n          \"time\": 1574835188000,\n          \"verticalAccuracyMeters\": {\n            \"value\": 2\n          },\n          \"isFromMockProvider\": false,\n          \"address\": {\n            \"value\": \"No. 4, Alley 2, Lane 421, Guangfu South Road, Xinyi District, Taipei City, Taiwan 110\"\n          }\n        }\n      },\n      \"current\": {\n        \"value\": {\n          \"accuracy\": 28.397,\n          \"altitude\": 0,\n          \"bearing\": 0,\n          \"bearingAccuracyDegrees\": {\n            \"value\": 0\n          },\n          \"latitude\": 25.0360477,\n          \"longitude\": 121.5578969,\n          \"provider\": \"fused\",\n          \"speed\": 0,\n          \"speedAccuracyMetersPerSecond\": {\n            \"value\": 0\n          },\n          \"time\": 1574839387381,\n          \"verticalAccuracyMeters\": {\n            \"value\": 0\n          },\n          \"isFromMockProvider\": false,\n          \"address\": {\n            \"value\": \"No. 429-1, Guangfu South Road, Xinyi District, Taipei City, Taiwan 110\"\n          }\n        }\n      }\n    }\n  },\n  \"sensorInfo\": {\n    \"value\": {\n      \"accelerometer\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            0.07664102,\n            0.019160256,\n            9.869992\n          ]\n        }\n      },\n      \"accelerometerUncalibrated\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"ambientTemperature\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"gameRotationVector\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            -6.35922E-4,\n            -0.0055800546,\n            -0.011479687,\n            0.9999163\n          ]\n        }\n      },\n      \"geomagneticRotationVector\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            0.0042034322,\n            -0.0044389903,\n            0.790616,\n            0.6122892,\n            0\n          ]\n        }\n      },\n      \"gravity\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            0.110811785,\n            -0.011867724,\n            9.80597\n          ]\n        }\n      },\n      \"gyroscope\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            0.0050228126,\n            0.0011342609,\n            0.004654825\n          ]\n        }\n      },\n      \"gyroscopeUncalibrated\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            -0.002434015,\n            0.0032647562,\n            -0.0012041484,\n            0,\n            0,\n            0\n          ]\n        }\n      },\n      \"heartBeat\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"heartRate\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"light\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            57.494713,\n            0,\n            0\n          ]\n        }\n      },\n      \"linearAcceleration\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            0.018869782,\n            0.04401975,\n            -0.0033977134\n          ]\n        }\n      },\n      \"lowLatencyOffbodyDetect\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"magneticField\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            31.222242,\n            -8.883545,\n            -16.315708\n          ]\n        }\n      },\n      \"magneticFieldUncalibrated\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            68.02247,\n            -16.388193,\n            39.97906,\n            34.67578,\n            -7.337952,\n            57.103165\n          ]\n        }\n      },\n      \"motionDetect\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"pose6Dof\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"pressure\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"proximity\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            9,\n            9,\n            0\n          ]\n        }\n      },\n      \"relativeHumidity\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"rotationVector\": {\n        \"value\": {\n          \"accuracy\": {\n            \"value\": 3\n          },\n          \"value\": [\n            0.0041284566,\n            -0.004110455,\n            0.79066783,\n            0.612217,\n            0\n          ]\n        }\n      },\n      \"significantMotion\": {\n        \"nullReason\": \"NO_UPDATE_RECEIVED_DURING_SNAP\"\n      },\n      \"stationaryDetect\": {\n        \"nullReason\": \"UNSUPPORTED\"\n      },\n      \"stepCounter\": {\n        \"nullReason\": \"NO_UPDATE_RECEIVED_DURING_SNAP\"\n      },\n      \"stepDetector\": {\n        \"nullReason\": \"NO_UPDATE_RECEIVED_DURING_SNAP\"\n      }\n    }\n  },\n  \"settingsInfo\": {\n    \"value\": {\n      \"adbEnabled\": {\n        \"value\": \"1\"\n      },\n      \"airplaneModeOn\": {\n        \"value\": \"1\"\n      },\n      \"airplaneModeRadios\": {\n        \"value\": \"cell,bluetooth,wifi,nfc,wimax\"\n      },\n      \"autoTime\": {\n        \"value\": \"1\"\n      },\n      \"autoTimeZone\": {\n        \"value\": \"1\"\n      },\n      \"bluetoothOn\": {\n        \"value\": \"0\"\n      },\n      \"dataRoaming\": {\n        \"value\": \"0\"\n      },\n      \"developmentSettingsEnabled\": {\n        \"value\": \"1\"\n      },\n      \"deviceName\": {\n        \"value\": \"EXODUS 1\"\n      },\n      \"deviceProvisioned\": {\n        \"value\": \"1\"\n      },\n      \"httpProxy\": {\n        \"nullReason\": \"NOT_FOUND\"\n      },\n      \"modeRinger\": {\n        \"value\": \"1\"\n      },\n      \"wifiOn\": {\n        \"value\": \"2\"\n      },\n      \"androidIdHash\": {\n        \"value\": \"2b9b17c05c6779ef55da84df30af7e38b42f206ed7258cb49d5168089f0e4c4a\"\n      }\n    }\n  }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnumbersprotocol%2Fandroid-info-snapshot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnumbersprotocol%2Fandroid-info-snapshot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnumbersprotocol%2Fandroid-info-snapshot/lists"}