{"_id":"@abrarmehraj/rn-foreground-service","_rev":"4-8ba89e3ad445b7db34da2eb65a8a6bb5","name":"@abrarmehraj/rn-foreground-service","dist-tags":{"latest":"2.2.9"},"versions":{"2.2.6":{"name":"@abrarmehraj/rn-foreground-service","version":"2.2.6","keywords":["react","react-native","android","foreground","service","background","maintained","fork"],"author":{"name":"Abrar Mehraj","email":"your-email@example.com"},"license":"MIT","_id":"@abrarmehraj/rn-foreground-service@2.2.6","maintainers":[{"name":"abrarmehraj","email":"darabrar@outlook.com"}],"homepage":"https://github.com/abrarmehraj/rn-foreground-service#readme","bugs":{"url":"https://github.com/abrarmehraj/rn-foreground-service/issues"},"dist":{"shasum":"e5f963890caa1d77aacffab1cdcd3f38c1f2907a","tarball":"https://registry.npmjs.org/@abrarmehraj/rn-foreground-service/-/rn-foreground-service-2.2.6.tgz","fileCount":17,"integrity":"sha512-pFmDZ7dp4oaF7qBkcL2TE82QByjXXXuIQcqLNoK7ds0yaR+Oyg3Y7AjPTBCLxM2t4r4j1FG5zjmkWEEDvWWqMw==","signatures":[{"sig":"MEQCIG9KJH4G9t3kWVsajueVmovJBTCI/L7wAkY5l3Izsn7FAiB4ifPv0FaCHfzN/ZsqOe8VyWB+oeECuXXHh/q84Ruw0g==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":66742},"main":"index.js","types":"./index.d.ts","gitHead":"e479502395bdce47985f82d55e2a0c3ec51b7fb6","scripts":{"test":"echo \"Error: no test specified\" && exit 1","postinstall":"node postinstall.js"},"_npmUser":{"name":"abrarmehraj","email":"darabrar@outlook.com"},"repository":{"url":"git+https://github.com/abrarmehraj/rn-foreground-service.git","type":"git"},"_npmVersion":"10.8.1","description":"A Foreground Service for React Native - Maintained fork of @supersami/rn-foreground-service","directories":{},"_nodeVersion":"22.4.1","dependencies":{},"_hasShrinkwrap":false,"peerDependencies":{"react-native":">=0.59.0"},"_npmOperationalInternal":{"tmp":"tmp/rn-foreground-service_2.2.6_1759895944805_0.6795118384345067","host":"s3://npm-registry-packages-npm-production"}},"2.2.7":{"name":"@abrarmehraj/rn-foreground-service","version":"2.2.7","keywords":["react","react-native","android","foreground","service","background","maintained","fork"],"author":{"name":"Abrar Mehraj"},"license":"MIT","_id":"@abrarmehraj/rn-foreground-service@2.2.7","maintainers":[{"name":"abrarmehraj","email":"darabrar@outlook.com"}],"homepage":"https://github.com/abrarmehraj/rn-foreground-service#readme","bugs":{"url":"https://github.com/abrarmehraj/rn-foreground-service/issues"},"dist":{"shasum":"a58f363100c18e1ef17da26b9d6d5d9b71779640","tarball":"https://registry.npmjs.org/@abrarmehraj/rn-foreground-service/-/rn-foreground-service-2.2.7.tgz","fileCount":17,"integrity":"sha512-4QO0mz3DlvFCnyG/gi2JMN56abXw0XWO3aXfbdayNzxSEaxZsKgwq5lKsU4oAewAlGGnapZgwJN0cJgg6nuFBg==","signatures":[{"sig":"MEUCIQDOG3iwqNvcCUvAKt0ib64phYtHl21lXO85ns8IZIBZOgIgRO/hB+wewv4G7UFpfc8V16c8voPfFeGm8T9Mf8cOXk8=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":66709},"main":"index.js","types":"./index.d.ts","gitHead":"da6acb48aab720bc2bff99040203d0f3e1ea65d7","scripts":{"test":"echo \"Error: no test specified\" && exit 1","postinstall":"node postinstall.js"},"_npmUser":{"name":"abrarmehraj","email":"darabrar@outlook.com"},"repository":{"url":"git+https://github.com/abrarmehraj/rn-foreground-service.git","type":"git"},"_npmVersion":"10.8.1","description":"A Foreground Service for React Native - Maintained fork of @supersami/rn-foreground-service","directories":{},"_nodeVersion":"22.4.1","dependencies":{},"_hasShrinkwrap":false,"peerDependencies":{"react-native":">=0.59.0"},"_npmOperationalInternal":{"tmp":"tmp/rn-foreground-service_2.2.7_1759896507506_0.489249670132232","host":"s3://npm-registry-packages-npm-production"}},"2.2.8":{"name":"@abrarmehraj/rn-foreground-service","version":"2.2.8","keywords":["react","react-native","android","foreground","service","background","maintained","fork"],"author":{"name":"Abrar Mehraj"},"license":"MIT","_id":"@abrarmehraj/rn-foreground-service@2.2.8","maintainers":[{"name":"abrarmehraj","email":"darabrar@outlook.com"}],"homepage":"https://github.com/abrarmehraj/rn-foreground-service#readme","bugs":{"url":"https://github.com/abrarmehraj/rn-foreground-service/issues"},"dist":{"shasum":"c83bfc027bf746f9bd2df15cab3960b07a8abec2","tarball":"https://registry.npmjs.org/@abrarmehraj/rn-foreground-service/-/rn-foreground-service-2.2.8.tgz","fileCount":17,"integrity":"sha512-4hrU1kqN2e/3wQoaKv7FfWzJSsbCnxYT8oQ7JkYXHJjkzzUOa8ObTxG2x7siKrUU1qdqx8tkKXS+vcdSZRUbEQ==","signatures":[{"sig":"MEUCIFBOEigyVJUquAYZmVMayJsNrldK0Iv6KAqlCoOVeqaZAiEAtr7s9amboBa7AvMbt+5dcv02w1J0gWpqXoBVKu6jwhI=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":69768},"main":"index.js","types":"./index.d.ts","gitHead":"5296fb15f99ef9d5edf7e7cb4f088db3a3a6d01b","scripts":{"test":"echo \"Error: no test specified\" && exit 1","postinstall":"node postinstall.js"},"_npmUser":{"name":"abrarmehraj","email":"darabrar@outlook.com"},"repository":{"url":"git+https://github.com/abrarmehraj/rn-foreground-service.git","type":"git"},"_npmVersion":"11.6.0","description":"A Foreground Service for React Native - Maintained fork of @supersami/rn-foreground-service","directories":{},"_nodeVersion":"24.10.0","dependencies":{},"_hasShrinkwrap":false,"peerDependencies":{"react-native":">=0.59.0"},"_npmOperationalInternal":{"tmp":"tmp/rn-foreground-service_2.2.8_1760604821461_0.24518282373328804","host":"s3://npm-registry-packages-npm-production"}},"2.2.9":{"name":"@abrarmehraj/rn-foreground-service","version":"2.2.9","description":"A Foreground Service for React Native - Maintained fork of @supersami/rn-foreground-service","main":"index.js","repository":{"type":"git","url":"git+https://github.com/abrarmehraj/rn-foreground-service.git"},"homepage":"https://github.com/abrarmehraj/rn-foreground-service#readme","bugs":{"url":"https://github.com/abrarmehraj/rn-foreground-service/issues"},"scripts":{"test":"echo \"Error: no test specified\" && exit 1","postinstall":"node postinstall.js"},"license":"MIT","keywords":["react","react-native","android","foreground","service","background","maintained","fork"],"author":{"name":"Abrar Mehraj"},"react-native":{"android":"./android"},"peerDependencies":{"react-native":">=0.59.0"},"dependencies":{},"_id":"@abrarmehraj/rn-foreground-service@2.2.9","gitHead":"5296fb15f99ef9d5edf7e7cb4f088db3a3a6d01b","types":"./index.d.ts","_nodeVersion":"24.1.0","_npmVersion":"11.3.0","dist":{"integrity":"sha512-nwfzo/exgywjET/xcX7+QTUHA/P05ASCURXDm9MUdRvvLypB74Qh4zE05wVkkOc/wsmhVESY+6CuAKb8aiAqsg==","shasum":"2bab5a66b4254c7503e881de7e5ba7adf9daf0f7","tarball":"https://registry.npmjs.org/@abrarmehraj/rn-foreground-service/-/rn-foreground-service-2.2.9.tgz","fileCount":19,"unpackedSize":70550,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIA4xiDrEvSgFACM45a139T4QEl0ZKxJV9VxHGBWLEtJRAiEA6NLlFuWcVO12lpR3A6kGtfhxNQ2UTLsrb8KtRzLyAEo="}]},"_npmUser":{"name":"abrarmehraj","email":"darabrar@outlook.com"},"directories":{},"maintainers":[{"name":"abrarmehraj","email":"darabrar@outlook.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/rn-foreground-service_2.2.9_1770215370551_0.43182009081108164"},"_hasShrinkwrap":false}},"time":{"created":"2025-10-08T03:59:04.731Z","modified":"2026-02-04T14:29:30.816Z","2.2.6":"2025-10-08T03:59:04.986Z","2.2.7":"2025-10-08T04:08:27.690Z","2.2.8":"2025-10-16T08:53:41.644Z","2.2.9":"2026-02-04T14:29:30.703Z"},"bugs":{"url":"https://github.com/abrarmehraj/rn-foreground-service/issues"},"author":{"name":"Abrar Mehraj"},"license":"MIT","homepage":"https://github.com/abrarmehraj/rn-foreground-service#readme","keywords":["react","react-native","android","foreground","service","background","maintained","fork"],"repository":{"type":"git","url":"git+https://github.com/abrarmehraj/rn-foreground-service.git"},"description":"A Foreground Service for React Native - Maintained fork of @supersami/rn-foreground-service","maintainers":[{"name":"abrarmehraj","email":"darabrar@outlook.com"}],"readme":"# @abrarmehraj/rn-foreground-service v2 🤟\n\n**Maintained Fork** of @supersami/rn-foreground-service\n\nThis is a maintained fork of the original [@supersami/rn-foreground-service](https://github.com/Raja0sama/rn-foreground-service) package, which was looking for contributors to help maintain it.\n\n## Installation\n\n```bash\nnpm install @abrarmehraj/rn-foreground-service\n# or\nyarn add @abrarmehraj/rn-foreground-service\n```\n\n## Migration from @supersami/rn-foreground-service\n\nSimply replace the package name in your dependencies:\n\n```json\n{\n  \"dependencies\": {\n    \"@abrarmehraj/rn-foreground-service\": \"^2.2.6\"\n  }\n}\n```\n\nThen update your imports:\n\n```javascript\n// Before\nimport { startForegroundService, stopForegroundService } from '@supersami/rn-foreground-service';\n\n// After  \nimport { startForegroundService, stopForegroundService } from '@abrarmehraj/rn-foreground-service';\n```\n\n## Documentation\n\n>> Documentation has been moved to https://rn-foreground.vercel.app/\n\n### Android 14+ Foreground ServiceType (Required)\n\nOn Android 14 (API 34+) you must supply a foreground service type when starting or updating the service. The library enforces this at type level and at runtime. If omitted on Android 14+, an alert is shown and the call is aborted.\n\nAllowed `ServiceType` values:\n\n```text\ncamera | connectedDevice | dataSync | health | location | mediaPlayback | mediaProjection | microphone | phoneCall | remoteMessaging | shortService | specialUse | systemExempted\n```\n\nExample:\n\n```ts\nimport ReactNativeForegroundService from '@abrarmehraj/rn-foreground-service';\n\n// Start service\nawait ReactNativeForegroundService.start({\n  id: 1,\n  title: 'Tracking',\n  message: 'Location service running',\n  ServiceType: 'location', // Required on Android 14+\n});\n\n// Update service\nawait ReactNativeForegroundService.update({\n  id: 1,\n  message: 'Updating...',\n  ServiceType: 'location',\n});\n```\n\n## Contributing\n\nIssues and pull requests are welcome! This package is actively maintained.\n\n## License\n\nMIT © [Abrar Mehraj](https://github.com/abrarmehraj) - Fork of original work by [rajaosama](https://github.com/raja0sama)\n","readmeFilename":"README.md"}