refactor: remove supabase auth
This commit is contained in:
20
packages/stripe/src/index.ts
Normal file
20
packages/stripe/src/index.ts
Normal file
@@ -0,0 +1,20 @@
|
||||
import { Stripe } from "stripe";
|
||||
|
||||
export const name = "stripe";
|
||||
|
||||
const stripeSecretKey = process.env.STRIPE_SECRET_KEY;
|
||||
|
||||
const createStripeClient = () => {
|
||||
if (!stripeSecretKey) {
|
||||
throw new Error("STRIPE_SECRET_KEY is not set");
|
||||
}
|
||||
|
||||
const stripe = new Stripe(stripeSecretKey, {
|
||||
apiVersion: "2025-04-30.basil",
|
||||
httpClient: Stripe.createFetchHttpClient(),
|
||||
});
|
||||
|
||||
return stripe;
|
||||
};
|
||||
|
||||
export { createStripeClient };
|
||||
Reference in New Issue
Block a user