#SteveLoyer
1 messages ยท Page 1 of 1 (latest)
Hi ๐ we do not have prebuilt functionality for passing processing fees to your customers, you will need to build the logic and math for doing that if it is something you'd like to accomplish.
Okay So i am doing this already --- But my issue is i want to pass the discount before the proccessing fee (The discount is being applied via a coupon)
No matter how i seem to try and do this the processing fee always comes after processing fee
Sorry there is a little debugging code for a cart total im workign with now
If you know the discount will be applied to the processing fee, can't you inflate the fee so when the discount changes it the value is returned to the expected amount?
I guess, but it would take quite a big of logic as discounts change by amount spent
The other option is to rebuild your Coupons so they don't apply to whatever product you're using to represent the Stripe fees.
Can you elaborate a little more
Coupons can be configured so they can only be applied to certain Products:
https://stripe.com/docs/api/coupons/create#create_coupon-applies_to
I believe you may be able to leverage that behavior so that your Coupons don't discount your fee line item.
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Is the processing fee right now considered a product?
If you're using Checkout Sessions, then everything has to be associated with a Product object. Either by being associated with a Price that is already associated with a Product, by you specifying a product via line_items.price_data.product, or by creating a Product adhoc by providing enough data in line_items.price_data.product_data.