Sample file: config.php
See the chapter: Retrieving the keys :
Depuis le
For the DEMO store:
NUMBER | VARIABLE | value | Description |
---|---|---|---|
1 | USERNAME | 61881992 | For calls to REST Web Services |
2 | PASSWORD | testpassword_q4JtCk2nuiMsl2hi1uU394oqQ5dB1sOoMMaS4k8SaiY00 | For calls to REST Web Services |
3 | PUBLIC_KEY | 61881992:testpublickey_k7sM5cu1WTzkCCqU966agj3Ia3b04Pcsw4dZoeLVVUbc3 | For creating a payment form in the Buyer's browser. |
4 | SHA_KEY | K9JZgQS96GDLgppNI6ShFQxAJRiclSCAxq2xUekaLvW9o | In order to verify the authenticity of the data returned during the payment form response in the browser |
Le cas échéant, à remplacer par les données de votre boutique.
Ajoutez les données suivantes :
NUMBER | VARIABLE | value | Description |
---|---|---|---|
5 | SERVER | https://api-sogecommerce.societegenerale.eu | To create theformToken |
6 | URL_JS | https://static-sogecommerce.societegenerale.eu/static/js/krypton-client/V4.0/stable/kr-payment-form.min.js | To load our JS library |
<?php
/**
* Define configuration
* Configuration initialisation, using Lyra account informations.
* provided in your Back Office (Menu: Settings > Shop > API REST Keys).
**/
// DEMO SHOP
define('USERNAME', '61881992');
define('PASSWORD', 'testpassword_q4JtCk2nuiMsl2hi1uU394oqQ5dB1sOoMMaS4k8SaiY00');
define('PUBLIC_KEY', '61881992:testpublickey_k7sM5cu1WTzkCCqU966agj3Ia3b04Pcsw4dZoeLVVUbc3');
define('SHA_KEY', 'K9JZgQS96GDLgppNI6ShFQxAJRiclSCAxq2xUekaLvW9o');
define('SERVER', 'https://api-sogecommerce.societegenerale.eu');
$URL_JS = 'https://static-sogecommerce.societegenerale.eu/static/js/krypton-client/V4.0/stable/kr-payment-form.min.js';
// SUBSTITUTE BY MERCHANT SHOP (Menu: Settings > Shop > API REST Keys)
// define('USERNAME', 'KEY Number 1');
// define('PASSWORD', 'KEY Number 2');
// define('PUBLIC_KEY', 'KEY Number 3');
// define('SHA_KEY', 'KEY Number 4');
// define('SERVER', 'KEY Number 5');
// $URL_JS = 'KEY Number 6';
/*DOMAIN_URL : racine domaine URL_JS */
define('DOMAIN_URL', strstr($URL_JS,'/static/',true));
?>