#xdarknox_unexpected

1 messages ¡ Page 1 of 1 (latest)

obsidian cypressBOT
#

👋 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/1289064870444142666

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

queen oxide
#

Hello, i am in the same team as thiago.nobre in this server, the case he openned in this server is related to our system, we have a problem in integrating our django app with stripe, after reading all the api documentation, he @hearty moat could make it work, but only with one time payment.

dense cradle
#

Could you please summarize the issue again? And the thread URL

queen oxide
#

We want now to make it works with installments, but the problem is that we can't make the api "enable" that option.

On API docs, explain that we need to set a atribute

#

sum everything

#

with this code over here as a test:

import stripe

# Set your secret key
stripe.api_key = "your_stripe_secret_key"

try:
    # Create a PaymentSession with installment options
    payment_session = stripe.PaymentSession.create(
        amount=2000,  # amount in cents
        currency="brl",  # currency code
        payment_method_types=["card"],  # specify the payment method
        payment_method_options={
            "card": {
                "installments": {
                    "enabled": True,  # enable installments
                    "plan": {
                        "count": 3,  # number of installments
                        "interval": "month"  # interval between installments
                    }
                }
            }
        }
    )
    print("PaymentSession created successfully:", payment_session)
except Exception as e:
    print("Error creating PaymentSession:", str(e))
#

we get a error where is don't know these arguments:

        payment_method_options={
            "card": {
                "installments": {
                    "enabled": True,  # enable installments
                    "plan": {
                        "count": 3,  # number of installments
                        "interval": "month"  # interval between installments
                    }
                }
            }
        }
#

hoo, by do way, this part:

        amount=2000,  # amount in cents
        currency="brl",  # currency code
        payment_method_types=["card"],  # specify the payment method

is wrongly too, but he @hearty moat could make it work in another way.

#

the problem now is about the installments...

dense cradle
#

How does your teammate make it work? Changing from which code to which code?

#

We mentioned that we don't support installments in Brazil yet, unfortunately

queen oxide
#

i will ask him the code.

#

as i said, the part that is working is with one time payment.

#

so we need to make a internal installment system?

dense cradle
queen oxide
#

okay, gonna ask him, can you wait a little?

#

because its 00:35 on brazil, so he is sleeping already...

#

gonna ask these informations you asked, dashboard, and the code too.

dense cradle
#

Feel free to come back whenever you have the info and request a new thread. We may need to close the thread when our staffing changes

queen oxide
#

okay, gonna save a "link" to this thread just to "link" everything.

dense cradle
#

Well you can tell him to open a new thread and we will have an automatic link to his past threads there. We group by the asker handle