Plugin hub

SaaS kit

saas · v1.3.0 · nuxtcms >=1.24.0 · 0 installs

Turn the site into a paid SaaS product: sign-up and sign-in (password, e-mail link, Google / GitHub / WeChat), a user dashboard; plans and billing (Stripe subscriptions, WeChat Pay / Alipay terms), plan-gated features; credits with a ledger, personal API keys, teams sharing a plan; users, plans and payments in the admin.

What it does

Scheduled tasks
SaaS: lifecycle e-mails · 23 * * * *

Settings

Allow new sign-upssignupEnabled · boolean
E-mail and password sign-inpasswordLogin · boolean
Passwordless sign-in by e-mail linkmagicLink · boolean

Needs e-mail (Admin → E-mail settings)

Password sign-ups must verify their e-mailrequireEmailVerification · boolean
Page after sign-inafterLoginPath · text
Automatic e-mails: welcome, plan ending reminders and ended noticelifecycleEmails · boolean

Needs e-mail and the scheduled tasks (runs hourly)

Remind this many days before the end (comma separated)reminderDays · text
Users may create API keysapiKeys · boolean
Lowest plan for API keys (slug, empty = everyone)apiKeysPlan · text
Requests per minute per API keyapiRateLimit · number
Teams (members share the owner's plan, limited by the plan's seats)teams · boolean
Google OAuth client ID (shows Google sign-in)googleClientId · text

Redirect URI: /api/saas/oauth/google/callback

Google OAuth client secretgoogleClientSecret · secret
GitHub OAuth client ID (shows GitHub sign-in)githubClientId · text

Callback URL: /api/saas/oauth/github/callback

GitHub OAuth client secretgithubClientSecret · secret
WeChat Open Platform website app AppID (shows WeChat sign-in)wechatAppId · text

Set the site domain as the callback domain; path: /api/saas/oauth/wechat/callback

WeChat website app AppSecretwechatAppSecret · secret
Stripe secret key (enables Stripe subscriptions)stripeSecretKey · secret

Empty: the shop plugin's setting is used. Enter the monthly / yearly Stripe price IDs (price_...) on each plan.

Stripe webhook signing secretstripeWebhookSecret · secret

Endpoint: /api/saas/webhooks/stripe, events: customer.subscription.*, checkout.session.completed, invoice.paid

WeChat Pay merchant IDwechatPayMchId · text

Empty: the shop plugin's setting is used. Callback: /api/saas/webhooks/wechat

WeChat Pay AppID (bound to the merchant)wechatPayAppId · text
WeChat Pay API v3 keywechatPayApiV3Key · secret
Merchant API certificate serial numberwechatPaySerialNo · text
Merchant API private key (apiclient_key.pem)wechatPayPrivateKey · secret
WeChat Pay public key ID (optional)wechatPayPublicKeyId · text
WeChat Pay public key (optional, verifies callback signatures)wechatPayPublicKey · textarea
WeChat H5 pay in mobile browsers (enable it on the merchant platform)wechatPayH5 · boolean
Alipay AppIDalipayAppId · text

Empty: the shop plugin's setting is used. Notify URL: /api/saas/webhooks/alipay

Alipay app private keyalipayPrivateKey · secret
Alipay public key (not the app public key)alipayPublicKey · textarea
Alipay sandboxalipaySandbox · boolean

How to install

Package plugin (needs a rebuild) · Run in your site project

node node_modules/nuxtcms/scripts/plugin.mjs add saas