#suraj-patidar_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/1443954567325679828
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
stripe_line_items = [
{"price": settings.CARD_VERIFICATION_FEES_ID, "quantity": 1},
]
session = stripe.checkout.Session.create(
expires_at=int(time.time()) + settings.STRIPE_CHECKOUT_SESSION_EXPIRE,
payment_method_types=["card"],
customer=stripe_customer_id,
line_items=stripe_line_items,
metadata=stripe_metadata,
payment_intent_data={"setup_future_usage": "off_session"},
mode="payment",
success_url=f"{prefix}{settings.NEXT_PUBLIC_MARINA_ADMIN}/payment/subscription/success?ref={reference_id}&secure_token={secure_token}&time={int(time.time())}",
cancel_url=f"{prefix}{settings.NEXT_PUBLIC_MARINA_ADMIN}/payment/subscription/failed?ref={reference_id}&secure_token={secure_token}&time={int(time.time())}",
)
or evne if i setup
session = stripe.checkout.Session.create(
customer=stripe_customer_id,
mode="setup",
ui_mode="hosted",
currency="usd",
metadata=stripe_metadata,
success_url=f"{prefix}{settings.NEXT_PUBLIC_MARINA_ADMIN}/payment/subscription/success?ref={reference_id}&secure_token={secure_token}&time={int(time.time())}",
cancel_url=f"{prefix}{settings.NEXT_PUBLIC_MARINA_ADMIN}/payment/subscription/failed?ref={reference_id}&secure_token={secure_token}&time={int(time.time())}",
)
client want
Is the left column customizable ?
We would like to add some information like:
Product: PRO Free Trial
Starting: current date
Ending: current date+6month
We will charge $1 to your credit card to verify it.
hey there ๐ the left column isn't directly customisable, but the details you're referring to (product name, start date, trial info, etc) are all included on the left automatically when you use mode: 'subscription'
is there a specific reason you're currently using 'payment' and 'setup' mode, but not 'subscription?
it's possible to add custom text/policies to the checkout page, but not specifically on the left side of the page from your screenshot
https://docs.stripe.com/payments/checkout/customization/policies
we are not use stripe subscription flow we have use our own that's why i use mode payment
ok! in that case your customisation options are limited to those described here: https://docs.stripe.com/payments/checkout/customization
specifically in relation to custom text on the page, the first link above explains what's possible
this doc I saw and i think it not help me
client want left side where check debit credit card show
you can't add these details on the left of the page when using Stripe-hosted Checkout
if you need more ability to customise, it might be worth using an integration where the page is hosted on your site (i.e. Embedded Checkout, or Elements)
I understand your request, but this isn't possible in hosted Checkout
any time of course ๐
to embed Checkout in your own site, you can follow this guide: https://docs.stripe.com/checkout/embedded/quickstart
alternatively, you could look into using the Payment Element: https://docs.stripe.com/payments/quickstart-checkout-sessions