#brandontrytn_terminal-dotnet-errors

1 messages ยท Page 1 of 1 (latest)

dense geyserBOT
#

๐Ÿ‘‹ Welcome to your new thread!

โฒ๏ธ We'll be here soon! We typically respond in a few minutes, but in some cases we might need a bit more time (e.g., server's busy, you've got a complex question, etc.).

โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can 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/1247215313703927809

๐Ÿ“ Have more to share? Add details, code, screenshots, videos, etc. below.

gentle yacht
#

Hi ๐Ÿ‘‹

Do you have any specific requests that have thrown this error?

orchid dragon
#

I haven't been able to find one so far. details from the client are very vague. claims intermittent issue for the past week. I assume in the dashboard it would be one of the payments listed as incomplete?

gentle yacht
#

Unfortunately I'm not seeing that specific error in their account logs (going back to Jan 2024).

#

I do see a somewhat related issue

orchid dragon
#

what's the related issue?

gentle yacht
orchid dragon
#

hmm, we only use automatic_payment_methods as far as I know, will review the code real quick to see if there's a place we aren't doing that

#

we have a selector to determine if the client wants to use the terminal or the payment element. the only place we're using "card_present" is on the terminal side

gentle yacht
#

In this request, the Stripe .NET SDK is explicitly sending a payment_method_types: ['card_present']

#

So it looks like a Terminal integration

orchid dragon
#

I suspect they selected terminal and then switched back to payment element is my best guess

#

so in the case of our split you're recommending we set the automatic_payment_methods only if not using terminal?

gentle yacht
#

The update is what is setting the PMT to card_present

#

Correct

orchid dragon
#

we also have the following code on the terminal side, is this acceptable?
createOptions.AutomaticPaymentMethods = new PaymentIntentAutomaticPaymentMethodsOptions { Enabled = false };
createOptions.CaptureMethod = "manual";
createOptions.PaymentMethodTypes = new List<string> { "card_present" };

#

or can we not even have that first line?

gentle yacht
#

Honestly that is up to your business logic. I can just tell you that, if you want to set a specific payment method type on a Payment Intent that has automatica payment methods enabled, you will need to also disable automatic payment methods. Which approach makes the most sense is up to how you design the business logic of your application.

orchid dragon
#

and the above code accomplishes this, yeah? disables automatic payment methods when using terminal

gentle yacht
#

It should but I recommend testing it out in test mode to be sure

orchid dragon
#

ok, and for reference, what scenerio generates the initial error reported?

gentle yacht
#

It's the scenario in the request I shared above.

#

Your .NET integration is attempting to apply a PMT of ['card_present'] to an existing Payment Intent that already has automatic payment methods enabled

orchid dragon
#

ok, I guess my confusion is we pass the stripe error provided by stripe through to the client, and in the log entry you sent the error message doesn't match what was presented to the client

gentle yacht
#

True but I looked at their API logs and there aren't any failed requests in the last year that match that description

orchid dragon
#

any errors of any kind for them in the logs posted around 6/1 15:42 mountain time? that's when the ticket was opened.

gentle yacht
#

Just a couple about a card having insufficeint funds

dense geyserBOT