[android-components](../../index.md) / [mozilla.components.concept.engine.webpush](../index.md) / [WebPushDelegate](index.md) / [onGetSubscription](./on-get-subscription.md)

# onGetSubscription

`open fun onGetSubscription(scope: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, onSubscription: (`[`WebPushSubscription`](../-web-push-subscription/index.md)`?) -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) [(source)](https://github.com/mozilla-mobile/android-components/blob/master/components/concept/engine/src/main/java/mozilla/components/concept/engine/webpush/WebPushDelegate.kt#L15)

Requests a WebPush subscription for the given Service Worker scope.

