#tbare_terminal-name

1 messages ยท Page 1 of 1 (latest)

main moatBOT
#

๐Ÿ‘‹ 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/1275491037862690848

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

ionic rampart
#

@regal marten we wouldn't put anything on the Customer object so that's entirely expected.

#

tbare_terminal-name

regal marten
#

So, how would I pass the info to Stripe from either the Terminal (ideally the name on the credit card), or from the data in-app to populate that field?

ionic rampart
#

Do you have a concrete PaymentIntent id you can share pi_123

regal marten
#

pi_3PHTL1ADBq5btLnO15FONZ7l is the top one on this list

#

if i go INTO the transaction, i see my email address for the customer, but not the Transaction list

#

where others are showing a name

ionic rampart
#

That is from 3 months ago. Do you have a clear example that you tried recently?

#

Are you the developer writing the code end to end here?

regal marten
#

yes, I'm the developer - the client just brought it up to me, and I don't have access to anything newer ATM (and my terminal is not with me).

#

pi_3PdcQYADBq5btLnO0j3qIamV

#

here's one from last month

ionic rampart
#

Okay so let's go with the "theory" instead. When the PaymentIntent succeeds you get a Charge object ch_12345. That will have this property which has the cardholder's name if it's present on the card (it's never guaranteed): https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-cardholder_name
What you can do as the developer is, after the payment, look up that value and then update the Customer object in the API to save their name there.
Does that make sense?

regal marten
#

So this would be after process-payment?

ionic rampart
#

yes

regal marten
#

the ch_123 is in the result?

 Public Function fProcessPaymentIntent(ByVal TerminalID As String, ByVal PaymentIntendID As String) As Reader
        ' https://docs.stripe.com/terminal/payments/collect-payment?terminal-sdk-platform=server-driven#process-payment
        ' https://docs.stripe.com/terminal/payments/collect-payment?terminal-sdk-platform=server-driven#customer-initiated-cancellation

        Dim rpi_options = New ReaderProcessPaymentIntentOptions With {
            .PaymentIntent = PaymentIntendID,
            .ProcessConfig = New Stripe.Terminal.ReaderProcessConfigOptions With {
                .EnableCustomerCancellation = True
            }
        }

        Dim rpi_service = New ReaderService()
        Dim rpi_result = rpi_service.ProcessPaymentIntent(TerminalID, rpi_options)

        Return rpi_result
    End Function```
ionic rampart
regal marten
#

So, I'm listening to the readeraction:

Private Sub ReaderStatusTimer_Tick(sender As Object, e As EventArgs) Handles ReaderStatusTimer.Tick

        Dim currentState As ReaderAction = fGetReaderAction(_TerminalID)

        Try
            If currentState.Status = "in_progress" Then

            ElseIf currentState.Status = "failed" Then
                ReaderStatusTimer.Stop()
                Dim FailureCode As String = currentState.FailureCode
                Dim FailureMessage As String = currentState.FailureMessage

                _FailureReason = FailureCode & " -- " & FailureMessage
                'lblError.Text = FailureCode & " -- " & FailureMessage
                'lblError.Visible = True
                TransactionSuccess = False
                sCancelTransaction()
                Me.Close()

            ElseIf currentState.Status = "succeeded" Then
                ReaderStatusTimer.Stop()
                TransactionSuccess = True
                Me.Close()

            End If
        Catch ex As Exception

        End Try
    End Sub```
#

which is just:

    Public Function fGetReaderAction(ByVal TerminalID As String) As ReaderAction

        Dim rstate_service = New ReaderService()
        Dim result = rstate_service.Get(TerminalID)

        Return result.Action

    End Function```
ionic rampart
#

yeah then listen to payment_intent.succeeded and take action based on that one

regal marten
#

ok. I'll play with that when I have a terminal in-hand

#

Appreciate the help

ionic rampart
#

sure thing!

regal marten
#

I wrote most of this almost 4 months ago, and forgot most of the paths I took to get where it is. the customer just brought it up today.

ionic rampart
#

haha definitely a common situation on this server ๐Ÿ™‚

regal marten
#

Ok - so say I don't use the cardholder_name that's may or may not be on the card info - is there a way to manually pass that field using payment intent (similar to how the old API does with Stripe.TokenCardOptions)?

ionic rampart
#

not with Terminal no.

#

We are working on a beta where you can collect more information on the screen so you could contact our support team to ask to be added to the waitlist maybe?

regal marten
#

Shy of attaching it to the description, i suppose.

regal marten
ionic rampart
regal marten
#

ok - I guess the other option would be adding meta fields which may work, too.

#

I haven't looked yet, but i'm assuming that's possible with Terminal?

#

or am I limited ot what's availabel no PaymentIntent?

ionic rampart
#

yes that's possible to pass/add server-side

regal marten
#

cool - that may be the "easy" option here