#krazy-dirt-promocodes
1 messages · Page 1 of 1 (latest)
hi there! https://stripe.com/docs/payments/checkout/discounts covers how you can create promo codes to give to customers and then configure our Checkout hosted page to have an input to enter those codes into to apply a discount. Does that cover what you're looking for?
hey, i've read every page of the documentation
the problem is that there isn't promo codes for the client-side only integration
i tried using a server-side but as i am new, i don't know how, and i haven't found a proper tutorial on it for reactjs
yep, true!
so i asked maybe there is some workarounds
cause it has been a day i am on it
like literally 24h
nope! you have to use the client-server integration.
which part are you stuck on speficially? https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=checkout is the relevant guide. There's not much React code involved since it's mostly all backend to create the CheckoutSession and then you'd have your backend redirect to the URL.
yeah i don't know how to do it
i tried watching vids on youtube
and installed the checkout sample
but nada
do you have a ready form for it by any chance?
so i can try replacing values such as api keys
and so
maybe you could use a PaymentLink instead?
let me check in the docs
okay i see
the payment link will redirect to a checkout page?
with the already discounted code?
aaaahhhh i seee
okay so just i add a hyperlink ref to the page
and it's done?
that's all that's needed to be able to redirect the customer to the payment page with those options enabled yes
thanks alot!
@final gull won't it be a security problem?
users may fast forward to the link
and the product won't be delivered from my side
yes, that's a risk!
if that's something you're worried about then all I can really say is
- if it happens, you might have to contact and refund the customer, or,
- you would have to integrate the client/server Checkout implementation so the session and URL is only created when you're ready and you control it