us.off-the-clock.push.registerPushSubscription

off-the-clock.us

Documentation

Registers this browser's push subscription to the viewer. An endpoint registered by someone else moves to the viewer: one browser has one recipient.

main procedure

Registers this browser's push subscription to the viewer. An endpoint registered by someone else moves to the viewer: one browser has one recipient.

Input

Encodingapplication/json
endpoint stringuri Required

An https URL on a public host.

maxLength: 1024 bytes
keys object Required

No description available.

label string Optional

No description available.

maxLength: 64 bytes

Output

Encodingapplication/json

Errors

InvalidRequest
NotSpaceMember
PushDisabled This AppView has no VAPID key.
Try It

Requests are sent directly from your browser. Some servers may block requests due to CORS.

Base URL for XRPC calls (e.g., https://bsky.social)
Enter valid JSON for the request body
View raw schema
{
  "description": "Registers this browser's push subscription to the viewer. An endpoint registered by someone else moves to the viewer: one browser has one recipient.",
  "errors": [
    {
      "name": "InvalidRequest"
    },
    {
      "name": "NotSpaceMember"
    },
    {
      "description": "This AppView has no VAPID key.",
      "name": "PushDisabled"
    }
  ],
  "input": {
    "encoding": "application/json",
    "schema": {
      "properties": {
        "endpoint": {
          "description": "An https URL on a public host.",
          "format": "uri",
          "maxLength": 1024,
          "type": "string"
        },
        "keys": {
          "properties": {
            "auth": {
              "description": "The 16-byte authentication secret, base64url.",
              "type": "string"
            },
            "p256dh": {
              "description": "The browser's P-256 public key, uncompressed (65 bytes), base64url.",
              "type": "string"
            }
          },
          "required": [
            "p256dh",
            "auth"
          ],
          "type": "object"
        },
        "label": {
          "maxLength": 64,
          "type": "string"
        }
      },
      "required": [
        "endpoint",
        "keys"
      ],
      "type": "object"
    }
  },
  "output": {
    "encoding": "application/json",
    "schema": {
      "properties": {},
      "type": "object"
    }
  },
  "type": "procedure"
}

Lexicon Garden

@