PaywallOS makes monetization simple. Define verbs, map to tiers, add attributes. Done.
Sign up for PaywallOS and create your first app. You'll get an API key and App ID instantly.
# Install OpenVerb SDK (used by PaywallOS) npm install @openverb/sdk # Or copy the PaywallOS client from our repo # lib/paywall-sdk.ts - set baseUrl: 'https://paywallos.openverb.org'
Create an OpenVerb library describing what users can do in your app. Use our AI assistant or write it yourself.
{
"namespace": "myapp.core",
"verbs": [
{
"name": "export_data",
"category": "file_system",
"description": "Export user data to CSV"
},
{
"name": "generate_report",
"category": "analysis",
"description": "Generate analytics report"
}
]
}Set up your pricing tiers (Free, Pro, Enterprise, etc.) and add your Stripe Price IDs.
Assign which verbs are available in each tier. Set usage limits if needed.
Initialize PaywallOS and add verb= attributes. That's it!
import { initPaywallOS } from './paywall-sdk'
// Call once at app startup
initPaywallOS(apiKey, appId, user.id, user.tier)
// Your app - add verb= to any element
<button verb="export_data">Export</button>
<button verb="generate_report">Reports</button>PaywallOS now automatically:
User clicks <button verb="export_data">
↓
PaywallOS intercepts click (capture phase)
↓
POST /api/openverb/check
{
verbId: "export_data",
userId: "user_123",
appId: "app_456"
}
↓
Database queries:
1. Get user's subscription tier
2. Check if verb enabled for tier
3. Check usage limits (if any)
↓
Response (~10ms):
{ ok: true, receipt: {...} } // allowed
or
{ denied: true, reason: { message: "Upgrade to Pro" } } // blocked
↓
If allowed: Original action proceeds
If blocked: Show upgrade modal