#Jack Drake

1 messages ยท Page 1 of 1 (latest)

worn heartBOT
pale kettle
#

Can you share your code snippet?

dawn prawn
#

yes

#

the error is given below

#

anything?

#

@pale kettle

pale kettle
#

Sorry Discord is very busy

#

Looking now

#

When you print out the paymentIntent, what does it show?

dawn prawn
#

this is what it prints

#

anything?

pale kettle
#

Oh I think you need to pass the payment intent client secret instead of the payment intent object

dawn prawn
#

ok lemme try that

#

@pale kettle why is the ReaderDisplayDelegate not in the scope

#

its the same code given

fallow vortex
#

hey again

dawn prawn
#

hey

#

how are you

#

@fallow vortex this is the error im getting

#

once the collectPaymentMethod is called it should show a screento collect payment but that doesnt show up and it shows error saying required parameter is invalid or missing

#

any ideas?

fallow vortex
#

Looking, but does that delegate error seem right to you, do you have one in place?

dawn prawn
#

wdym

#

@fallow vortex the ReaderDisplayDelegate isnt even in the StripeTerminal SDK

fallow vortex
#

Oh wait, that was removed in v2.0.0

#

What version are you using and where is that error in your code?

dawn prawn
#

how do i check what version

#

@fallow vortex

fallow vortex
#

This should be in your package dependencies i think

#

what did you use to install the sdk?

#

cocoapods?

dawn prawn
#

github

#

the repository link

fallow vortex
#

sure but how did you add the dependency to your app

#

Do you have a podfile.lock?

#

That doesnt show the version

dawn prawn
#

ok yes

fallow vortex
#

I'm not sure i understand how this was added

dawn prawn
#

its version 2

fallow vortex
#

ok and where did you get the code you're running?

#

if using version 2.0+ there shouldnt be any references to that delegate

dawn prawn
#

here

#

the documentation doesnt specify otherwise

fallow vortex
#

ah, interesting. ok.

#

Checking into this for you, trying to figure out the mismatch there

dawn prawn
#

yea same

#

cause i just keep getting the error. required parameter is invalid or missing

fallow vortex
#

Wait so the delegate error is not actually blocking you?

grave isle
#

๐Ÿ‘‹ what happens when you remove that ReaderDisplayDelegate?

dawn prawn
#

its when the collectPaymentMethod

dawn prawn
#

but it doesnt exist

grave isle
#

Yeah I think that is outdated though

dawn prawn
#

yea obviously

#

anyyways i removed it and it works

grave isle
#

Yeah so I'll get that documentation updated

dawn prawn
#

but when the collectPaymentMethod is called it shows the error

#

@grave isle it keeps saying that a parameter is missing

grave isle
#

Yep okay looking

#

Don't think that is related to the ReaderDisplayDelegate

dawn prawn
#

no its not

grave isle
#

What reader are you using?

#

And can you give me the PaymentIntent ID that is created when you log it out?

dawn prawn
#

tap to pay

grave isle
#

Ah

dawn prawn
#

pi_3MAKqV2fdyCgG0bf0qNKVag4

grave isle
#

You need card_present in your params I believe

#

Yeah

#

So payment_method_types: ['card_present']

#

Try that

dawn prawn
#

i had that

#

but let me try it again

grave isle
#

Oh that is on the one you provided

#

But didn't see it in your code sample above

dawn prawn
#

any ideas

#

from what i read the paymentMethodTypes is by default card present so im not sure what the issue is

#

anything?

grave isle
#

Still looking

#

I'm wondering if we don't allow client-side PaymentIntent creation... Not sure why that would be the case though. But nothing else is jumping out to me in terms of you doing anything incorrectly. Have you tried server-side PaymentIntent creation?

#

I haven't tested/integrated tap to pay myself yet as it is nearly brand new

#

Going to double check internally to get an answer here. Give me a moment

dawn prawn
#

ok go ahead

#

no i have not tried the server side payment intent creation

grave isle
#

Okay

#

Did you set the Connected Account in your SCPLocalMobileConnectionConfiguration?

dawn prawn
#

yes

grave isle
#

Yeah okay I think that is the issue

#

You aren't using OBO here

#

You are creating directly on the Connected Account

dawn prawn
#

ok what is OBO

grave isle
#

So remove the Connected Account from there

#

OBO is on_behalf_of

dawn prawn
#

ok so if i remove it where do i put it

#

ok it works

#

but will i get charged if i test with my card

#

?

grave isle
#

Do you have a Terminal Test Card?

dawn prawn
#

no i do not

grave isle
#

It should fail in testmode if you try to use your own card

dawn prawn
#

ok

grave isle
#

So yeah, you want to order one of our Test Cards to actually test end-to-end

dawn prawn
#

yes please

#

wait actually

grave isle
dawn prawn
#

whats the difference if i use my card

grave isle
#

It won't work

#

It will error saying you are using a live card in test mode

dawn prawn
#

ok quick question

#

now i tried my card on a 1 dollar transaction

#

and it says now after the paymentintent succeeded

#

that it requires confirmation

grave isle
#

Should be requires_capture

#

You are using manual_capture correct?

dawn prawn
#

no automativ

#

automatic

grave isle
#

Oh

#

Can you give me the PaymentIntent ID?

dawn prawn
#

pi_3MALcp2fdyCgG0bf1DjeJqM4

grave isle
#

Don't think that is the right one. That PaymentIntent hasn't gone through collectPaymentMethod

#

Nor processPayment

#

... I assume you have the code for processPayment?

dawn prawn
#

no this is all i have

grave isle
#

Oh

#

Then yeah

#

You need to processPayment

#

See the above

dawn prawn
#

but why though isnt it automatic

#

oh i see

grave isle
#

Yeah no that is for what happens after processPayment

#

In terms of the actual capture

dawn prawn
#

ok it works thank you

grave isle
#

๐ŸŽ‰

dawn prawn
#

we are using live mode for testing and ensuring that it is working

#

@grave isle it returns stripe api declined the transaction

grave isle
#

We can't recommend you test in live-mode. That is against card network regulations

#

That is what test mode is for

#

A card can get declined for a variety of reasons in live mode though

dawn prawn
#

it simply says generic decline

grave isle
#

And if you are testing in live mode, an issuer can quickly catch on to that fact and start declining the transactions for that card

#

If you give me the PaymentIntent I can look at it

#

But really you should be testing in testmode

dawn prawn
#

we have only tried one transaction

#

ok nvm thank you

#

we will switch to the test mode