#grace-m6795_docs
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/1228238085977018389
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- grace-m6795_api, 2 days ago, 4 messages
- grace-m6795_api, 3 days ago, 11 messages
- grace-m6795_api, 6 days ago, 21 messages
- grace-m6795_api, 6 days ago, 9 messages
hello! can you share the corresponding PaymentIntent or SetupIntent id?
There is no PaymentIntent or SetupIntent id. The payment method itself is not available for test purchase. I want to test Afterpay.
i'm not sure i understand, if you're using Payment Element, you should have a corresponding PaymentIntent or SetupIntent
can you share the guide which you're following to implement the Payment Element?
I'm not using PaymentIntent or SetupIntent to create payment element. I'm creating it in the following way:
const options = {
mode: 'payment',
currency: crs_currency_code,
amount: selected_plan_price * 100,
paymentMethodCreation: 'manual',
};
stripe.stripe = Stripe(publishable_key, {stripeAccount: account_id});
elements = stripe.stripe.elements( options );
const paymentElementOptions = {
layout: "tabs",
};
const paymentElement = elements.create("payment", paymentElementOptions);
paymentElement.mount("#payment-element");
const addressElementOptions = {
mode: 'shipping',
};
const addressElement = elements.create("address", addressElementOptions);
addressElement.mount("#address-element");
These are the options I can see right now.
That's what we call the deferred payment flow. You would eventually create a PaymentIntent for that. Anyway, it looks like you are planning to create a direct charge. Can you share your account id and the corresponding stripeAccount value for the screenshot in your example? I'll see if i'm able to track down the request to initialize the Payment Element in your screenshot
The account id has the prefix of acct_
is that your platform account id?
no. this is a connected account
then what's your platform account id?
acct_19ZGMoEf37nkqkTs
If you are based in India i.e. your IP address is based in India, Afterpay won't show as a payment method option since you are using Dynamic Payment Methods (which determines what payment methods to show based on a variety of factors).
If you really want to test Afterpay, i suggest you try explicitly define it in paymentMethodTypes , you'll subsequently also need to explicitly define the paymentMethodTypes when creating the PaymentIntent too : https://docs.stripe.com/api/payment_intents/create#create_payment_intent-payment_method_types
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Ok. Thank you
If you really want to test Afterpay, i suggest you try explicitly define it in paymentMethodTypes - Where can I exactly specify this? I know how to define paymentMethodTypes when creating the PaymentIntent. Also, even though I'm based in India, I can see other payment methods which wouldn't be shown in India in live mode. Only Afterpay is not listed. Shouldn't it also be listed since the account is in test mode?
you can define the paymentMethodTypes in the options object which you pass in to elements : https://docs.stripe.com/payments/accept-a-payment-deferred?platform=web&type=payment#additional-options