#amirny2205_error

1 messages · Page 1 of 1 (latest)

astral wyvernBOT
#

👋 Welcome to your new thread!

⏱️ We automatically close idle threads, which makes them read-only. Make sure you stick around to chat in realtime!

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1212004857389785108

📝 Have more to share? You can add more detail below, including code, screenshots, videos, etc.

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question. Thank you for your patience!

near yewBOT
shell jay
#

hi there!

still remnant
#

Oh it worked for some time, then just stopped working
hi soma!

shell jay
#

if you are trying to confirm a PaymentIntent, it should be a POST request, not a GET request

still remnant
shell jay
#

cna you share the code that generated that error?

still remnant
#

sure, a few minutes

#

https://dpaste.org/P3NZd
this is basically almost the same as in quickstart, I just changed createIntent url and return url

shell jay
#

which explains the issue:

message: "Not a valid URL",
param: "return_url",
#

you set the return_url to "/admin/", which is not a valid url

still remnant
#

well, it doesn't make any difference,
actually I have the url /admin/ in my django server, and at first it worked well

#

oh wait I understand

#

I'll try on my own and return if there is still an issue

shell jay
#

but that's still not a full URL. it should be something like https://www.example.com/success/

still remnant
#

so when I'm developing an app I should have a VPS up and serving a success page?

shell jay
#

it should also work with a locallhost URL, but you really need a full absolute URL.

still remnant
#

oh I understand. Thank you very much, it works. I hope I won't get any other erors though
thank you very much @shell jay

shell jay
#

happy to help 🙂

still remnant
#

I can't create a new thread because it shows : You already have an open thread: ⁠amirny2205_error
So I'll ask here
I have a few questions:
1)in a stripe session, you can set up items, tax, discount
how do I do that with paymentIntents? Or is it supposed to be a diferent type of feature?
2)if I can add several items to my paymentIntent, what would be the best practice if there are items with different currency?
Thank you very much

shell jay
#
  1. you can't do that with PaymentIntent
  2. a PaymentIntent can have a single currency