The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
update endpoints
Steven Tey5fc71a2cfaf8
diff --git a/apps/web/app/api/campaigns/callback/stripe/route.ts b/apps/web/app/api/stripe/connect/callback/route.tssimilarity index 100%rename from apps/web/app/api/campaigns/callback/stripe/route.tsrename to apps/web/app/api/stripe/connect/callback/route.tsdiff --git a/apps/web/app/api/campaigns/webhooks/stripe/checkout-session-completed.ts b/apps/web/app/api/stripe/connect/webhook/checkout-session-completed.tssimilarity index 100%rename from apps/web/app/api/campaigns/webhooks/stripe/checkout-session-completed.tsrename to apps/web/app/api/stripe/connect/webhook/checkout-session-completed.tsdiff --git a/apps/web/app/api/campaigns/webhooks/stripe/customer-created.ts b/apps/web/app/api/stripe/connect/webhook/customer-created.tssimilarity index 100%rename from apps/web/app/api/campaigns/webhooks/stripe/customer-created.tsrename to apps/web/app/api/stripe/connect/webhook/customer-created.tsdiff --git a/apps/web/app/api/campaigns/webhooks/stripe/invoice-paid.ts b/apps/web/app/api/stripe/connect/webhook/invoice-paid.tssimilarity index 100%rename from apps/web/app/api/campaigns/webhooks/stripe/invoice-paid.tsrename to apps/web/app/api/stripe/connect/webhook/invoice-paid.tsdiff --git a/apps/web/app/api/campaigns/webhooks/stripe/route.ts b/apps/web/app/api/stripe/connect/webhook/route.tssimilarity index 100%rename from apps/web/app/api/campaigns/webhooks/stripe/route.tsrename to apps/web/app/api/stripe/connect/webhook/route.tsdiff --git a/apps/web/app/api/stripe/webhook/route.ts b/apps/web/app/api/stripe/webhook/route.tsnew file mode 100644index 0000000000..38e4153c39--- /dev/null+++ b/apps/web/app/api/stripe/webhook/route.ts@@ -0,0 +1 @@+export * from "../../callback/stripe/route";diff --git a/apps/web/app/api/workspaces/[idOrSlug]/connect-stripe/route.ts b/apps/web/app/api/workspaces/[idOrSlug]/connect-stripe/route.tsindex b893d88286..bcc5aece62 100644--- a/apps/web/app/api/workspaces/[idOrSlug]/connect-stripe/route.ts+++ b/apps/web/app/api/workspaces/[idOrSlug]/connect-stripe/route.ts@@ -32,7 +32,7 @@ export const POST = withWorkspace(async ({ workspace }) => {url.searchParams.set("client_id", STRIPE_APP_CLIENT_ID);url.searchParams.set("redirect_uri",- `${APP_DOMAIN_WITH_NGROK}/api/campaigns/callback/stripe`,+ `${APP_DOMAIN_WITH_NGROK}/api/stripe/connect/callback`,);url.searchParams.set("state", state);diff --git a/packages/stripe-app/stripe-app.json b/packages/stripe-app/stripe-app.jsonindex e6f7d4f7a6..a500616e32 100644--- a/packages/stripe-app/stripe-app.json+++ b/packages/stripe-app/stripe-app.json@@ -1,6 +1,6 @@{"id": "com.example.dub",- "version": "0.0.21",+ "version": "0.0.23","name": "Dub","icon": "","permissions": [@@ -45,8 +45,8 @@}},"allowed_redirect_uris": [- "https://6dc0-103-70-36-143.ngrok-free.app/api/campaigns/callback/stripe",- "https://rich-easily-kingfish.ngrok-free.app/api/campaigns/callback/stripe"+ "https://6dc0-103-70-36-143.ngrok-free.app/api/stripe/connect/callback",+ "https://rich-easily-kingfish.ngrok-free.app/api/stripe/connect/callback"],"stripe_api_access_type": "oauth","distribution_type": "public"