{"id":15025242,"url":"https://github.com/jaredrummler/androiddevicenames","last_synced_at":"2025-04-15T03:51:57.267Z","repository":{"id":45996060,"uuid":"43323326","full_name":"jaredrummler/AndroidDeviceNames","owner":"jaredrummler","description":"A small Android library to get the market name of an Android device.","archived":false,"fork":false,"pushed_at":"2022-12-06T15:29:43.000Z","size":20627,"stargazers_count":1394,"open_issues_count":28,"forks_count":183,"subscribers_count":57,"default_branch":"master","last_synced_at":"2025-04-15T03:51:53.061Z","etag":null,"topics":["android","android-device","android-library","device-detection"],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jaredrummler.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-09-28T19:50:36.000Z","updated_at":"2025-04-12T20:51:06.000Z","dependencies_parsed_at":"2023-01-24T02:31:19.074Z","dependency_job_id":null,"html_url":"https://github.com/jaredrummler/AndroidDeviceNames","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jaredrummler%2FAndroidDeviceNames","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jaredrummler%2FAndroidDeviceNames/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jaredrummler%2FAndroidDeviceNames/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jaredrummler%2FAndroidDeviceNames/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jaredrummler","download_url":"https://codeload.github.com/jaredrummler/AndroidDeviceNames/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249003954,"owners_count":21196794,"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":["android","android-device","android-library","device-detection"],"created_at":"2024-09-24T20:01:52.574Z","updated_at":"2025-04-15T03:51:57.243Z","avatar_url":"https://github.com/jaredrummler.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Android Device Names\n\n[![Maven Central](https://maven-badges.herokuapp.com/maven-central/com.jaredrummler/android-device-names/badge.svg)](https://maven-badges.herokuapp.com/maven-central/com.jaredrummler/android-device-names) [![License](http://img.shields.io/:license-apache-blue.svg)](LICENSE.txt) [![API](https://img.shields.io/badge/API-7%2B-blue.svg?style=flat)](https://android-arsenal.com/api?level=7) \u003ca href=\"http://www.methodscount.com/?lib=com.jaredrummler%3Aandroid-device-names%3A2.1.1\" target=\"_blank\"\u003e\u003cimg src=\"https://img.shields.io/badge/method count-86-e91e63.svg\"\u003e\u003c/img\u003e\u003c/a\u003e \u003ca href=\"http://www.methodscount.com/?lib=com.jaredrummler%3Aandroid-device-names%3A2.1.1\" target=\"_blank\"\u003e\u003cimg src=\"https://img.shields.io/badge/size-34 KB-e91e63.svg\"\u003e\u003c/img\u003e\u003c/a\u003e [![Twitter Follow](https://img.shields.io/twitter/follow/jaredrummler.svg?style=social)](https://twitter.com/jaredrummler)\n\nA small Android library to get the market name of an Android device.\n\nOn many popular devices the market name of the device is not available. For example, on the Samsung Galaxy S7 the value of [`Build.MODEL`](http://developer.android.com/reference/android/os/Build.html#MODEL) could be `\"SAMSUNG-SM-G930A\"`, `\"SM-G930F\"`, `\"SM-G930K\"`, `\"SM-G930L\"`, etc.\n\nThis small library gets the market (consumer friendly) name of a device.\n\nUsage\n-----\n\n**Setup the library**\n\n```java\nDeviceName.init(this);\n```\n\n**Get the name of the current device:**\n\n```java\nString deviceName = DeviceName.getDeviceName();\n```\n\nThe above code will get the correct device name for the top 600 Android devices. If the device is unrecognized, then [`Build.MODEL`](http://developer.android.com/reference/android/os/Build.html#MODEL) is returned. This can be executed from the UI thread.\n\n**Get the name of a device using the device's codename:**\n\n```java\n// Returns \"Moto X Style\"\nDeviceName.getDeviceName(\"clark\", \"Unknown device\");\n```\n\n**Get information about the device:**\n\n```java\nDeviceName.with(context).request(new DeviceName.Callback() {\n\n  @Override public void onFinished(DeviceName.DeviceInfo info, Exception error) {\n    String manufacturer = info.manufacturer;  // \"Samsung\"\n    String name = info.marketName;            // \"Galaxy S8+\"\n    String model = info.model;                // \"SM-G955W\"\n    String codename = info.codename;          // \"dream2qltecan\"\n    String deviceName = info.getName();       // \"Galaxy S8+\"\n    // FYI: We are on the UI thread.\n  }\n});\n ```\n\nThe above code queries a database included in the library based on [Google's maintained list\n](https://support.google.com/googleplay/answer/1727131?hl=en). This supports *over 27,000* devices.\n\nDownload\n--------\n\nDownload [the latest AAR](https://repo1.maven.org/maven2/com/jaredrummler/android-device-names/2.1.1/android-device-names-2.1.1.aar) or grab via Gradle:\n\n```groovy\nimplementation('com.jaredrummler:android-device-names:2.1.1') \n```\n\n\nLicense\n--------\n\n    Copyright (C) 2015 Jared Rummler\n\n    Licensed under the Apache License, Version 2.0 (the \"License\");\n    you may not use this file except in compliance with the License.\n    You may obtain a copy of the License at\n\n       http://www.apache.org/licenses/LICENSE-2.0\n\n    Unless required by applicable law or agreed to in writing, software\n    distributed under the License is distributed on an \"AS IS\" BASIS,\n    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n    See the License for the specific language governing permissions and\n    limitations under the License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjaredrummler%2Fandroiddevicenames","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjaredrummler%2Fandroiddevicenames","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjaredrummler%2Fandroiddevicenames/lists"}