1{2 "$schema": "node_modules/wrangler/config-schema.json",3 "name": "nzip",4 "main": "src/index.ts",5 "compatibility_date": "2026-07-15",6 "compatibility_flags": ["nodejs_compat"],7 "cache": { "enabled": true },8 "observability": {9 "enabled": true,10 "logs": {11 "enabled": true,12 "head_sampling_rate": 1,13 "invocation_logs": false14 }15 },16 "routes": [17 { "pattern": "share.demo.dev", "custom_domain": true },18 { "pattern": "*.demo.dev/*", "zone_name": "demo.dev" }19 ],20 "r2_buckets": [21 {22 "binding": "CONTENT",23 "bucket_name": "nzip-content"24 }25 ],26 "d1_databases": [27 {28 "binding": "DB",29 "database_name": "nzip",30 "database_id": "00000000-0000-0000-0000-000000000000"31 }32 ],33 "ratelimits": [34 {35 "name": "RL_ENUM",36 "namespace_id": "1001",37 "simple": { "limit": 30, "period": 60 }38 },39 {40 "name": "RL_UNLOCK",41 "namespace_id": "1002",42 "simple": { "limit": 5, "period": 60 }43 },44 {45 "name": "RL_OBSERVE",46 "namespace_id": "1003",47 "simple": { "limit": 30, "period": 60 }48 },49 {50 "name": "RL_SIGNAL",51 "namespace_id": "1004",52 "simple": { "limit": 1, "period": 60 }53 },54 {55 "name": "RL_NOTIFY_ENROLL",56 "namespace_id": "1005",57 "simple": { "limit": 5, "period": 60 }58 },59 {60 "name": "RL_NOTIFY_READ",61 "namespace_id": "1006",62 "simple": { "limit": 60, "period": 60 }63 },64 {65 "name": "RL_FEEDBACK",66 "namespace_id": "1008",67 "simple": { "limit": 60, "period": 60 }68 }69 ],70 "send_email": [71 { "name": "EMAIL", "destination_address": "operator@example.com" }72 ],73 "triggers": {74 "crons": [75 "*/5 * * * *",76 "0 4 * * *"77 ]78 },79 "vars": {80 "PUBLIC_BASE": "https://share.demo.dev",81 "SITE_DOMAIN": "demo.dev",82 "ALERT_EMAIL_TO": "operator@example.com",83 "ALERT_EMAIL_FROM": "alerts@share.demo.dev",84 "NOTIFY_ENABLED": "false",85 "WEB_PUSH_ORIGINS": "",86 "VAPID_PUBLIC_KEY": "replace-with-url-safe-base64-public-key",87 "VAPID_SUBJECT": "mailto:operator@example.com"88 }89 // Secrets (wrangler secret put --config wrangler.jsonc): NZIP_TOKEN, VAPID_PRIVATE_KEY90}