/setPluginConf (POST)
Ce endpoint permet d'enregistrer la configuration du plugin dans SPREAD.
Endpoint : https://social-sb.com/api/v3/setPluginConf
Verbe HTTP : POST
Paramètres obligatoires :
data
: tableau de donnée contenant la configuration du plugin
publicKey
: Clé publique API de votre compte SPREAD
privateKey
: Clé privée API de votre compte SPREAD
Exemple de code
Vous pouvez ajouter toutes les données que vous souhaitez.
$publicKey = 'xxxxx'; // À modifier $privateKey = 'xxxxx'; // À modifier $data = array( "cms" => "Prestashop", "version" => "1.7.6.2", "date_config" => "2020-05-25 07:43:45", "active" => true, "keys" => array( "public" => false, "private" => false ), "cron" => false, "abCart_automationName" => "abandoned_cart", "plugin_function" => array( "send_customers" => true, "send_orders" => true, "send_abCart" => true, "widgets" => true ), "orders_tags" => false, "customers_tags" => false, "coupons" => array( "partial_use" => false, "cumulable" => false, "coupon_max_percent" => false, "coupon_max_fixed" => false, "coupon_lifetime" => false, "coupon_min_amount" => false ) ); $ch = curl_init('https://social-sb.com/api/v3/setPluginConf'); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data)); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_USERPWD, $publicKey . ":" . $privateKey); $result = curl_exec($ch);
Si vous avez d’autres questions sur ce sujet, vous pouvez contacter le support. 💬