Papermark is the open-source DocSend alternative and secure data rooms with built-in analytics and custom domains.
feat: add trigger.dev
Marc Seitzac39515a4f5e
diff --git a/.env.example b/.env.exampleindex 33f05830..628a792f 100644--- a/.env.example+++ b/.env.example@@ -28,4 +28,9 @@ AUTH_BEARER_TOKEN=# Get your QStash Token here: https://upstash.com/docs/qstash/overall/getstartedQSTASH_TOKEN=QSTASH_CURRENT_SIGNING_KEY=-QSTASH_NEXT_SIGNING_KEY=\ No newline at end of file+QSTASH_NEXT_SIGNING_KEY=++# Trigger+TRIGGER_API_KEY=+TRIGGER_API_URL=https://api.trigger.dev+NEXT_PUBLIC_TRIGGER_PUBLIC_API_KEY=\ No newline at end of filediff --git a/app/api/trigger/route.ts b/app/api/trigger/route.tsnew file mode 100644index 00000000..747b27e0--- /dev/null+++ b/app/api/trigger/route.ts@@ -0,0 +1,7 @@+import { createAppRoute } from "@trigger.dev/nextjs";+import { client } from "@/trigger";++import "@/jobs";++//this route is used to send and receive data with Trigger.dev+export const { POST, dynamic } = createAppRoute(client);diff --git a/package-lock.json b/package-lock.jsonindex 0760f0ba..4c2da930 100644--- a/package-lock.json+++ b/package-lock.json@@ -29,6 +29,9 @@"@stripe/stripe-js": "^2.1.7","@tailwindcss/typography": "^0.5.10","@tremor/react": "^3.8.2",+ "@trigger.dev/nextjs": "^2.2.0",+ "@trigger.dev/react": "^2.2.0",+ "@trigger.dev/sdk": "^2.2.0","@types/node": "^20.8.4","@types/react": "^18.2.27","@types/react-dom": "^18.2.12",@@ -2822,6 +2825,41 @@"node": ">=4"}},+ "node_modules/@tanstack/query-core": {+ "version": "5.0.0-beta.0",+ "resolved": "https://registry.npmjs.org/@tanstack/query-core/-/query-core-5.0.0-beta.0.tgz",+ "integrity": "sha512-VGq/H3PuRoj0shOcg1S5Flv3YD2qNz2ttk8w5xe5AHQE1I8NO9EHSBUxezIpk4dD6M7bQDtwHBMqqU2EwMwyUw==",+ "funding": {+ "type": "github",+ "url": "https://github.com/sponsors/tannerlinsley"+ }+ },+ "node_modules/@tanstack/react-query": {+ "version": "5.0.0-beta.2",+ "resolved": "https://registry.npmjs.org/@tanstack/react-query/-/react-query-5.0.0-beta.2.tgz",+ "integrity": "sha512-JdK1HRw20tuwg3GfT3QZTkuS7s2KDa9FeozuJ7jZULlwPczZagouqYmM6+PL0ad6jfCnw8NzmLFtZdlBx6cTmA==",+ "dependencies": {+ "@tanstack/query-core": "5.0.0-beta.0",+ "client-only": "0.0.1"+ },+ "funding": {+ "type": "github",+ "url": "https://github.com/sponsors/tannerlinsley"+ },+ "peerDependencies": {+ "react": "^18.0.0",+ "react-dom": "^18.0.0",+ "react-native": "*"+ },+ "peerDependenciesMeta": {+ "react-dom": {+ "optional": true+ },+ "react-native": {+ "optional": true+ }+ }+ },"node_modules/@tootallnate/once": {"version": "2.0.0","resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-2.0.0.tgz",@@ -2849,6 +2887,119 @@"react-dom": ">=16.6.0"}},+ "node_modules/@trigger.dev/core": {+ "version": "2.2.0",+ "resolved": "https://registry.npmjs.org/@trigger.dev/core/-/core-2.2.0.tgz",+ "integrity": "sha512-BtPnNt5rd4i92jthM6CVRgZ31qWyyzXAaicrvs6Xmk0MRasrbyvSU9g4FmUTcM+9ne1UiZ3Mh38y0hLMGfrCGQ==",+ "dependencies": {+ "ulid": "^2.3.0",+ "zod": "3.22.3",+ "zod-error": "1.5.0"+ },+ "engines": {+ "node": ">=18.0.0"+ }+ },+ "node_modules/@trigger.dev/core/node_modules/zod": {+ "version": "3.22.3",+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.22.3.tgz",+ "integrity": "sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug==",+ "funding": {+ "url": "https://github.com/sponsors/colinhacks"+ }+ },+ "node_modules/@trigger.dev/nextjs": {+ "version": "2.2.0",+ "resolved": "https://registry.npmjs.org/@trigger.dev/nextjs/-/nextjs-2.2.0.tgz",+ "integrity": "sha512-2djyu03AyF/XT8e3MHegA4DiUxWoEocGht9hcGTON0DxsCJegrQwjPcQ79sZ1uxP53I7m88raD6vLQjJKZ8PQw==",+ "dependencies": {+ "debug": "^4.3.4"+ },+ "engines": {+ "node": ">=18.0.0"+ },+ "peerDependencies": {+ "@trigger.dev/sdk": "^2.2.0",+ "next": ">=12.0.0 <14.0.0"+ }+ },+ "node_modules/@trigger.dev/react": {+ "version": "2.2.0",+ "resolved": "https://registry.npmjs.org/@trigger.dev/react/-/react-2.2.0.tgz",+ "integrity": "sha512-sp2p+PYM5DRmzFOla0sYUoptxVu1X7qpN0nqUU2VcumWHtf2JjA4rhkHIxmgP7vs84itruiTX+SOR2SmtHWODQ==",+ "dependencies": {+ "@tanstack/react-query": "5.0.0-beta.2",+ "@trigger.dev/core": "^2.2.0",+ "debug": "^4.3.4",+ "zod": "3.22.3"+ },+ "peerDependencies": {+ "react": "^16.8.0 || ^17.0.0 || ^18"+ }+ },+ "node_modules/@trigger.dev/react/node_modules/zod": {+ "version": "3.22.3",+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.22.3.tgz",+ "integrity": "sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug==",+ "funding": {+ "url": "https://github.com/sponsors/colinhacks"+ }+ },+ "node_modules/@trigger.dev/sdk": {+ "version": "2.2.0",+ "resolved": "https://registry.npmjs.org/@trigger.dev/sdk/-/sdk-2.2.0.tgz",+ "integrity": "sha512-gyRly4mGVMwdH3lrVBXDxTFf1b3GKj7BOGg/xUQh/hV7iFJLCo4Vf0K+2CL/R8YUA3kFZCsFJfVUOqwaYwX0Eg==",+ "dependencies": {+ "@trigger.dev/core": "^2.2.0",+ "chalk": "^5.2.0",+ "cronstrue": "^2.21.0",+ "debug": "^4.3.4",+ "evt": "^2.4.13",+ "get-caller-file": "^2.0.5",+ "git-remote-origin-url": "^4.0.0",+ "git-repo-info": "^2.1.1",+ "slug": "^6.0.0",+ "terminal-link": "^3.0.0",+ "ulid": "^2.3.0",+ "uuid": "^9.0.0",+ "ws": "^8.11.0",+ "zod": "3.22.3"+ },+ "engines": {+ "node": ">=18.0.0"+ }+ },+ "node_modules/@trigger.dev/sdk/node_modules/chalk": {+ "version": "5.3.0",+ "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.3.0.tgz",+ "integrity": "sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==",+ "engines": {+ "node": "^12.17.0 || ^14.13 || >=16.0.0"+ },+ "funding": {+ "url": "https://github.com/chalk/chalk?sponsor=1"+ }+ },+ "node_modules/@trigger.dev/sdk/node_modules/uuid": {+ "version": "9.0.1",+ "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz",+ "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==",+ "funding": [+ "https://github.com/sponsors/broofa",+ "https://github.com/sponsors/ctavan"+ ],+ "bin": {+ "uuid": "dist/bin/uuid"+ }+ },+ "node_modules/@trigger.dev/sdk/node_modules/zod": {+ "version": "3.22.3",+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.22.3.tgz",+ "integrity": "sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug==",+ "funding": {+ "url": "https://github.com/sponsors/colinhacks"+ }+ },"node_modules/@types/bcryptjs": {"version": "2.4.4","resolved": "https://registry.npmjs.org/@types/bcryptjs/-/bcryptjs-2.4.4.tgz",@@ -3286,6 +3437,31 @@"@types/dlv": "^1.0.0"}},+ "node_modules/ansi-escapes": {+ "version": "5.0.0",+ "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-5.0.0.tgz",+ "integrity": "sha512-5GFMVX8HqE/TB+FuBJGuO5XG0WrsA6ptUqoODaT/n9mmUaZFkqnBueB4leqGBCmrUHnCnC4PCZTCd0E7QQ83bA==",+ "dependencies": {+ "type-fest": "^1.0.2"+ },+ "engines": {+ "node": ">=12"+ },+ "funding": {+ "url": "https://github.com/sponsors/sindresorhus"+ }+ },+ "node_modules/ansi-escapes/node_modules/type-fest": {+ "version": "1.4.0",+ "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-1.4.0.tgz",+ "integrity": "sha512-yGSza74xk0UG8k+pLh5oeoYirvIiWo5t0/o3zHHAO2tRDiZcxWP7fywNlXhqb6/r6sWvwi+RsyQMWhVLe4BVuA==",+ "engines": {+ "node": ">=10"+ },+ "funding": {+ "url": "https://github.com/sponsors/sindresorhus"+ }+ },"node_modules/ansi-regex": {"version": "5.0.1","resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz",@@ -4094,6 +4270,14 @@"resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz","integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ=="},+ "node_modules/cronstrue": {+ "version": "2.32.0",+ "resolved": "https://registry.npmjs.org/cronstrue/-/cronstrue-2.32.0.tgz",+ "integrity": "sha512-dmNflOCNJL6lZEj0dp2YhGIPY83VTjFue6d9feFhnNtrER6mAjBrUvSgK95j3IB/xNGpLjaZDIDG6ACKTZr9Yw==",+ "bin": {+ "cronstrue": "bin/cli.js"+ }+ },"node_modules/cross-spawn": {"version": "7.0.3","resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz",@@ -5522,6 +5706,16 @@"resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz","integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw=="},+ "node_modules/evt": {+ "version": "2.5.3",+ "resolved": "https://registry.npmjs.org/evt/-/evt-2.5.3.tgz",+ "integrity": "sha512-wZKx0JgXaTOVOXI2saNVxINU6VToOHDowMwb3NRcU6l+C59eW3w9dZgNxjokiM8rvMgc7/11yFG0cSDxn4qxgA==",+ "dependencies": {+ "minimal-polyfills": "^2.2.3",+ "run-exclusive": "^2.2.19",+ "tsafe": "^1.6.5"+ }+ },"node_modules/execa": {"version": "7.1.1","resolved": "https://registry.npmjs.org/execa/-/execa-7.1.1.tgz",@@ -5888,6 +6082,14 @@"node": ">=10"}},+ "node_modules/get-caller-file": {+ "version": "2.0.5",+ "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",+ "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==",+ "engines": {+ "node": "6.* || 8.* || >= 10.*"+ }+ },"node_modules/get-intrinsic": {"version": "1.2.1","resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz",@@ -5947,6 +6149,36 @@"url": "https://github.com/privatenumber/get-tsconfig?sponsor=1"}},+ "node_modules/git-remote-origin-url": {+ "version": "4.0.0",+ "resolved": "https://registry.npmjs.org/git-remote-origin-url/-/git-remote-origin-url-4.0.0.tgz",+ "integrity": "sha512-EAxDksNdjuWgmVW9pVvA9jQDi/dmTaiDONktIy7qiRRhBZUI4FQK1YvBvteuTSX24aNKg9lfgxNYJEeeSXe6DA==",+ "dependencies": {+ "gitconfiglocal": "^2.1.0"+ },+ "engines": {+ "node": "^12.20.0 || ^14.13.1 || >=16.0.0"+ },+ "funding": {+ "url": "https://github.com/sponsors/sindresorhus"+ }+ },+ "node_modules/git-repo-info": {+ "version": "2.1.1",+ "resolved": "https://registry.npmjs.org/git-repo-info/-/git-repo-info-2.1.1.tgz",+ "integrity": "sha512-8aCohiDo4jwjOwma4FmYFd3i97urZulL8XL24nIPxuE+GZnfsAyy/g2Shqx6OjUiFKUXZM+Yy+KHnOmmA3FVcg==",+ "engines": {+ "node": ">= 4.0"+ }+ },+ "node_modules/gitconfiglocal": {+ "version": "2.1.0",+ "resolved": "https://registry.npmjs.org/gitconfiglocal/-/gitconfiglocal-2.1.0.tgz",+ "integrity": "sha512-qoerOEliJn3z+Zyn1HW2F6eoYJqKwS6MgC9cztTLUB/xLWX8gD/6T60pKn4+t/d6tP7JlybI7Z3z+I572CR/Vg==",+ "dependencies": {+ "ini": "^1.3.2"+ }+ },"node_modules/glob": {"version": "7.1.7","resolved": "https://registry.npmjs.org/glob/-/glob-7.1.7.tgz",@@ -7442,6 +7674,11 @@"mini-svg-data-uri": "cli.js"}},+ "node_modules/minimal-polyfills": {+ "version": "2.2.3",+ "resolved": "https://registry.npmjs.org/minimal-polyfills/-/minimal-polyfills-2.2.3.tgz",+ "integrity": "sha512-oxdmJ9cL+xV72h0xYxp4tP2d5/fTBpP45H8DIOn9pASuF8a3IYTf+25fMGDYGiWW+MFsuog6KD6nfmhZJQ+uUw=="+ },"node_modules/minimatch": {"version": "3.1.2","resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz",@@ -9231,6 +9468,14 @@"node": ">=6"}},+ "node_modules/run-exclusive": {+ "version": "2.2.19",+ "resolved": "https://registry.npmjs.org/run-exclusive/-/run-exclusive-2.2.19.tgz",+ "integrity": "sha512-K3mdoAi7tjJ/qT7Flj90L7QyPozwUaAG+CVhkdDje4HLKXUYC3N/Jzkau3flHVDLQVhiHBtcimVodMjN9egYbA==",+ "dependencies": {+ "minimal-polyfills": "^2.2.3"+ }+ },"node_modules/run-parallel": {"version": "1.2.0","resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz",@@ -9477,6 +9722,11 @@"node": ">=8"}},+ "node_modules/slug": {+ "version": "6.1.0",+ "resolved": "https://registry.npmjs.org/slug/-/slug-6.1.0.tgz",+ "integrity": "sha512-x6vLHCMasg4DR2LPiyFGI0gJJhywY6DTiGhCrOMzb3SOk/0JVLIaL4UhyFSHu04SD3uAavrKY/K3zZ3i6iRcgA=="+ },"node_modules/sonner": {"version": "1.0.3","resolved": "https://registry.npmjs.org/sonner/-/sonner-1.0.3.tgz",@@ -9805,6 +10055,18 @@"node": ">=8"}},+ "node_modules/supports-hyperlinks": {+ "version": "2.3.0",+ "resolved": "https://registry.npmjs.org/supports-hyperlinks/-/supports-hyperlinks-2.3.0.tgz",+ "integrity": "sha512-RpsAZlpWcDwOPQA22aCH4J0t7L8JmAvsCxfOSEwm7cQs3LshN36QaTkwd70DnBOXDWGssw2eUoc8CaRWT0XunA==",+ "dependencies": {+ "has-flag": "^4.0.0",+ "supports-color": "^7.0.0"+ },+ "engines": {+ "node": ">=8"+ }+ },"node_modules/supports-preserve-symlinks-flag": {"version": "1.0.0","resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz",@@ -9951,6 +10213,21 @@"node": ">=10"}},+ "node_modules/terminal-link": {+ "version": "3.0.0",+ "resolved": "https://registry.npmjs.org/terminal-link/-/terminal-link-3.0.0.tgz",+ "integrity": "sha512-flFL3m4wuixmf6IfhFJd1YPiLiMuxEc8uHRM1buzIeZPm22Au2pDqBJQgdo7n1WfPU1ONFGv7YDwpFBmHGF6lg==",+ "dependencies": {+ "ansi-escapes": "^5.0.0",+ "supports-hyperlinks": "^2.2.0"+ },+ "engines": {+ "node": ">=12"+ },+ "funding": {+ "url": "https://github.com/sponsors/sindresorhus"+ }+ },"node_modules/text-table": {"version": "0.2.0","resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz",@@ -10069,6 +10346,11 @@"resolved": "https://registry.npmjs.org/ts-interface-checker/-/ts-interface-checker-0.1.13.tgz","integrity": "sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA=="},+ "node_modules/tsafe": {+ "version": "1.6.5",+ "resolved": "https://registry.npmjs.org/tsafe/-/tsafe-1.6.5.tgz",+ "integrity": "sha512-895zss8xqqHKTc28sHGIfZKnt3C5jrstB1DyPr/h3/flK0zojsZUMQL1/W4ytdDW6KI4Oth62nb9rrxmA3s3Iw=="+ },"node_modules/tsconfig-paths": {"version": "3.14.2","resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.2.tgz",@@ -10400,6 +10682,14 @@"node": "*"}},+ "node_modules/ulid": {+ "version": "2.3.0",+ "resolved": "https://registry.npmjs.org/ulid/-/ulid-2.3.0.tgz",+ "integrity": "sha512-keqHubrlpvT6G2wH0OEfSW4mquYRcbe/J8NMmveoQOjUqmo+hXtO+ORCpWhdbZ7k72UtY61BL7haGxW6enBnjw==",+ "bin": {+ "ulid": "bin/cli.js"+ }+ },"node_modules/unbox-primitive": {"version": "1.0.2","resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz",@@ -10874,6 +11164,14 @@"funding": {"url": "https://github.com/sponsors/colinhacks"}+ },+ "node_modules/zod-error": {+ "version": "1.5.0",+ "resolved": "https://registry.npmjs.org/zod-error/-/zod-error-1.5.0.tgz",+ "integrity": "sha512-zzopKZ/skI9iXpqCEPj+iLCKl9b88E43ehcU+sbRoHuwGd9F1IDVGQ70TyO6kmfiRL1g4IXkjsXK+g1gLYl4WQ==",+ "dependencies": {+ "zod": "^3.20.2"+ }}},"dependencies": {@@ -12566,6 +12864,20 @@}}},+ "@tanstack/query-core": {+ "version": "5.0.0-beta.0",+ "resolved": "https://registry.npmjs.org/@tanstack/query-core/-/query-core-5.0.0-beta.0.tgz",+ "integrity": "sha512-VGq/H3PuRoj0shOcg1S5Flv3YD2qNz2ttk8w5xe5AHQE1I8NO9EHSBUxezIpk4dD6M7bQDtwHBMqqU2EwMwyUw=="+ },+ "@tanstack/react-query": {+ "version": "5.0.0-beta.2",+ "resolved": "https://registry.npmjs.org/@tanstack/react-query/-/react-query-5.0.0-beta.2.tgz",+ "integrity": "sha512-JdK1HRw20tuwg3GfT3QZTkuS7s2KDa9FeozuJ7jZULlwPczZagouqYmM6+PL0ad6jfCnw8NzmLFtZdlBx6cTmA==",+ "requires": {+ "@tanstack/query-core": "5.0.0-beta.0",+ "client-only": "0.0.1"+ }+ },"@tootallnate/once": {"version": "2.0.0","resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-2.0.0.tgz",@@ -12586,6 +12898,87 @@"tailwind-merge": "^1.9.1"}},+ "@trigger.dev/core": {+ "version": "2.2.0",+ "resolved": "https://registry.npmjs.org/@trigger.dev/core/-/core-2.2.0.tgz",+ "integrity": "sha512-BtPnNt5rd4i92jthM6CVRgZ31qWyyzXAaicrvs6Xmk0MRasrbyvSU9g4FmUTcM+9ne1UiZ3Mh38y0hLMGfrCGQ==",+ "requires": {+ "ulid": "^2.3.0",+ "zod": "3.22.3",+ "zod-error": "1.5.0"+ },+ "dependencies": {+ "zod": {+ "version": "3.22.3",+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.22.3.tgz",+ "integrity": "sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug=="+ }+ }+ },+ "@trigger.dev/nextjs": {+ "version": "2.2.0",+ "resolved": "https://registry.npmjs.org/@trigger.dev/nextjs/-/nextjs-2.2.0.tgz",+ "integrity": "sha512-2djyu03AyF/XT8e3MHegA4DiUxWoEocGht9hcGTON0DxsCJegrQwjPcQ79sZ1uxP53I7m88raD6vLQjJKZ8PQw==",+ "requires": {+ "debug": "^4.3.4"+ }+ },+ "@trigger.dev/react": {+ "version": "2.2.0",+ "resolved": "https://registry.npmjs.org/@trigger.dev/react/-/react-2.2.0.tgz",+ "integrity": "sha512-sp2p+PYM5DRmzFOla0sYUoptxVu1X7qpN0nqUU2VcumWHtf2JjA4rhkHIxmgP7vs84itruiTX+SOR2SmtHWODQ==",+ "requires": {+ "@tanstack/react-query": "5.0.0-beta.2",+ "@trigger.dev/core": "^2.2.0",+ "debug": "^4.3.4",+ "zod": "3.22.3"+ },+ "dependencies": {+ "zod": {+ "version": "3.22.3",+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.22.3.tgz",+ "integrity": "sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug=="+ }+ }+ },+ "@trigger.dev/sdk": {+ "version": "2.2.0",+ "resolved": "https://registry.npmjs.org/@trigger.dev/sdk/-/sdk-2.2.0.tgz",+ "integrity": "sha512-gyRly4mGVMwdH3lrVBXDxTFf1b3GKj7BOGg/xUQh/hV7iFJLCo4Vf0K+2CL/R8YUA3kFZCsFJfVUOqwaYwX0Eg==",+ "requires": {+ "@trigger.dev/core": "^2.2.0",+ "chalk": "^5.2.0",+ "cronstrue": "^2.21.0",+ "debug": "^4.3.4",+ "evt": "^2.4.13",+ "get-caller-file": "^2.0.5",+ "git-remote-origin-url": "^4.0.0",+ "git-repo-info": "^2.1.1",+ "slug": "^6.0.0",+ "terminal-link": "^3.0.0",+ "ulid": "^2.3.0",+ "uuid": "^9.0.0",+ "ws": "^8.11.0",+ "zod": "3.22.3"+ },+ "dependencies": {+ "chalk": {+ "version": "5.3.0",+ "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.3.0.tgz",+ "integrity": "sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w=="+ },+ "uuid": {+ "version": "9.0.1",+ "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz",+ "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA=="+ },+ "zod": {+ "version": "3.22.3",+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.22.3.tgz",+ "integrity": "sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug=="+ }+ }+ },"@types/bcryptjs": {"version": "2.4.4","resolved": "https://registry.npmjs.org/@types/bcryptjs/-/bcryptjs-2.4.4.tgz",@@ -12940,6 +13333,21 @@"dlv": "^1.1.3"}},+ "ansi-escapes": {+ "version": "5.0.0",+ "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-5.0.0.tgz",+ "integrity": "sha512-5GFMVX8HqE/TB+FuBJGuO5XG0WrsA6ptUqoODaT/n9mmUaZFkqnBueB4leqGBCmrUHnCnC4PCZTCd0E7QQ83bA==",+ "requires": {+ "type-fest": "^1.0.2"+ },+ "dependencies": {+ "type-fest": {+ "version": "1.4.0",+ "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-1.4.0.tgz",+ "integrity": "sha512-yGSza74xk0UG8k+pLh5oeoYirvIiWo5t0/o3zHHAO2tRDiZcxWP7fywNlXhqb6/r6sWvwi+RsyQMWhVLe4BVuA=="+ }+ }+ },"ansi-regex": {"version": "5.0.1","resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz",@@ -13485,6 +13893,11 @@"resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz","integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ=="},+ "cronstrue": {+ "version": "2.32.0",+ "resolved": "https://registry.npmjs.org/cronstrue/-/cronstrue-2.32.0.tgz",+ "integrity": "sha512-dmNflOCNJL6lZEj0dp2YhGIPY83VTjFue6d9feFhnNtrER6mAjBrUvSgK95j3IB/xNGpLjaZDIDG6ACKTZr9Yw=="+ },"cross-spawn": {"version": "7.0.3","resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz",@@ -14563,6 +14976,16 @@"resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz","integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw=="},+ "evt": {+ "version": "2.5.3",+ "resolved": "https://registry.npmjs.org/evt/-/evt-2.5.3.tgz",+ "integrity": "sha512-wZKx0JgXaTOVOXI2saNVxINU6VToOHDowMwb3NRcU6l+C59eW3w9dZgNxjokiM8rvMgc7/11yFG0cSDxn4qxgA==",+ "requires": {+ "minimal-polyfills": "^2.2.3",+ "run-exclusive": "^2.2.19",+ "tsafe": "^1.6.5"+ }+ },"execa": {"version": "7.1.1","resolved": "https://registry.npmjs.org/execa/-/execa-7.1.1.tgz",@@ -14834,6 +15257,11 @@"wide-align": "^1.1.2"}},+ "get-caller-file": {+ "version": "2.0.5",+ "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",+ "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg=="+ },"get-intrinsic": {"version": "1.2.1","resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz",@@ -14872,6 +15300,27 @@"resolve-pkg-maps": "^1.0.0"}},+ "git-remote-origin-url": {+ "version": "4.0.0",+ "resolved": "https://registry.npmjs.org/git-remote-origin-url/-/git-remote-origin-url-4.0.0.tgz",+ "integrity": "sha512-EAxDksNdjuWgmVW9pVvA9jQDi/dmTaiDONktIy7qiRRhBZUI4FQK1YvBvteuTSX24aNKg9lfgxNYJEeeSXe6DA==",+ "requires": {+ "gitconfiglocal": "^2.1.0"+ }+ },+ "git-repo-info": {+ "version": "2.1.1",+ "resolved": "https://registry.npmjs.org/git-repo-info/-/git-repo-info-2.1.1.tgz",+ "integrity": "sha512-8aCohiDo4jwjOwma4FmYFd3i97urZulL8XL24nIPxuE+GZnfsAyy/g2Shqx6OjUiFKUXZM+Yy+KHnOmmA3FVcg=="+ },+ "gitconfiglocal": {+ "version": "2.1.0",+ "resolved": "https://registry.npmjs.org/gitconfiglocal/-/gitconfiglocal-2.1.0.tgz",+ "integrity": "sha512-qoerOEliJn3z+Zyn1HW2F6eoYJqKwS6MgC9cztTLUB/xLWX8gD/6T60pKn4+t/d6tP7JlybI7Z3z+I572CR/Vg==",+ "requires": {+ "ini": "^1.3.2"+ }+ },"glob": {"version": "7.1.7","resolved": "https://registry.npmjs.org/glob/-/glob-7.1.7.tgz",@@ -15912,6 +16361,11 @@"integrity": "sha512-r9deDe9p5FJUPZAk3A59wGH7Ii9YrjjWw0jmw/liSbHl2CHiyXj6FcDXDu2K3TjVAXqiJdaw3xxwlZZr9E6nHg==","dev": true},+ "minimal-polyfills": {+ "version": "2.2.3",+ "resolved": "https://registry.npmjs.org/minimal-polyfills/-/minimal-polyfills-2.2.3.tgz",+ "integrity": "sha512-oxdmJ9cL+xV72h0xYxp4tP2d5/fTBpP45H8DIOn9pASuF8a3IYTf+25fMGDYGiWW+MFsuog6KD6nfmhZJQ+uUw=="+ },"minimatch": {"version": "3.1.2","resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz",@@ -17113,6 +17567,14 @@}}},+ "run-exclusive": {+ "version": "2.2.19",+ "resolved": "https://registry.npmjs.org/run-exclusive/-/run-exclusive-2.2.19.tgz",+ "integrity": "sha512-K3mdoAi7tjJ/qT7Flj90L7QyPozwUaAG+CVhkdDje4HLKXUYC3N/Jzkau3flHVDLQVhiHBtcimVodMjN9egYbA==",+ "requires": {+ "minimal-polyfills": "^2.2.3"+ }+ },"run-parallel": {"version": "1.2.0","resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz",@@ -17275,6 +17737,11 @@"resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz","integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q=="},+ "slug": {+ "version": "6.1.0",+ "resolved": "https://registry.npmjs.org/slug/-/slug-6.1.0.tgz",+ "integrity": "sha512-x6vLHCMasg4DR2LPiyFGI0gJJhywY6DTiGhCrOMzb3SOk/0JVLIaL4UhyFSHu04SD3uAavrKY/K3zZ3i6iRcgA=="+ },"sonner": {"version": "1.0.3","resolved": "https://registry.npmjs.org/sonner/-/sonner-1.0.3.tgz",@@ -17519,6 +17986,15 @@"has-flag": "^4.0.0"}},+ "supports-hyperlinks": {+ "version": "2.3.0",+ "resolved": "https://registry.npmjs.org/supports-hyperlinks/-/supports-hyperlinks-2.3.0.tgz",+ "integrity": "sha512-RpsAZlpWcDwOPQA22aCH4J0t7L8JmAvsCxfOSEwm7cQs3LshN36QaTkwd70DnBOXDWGssw2eUoc8CaRWT0XunA==",+ "requires": {+ "has-flag": "^4.0.0",+ "supports-color": "^7.0.0"+ }+ },"supports-preserve-symlinks-flag": {"version": "1.0.0","resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz",@@ -17626,6 +18102,15 @@}}},+ "terminal-link": {+ "version": "3.0.0",+ "resolved": "https://registry.npmjs.org/terminal-link/-/terminal-link-3.0.0.tgz",+ "integrity": "sha512-flFL3m4wuixmf6IfhFJd1YPiLiMuxEc8uHRM1buzIeZPm22Au2pDqBJQgdo7n1WfPU1ONFGv7YDwpFBmHGF6lg==",+ "requires": {+ "ansi-escapes": "^5.0.0",+ "supports-hyperlinks": "^2.2.0"+ }+ },"text-table": {"version": "0.2.0","resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz",@@ -17720,6 +18205,11 @@"resolved": "https://registry.npmjs.org/ts-interface-checker/-/ts-interface-checker-0.1.13.tgz","integrity": "sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA=="},+ "tsafe": {+ "version": "1.6.5",+ "resolved": "https://registry.npmjs.org/tsafe/-/tsafe-1.6.5.tgz",+ "integrity": "sha512-895zss8xqqHKTc28sHGIfZKnt3C5jrstB1DyPr/h3/flK0zojsZUMQL1/W4ytdDW6KI4Oth62nb9rrxmA3s3Iw=="+ },"tsconfig-paths": {"version": "3.14.2","resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.2.tgz",@@ -17916,6 +18406,11 @@"resolved": "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-1.0.36.tgz","integrity": "sha512-znuyCIXzl8ciS3+y3fHJI/2OhQIXbXw9MWC/o3qwyR+RGppjZHrM27CGFSKCJXi2Kctiz537iOu2KnXs1lMQhw=="},+ "ulid": {+ "version": "2.3.0",+ "resolved": "https://registry.npmjs.org/ulid/-/ulid-2.3.0.tgz",+ "integrity": "sha512-keqHubrlpvT6G2wH0OEfSW4mquYRcbe/J8NMmveoQOjUqmo+hXtO+ORCpWhdbZ7k72UtY61BL7haGxW6enBnjw=="+ },"unbox-primitive": {"version": "1.0.2","resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz",@@ -18263,6 +18758,14 @@"version": "3.22.4","resolved": "https://registry.npmjs.org/zod/-/zod-3.22.4.tgz","integrity": "sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg=="+ },+ "zod-error": {+ "version": "1.5.0",+ "resolved": "https://registry.npmjs.org/zod-error/-/zod-error-1.5.0.tgz",+ "integrity": "sha512-zzopKZ/skI9iXpqCEPj+iLCKl9b88E43ehcU+sbRoHuwGd9F1IDVGQ70TyO6kmfiRL1g4IXkjsXK+g1gLYl4WQ==",+ "requires": {+ "zod": "^3.20.2"+ }}}}diff --git a/package.json b/package.jsonindex 17c3c67e..8250a540 100644--- a/package.json+++ b/package.json@@ -35,6 +35,9 @@"@stripe/stripe-js": "^2.1.7","@tailwindcss/typography": "^0.5.10","@tremor/react": "^3.8.2",+ "@trigger.dev/nextjs": "^2.2.0",+ "@trigger.dev/react": "^2.2.0",+ "@trigger.dev/sdk": "^2.2.0","@types/node": "^20.8.4","@types/react": "^18.2.27","@types/react-dom": "^18.2.12",@@ -84,5 +87,8 @@"@types/ms": "^0.7.32","@types/ua-parser-js": "^0.7.37","prisma": "^4.16.2"+ },+ "trigger.dev": {+ "endpointId": "papermark-dev-Ojwu"}}diff --git a/trigger.ts b/trigger.tsnew file mode 100644index 00000000..b802654c--- /dev/null+++ b/trigger.ts@@ -0,0 +1,7 @@+import { TriggerClient } from "@trigger.dev/sdk";++export const client = new TriggerClient({+ id: "papermark-dev-Ojwu",+ apiKey: process.env.TRIGGER_API_KEY,+ apiUrl: process.env.TRIGGER_API_URL,+});