Pour afficher le widget sur votre site, il suffit d'intégrer le code Javascript suivant juste avant la fermeture de la balise </head> dans le code de votre boutique, en indiquant vos propres paramètres liés à votre compte. Consultez l'exemple ci-dessous :
<script type="text/javascript" src="https://king-avis.com/widgets/31-991bf70b65ba2b823dd8b50fd3621a2b8933b47d5.js"></script>
| 31 | = Marchand ID |
| 991bf70b65ba2b823dd8b50fd3621a2b8933b47d5 | = Marchand Token |
<?php
file_get_contents('https://king-avis.com/fr/merchantorder/add?id_merchant=31&token=991bf70b65ba2b823dd8b50fd3621a2b8933b47d5&private_key=62af78aebuiod02e4e773b21e9bd4a7c54a2ab68&ref_order=17&email[email protected]&amount=57.230000&iso_currency=CHF&company=Webbax&firstname=Germain&lastname=Tenthorey&address=CP%20157&postcode=1926&city=Fully&iso_country=CH&phone=0277461981&date_order=2021-01-01%2010:01:32&iso_lang=fr');
?>
<img src="https://king-avis.com/fr/merchantorder/add?id_merchant=31&token=991bf70b65ba2b823dd8b50fd3621a2b8933b47d5&private_key=62af78aebuiod02e4e773b21e9bd4a7c54a2ab68&ref_order=17&email[email protected]&amount=57.230000&iso_currency=CHF&company=Webbax&firstname=Germain&lastname=Tenthorey&address=CP%20157&postcode=1926&city=Fully&iso_country=CH&phone=0277461981&date_order=2021-01-01%2010:01:32&iso_lang=fr" height="0" width="0">
| https://king-avis.com/fr/merchantorder/add? | : Le lien de base doit être préfixé comme cet exemple. La valeur "/fr/" peut être remplacée par "/de/", "/en/", "/it/". |
| id_merchant |
Marchant ID mentionné dans votre back-office King-Avis. Type : int Champ : obligatoire |
| token |
Marchant Token mentionné dans votre back-office King-Avis. Type : string Champ : obligatoire |
| private_key |
Marchand Private Key mentionné dans votre back-office King-Avis. Type : string Champ : obligatoire |
| ref_order |
numéro / référence de la commande Type : string Champ : obligatoire |
|
adresse e-mail de l'acheteur Type : email Champ : obligatoire |
|
| amount |
montant total de la commande Type : float Champ : obligatoire |
| iso_currency |
code ISO de la monnaie (ex. CHF, EUR, USD...) Type : string(3) Champ : obligatoire |
| company |
nom de la société Type : string Champ : facultatif |
| firstname |
prénom de l'acheteur Type : string Champ : obligatoire |
| lastname |
nom de l'acheteur Type : string Champ : obligatoire |
| address |
adresse de l'acheteur Type : string Champ : facultatif |
| postcode |
code postal de l'acheteur Type : string Champ : facultatif |
| city |
ville de l'acheteur Type : string Champ : facultatif |
| iso_country |
code iso du pays de l'acheteur (ex. FR, CH, DE, IT...) Type : string(2) Champ : facultatif |
| phone |
n° de téléphone de l'acheteur Type : string Champ : facultatif |
| iso_lang |
code iso de la langue de l'acheteur (ex. fr, de, en, it...) Type : string(2) Champ : obligatoire |
| date_order |
date de la commande Type : DateTime (Y-m-d H:i:s) Champ : facultatif |