API per partner › Impostazioni Terminare la sessione utente POST /api/crm/v2/team.delete_sessionv2
operationId: team.deleteSession
Termina la sessione dell'utente. Nei modelli partner e affiliate, le sessioni sono gestite dal proprietario dell'account e solo all'interno di tale account; per gli altri casi viene restituito l'errore 100. È sempre possibile chiudere le proprie sessioni.
Autorizzazione api-token + language + role
Corpo della richiesta application/json object
id integer obbligatorio
Esempio: 15342
Risposte 200
object
status string obbligatorio
Valori: successerror
Esempio: success
data object
description string obbligatorio
Esempio: Successfully deleted
curl PHP JavaScript Python Copiare
curl -X POST 'https://foodsoul.pro/api/crm/v2/team.delete_session' \
-H 'Authorization: Bearer fs_api_YOUR_TOKEN' \
-H 'language: it' \
-H 'role: partner' \
-H 'Content-Type: application/json' \
-d '{"id":15342}' <?php
$client = new \GuzzleHttp\Client ();
$response = $client -> request ( 'POST' , 'https://foodsoul.pro/api/crm/v2/team.delete_session' , [
'headers' => [
'Authorization' => 'Bearer fs_api_YOUR_TOKEN' ,
'language' => 'it' ,
'role' => 'partner' ,
],
'json' => [
'id' => 15342 ,
],
]);
$data = json_decode (( string ) $response -> getBody (), true ); const response = await fetch ( "https://foodsoul.pro/api/crm/v2/team.delete_session" , {
method : "POST" ,
headers : {
"Authorization" : "Bearer fs_api_YOUR_TOKEN" ,
"language" : "it" ,
"role" : "partner" ,
"Content-Type" : "application/json"
},
body : JSON . stringify ({
"id" : 15342
}),
})
const data = await response . json () import requests
response = requests . request (
"POST" ,
"https://foodsoul.pro/api/crm/v2/team.delete_session" ,
headers ={
"Authorization" : "Bearer fs_api_YOUR_TOKEN" ,
"language" : "it" ,
"role" : "partner" ,
},
json ={
"id" : 15342 ,
},
)
data = response . json () Risposta 200
{
"status" : "success" ,
"data" : {
"description" : "Successfully deleted"
}
} Le richieste vengono inviate a foodsoul.pro, che è l’host di questo portale; non è possibile sceglierne un altro.