#iminthematrix_api

1 messages ¡ Page 1 of 1 (latest)

winter joltBOT
#

👋 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/1283465882957254688

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

crisp temple
#

Hello
When you say capture card details on salesforce, how exactly are you doing that?

#

Are you using a connector?

cyan sphinx
#

I have a Visualforce page with the Stripe JS file and then using the card element:

stripe.createPaymentMethod({
type: 'card',
card: card
})

I then pass this to SF server side using vs remoting and on there I am calling setup_intents and passing these variables to ensure its flagged as a MOTO payment

List<String> postSetupIntentParameters = new List<String>{
'customer=' + customerId,
'payment_method=' + paymentmethodId,
'confirm=true',
'payment_method_options[card][moto]=true',
'usage=off_session'
};

Yes we are using the Stripe connector for Salesforce

crisp temple
#

I see. My team on discord knows nothing about the connectors/plugins unfortunately. I would suggest you reach out to our support about that
https://support.stripe.com/?contact=true

They can route this question to the correct team who is more familiar with how the connector works

cyan sphinx
#

If I shared with you the requests that SF is sending to Stripe to create this payment method can you tell me way its being flagged as requireing 3DS?

#

This is the request to setup the Payment_Method which is fine:

{
"billing_details": {
"address": {
"postal_code": "55555"
}
},
"card": {
"cvc": "***",
"exp_month": "05",
"exp_year": "55",
"number": "************3155"
},
"guid": "NA",
"key": "pk_test_*********************************************************************************************wLiLPy",
"muid": "401f79b3-7824-4c33-9033-24b65c396a4e199065",
"pasted_fields": "number",
"payment_user_agent": "stripe.js/d4791ce8a1; stripe-js-v3/d4791ce8a1; card-element",
"radar_options": {
"hcaptcha_token": "20000000-aaaa-bbbb-cccc-000000000002"
},
"referrer": "sfg.vf.force.com",
"sid": "5f7bc147-e827-45a0-ab37-8eeb9a6f9d3d1dd92d",
"time_on_page": "5221",
"type": "card"
}

And then this is the request that is doing the setup_intent

{
"confirm": "true",
"customer": "cus_QpV0m7NTNRIuaR",
"payment_method": "pm_1PxsyEG7SulwOLctJF2jgaBo",
"payment_method_options": {
"card": {
"moto": "true"
}
},
"usage": "off_session"
}

crisp temple
#

Hmm unsure.. Is there a reason you're trying to save the payment method prior to creating the subscription?

The idea flow would be to
1/ Create a subscription
2/ retrieve the latest_invoice.payment_intent (or pending_setup_intent in case you have a trial period) and use elements to collect payment method details
3/ elements should handle 3DS automatically if prompted.

I'm not sure if this is something salesforce connector can support by default though

#

so i'd recommend checking with the support team since they're experts on this

cyan sphinx
#

My issue is that I want to bypass the 3DS part and flag this payment method as a MOTO payment as it will be agents using this component on Salesforce and not the card holders.

crisp temple
#

Yeah unfortunately, MOTO is a gated feature so we don't know a ton about that either.

cyan sphinx
#

Ok got it. I will raise as support ticket and see what they come back with. THanks for your help.