Plugins
Enable with Cargo features on sova. Presets:
bash
cargo add sova --features web # HTML apps
cargo add sova --features api # JSON APIs
cargo add sova --features cors,session,dbOpen a plugin page from the table. Extra notes for heavier stacks are below.
Catalog
| Plugin | Version | Summary | Features |
|---|---|---|---|
activity | 0.1.0 | Audit / activity log (who changed what) | activity |
auth | 0.1.1 | Register/login, verify, reset, 2FA, profile, roles | auth, auth-activity, auth-vld |
compress | 0.1.0 | gzip / deflate / brotli response compression | compress |
cookies | 0.1.0 | Parse Cookie header into request-local Cookies | cookies |
cors | 0.1.0 | Cross-Origin Resource Sharing headers | cors |
csrf | 0.1.0 | Session double-submit CSRF (Laravel-style except/XSRF cookie) | csrf |
db | 0.1.1 | SeaORM pool, migrate CLI, optional seed CLI | db, db-mysql, db-sqlite |
env | 0.1.0 | Cascade .env loading for Sova apps (dotenvy) | env |
http | 0.1.0 | Outbound HTTP client with SSRF guards and named configs | http-client |
i18n | 0.1.0 | Locales, catalogs, optional path prefix and cookie | i18n, i18n-cookie |
mail | 0.1.0 | Outbound email via lettre (SMTP / fake / file) | mail, mail-markdown, mail-templates |
meta | 0.1.0 | Document meta, OG/Twitter, JSON-LD, and head inject | meta, meta-i18n, meta-store, meta-templates |
notifications | 0.1.0 | DB inbox, channels with ACL, optional WS/mail | notifications, notifications-auth, notifications-mail, notifications-templates, notifications-ws |
observability | 0.1.0 | HTTP metrics, OpenTelemetry, Elasticsearch log shipping | observability, observability-elasticsearch, observability-otel |
openapi | 0.1.0 | OpenAPI 3.1 document + Scalar UI at mount path | openapi |
passport | 0.1.0 | Users + access/refresh JWT + personal access tokens | passport, passport-jwt, passport-oauth, passport-session |
quic | 0.1.0 | QUIC datagrams BackgroundService helpers for Sova | quic-udp |
rate-limit | 0.1.0 | Per-key request rate limiting | rate-limit |
redis | 0.1.0 | Shared Redis/Valkey connection for KvStore, tasks, cache, pub/sub, queues | redis |
session | 0.1.0 | Cookie sessions backed by a SessionStore | session, session-redis, session-sql |
shield | 0.1.0 | Baseline security response headers (helmet-style) | shield |
sse | 0.1.0 | Server-Sent Events helpers for Sova (channels, Last-Event-ID, keep-alive) | sse-feed |
static | 0.1.0 | Serve files from a directory under a mount path | static-files |
storage | 0.1.0 | Object storage (local / memory / S3 / GCS / Azure) | storage, storage-azure, storage-gcs, storage-memory, storage-s3 |
store | 0.1.0 | KvStore trait + memory / file / sql / redis backends for Sova | store, store-crypto, store-file, store-redis, store-sql |
tasks | 0.1.0 | Job worker, priorities, and optional cron/interval scheduler | tasks |
tasks-store | 0.1.0 | TaskStore trait + memory / file / sql / redis backends | tasks-file, tasks-redis, tasks-sql, tasks-store |
templates | 0.1.0 | MiniJinja HTML templates with optional autoreload | templates |
udp | 0.1.0 | UDP BackgroundService helpers for Sova | udp |
vld | 0.1.0 | Request validation hooks and coverage check | vld, vld-flash, vld-flash-templates, vld-form, vld-i18n, vld-openapi |
ws | 0.1.0 | WebSocket hub, origin allowlist, max message size | ws |
cli | 0.1.0 | CLI ServerArgs / listen_args for Sova (local dev) | — |
Notes
Auth (Fortify)
Needs db + mail + session. Example:
rust
app.install(Db::from_env().migrations::<sova_auth::AuthMigrator>());
app.install(Mail::from_env());
app.install(SessionLayer::memory());
app.install(
Fortify::new()
.features([AuthFeature::Registration, AuthFeature::ResetPasswords])
.home("/cabinet"),
);
cabinet.use_middleware(Fortify::guard());auth-activity writes Fortify mutations to the activity log. Full reference: auth.
Passport (JWT / PAT / OAuth)
| Kind | Storage | Use |
|---|---|---|
| JWT access | signed, short TTL | browsers |
| Refresh | auth_refresh_tokens | rotate access |
PAT (svpat_…) | auth_api_tokens | machine / CI |
JwtAuth::guard accepts Bearer JWT or PAT. OAuth drivers: GitHub / Google / Apple / Custom ({NAME}_CLIENT_ID / _CLIENT_SECRET). See passport.
Tasks
Same handlers for Dispatch and CLI. After install: tasks list | schedule | run NAME.
Console (info / ask / table) only during tasks run.
toml
[schedule.ping]
every = "15s"Toml overrides code .cron() / .every(). See examples/misc/tasks and tasks.
Database
URL: DATABASE_URL or [db] url. CLI: migrate / seed (cargo sovax db …). SQL KV/queue backends reuse the same DbPool. See db.
