#kareem_api
1 messages ยท Page 1 of 1 (latest)
๐ Welcome to your new thread!
โฒ๏ธ 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.
โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
๐ 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/1234495441115021415
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
Hi ๐ I'm pretty sure it's an invalid_request_error. Do you see something different when you test that flow?
hey toby!
yeah I'm sure that's the general code but was looking for something more specific
Request req_ogszNwDoei9YiZ: No such subscription: 'sub_1P7GUbKRFSLReU4y7eHhzDPa'
ah interesting, I get this back
Ah, you wanted the error message not the error code?
try:
stripe.Refund.create(
payment_intent=payment_intent_id, **self._extra_client_kwargs()
)
except stripe.error.InvalidRequestError as err:
if err.code in ("charge_already_refunded", "charge_not_refundable"):
return
raise
so for example refunding a payment this code is available
invalid_request_error is the type
Fair, do you have what you need?
Fair, do you have what you need?
kinda, I just wanna make sure I'm missing anything stupid here
the error message seems to be a bit odd that it gives a not found error for this
I see the Subscription you're referring to was already canceled. Are you able to retrieve it using it's ID still? I agree the error isn't the most clear if that Subscription is still accessible via its ID.