Forum Academy Marketplace Showcase Pricing Features

"Formatted As..." Causes An Error Even Though It's A Number

I’ve got a field that is a number type but when I select “formatted as…” it creates an error in the error checker and says that the field should be a number… but it is a number and I’m not understanding why or what’s causing it. ?

Any time you format something, it changes it into a text.

You should save the value without formatting, and only format it when you’re displaying it.

2 Likes

Ahhh.

The problem I’m having is it strings a charge that is too long, like $86.666666666 and when I go to capture the users card by direct API call to stripe (vs. bubble which does not do capture yet) it gives me an invalid integer error.

Oh, ok.

In that case, use :rounded at the end of the number, and set it to 2. That way, you’ll get the number that you’re looking for.

Also, when making an API call to Stripe, you’ll most likely need to multiply your decimal by 100, as Stripe doesn’t accept decimals in their API call.

So a $10 charge would be sent to Stripe as 1000, versus $0.76 being sent as 76.

1 Like

Worked!

Now, any idea how to Pay Another User using the Stripe API vs. the built in Bubble Stripe plugin?

I need to capture a charge which bubble doesn’t allow yet, and pay a portion of that charge to another user.

You can do the calculations on Bubble’s side, and then just pay the correct amount either to your user’s bank accounts, or directly to their debit cards.

Sending payouts with Stripe.
Sending payouts to debit cards.

The problem is I’ve got payouts to countries outside of USA and these functions only work for US based accounts.

When a user is a payee, do they simply signup for a Stripe account like they would a PayPal account and configure their bank account for withdrawls?

Gotcha.

I don’t really have any experience doing international payouts with Stripe. I usually use the methods above.

I’m not sure that Stripe has a way to send payouts to countries outside of the U.S. currently. Not to my knowledge, at least. I could very well be wrong. But you may have to find another API to do that. Some other options are listed here.

Inside of Bubble, when the payee is another user, does it use the “pay out” features on Stripe to faciliate this? i.e. ACH?

Is this stripe connect?

No, it’s as you mentioned before. They have their own Stripe account that they setup with their own bank account information, and it’s sent to their Stripe balance. From there, Stripe handles paying out the money to their bank account.

Yes, it’s essentially Stripe Connect.

1 Like

Is there a working app that has “Sending payouts with Stripe” connected?

How do we make the API calls work with Bubble is what I’m trying to figure out.