---
title: "Save a Web Push installation"
method: PUT
path: "/integrations/web_push/installations"
tags: ["web_push"]
---

# Save a Web Push installation

`PUT /integrations/web_push/installations`

Creates a new installation of a Web Push integration for a user. This endpoint is used when an integration needs to be set up with user-specific credentials or configuration.

## Request body

- WebPushTokenPayload
  - `endpoint` string, uri, required — The push subscription URL obtained from PushSubscription.endpoint after calling registration.pushManager.subscribe(). This is the unique URL for this device that push messages will be sent to.
  - `keys` object, required — The encryption keys from the PushSubscription.getKey() method, needed to encrypt push messages for this subscription.
    - `auth` string, byte, required — The authentication secret obtained from PushSubscription.getKey('auth'). Used to encrypt push messages for this subscription.
    - `p256dh` string, byte, required — The P-256 ECDH public key obtained from PushSubscription.getKey('p256dh'). Used to encrypt push messages for this subscription.

## Response `200`

OK

- WebPushTokenPayload
  - `endpoint` string, uri, required — The push subscription URL obtained from PushSubscription.endpoint after calling registration.pushManager.subscribe(). This is the unique URL for this device that push messages will be sent to.
  - `keys` object, required — The encryption keys from the PushSubscription.getKey() method, needed to encrypt push messages for this subscription.
    - `auth` string, byte, required — The authentication secret obtained from PushSubscription.getKey('auth'). Used to encrypt push messages for this subscription.
    - `p256dh` string, byte, required — The P-256 ECDH public key obtained from PushSubscription.getKey('p256dh'). Used to encrypt push messages for this subscription.

---

[API](https://skmtc.net/magicbell/apis/magicbell-api.md) · [All operations](https://skmtc.net/magicbell/apis/magicbell-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/magicbell/magicbell-api/revisions/8b99dca11019/schema)
