Added standard payment processing for Stripe BOD-146.
This commit is contained in:
@@ -16,27 +16,13 @@ exports.payment = async (req, res) => {
|
||||
console.log("exports.payment -> amount", amount);
|
||||
console.log("exports.payment -> stripe_acct_id", stripe_acct_id);
|
||||
try {
|
||||
|
||||
const pr = await stripe.paymentRequest.create({
|
||||
country: "CA",
|
||||
currency: "cad",
|
||||
total: {
|
||||
label: "Demo total",
|
||||
amount: 1099,
|
||||
},
|
||||
requestPayerName: true,
|
||||
requestPayerEmail: true,
|
||||
});
|
||||
|
||||
console.log(pr);
|
||||
|
||||
await stripe.paymentIntents
|
||||
.create(
|
||||
{
|
||||
payment_method_types: ["card"],
|
||||
amount: amount,
|
||||
currency: "cad",
|
||||
application_fee_amount: 100,
|
||||
application_fee_amount: 50,
|
||||
},
|
||||
{
|
||||
stripeAccount: stripe_acct_id,
|
||||
|
||||
Reference in New Issue
Block a user