Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

Merge branch 'main' into bank-debits

Steven Tey25f38e69c32b
diff --cc apps/web/lib/partners/constants.ts
index 4be33a1ffc,81c6671198..02d987ccb9
--- a/apps/web/lib/partners/constants.ts
+++ b/apps/web/lib/partners/constants.ts
@@@ -15,58 -12,11 +15,59 @@@ export const PAYOUT_FEES =
card: 0.08,
},
enterprise: {
- ach: 0.03,
+ direct_debit: 0.03,
card: 0.06,
},
-};
-
-export const DUB_MIN_PAYOUT_AMOUNT_CENTS = 10000; // 100 USD
+} as const;
+export const DUB_MIN_PAYOUT_AMOUNT_CENTS = 10000;
+ export const PAYOUT_FAILURE_FEE_CENTS = 1000; // 10 USD
+
+// Direct debit payment types for Partner payout
+export const DIRECT_DEBIT_PAYMENT_TYPES_INFO: {
+ type: Stripe.PaymentMethod.Type;
+ location: string;
+ title: string;
+ icon: string;
+ option: PaymentMethodOption;
+}[] = [
+ {
+ type: "us_bank_account",
+ location: "US",
+ title: "ACH",
+ icon: "https://hatscripts.github.io/circle-flags/flags/us.svg",
+ option: {},
+ },
+ {
+ type: "acss_debit",
+ location: "CA",
+ title: "ACSS Debit",
+ icon: "https://hatscripts.github.io/circle-flags/flags/ca.svg",
+ option: {
+ currency: "cad",
+ mandate_options: {
+ payment_schedule: "sporadic",
+ transaction_type: "business",
+ },
+ },
+ },
+ {
+ type: "sepa_debit",
+ location: "EU",
+ title: "SEPA Debit",
+ icon: "https://hatscripts.github.io/circle-flags/flags/eu.svg",
+ option: {},
+ },
+];
+
+export const DIRECT_DEBIT_PAYMENT_METHOD_TYPES: Stripe.PaymentMethod.Type[] = [
+ "us_bank_account",
+ "acss_debit",
+ "sepa_debit",
+];
+
+export const PAYMENT_METHOD_TYPES: Stripe.PaymentMethod.Type[] = [
+ "card",
+ "link",
+ ...DIRECT_DEBIT_PAYMENT_METHOD_TYPES,
+];