#Kade
1 messages · Page 1 of 1 (latest)
Sure, what is your question
위의 url에 나와있는 테스트 코드를 작동하여 테스트를 해봤는데 아래의 이미지가 정상적으로 결제가 된 결과인것입니까?
I think I gave you the wrong URL.
The url below is the correct url.
I write code like this
StripeConfiguration.ApiKey = "";
var options = new PaymentIntentCreateOptions
{
Amount = 1000,
Currency = "CAD",
PaymentMethod = "pm_card_createDispute",
};
var service = new PaymentIntentService();
service.Create(options);
When I tried turning the code to all the card payment methods on the page, the card number was different and all of them were the same.
What do you mean by the card number was different but all of them were the same?
You can look at your request log to see if you send in expected parameters
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
What I mean is that the image below is all the same even if the Payment Method is different.
I only gave different value of Payment Method.
i think your question is why are the payments incomplete?
Yes
If that's your question, you need to confirm the PaymentIntent. In most cases, the confirmation will take place client-side. If you're doing it server side just for testing purposes, pass in confirm=true when creating the PaymentIntent : https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
I just checked!
I have one more question
When I set the PaymetMethod to pm_card_visa_chargeDeclined, the .Net program ends with Your cardDeclined as Exception, is there a way to prevent the program from shutting down?
you should handle the exception with try catch. See https://stripe.com/docs/error-handling?lang=dotnet#payment-errors