{"_id":"@capawesome/capacitor-device-info","_rev":"4-d7fc841b51c0fff1e00788ee63315803","name":"@capawesome/capacitor-device-info","dist-tags":{"latest":"0.1.2"},"versions":{"0.0.1":{"name":"@capawesome/capacitor-device-info","version":"0.0.1","keywords":["capacitor","plugin","native"],"author":{"name":"Robin Genz","email":"mail@robingenz.dev"},"license":"MIT","_id":"@capawesome/capacitor-device-info@0.0.1","maintainers":[{"name":"robingenz","email":"mail@robingenz.dev"}],"homepage":"https://capawesome.io/docs/sdks/capacitor/device-info/","bugs":{"url":"https://github.com/capawesome-team/capacitor-plugins/issues"},"dist":{"shasum":"17b8c982ae51263c00572c0600700aaedd6a6880","tarball":"https://registry.npmjs.org/@capawesome/capacitor-device-info/-/capacitor-device-info-0.0.1.tgz","fileCount":38,"integrity":"sha512-Aw7FUC5MFowViNvl/apU2UIbC8qevMe06eQ/Pqt/jhNZyYwT0cj3ajoVFj3mLKIzPHcklzn15QGDDR9+/ddh9w==","signatures":[{"sig":"MEYCIQC3LpqOsbf6h5A9nd9bBjutwPmJAsJhcSuB/WsYoOdlDgIhAK5aqFGBNp+OYpBUYa9FntB6loV1+o1cD81a6pQQNfex","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":106998},"main":"dist/plugin.cjs.js","types":"dist/esm/index.d.ts","unpkg":"dist/plugin.js","module":"dist/esm/index.js","funding":[{"url":"https://github.com/sponsors/capawesome-team/","type":"github"},{"url":"https://opencollective.com/capawesome","type":"opencollective"}],"gitHead":"e18228f8362b044cd453aba542fe8e0a02fd996f","scripts":{"fmt":"npm run eslint -- --fix && npm run prettier -- --write && npm run swiftlint -- --fix --format","lint":"npm run eslint && npm run prettier -- --check && npm run swiftlint -- lint","build":"npm run clean && npm run docgen && tsc && rollup -c rollup.config.mjs","clean":"rimraf ./dist","watch":"tsc --watch","docgen":"docgen --api DeviceInfoPlugin --output-readme README.md --output-json dist/docs.json","eslint":"eslint . --ext ts","verify":"npm run verify:ios && npm run verify:android && npm run verify:web","prettier":"prettier \"**/*.{css,html,ts,js,java}\"","swiftlint":"node-swiftlint","verify:ios":"cd ios && pod install && xcodebuild -workspace Plugin.xcworkspace -scheme Plugin -destination generic/platform=iOS && cd ..","verify:web":"npm run build","prepublishOnly":"npm run build","verify:android":"cd android && ./gradlew clean build test && cd ..","ios:pod:install":"cd ios && pod install --repo-update && cd ..","ios:spm:install":"cd ios && swift package resolve && cd .."},"_npmUser":{"name":"robingenz","email":"mail@robingenz.dev"},"capacitor":{"ios":{"src":"ios"},"android":{"src":"android"}},"repository":{"url":"git+https://github.com/capawesome-team/capacitor-plugins.git","type":"git"},"_npmVersion":"11.13.0","description":"Capacitor plugin to read device information.","directories":{},"_nodeVersion":"24.16.0","eslintConfig":{"extends":"@ionic/eslint-config/recommended"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"8.57.0","rimraf":"6.1.2","rollup":"4.53.3","swiftlint":"2.0.0","typescript":"5.9.3","@capacitor/cli":"8.0.0","@capacitor/ios":"8.0.0","@capacitor/core":"8.0.0","@capacitor/docgen":"0.3.1","@capacitor/android":"8.0.0","@ionic/eslint-config":"0.4.0","prettier-plugin-java":"2.6.7"},"peerDependencies":{"@capacitor/core":">=8.0.0"},"_npmOperationalInternal":{"tmp":"tmp/capacitor-device-info_0.0.1_1783426815920_0.30719595229879193","host":"s3://npm-registry-packages-npm-production"}},"0.1.0":{"name":"@capawesome/capacitor-device-info","version":"0.1.0","keywords":["capacitor","plugin","native","capacitor-plugin","device info","device information","device model","device identifier","operating system version","device type","memory usage"],"author":{"name":"Robin Genz","email":"mail@robingenz.dev"},"license":"MIT","_id":"@capawesome/capacitor-device-info@0.1.0","maintainers":[{"name":"robingenz","email":"mail@robingenz.dev"}],"homepage":"https://capawesome.io/docs/sdks/capacitor/device-info/","bugs":{"url":"https://github.com/capawesome-team/capacitor-plugins/issues"},"dist":{"shasum":"9530daf6151880f3a04b5108ba6abf7c56d585b9","tarball":"https://registry.npmjs.org/@capawesome/capacitor-device-info/-/capacitor-device-info-0.1.0.tgz","fileCount":38,"integrity":"sha512-oBxf0S6PKvDMwT64m9uMKuYWNGjEjoo08qqQKBbWuvdk8RhK2RI89JVk4xpuPr0GE81YUlcp3BuhPJJ+4g6GWQ==","signatures":[{"sig":"MEUCIQCqdfP7piYw/ggFiKEfcSAyFuUexvR5SeLrjIrG8vkJMQIgKfaE6ltl6x7Pni/RneHYYOtF8JKii9m5MUa66JUX8DU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@capawesome%2fcapacitor-device-info@0.1.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":112120},"main":"dist/plugin.cjs.js","types":"dist/esm/index.d.ts","unpkg":"dist/plugin.js","module":"dist/esm/index.js","funding":[{"url":"https://github.com/sponsors/capawesome-team/","type":"github"},{"url":"https://opencollective.com/capawesome","type":"opencollective"}],"gitHead":"1ce17b1fd14c43b2f1d5d3c2da82221e1d1dca37","scripts":{"fmt":"npm run eslint -- --fix && npm run prettier -- --write && npm run swiftlint -- --fix --format","lint":"npm run eslint && npm run prettier -- --check && npm run swiftlint -- lint","build":"npm run clean && npm run docgen && tsc && rollup -c rollup.config.mjs","clean":"rimraf ./dist","watch":"tsc --watch","docgen":"docgen --api DeviceInfoPlugin --output-readme README.md --output-json dist/docs.json","eslint":"eslint . --ext ts","verify":"npm run verify:ios && npm run verify:android && npm run verify:web","prettier":"prettier \"**/*.{css,html,ts,js,java}\"","swiftlint":"node-swiftlint","verify:ios":"cd ios && pod install && xcodebuild -workspace Plugin.xcworkspace -scheme Plugin -destination generic/platform=iOS && cd ..","verify:web":"npm run build","prepublishOnly":"npm run build","verify:android":"cd android && ./gradlew clean build test && cd ..","ios:pod:install":"cd ios && pod install --repo-update && cd ..","ios:spm:install":"cd ios && swift package resolve && cd .."},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1d8dc3e0-6d19-411b-92bb-db8a3ce32d33"}},"capacitor":{"ios":{"src":"ios"},"android":{"src":"android"}},"repository":{"url":"git+https://github.com/capawesome-team/capacitor-plugins.git","type":"git"},"_npmVersion":"11.16.0","description":"Capacitor plugin to read device information on Android, iOS, and Web.","directories":{},"_nodeVersion":"24.18.0","eslintConfig":{"extends":"@ionic/eslint-config/recommended"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"8.57.0","rimraf":"6.1.2","rollup":"4.53.3","swiftlint":"2.0.0","typescript":"5.9.3","@capacitor/cli":"8.0.0","@capacitor/ios":"8.0.0","@capacitor/core":"8.0.0","@capacitor/docgen":"0.3.1","@capacitor/android":"8.0.0","@ionic/eslint-config":"0.4.0","prettier-plugin-java":"2.6.7"},"peerDependencies":{"@capacitor/core":">=8.0.0"},"_npmOperationalInternal":{"tmp":"tmp/capacitor-device-info_0.1.0_1784015518625_0.06811982600218025","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"name":"@capawesome/capacitor-device-info","version":"0.1.1","keywords":["capacitor","plugin","native","capacitor-plugin","device info","device information","device model","device identifier","operating system version","device type","memory usage"],"author":{"name":"Robin Genz","email":"mail@robingenz.dev"},"license":"MIT","_id":"@capawesome/capacitor-device-info@0.1.1","maintainers":[{"name":"robingenz","email":"mail@robingenz.dev"}],"homepage":"https://capawesome.io/docs/sdks/capacitor/device-info/","bugs":{"url":"https://github.com/capawesome-team/capacitor-plugins/issues"},"dist":{"shasum":"d315ab254cb4819f529da4fc3ca06cebae8a1864","tarball":"https://registry.npmjs.org/@capawesome/capacitor-device-info/-/capacitor-device-info-0.1.1.tgz","fileCount":38,"integrity":"sha512-DLoTZl/RHNTpxkuuqwhuq4lj+hCv3KqJZI5J+bG+livp3Rou2TdsI/SwNVCA+9ajY8/v5Zdd2YSRvdndbT/M8A==","signatures":[{"sig":"MEUCIAW/QVZdjWmu0G1ZhGNXwf3DWgktRDcxyk5cNoI6x/xxAiEArLFI38UYmjaMIZCbooaGSuzxPlgfNtiLOHrxoEX/Puw=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@capawesome%2fcapacitor-device-info@0.1.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":112129},"main":"dist/plugin.cjs.js","types":"dist/esm/index.d.ts","unpkg":"dist/plugin.js","module":"dist/esm/index.js","funding":[{"url":"https://github.com/sponsors/capawesome-team/","type":"github"},{"url":"https://opencollective.com/capawesome","type":"opencollective"}],"gitHead":"3e61f4b412f9f3f512c21169bb135bbb23a67e6d","scripts":{"fmt":"npm run eslint -- --fix && npm run prettier -- --write && npm run swiftlint -- --fix --format","lint":"npm run eslint && npm run prettier -- --check && npm run swiftlint -- lint","build":"npm run clean && npm run docgen && tsc && rollup -c rollup.config.mjs","clean":"rimraf ./dist","watch":"tsc --watch","docgen":"docgen --api DeviceInfoPlugin --output-readme README.md --output-json dist/docs.json","eslint":"eslint . --ext ts","verify":"npm run verify:ios && npm run verify:android && npm run verify:web","prettier":"prettier \"**/*.{css,html,ts,js,java}\"","swiftlint":"node-swiftlint","verify:ios":"cd ios && pod install && xcodebuild -workspace Plugin.xcworkspace -scheme Plugin -destination generic/platform=iOS && cd ..","verify:web":"npm run build","prepublishOnly":"npm run build","verify:android":"cd android && ./gradlew clean build test && cd ..","ios:pod:install":"cd ios && pod install --repo-update && cd ..","ios:spm:install":"cd ios && swift package resolve && cd .."},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1d8dc3e0-6d19-411b-92bb-db8a3ce32d33"}},"capacitor":{"ios":{"src":"ios"},"android":{"src":"android"}},"repository":{"url":"git+https://github.com/capawesome-team/capacitor-plugins.git","type":"git"},"_npmVersion":"11.16.0","description":"Capacitor plugin to read device information on Android, iOS, and Web.","directories":{},"_nodeVersion":"24.18.0","eslintConfig":{"extends":"@ionic/eslint-config/recommended"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"8.57.0","rimraf":"6.1.2","rollup":"4.53.3","swiftlint":"2.0.0","typescript":"5.9.3","@capacitor/cli":"8.0.0","@capacitor/ios":"8.0.0","@capacitor/core":"8.0.0","@capacitor/docgen":"0.3.1","@capacitor/android":"8.0.0","@ionic/eslint-config":"0.4.0","prettier-plugin-java":"2.6.7"},"peerDependencies":{"@capacitor/core":">=8.0.0"},"_npmOperationalInternal":{"tmp":"tmp/capacitor-device-info_0.1.1_1784102971198_0.6539995042596971","host":"s3://npm-registry-packages-npm-production"}},"0.1.2":{"name":"@capawesome/capacitor-device-info","version":"0.1.2","description":"Capacitor plugin to read device information on Android, iOS, and Web.","main":"dist/plugin.cjs.js","module":"dist/esm/index.js","types":"dist/esm/index.d.ts","unpkg":"dist/plugin.js","author":{"name":"Robin Genz","email":"mail@robingenz.dev"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/capawesome-team/capacitor-plugins.git"},"bugs":{"url":"https://github.com/capawesome-team/capacitor-plugins/issues"},"funding":[{"type":"github","url":"https://github.com/sponsors/capawesome-team/"},{"type":"opencollective","url":"https://opencollective.com/capawesome"}],"homepage":"https://capawesome.io/docs/sdks/capacitor/device-info/","keywords":["capacitor","plugin","native","capacitor-plugin","device info","device information","device model","device identifier","operating system version","device type","memory usage"],"scripts":{"verify":"npm run verify:ios && npm run verify:android && npm run verify:web","verify:ios":"cd ios && pod install && xcodebuild -workspace Plugin.xcworkspace -scheme Plugin -destination generic/platform=iOS && cd ..","verify:android":"cd android && ./gradlew clean build test && cd ..","verify:web":"npm run build","lint":"npm run eslint && npm run prettier -- --check && npm run swiftlint -- lint","fmt":"npm run eslint -- --fix && npm run prettier -- --write && npm run swiftlint -- --fix --format","eslint":"eslint . --ext ts","prettier":"prettier \"**/*.{css,html,ts,js,java}\"","swiftlint":"node-swiftlint","docgen":"docgen --api DeviceInfoPlugin --output-readme README.md --output-json dist/docs.json","build":"npm run clean && npm run docgen && tsc && rollup -c rollup.config.mjs","clean":"rimraf ./dist","watch":"tsc --watch","ios:pod:install":"cd ios && pod install --repo-update && cd ..","ios:spm:install":"cd ios && swift package resolve && cd ..","prepublishOnly":"npm run build"},"devDependencies":{"@capacitor/android":"8.0.0","@capacitor/cli":"8.4.2","@capacitor/core":"8.0.0","@capacitor/docgen":"0.3.1","@capacitor/ios":"8.0.0","@ionic/eslint-config":"0.4.0","eslint":"8.57.0","prettier-plugin-java":"2.9.7","rimraf":"6.1.2","rollup":"4.62.3","swiftlint":"2.0.0","typescript":"5.9.3"},"peerDependencies":{"@capacitor/core":">=8.0.0"},"eslintConfig":{"extends":"@ionic/eslint-config/recommended"},"capacitor":{"ios":{"src":"ios"},"android":{"src":"android"}},"publishConfig":{"access":"public"},"gitHead":"7c1937ed10b7de86ca2c1cdc3539a2735fd69a00","_id":"@capawesome/capacitor-device-info@0.1.2","_nodeVersion":"24.19.0","_npmVersion":"11.17.0","dist":{"integrity":"sha512-Z/OhleW4Bonkkj63B7N86pHFHB8m7Beau8oaON6keQoBacj9xg32+bfqXIFV1LjFbupthcisJ/8wfXf5AKstFA==","shasum":"12a50c980914e82a9a2c5310829511966a0ed5e4","tarball":"https://registry.npmjs.org/@capawesome/capacitor-device-info/-/capacitor-device-info-0.1.2.tgz","fileCount":38,"unpackedSize":111979,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@capawesome%2fcapacitor-device-info@0.1.2","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCe9VeRmV3DeQ8Vc9nIPXIwMoUrlDubRZX4/Ga4cf16WwIhAOVTWilVql0Q0GhIeVekwW4vy4xDc5OKAjnk7CbbCwmO"}]},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1d8dc3e0-6d19-411b-92bb-db8a3ce32d33"}},"directories":{},"maintainers":[{"name":"robingenz","email":"mail@robingenz.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/capacitor-device-info_0.1.2_1788337331823_0.8028401640861469"},"_hasShrinkwrap":false}},"time":{"created":"2026-07-07T12:20:15.748Z","modified":"2026-09-02T08:22:12.426Z","0.0.1":"2026-07-07T12:20:16.054Z","0.1.0":"2026-07-14T07:51:58.780Z","0.1.1":"2026-07-15T08:09:31.331Z","0.1.2":"2026-09-02T08:22:11.962Z"},"bugs":{"url":"https://github.com/capawesome-team/capacitor-plugins/issues"},"author":{"name":"Robin Genz","email":"mail@robingenz.dev"},"license":"MIT","homepage":"https://capawesome.io/docs/sdks/capacitor/device-info/","keywords":["capacitor","plugin","native","capacitor-plugin","device info","device information","device model","device identifier","operating system version","device type","memory usage"],"repository":{"type":"git","url":"git+https://github.com/capawesome-team/capacitor-plugins.git"},"description":"Capacitor plugin to read device information on Android, iOS, and Web.","maintainers":[{"name":"robingenz","email":"mail@robingenz.dev"}],"readme":"# Capacitor Device Info Plugin\n\nCapacitor plugin to read device information, such as the model, manufacturer, operating system, memory, and a per-install identifier.\n\n<div class=\"capawesome-z29o10a\">\n  <a href=\"https://cloud.capawesome.io/\" target=\"_blank\">\n    <img alt=\"Deliver Live Updates to your Capacitor app with Capawesome Cloud\" src=\"https://cloud.capawesome.io/assets/banners/cloud-build-and-deploy-capacitor-apps.png?t=1\" />\n  </a>\n</div>\n\n## Features\n\n- 🆔 **Identifier**: Read a unique per-install identifier for the device.\n- 📱 **Information**: Read the model, manufacturer, operating system, and more.\n- 🧠 **Memory**: Read the total memory of the device and the memory used by the app.\n- ⏱️ **Uptime**: Read how long the device has been running since its last boot.\n- 🖥️ **Cross-platform**: Support for Android, iOS, and Web.\n- 🤝 **Compatibility**: Works alongside the [Battery](https://capawesome.io/docs/sdks/capacitor/battery/) and [Localization](https://capawesome.io/docs/sdks/capacitor/localization/) plugins.\n- 📦 **CocoaPods & SPM**: Supports CocoaPods and Swift Package Manager for iOS.\n- 🔁 **Up-to-date**: Always supports the latest Capacitor version.\n\nMissing a feature? Just [open an issue](https://github.com/capawesome-team/capacitor-plugins/issues) and we'll take a look!\n\n## Use Cases\n\nThe Device Info plugin is typically used whenever an app needs to know more about the device it is running on, for example:\n\n- **Bug reports and support**: Attach the device model, manufacturer, operating system version, and WebView version to support tickets or crash reports.\n- **Device registration**: Use the per-install identifier to register a device on your backend without collecting personal data.\n- **Adaptive user interfaces**: Adjust your layout based on the device type, for example phone versus tablet.\n- **Feature gating**: Enable or disable features depending on the Android SDK version or the major iOS version.\n- **Diagnostics**: Monitor the memory used by your app or detect whether it is running on an emulator or simulator.\n\n## Compatibility\n\n| Plugin Version | Capacitor Version | Status         |\n| -------------- | ----------------- | -------------- |\n| 0.x.x          | >=8.x.x           | Active support |\n\n## Installation\n\nYou can use our **AI-Assisted Setup** to install the plugin.\nAdd the [Capawesome Skills](https://github.com/capawesome-team/skills) to your AI tool using the following command:\n\n```bash\nnpx skills add capawesome-team/skills --skill capacitor-plugins\n```\n\nThen use the following prompt:\n\n```\n Use the `capacitor-plugins` skill from `capawesome-team/skills` to install the `@capawesome/capacitor-device-info` plugin in my project.\n```\n\nIf you prefer **Manual Setup**, install the plugin by running the following commands and follow the platform-specific instructions below:\n\n```bash\nnpm install @capawesome/capacitor-device-info\nnpx cap sync\n```\n\nNo additional permissions or configuration are required on any platform.\n\n## Configuration\n\nNo configuration required for this plugin.\n\n## Usage\n\nThe following examples show how to read the device identifier, read device information, and read the device uptime.\n\n### Read the device identifier\n\nGet a unique per-install identifier for the device, for example to register the device on your backend. See the [API documentation](#getid) for when the identifier is reset on each platform:\n\n```typescript\nimport { DeviceInfo } from '@capawesome/capacitor-device-info';\n\nconst getId = async () => {\n  const { identifier } = await DeviceInfo.getId();\n  return identifier;\n};\n```\n\n### Read device information\n\nGet information about the device, such as the model, manufacturer, operating system, device type, and memory. Fields that a platform cannot determine are `null` (see [Platform Support](#platform-support)):\n\n```typescript\nimport { DeviceInfo } from '@capawesome/capacitor-device-info';\n\nconst getInfo = async () => {\n  const info = await DeviceInfo.getInfo();\n  return info;\n};\n```\n\n### Read the device uptime\n\nGet the time the device has been running since its last boot, in milliseconds. Only available on Android and iOS:\n\n```typescript\nimport { DeviceInfo } from '@capawesome/capacitor-device-info';\n\nconst getUptime = async () => {\n  const { uptime } = await DeviceInfo.getUptime();\n  return uptime;\n};\n```\n\n## API\n\n<docgen-index>\n\n* [`getId()`](#getid)\n* [`getInfo()`](#getinfo)\n* [`getUptime()`](#getuptime)\n* [Interfaces](#interfaces)\n* [Type Aliases](#type-aliases)\n\n</docgen-index>\n\n<docgen-api>\n<!--Update the source file JSDoc comments and rerun docgen to update the docs below-->\n\n### getId()\n\n```typescript\ngetId() => Promise<GetIdResult>\n```\n\nGet a unique identifier for the device.\n\nOn **Android**, the identifier is the `ANDROID_ID` value, which is unique\nper app-signing key, user, and device. It is reset when the app is\nreinstalled after the signing key changes or the device is factory reset.\n\nOn **iOS**, the identifier is the `identifierForVendor` value, which is\nunique per vendor and device. It is reset when all apps from the vendor are\nuninstalled.\n\nOn **Web**, the identifier is a random UUID that is persisted in the\nbrowser's `localStorage`. It is reset when the browser storage is cleared.\n\n**Returns:** <code>Promise&lt;<a href=\"#getidresult\">GetIdResult</a>&gt;</code>\n\n**Since:** 0.1.0\n\n--------------------\n\n\n### getInfo()\n\n```typescript\ngetInfo() => Promise<GetInfoResult>\n```\n\nGet information about the device.\n\n**Returns:** <code>Promise&lt;<a href=\"#getinforesult\">GetInfoResult</a>&gt;</code>\n\n**Since:** 0.1.0\n\n--------------------\n\n\n### getUptime()\n\n```typescript\ngetUptime() => Promise<GetUptimeResult>\n```\n\nGet the time the device has been running since its last boot, in\nmilliseconds.\n\nOnly available on Android and iOS.\n\n**Returns:** <code>Promise&lt;<a href=\"#getuptimeresult\">GetUptimeResult</a>&gt;</code>\n\n**Since:** 0.1.0\n\n--------------------\n\n\n### Interfaces\n\n\n#### GetIdResult\n\n| Prop             | Type                | Description                          | Since |\n| ---------------- | ------------------- | ------------------------------------ | ----- |\n| **`identifier`** | <code>string</code> | The unique identifier of the device. | 0.1.0 |\n\n\n#### GetInfoResult\n\n| Prop                    | Type                                                        | Description                                                                                                                                                                                                         | Since |\n| ----------------------- | ----------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----- |\n| **`androidSdkVersion`** | <code>number \\| null</code>                                 | The Android SDK version number (API level). Returns `null` on platforms other than Android. Only available on Android.                                                                                              | 0.1.0 |\n| **`deviceType`**        | <code><a href=\"#devicetype\">DeviceType</a></code>           | The type of the device.                                                                                                                                                                                             | 0.1.0 |\n| **`iosVersion`**        | <code>number \\| null</code>                                 | The major version number of iOS. Returns `null` on platforms other than iOS. Only available on iOS.                                                                                                                 | 0.1.0 |\n| **`isVirtual`**         | <code>boolean</code>                                        | Whether the app is running on a virtual device (simulator or emulator).                                                                                                                                             | 0.1.0 |\n| **`manufacturer`**      | <code>string</code>                                         | The manufacturer of the device.                                                                                                                                                                                     | 0.1.0 |\n| **`model`**             | <code>string</code>                                         | The model identifier of the device. On **iOS**, this is the internal model identifier (e.g. `iPhone13,4`), not the marketing name.                                                                                  | 0.1.0 |\n| **`name`**              | <code>string \\| null</code>                                 | The name of the device. On **iOS 16 and newer**, a generic device name (e.g. `iPhone`) is returned unless the app has the required entitlement. Returns `null` if the name cannot be determined.                    | 0.1.0 |\n| **`operatingSystem`**   | <code><a href=\"#operatingsystem\">OperatingSystem</a></code> | The operating system of the device.                                                                                                                                                                                 | 0.1.0 |\n| **`osVersion`**         | <code>string</code>                                         | The version of the operating system.                                                                                                                                                                                | 0.1.0 |\n| **`platform`**          | <code><a href=\"#platform\">Platform</a></code>               | The platform the app is running on.                                                                                                                                                                                 | 0.1.0 |\n| **`totalMemory`**       | <code>number \\| null</code>                                 | The total amount of memory of the device, in bytes. Returns `null` if the total memory cannot be determined. Only available on Android and iOS.                                                                     | 0.1.0 |\n| **`usedMemory`**        | <code>number \\| null</code>                                 | The amount of memory used by the app, in bytes. Returns `null` if the used memory cannot be determined. Only available on Android and iOS.                                                                          | 0.1.0 |\n| **`webViewVersion`**    | <code>string \\| null</code>                                 | The version of the WebView that renders the app. On **iOS**, the version of the operating system is returned, because the WebKit version is tied to it. Returns `null` if the WebView version cannot be determined. | 0.1.0 |\n\n\n#### GetUptimeResult\n\n| Prop         | Type                | Description                                                                | Since |\n| ------------ | ------------------- | -------------------------------------------------------------------------- | ----- |\n| **`uptime`** | <code>number</code> | The time the device has been running since its last boot, in milliseconds. | 0.1.0 |\n\n\n### Type Aliases\n\n\n#### DeviceType\n\nThe type of a device.\n\n- `phone`: A handheld phone-sized device.\n- `tablet`: A tablet-sized device.\n- `desktop`: A desktop or laptop computer.\n- `tv`: A television or set-top box.\n- `unknown`: The type could not be determined.\n\n<code>'phone' | 'tablet' | 'desktop' | 'tv' | 'unknown'</code>\n\n\n#### OperatingSystem\n\nThe operating system of a device.\n\n<code>'android' | 'ios' | 'windows' | 'mac' | 'unknown'</code>\n\n\n#### Platform\n\nThe platform an app is running on.\n\n<code>'android' | 'ios' | 'web'</code>\n\n</docgen-api>\n\n## Platform Support\n\nThe plugin returns `null` for any field that a platform cannot determine. The following table shows which fields of the `getInfo()` result are available on each platform:\n\n| Property            | Android | iOS | Web              |\n| ------------------- | ------- | --- | ---------------- |\n| `androidSdkVersion` | ✅      | ❌  | ❌               |\n| `deviceType`        | ✅      | ✅  | ✅ (best-effort) |\n| `iosVersion`        | ❌      | ✅  | ❌               |\n| `isVirtual`         | ✅      | ✅  | ✅               |\n| `manufacturer`      | ✅      | ✅  | ❌               |\n| `model`             | ✅      | ✅  | ✅ (best-effort) |\n| `name`              | ✅      | ✅  | ❌               |\n| `operatingSystem`   | ✅      | ✅  | ✅ (best-effort) |\n| `osVersion`         | ✅      | ✅  | ✅ (best-effort) |\n| `platform`          | ✅      | ✅  | ✅               |\n| `totalMemory`       | ✅      | ✅  | ❌               |\n| `usedMemory`        | ✅      | ✅  | ❌               |\n| `webViewVersion`    | ✅      | ✅  | ✅ (best-effort) |\n\nThe `getUptime()` method is only available on Android and iOS.\n\n## Migration from `@capacitor/device`\n\nThis plugin can be used as a replacement for the official [`@capacitor/device`](https://capacitorjs.com/docs/apis/device) plugin. The following table shows how the methods map:\n\n| `@capacitor/device` | `@capawesome/capacitor-device-info`                                                    |\n| ------------------- | -------------------------------------------------------------------------------------- |\n| `getId()`           | `getId()`                                                                              |\n| `getInfo()`         | `getInfo()`                                                                            |\n| `getBatteryInfo()`  | Use the [Battery](https://capawesome.io/docs/sdks/capacitor/battery/) plugin           |\n| `getLanguageCode()` | Use the [Localization](https://capawesome.io/docs/sdks/capacitor/localization/) plugin |\n| `getLanguageTag()`  | Use the [Localization](https://capawesome.io/docs/sdks/capacitor/localization/) plugin |\n\n## FAQ\n\n### How is this plugin different from other similar plugins?\n\nIt gathers a wide range of device details through one fully typed API — model, manufacturer, operating system, a per-install identifier, total and used memory, device type, virtual-device detection, WebView version, and uptime — with consistent behavior across Android, iOS, and the Web. Fields a platform cannot determine are returned as `null`, and the package is actively maintained against the latest Capacitor and OS versions. If you only need the platform name, a minimal setup is enough; if you want a complete, honest picture of the device, this plugin is built for exactly that.\n\n### How stable is the identifier returned by `getId`?\n\nThe identifier is unique per install. On Android, it is the `ANDROID_ID` value, which is reset when the app is reinstalled after the signing key changes or the device is factory reset. On iOS, it is the `identifierForVendor` value, which is reset when all apps from the vendor are uninstalled. On the Web, it is a random UUID persisted in the browser's `localStorage`, which is reset when the browser storage is cleared.\n\n### Can this plugin replace the official `@capacitor/device` plugin?\n\nYes, this plugin can be used as a replacement for the official `@capacitor/device` plugin. The `getId()` and `getInfo()` methods map directly, while battery information and language settings are covered by the [Battery](https://capawesome.io/docs/sdks/capacitor/battery/) and [Localization](https://capawesome.io/docs/sdks/capacitor/localization/) plugins. See the [migration table](#migration-from-capacitordevice) above.\n\n### Why is the device name always a generic value like `iPhone` on iOS?\n\nOn iOS 16 and newer, a generic device name is returned unless the app has the required entitlement from Apple. If the name cannot be determined at all, the `name` property is `null`.\n\n### Why are some fields `null` on my platform?\n\nThe plugin returns `null` for any field that a platform cannot determine. For example, `totalMemory` and `usedMemory` are only available on Android and iOS, and `androidSdkVersion` is only available on Android. See the [Platform Support](#platform-support) section for a complete overview.\n\n### Can I get the battery level or the device language with this plugin?\n\nNo, this plugin focuses on device information such as the model, manufacturer, operating system, and memory. For battery information, use the [Battery](https://capawesome.io/docs/sdks/capacitor/battery/) plugin. For the user's language and locale preferences, use the [Localization](https://capawesome.io/docs/sdks/capacitor/localization/) plugin.\n\n### Can I use this plugin with Ionic, React, Vue or Angular?\n\nYes, the plugin is framework-agnostic. It works in any Capacitor app regardless of the web framework, including Ionic with Angular, React, or Vue, as well as plain JavaScript projects.\n\n## Related Plugins\n\n- [Battery](https://capawesome.io/docs/sdks/capacitor/battery/): Access battery information.\n- [Localization](https://capawesome.io/docs/sdks/capacitor/localization/): Read the user's localization preferences, such as preferred locales and time zone.\n- [Network](https://capawesome.io/docs/sdks/capacitor/network/): Access network information.\n\n## Newsletter\n\nStay up to date with the latest news and updates about the Capawesome, Capacitor, and Ionic ecosystem by subscribing to our [Capawesome Newsletter](https://cloud.capawesome.io/newsletter/).\n\n## Changelog\n\nSee [CHANGELOG.md](https://github.com/capawesome-team/capacitor-plugins/blob/main/packages/device-info/CHANGELOG.md).\n\n## License\n\nSee [LICENSE](https://github.com/capawesome-team/capacitor-plugins/blob/main/packages/device-info/LICENSE).\n","readmeFilename":"README.md"}