Rask.WebPush
0.23.1-alpha.0.72
See the version list below for details.
dotnet add package Rask.WebPush --version 0.23.1-alpha.0.72
NuGet\Install-Package Rask.WebPush -Version 0.23.1-alpha.0.72
<PackageReference Include="Rask.WebPush" Version="0.23.1-alpha.0.72" />
<PackageVersion Include="Rask.WebPush" Version="0.23.1-alpha.0.72" />
<PackageReference Include="Rask.WebPush" />
paket add Rask.WebPush --version 0.23.1-alpha.0.72
#r "nuget: Rask.WebPush, 0.23.1-alpha.0.72"
#:package Rask.WebPush@0.23.1-alpha.0.72
#addin nuget:?package=Rask.WebPush&version=0.23.1-alpha.0.72&prerelease
#tool nuget:?package=Rask.WebPush&version=0.23.1-alpha.0.72&prerelease
Rask.WebPush
Web Push from your own server, on your own keys and your own database. The browsers that subscribed are kept in a table on the app's database, and one line reaches them:
await Push.Send(WebPushMessage.Text("Order shipped", "#1042 is on its way", "/orders/1042"));
await Push.Send(WebPushMessage.Text("Your order shipped")).To(userId); // one person's devices
A subscription the push service says is gone (404/410) is dropped as the send finds it. Messages are
signed with VAPID and encrypted with
RFC 8291 aes128gcm, using in-box System.Security.Cryptography.
Included in Rask.Server and on by default — app.Configure(c => c.Push.Off()) to do without it.
Subscribe
On the server host a component keeps what the browser API hands back:
var subscription = await push.SubscribeAsync(Push.PublicKey!); // IWebPush, the browser API
await Push.Subscribe(subscription); // the signed-in user's, when there is one
A WebAssembly client or a SPA posts it to the endpoints RaskApp maps: GET /_rask/push/key,
POST /_rask/push/subscribe, POST /_rask/push/unsubscribe.
Keys
The key pair and the contact come from Rask:WebPush. A rask new app already has a development pair in
its gitignored appsettings.Development.json; deployed, both keys come from the environment
(Rask__WebPush__VapidKeys__PublicKey, …__PrivateKey). The table and the subscribe endpoints work without
keys; sending names the settings it is missing.
Test
using var push = Push.Fake();
await orders.Ship(order);
push.Sent().To(order.CustomerId).WithTitle("Order shipped").Once();
By hand
builder.Services.AddRaskWebPush<AppDbContext>(); // and modelBuilder.AddRaskWebPush() in OnModelCreating
app.MapRaskPush(); // after MapRask
AddRaskWebPush() without a context registers the sender alone — IWebPush.Send(subscription, message) —
for an app that keeps its subscriptions somewhere of its own.
Full documentation: https://rask.sh/docs/guides/webpush
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. net11.0 is compatible. |
-
net10.0
- Microsoft.EntityFrameworkCore (>= 10.0.12)
- Rask.Data (>= 0.23.1-alpha.0.72)
-
net11.0
- Microsoft.EntityFrameworkCore (>= 10.0.12)
- Rask.Data (>= 0.23.1-alpha.0.72)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Rask.WebPush:
| Package | Downloads |
|---|---|
|
Rask.Server
The ASP.NET host for Rask, a full-stack .NET web framework, with every battery: database (SQLite, PostgreSQL or SQL Server, picked by Rask:Database:Provider), mediator and query cache, accounts, background jobs, transactional email, cache, file storage, outbox, operator dashboard, durable logs, Web Push, SQLite snapshots and continuous backup. Renders Rask components with live updates over a WebSocket. RaskApp.Create(args).Run<App>() is the whole Program.cs; app.Configure(c => c.Jobs.Off()) is how an app does without one. Depends on Rask, the shared core. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.23.1-alpha.0.84 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.82 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.81 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.80 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.79 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.78 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.76 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.74 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.72 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.70 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.69 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.68 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.67 | 0 | 9/25/2026 |
| 0.23.1-alpha.0.66 | 26 | 9/24/2026 |
| 0.23.1-alpha.0.65 | 24 | 9/24/2026 |
| 0.23.1-alpha.0.64 | 30 | 9/24/2026 |
| 0.23.1-alpha.0.62 | 31 | 9/24/2026 |
| 0.23.1-alpha.0.61 | 29 | 9/24/2026 |
| 0.23.1-alpha.0.50 | 31 | 9/24/2026 |
| 0.23.0 | 144 | 9/18/2026 |