[**react-native-notify-kit**](react-native/reference/index)

---

[react-native-notify-kit](react-native/reference/index) / ForegroundServiceTask

# Type Alias: ForegroundServiceTask

> **ForegroundServiceTask** = (`notification`) => `Promise`<`void`>

Defined in: [packages/react-native/src/types/Notification.ts:222](https://github.com/marcocrupi/react-native-notify-kit/blob/main/packages/react-native/src/types/Notification.ts#L222)

A representation of a Foreground Service task registered via [`registerForegroundService`](/react-native/reference/registerforegroundservice).

The task must resolve a promise once complete, and in turn removes the notification.

View the [Foreground Service](/react-native/android/foreground-service) documentation to
learn more.

## Parameters

### notification

[`Notification`](react-native/reference/Interface.Notification)

## Returns

`Promise`<`void`>

## Platform

android
