Click here to Skip to main content
15,887,989 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
So, I'm not sure if this is a coding error or a misunderstanding of the Stripe Connect process on my part, but I'm trying to make a charge using the Stripe .NET wrapper. My code is below:

C#
int chargeAmount = 2014;
int appFee = 1986;

var stripeChargeOption = new StripeChargeCreateOptions()
                            {
                                AmountInCents = chargeAmount,
                                Currency = "cad",
                                Card = stripeToken.Id,
                                Description = "Your Purchase with Coupons4Giving - " + info.Merchant.Name,
                                ApplicationFeeInCents = appFee
                            };
                            var response = stripeService.Create(stripeChargeOption);


The problem is when I go and look at what's actually gone through, the values differ from what I specify in this call. On Stripe's side, it shows the Application Fee as being $19.26 (which is $20.14 minus Stripe's fee of 2.9% + $0.30).

Can anyone tell me why my Application Fee is $20.14 instead of the $19.86 I've attempted to specify?

Thanks!
Posted

Your question should be asked in the forums here[^]. It's very unlikely that you're going to find anyone here who has used that library.

But, it seems obvious to me that you set a variable called chargeAmount as an integer 2014, then passed it to some parameter that your library expects, AmountInCents. Sooooo.... again. You're probably not going to find anyone here who knows that library.
 
Share this answer
 
v2
Okay, well just in case anyone else comes across this thread and can be helped by it, Stripe takes the Application Fee out of the total Charge. My mistake was thinking that it added the fee to the charge, thus a $2 charge with a $2.25 fee won't work (the fee gets dropped to $2, as that's the most it can be).
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900