Cybersource's Storefront Reference Architecture Cartridge can be installed from Salesforce Commerce Cloud's marketplace link
- Create a folder “CyberSource” in your workspace and place the cartridge (int_cybersource_sfra)downloaded from Marketplace.
- If you have a different project set-up, you will need to open the file ‘/package.json’ and modify the paths.base value to point to your ‘app_storefront_base’ cartridge. This path is used by the JS and SCSS build scripts.
- If using VSCode, install the extension Prophet Debugger link or any other SFCC extension and include below in dw.json ().
{
"hostname": "your-sandbox-hostname.demandware.net",
"username": "yourlogin",
"password": "yourpwd",
"version": "version_to_upload_to",
"cartridge": [
"int_cybersource_sfra",
"app_storefront_base",
"modules"
]
}
Create a p12 file that you can use to authenticate requests. Place the file generated in the webreferences2 folder in the same cartridge as the WSDL file and name of the p12 file must be the same as the WSDL file and the file extension must be that of the type jks or pkcs12.
NOTE: If you are using different IDE, refer respective developer guide to setup the workspace.
Prerequisite: install node under "Cybersource" folder.
Install sgmf-scripts with following command
npm install sgmf-scripts && npm install copy-webpack-plugin
Compile JS and SCSS with following command
npm run compile:js && npm run compile:scss
Upload the code to Salesforce Commerce Cloud instance
npm run uploadCartridge