#dowabes219

1 messages · Page 1 of 1 (latest)

wet ospreyBOT
strong ingot
fiery kernel
#

I need to pass float value

strong ingot
#

Ok, but to which endpoint/parameter?

fiery kernel
#
    amount=(price),
    currency='usd',
    automatic_payment_methods={
        'enabled': True,
    },
)```
strong ingot
#

Yep, amount expects an integer in the lowest currency denominator (so for USD, cents)

#

So if you want to charge $664.62, you'd send amount: 66462

fiery kernel
#

how this will know where is is "."?

#

maybe I want to charge 66462$

strong ingot
#

I don't understand

#

Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the smallest currency unit (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or equivalent in charge currency. The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).

fiery kernel
#

do I need to point cents instead of $?

#

by default is it accept cents or dollars?

strong ingot
#

As explained, amount is in the lowest currency unit (i.e. cents)

#

So $664.62 = 66462