Step 6: Shift in Production
I. Performing mandatory tests
It is essential to perform the mandatory tests in order to go to PRODUCTION.
Tests must be performed with:
- Test password
- Public test key
- HMAC-SHA-256 test key
The list of tests to be performed is displayed in the
- You must simulate several payments using the test cards in the table below, using the debug bar.
- Using one card on each line is sufficient.
- The test card numbers are available from the debug bar, Test cards tab.
- When the test is validated, the icon color of the "test status" column changes to green.
- Once the 4 tests have been validated, the Generate the password and the HMAC-SHA-256 production key button becomes available.
II. Generate the PRODUCTION keys
Click the "Generate the password and the HMAC-SHA-256 production key" button. Note that the TEST mode is still available, even after the production key is generated.
Insert the PRODUCTION keys into your implementation:
- The production password.
- The public production key.
- The HMAC-SHA-256 production key for calculating the signature contained in the kr-hash field.
Set the notification URL correctly at the end of the payment in PRODUCTION mode from the Setting > Notification Rules menu. (link Set up notification URL ).
Store the keys.
We recommend you to store the information (password, public key, HMAC-SHA-256 production key) securely because as soon as the first payment is made in PRODUCTION mode, it will be marked in theMerchant Back Office .
III. Making the first production payment
- Make an actual transaction of at least 2 €.
. This transaction can subsequently be canceled from the
- Make sure the notification URL at the end of payment (IPN) is working
Display the transaction details in the
IV. Simplified example in PHP
The example file is given as an indication, in order to understand the integration mechanism.
Renseignez les clés d'API REST de Test dans le fichier
config.php
(lien Fichier d'exemple : config.php).Si besoin, modifiez les données du paiement dans le fichier
formToken.php
(lien Fichier d'exemple : formToken.php).Affichez le formulaire de paiement dans un navigateur en utilisant le fichier
smartForm.php
(lien Fichier d'exemple : smartForm.php).Once the form is displayed, click the Test cards tab of the debug bar and select the type of card you want to use.
See the test list in the
Merchant Back Office to identify the card number that will be used.When a test is validated, its status is updated in the list. Use the Refresh Table button if the status did not refresh automatically.
Once the 4 tests have been validated, the Generate the password and the HMAC-SHA-256 production key button becomes available.
Click Generate the password and the HMAC-SHA-256 production key and accept the various warning messages.