mirror of
https://github.com/HeyPuter/puter.git
synced 2026-11-04 13:03:37 +00:00
docs(notifications): publish the push limits of 12 a minute and 1,000 a day
Pushes are capped per user per app at 12 a minute and 1,000 a day, and at 6 a minute and 200 a day while an app is new. The rate limits table and the notification pages said one a minute and 100 a day.
This commit is contained in:
1 parent
efba8bb7a9
commit
cb3e4586d9
5 files changed
+6
-6
No files matched your search
@@ -23,7 +23,7 @@ A notification always shows in the user's Puter notifications panel. Puter then
|
||||
|
||||
For a push, the user has to have turned them on. On a website, call [`enable()`](/Notifications/enable/) from a click and handle pushes with [`onPush()`](/Notifications/onPush/); they arrive on your own origin through a small service worker, and [Push notifications for your app](/Notifications/push/) has the setup step by step. Inside the Puter desktop, pushes go through Puter: ask with [`requestPermission()`](/Notifications/requestPermission/), and [`enablePush()`](/Notifications/enablePush/) offers to turn them on in the browser.
|
||||
|
||||
A user gets at most one push a minute from each app. A notification over that still shows in the panel; it's just not pushed.
|
||||
A user gets at most 12 pushes a minute and 1,000 a day from each app, and fewer while the app is new. A notification over that still shows in the panel. It just isn't pushed.
|
||||
|
||||
## What a notification carries
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ platforms: [websites, apps]
|
||||
|
||||
Sends the user your app runs for a notification. It shows in their Puter notifications panel and reaches your app through [`onNotification()`](/Notifications/onNotification/) while it's open. When no page of your app receives it live within 5 seconds, it also goes out as a push notification, if the user [allowed pushes](/Notifications/requestPermission/) from your app and has push notifications turned on on a device.
|
||||
|
||||
Only an app can send notifications: an app running on Puter, or a website using Puter.js. Every notification carries your app's name, and a user gets at most one push a minute from each app (the rest still show in the panel).
|
||||
Only an app can send notifications: an app running on Puter, or a website using Puter.js. Every notification carries your app's name, and a user gets at most 12 pushes a minute and 1,000 a day from each app (the rest still show in the panel).
|
||||
|
||||
On a website with nobody signed in, it asks the user to sign in first, as other Puter.js calls do.
|
||||
|
||||
|
||||
@@ -86,7 +86,7 @@ await puter.notifications.notify({
|
||||
});
|
||||
```
|
||||
|
||||
It works from the page and from a worker. The notification always shows in the user's Puter notifications panel. It goes out as a push only when no page of your app received it live within 5 seconds, and a user gets at most one push a minute from each app. The other limits are on [Rate Limits and Quotas](/rate-limits-and-quotas/#notifications).
|
||||
It works from the page and from a worker. The notification always shows in the user's Puter notifications panel. It goes out as a push only when no page of your app received it live within 5 seconds, and a user gets at most 12 pushes a minute and 1,000 a day from each app, and fewer while the app is new. The other limits are on [Rate Limits and Quotas](/rate-limits-and-quotas/#notifications).
|
||||
|
||||
When the user taps the push, the browser opens the handler's `url` on your domain. When the user clicks the notification in the Puter panel instead, Puter opens your app and hands the `target` and `data` back through [`on('click')`](/Notifications/on/).
|
||||
|
||||
|
||||
@@ -403,8 +403,8 @@ An app, its workers and the tokens it issues can send the user they act for an `
|
||||
| Limit | Value | Scope |
|
||||
| -------------------------------- | --------------------------------- | ----------------- |
|
||||
| `app.message` notifications | 30/min, 300/day | Per user, per app |
|
||||
| Pushes | 1/min, 100/day | Per user, per app |
|
||||
| Pushes while an app is new | 20/day | Per user, per app |
|
||||
| Pushes | 12/min, 1,000/day | Per user, per app |
|
||||
| Pushes while an app is new | 6/min, 200/day | Per user, per app |
|
||||
| `title` | 120 characters | |
|
||||
| `text` | 240 characters | |
|
||||
| `icon` (an `https` URL) | 2,048 characters | |
|
||||
|
||||
@@ -72,7 +72,7 @@ await puter.notifications.notify({
|
||||
});
|
||||
```
|
||||
|
||||
It works from the page and from a worker. The notification always shows in the user's Puter notifications panel. It goes out as a push only when no page of your app received it live within 5 seconds, and a user gets at most one push a minute from each app. A notification over that still shows in the panel. The other limits are on [Rate Limits and Quotas](/rate-limits-and-quotas/#notifications).
|
||||
It works from the page and from a worker. The notification always shows in the user's Puter notifications panel. It goes out as a push only when no page of your app received it live within 5 seconds, and a user gets at most 12 pushes a minute and 1,000 a day from each app, and fewer while the app is new. A notification over that still shows in the panel. The other limits are on [Rate Limits and Quotas](/rate-limits-and-quotas/#notifications).
|
||||
|
||||
Push services can read `data`, so put IDs in it and fetch the rest. For a notification whose text shouldn't leave Puter, set `sensitive: true`, and the push shows a generic line instead.
|
||||
|
||||
|
||||
Reference in new issue
Block a user