Skip to content
Back to skills

Android Background Work

ASecurity

Implement WorkManager and background processing correctly on Android. Use when creating Worker classes, scheduling tasks, choosing between WorkManager and Foreground Services, or setting up Hilt in workers.

  • 549 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added June 6, 2026
development

Security analysis

A100/100

Pro scans all 3 files and shows the line behind each finding

Scanned June 6, 2026

npx -y skills add HoangNguyen0403/agent-skills-standard --skill android-background-work --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Android Background Work?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Android Background Work
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/hoangnguyen0403-android-background-work/badge)](https://www.skillsdirectory.com/skills/hoangnguyen0403-android-background-work)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: android-background-work
description: Implement WorkManager and background processing correctly on Android. Use when creating Worker classes, scheduling tasks, choosing between WorkManager and Foreground Services, or setting up Hilt in workers.
metadata:
  triggers:
    files:
      - '**/*Worker.kt'
    keywords:
      - CoroutineWorker
      - WorkManager
      - doWork
      - PeriodicWorkRequest
      - OneTimeWorkRequest
      - '@HiltWorker'
---

# Android Background Work Standards

## **Priority: P1**

## Implementation Guidelines

### WorkManager

- **CoroutineWorker**: Use for all background tasks.
- **Constraints**: explicit (Require Network, Charging).
- **Hilt**: Use `@HiltWorker` for DI integration. Inject dependencies via `@AssistedInject` constructor; bind with `HiltWorkerFactory` in `WorkManager` configuration.

### Foreground Services

- **Only When Necessary**: Use generating visible notifications only for tasks user actively aware of (Playback, Calls, Active Navigation). Otherwise use WorkManager.

## Anti-Patterns

- **No IntentService**: Deprecated. Use WorkManager for all background tasks.
- **No Short Background Jobs**: Use Coroutines in ViewModel scope instead.

## References

- [Worker Template](references/implementation.md)

Files in this skill

  • SKILL.md1.2 KB
  • evals/evals.json2.8 KB
  • references/implementation.md980 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.