API para afiliados › Suporte Obter o histórico de alterações do ticket POST /api/crm/v2/tickets.get_historyv2
operationId: tickets.getHistory
Retorna o histórico de alterações do ticket: criação, arquivos adicionados e removidos, alterações de status, assunto, descrição, responsável, equipes, produto, plataforma e tipo — com data, iniciador, valores antes e depois e nome da rede.
Autorização api-token + language + role
Corpo da solicitação application/json object
id integer obrigatório
Exemplo: 394
Respostas 200
object
status string obrigatório
Valores: successerror
Exemplo: success
data array of object
id integer obrigatório
Exemplo: 1100
date string (DataTimeFormatSQL) obrigatório
Exemplo: 2024-05-02 08:31:16
action string (HistoryItemAction) obrigatório
Valores: createdaddedchangeddeleted
Exemplo: created
type string (HistoryItemType) obrigatório
Valores: subjectdescriptionfilesstatususer_name_in_chargeteamsproductplatformtype
Exemplo: subject
before string
Valor antes da alteração: status da solicitação, ação ou identificadores de arquivos
Exemplo: waiting_customer_response
after string
Valor após a alteração: status da solicitação, ação ou identificadores de arquivos
Exemplo: 28d25e2b19189609dc68018406d920cb, b942924cbf4d341567dade78e60d8e2e
user_name string
Exemplo: user name
chain_name string
Exemplo: Green Basket | Kirov
affiliate_name string
Exemplo: Alexandritto
curl PHP JavaScript Python Copiar
curl -X POST 'https://foodsoul.ru/api/crm/v2/tickets.get_history' \
-H 'Authorization: Bearer fs_api_YOUR_TOKEN' \
-H 'language: pt' \
-H 'role: affiliate' \
-H 'Content-Type: application/json' \
-d '{"id":394}' <?php
$client = new \GuzzleHttp\Client ();
$response = $client -> request ( 'POST' , 'https://foodsoul.ru/api/crm/v2/tickets.get_history' , [
'headers' => [
'Authorization' => 'Bearer fs_api_YOUR_TOKEN' ,
'language' => 'pt' ,
'role' => 'affiliate' ,
],
'json' => [
'id' => 394 ,
],
]);
$data = json_decode (( string ) $response -> getBody (), true ); const response = await fetch ( "https://foodsoul.ru/api/crm/v2/tickets.get_history" , {
method : "POST" ,
headers : {
"Authorization" : "Bearer fs_api_YOUR_TOKEN" ,
"language" : "pt" ,
"role" : "affiliate" ,
"Content-Type" : "application/json"
},
body : JSON . stringify ({
"id" : 394
}),
})
const data = await response . json () import requests
response = requests . request (
"POST" ,
"https://foodsoul.ru/api/crm/v2/tickets.get_history" ,
headers ={
"Authorization" : "Bearer fs_api_YOUR_TOKEN" ,
"language" : "pt" ,
"role" : "affiliate" ,
},
json ={
"id" : 394 ,
},
)
data = response . json () Resposta 200
{
"status" : "success" ,
"data" : [
{
"id" : 1100 ,
"date" : "2024-05-02 08:31:16" ,
"action" : "created" ,
"type" : "subject" ,
"before" : "waiting_customer_response" ,
"after" : "28d25e2b19189609dc68018406d920cb, b942924cbf4d341567dade78e60d8e2e" ,
"user_name" : "user name" ,
"chain_name" : "Green Basket | Kirov" ,
"affiliate_name" : "Alexandritto"
}
]
} As solicitações são enviadas para foodsoul.ru — o host deste portal, não é possível escolher outro.