コンテンツにスキップ

Send push notification

POST
/api/v1/notify

Enqueues a push notification to all active subscribers (or a specific endpoint). Set dry_run to validate and count recipients without enqueueing.

object
title
required

Notification title

string
body
required

Notification body

string
url

URL to open on click

string format: uri
icon
string format: uri
badge
string format: uri
endpoint

Target specific subscription endpoint

string
dry_run

Validate and count recipients without enqueueing

boolean

Dry run completed without enqueueing

object
ok
required
boolean
dry_run
required
boolean
queued
required
integer
Allowed values: 0
would_send
required
integer

Notification enqueued

object
ok
required
boolean
send_id
required
string

Missing required fields, invalid URL/endpoint, or invalid dry_run. endpoint is rejected (INVALID_ENDPOINT) when it is not HTTPS, points to an internal host, or exceeds 2,048 bytes

Unauthorized

Insufficient scope

Payload too large

Monthly limit exceeded or rate limited (RATE_LIMITED)