#dovahkiin

1 messages · Page 1 of 1 (latest)

slim laurelBOT
stone crescent
#

👋 Hi there, Happy to help!
Could you please resume your last issue ?

steep bough
#

Yes the issue is the following:
I'm trying to implement paynow, so I copied an example from the doc to an html file but the issue I have is the popup with the QR code never opens.
So then obviously when the confirm request is sent I have an error saying there is no payment method attached.
here is a link where you can see the issue : https://replit.com/join/knofbsprhc-bilalatmane

#

Yesterday someone here tried to help me and managed to have the QR code opens with nearly the same code as me so I start wondering if this is linked to the configuration of the account I use.

Could you try to reproduce the sample I just sent you but with your own publishable and client secret to check if that makes a difference ?

stone crescent
steep bough
#

I don't get what you mean, the link I shared with you is publicly accessible, do you have an issue with it ?

stone crescent
#

Yes, I need to create an account unfortunately

steep bough
#

Ok I can send you the files if you prefer not to login there

stone crescent
#

Thanks for sharing, give me couple of minutes while I do a test please

stone crescent
#

Could you please share also how are you creating the Payment Intent ?

steep bough
#

yes I'll give you the request + response

stone crescent
#

Your request body when creating the PaymentIntent should be something like this:

{
        amount: "11700",
        payment_method_types: ['paynow'], // Set this param
        payment_method_data: {type: 'paynow'}, // Set this param
        capture_method: "automatic",
        shipping: {
            address: {
                line1: "152 b Rue du Général de Gaulle94350 Villiers-sur-Marne",
                city: "Villiers-sur-Marne",
                postal_code: "94350",
                country: "FR"
            },
            phone: "33 751390441",
            name: "Guesmi Abdelkader"
        },
        metadata: {
            order_reference: "FRAMYORDER7071"
        },
        currency: "SGD",
}
steep bough
#

Damn I guess that's what was missing !! Since we didn't have to update the payment_method_data for other payment methods with stripe we must've missed it. However what's strange is that we normally are sending the payment_method_types

#

Ah yes it's there i'm not crazy 😅 let me try to add the payment_method_data and see if it solves the issue

steep bough
#

alelujaa the popup is opening with it ! 🥳