#Santhosh Kumar R - PaymentLinks
1 messages · Page 1 of 1 (latest)
Java
Got it. PaymentLink support was added in version 20.97.0
https://github.com/stripe/stripe-java/blob/master/CHANGELOG.md#20970---2022-01-20
then the price api fails for unknown reason
Can you share more details about this? What is your code doing exactly? And what's the error message?
I am attaching a dynamic price to my product everytime customer checkout..and then generate a paymentlink and sent it to the customer
Which part of this is causing the error?
when i am using the latest version of 22.8.0 the price part failed..I am now trying with the 20.97.0 to attach price and generate a paymentlink against it..
when i am using the latest version of 22.8.0 the price part failed.
But can you give more details on exactly what failed? Like can you share the code that returns an error, and also share the error message you see? Without this information I cannot help.
Ok let me switch to 22.8.0 and hit the error
in the meanwhile. I am .setUnitAmountDecimal(BigDecimal.valueOf(myobjct.getTotalAmount())) using this to set my amount value for example 110.00 however in the stripe dashboard its alwas pricing as 1.10
Can you share the request ID (req_xxx) where you saw this? Here's how you can find it: https://support.stripe.com/questions/finding-the-id-for-an-api-request
when i switch to 22.8.0 the request fails abruptly..i dont see any logs on the stripe developer
Price price = Price.create(params); Throws error and is not caught in the immediate catch block
?
If it creates a price, there should be a dashboard log
Do you have the ID of the price that was created this way (price_1234)?
It sounds like you may be trying to give the price in dollars (or pounds, etc) but our API expects the price to be in cents. If you multiply your price by 100 you should get the one that you are expecting
no it fails in the above step
What is the full error being thrown?
the same code when i switch to 20.97.0 works fine
Good to hear! So all of this code is working now?
yes except for the below issue>>
during pricing
setUnitAmountDecimal(BigDecimal.valueOf(myobjct.getTotalAmount())) using this to set my amount value for example 110.00 however in the stripe dashboard its alwas pricing as 1.10