curl PHP JavaScript Python Copier
curl -X POST 'https://foodsoul.pro/api/crm/v2/integration_sms.update?branch_id=1' \
-H 'Authorization: Bearer fs_api_YOUR_TOKEN' \
-H 'language: fr' \
-H 'role: partner' \
-H 'Content-Type: application/json' \
-d '{"order_creation_notifications_channel":"internal_sms","order_status_change_notifications_platform":"site","authorization_force_code_enabled":true,"id":1,"api_id":"secret","from":"secret"}' <?php
$client = new \GuzzleHttp\Client ();
$response = $client -> request ( 'POST' , 'https://foodsoul.pro/api/crm/v2/integration_sms.update?branch_id=1' , [
'headers' => [
'Authorization' => 'Bearer fs_api_YOUR_TOKEN' ,
'language' => 'fr' ,
'role' => 'partner' ,
],
'json' => [
'order_creation_notifications_channel' => 'internal_sms' ,
'order_status_change_notifications_platform' => 'site' ,
'authorization_force_code_enabled' => true ,
'id' => 1 ,
'api_id' => 'secret' ,
'from' => 'secret' ,
],
]);
$data = json_decode (( string ) $response -> getBody (), true ); const response = await fetch ( "https://foodsoul.pro/api/crm/v2/integration_sms.update?branch_id=1" , {
method : "POST" ,
headers : {
"Authorization" : "Bearer fs_api_YOUR_TOKEN" ,
"language" : "fr" ,
"role" : "partner" ,
"Content-Type" : "application/json"
},
body : JSON . stringify ({
"order_creation_notifications_channel" : "internal_sms" ,
"order_status_change_notifications_platform" : "site" ,
"authorization_force_code_enabled" : true ,
"id" : 1 ,
"api_id" : "secret" ,
"from" : "secret"
}),
})
const data = await response . json () import requests
response = requests . request (
"POST" ,
"https://foodsoul.pro/api/crm/v2/integration_sms.update?branch_id=1" ,
headers ={
"Authorization" : "Bearer fs_api_YOUR_TOKEN" ,
"language" : "fr" ,
"role" : "partner" ,
},
json ={
"order_creation_notifications_channel" : "internal_sms" ,
"order_status_change_notifications_platform" : "site" ,
"authorization_force_code_enabled" : True ,
"id" : 1 ,
"api_id" : "secret" ,
"from" : "secret" ,
},
)
data = response . json () Réponse 200
{
"status" : "success" ,
"data" : {}
} Les requêtes sont envoyées à foodsoul.pro — l’hôte de ce portail, il n’est pas possible d’en choisir un autre.