Closed FabianMartin1988 closed 4 years ago
Please use the https://github.com/Mangopay/cardregistration-js-kit SDK on the client side, in order to manage the user credit cards.
Also, here is the card registration flow described: https://docs.mangopay.com/endpoints/v2.01/cards#e177_the-card-registration-object
The NodeJS SDK is backend only.
Feel free to write in this issue for further information.
Hello,
we try to integrate the following Code into our Sandbox enviroment:
https://github.com/Mangopay/mangopay2-php-sdk/blob/master/demos/paymentDirect/js/script.js
In the fourth line, the script tries to initialize the mangoPay.cardRegistration.init Object: He does not even know the mangopay object since it is undefined till then. On our Node.js server we use the following code to initialize the MangoPay Api:
var mangopay = require('mangopay2-nodejs-sdk');
var api = new mangopay({ clientId: '100300400', clientApiKey: '2BF0k9Ey2yadk27K3jz9MyqbQ2MGm0tBJKgJ68rFDfCXs04Qsu' });
How do i manage to intitalize the API in Plain Javascript. I cant to a require since it is not supported in HTML (JS) ....
Does anyone have any expirience in integrating the Code above into an HTML / Javascript environment?
Thanks in advance Fabian