Upraviť CRM udalosť
Čiastočne aktualizuje CRM udalosť. Meniteľné sú iba metadata, attachmentUploadTokens[] a deletedAttachmentIds[]; type a target polia sú pri update zakázané. Pri document_linked type sa attachmenty nepodporujú. Dostupnosť jednotlivých metadata polí je popísaná priamo pri metadata.content, metadata.email, metadata.personName, metadata.phoneNumber, metadata.documentType a metadata.documentId.
curl --request PATCH \
--url https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"metadata": {
"content": "Follow-up call summary",
"email": "crm@example.test",
"personName": "John Caller",
"phoneNumber": "+421900000000",
"documentType": "invoice",
"documentId": 301
},
"attachmentUploadTokens": [
"eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0="
],
"deletedAttachmentIds": [
9001
]
}
'import requests
url = "https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}"
payload = {
"metadata": {
"content": "Follow-up call summary",
"email": "crm@example.test",
"personName": "John Caller",
"phoneNumber": "+421900000000",
"documentType": "invoice",
"documentId": 301
},
"attachmentUploadTokens": ["eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0="],
"deletedAttachmentIds": [9001]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
metadata: {
content: 'Follow-up call summary',
email: 'crm@example.test',
personName: 'John Caller',
phoneNumber: '+421900000000',
documentType: 'invoice',
documentId: 301
},
attachmentUploadTokens: ['eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0='],
deletedAttachmentIds: [9001]
})
};
fetch('https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'metadata' => [
'content' => 'Follow-up call summary',
'email' => 'crm@example.test',
'personName' => 'John Caller',
'phoneNumber' => '+421900000000',
'documentType' => 'invoice',
'documentId' => 301
],
'attachmentUploadTokens' => [
'eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0='
],
'deletedAttachmentIds' => [
9001
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}"
payload := strings.NewReader("{\n \"metadata\": {\n \"content\": \"Follow-up call summary\",\n \"email\": \"crm@example.test\",\n \"personName\": \"John Caller\",\n \"phoneNumber\": \"+421900000000\",\n \"documentType\": \"invoice\",\n \"documentId\": 301\n },\n \"attachmentUploadTokens\": [\n \"eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0=\"\n ],\n \"deletedAttachmentIds\": [\n 9001\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"metadata\": {\n \"content\": \"Follow-up call summary\",\n \"email\": \"crm@example.test\",\n \"personName\": \"John Caller\",\n \"phoneNumber\": \"+421900000000\",\n \"documentType\": \"invoice\",\n \"documentId\": 301\n },\n \"attachmentUploadTokens\": [\n \"eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0=\"\n ],\n \"deletedAttachmentIds\": [\n 9001\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"metadata\": {\n \"content\": \"Follow-up call summary\",\n \"email\": \"crm@example.test\",\n \"personName\": \"John Caller\",\n \"phoneNumber\": \"+421900000000\",\n \"documentType\": \"invoice\",\n \"documentId\": 301\n },\n \"attachmentUploadTokens\": [\n \"eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0=\"\n ],\n \"deletedAttachmentIds\": [\n 9001\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": 551,
"type": "note",
"metadata": {
"content": "Follow-up call summary",
"email": "crm@example.test",
"personName": "John Caller",
"phoneNumber": "+421900000000",
"documentNumberSnapshot": "20260001",
"documentPriceSnapshot": 121,
"documentCurrencySnapshot": {
"id": 1,
"symbol": "EUR",
"name": "Euro",
"mark": "€"
},
"paidAmount": 25.5,
"relatedDocument": {
"documentType": "invoice",
"documentId": 301,
"name": "Faktúra 20260001",
"number": "20260001",
"issueDate": "2026-03-10",
"totalWithVat": 121,
"currency": {
"id": 1,
"symbol": "EUR",
"name": "Euro",
"mark": "€"
}
}
},
"attachments": [
{
"id": 9001,
"name": "note.pdf",
"mimeType": "application/pdf",
"url": "https://cdn.fintoro.sk/contact-activity-attachments/note.pdf"
}
],
"businessCaseId": 501,
"clientId": 101,
"supplierId": 151,
"createdAt": "2026-03-10T10:00:00+01:00",
"updatedAt": "2026-03-10T10:30:00+01:00"
}{
"message": "This action is unauthorized."
}{
"message": "No query results for model."
}{
"message": "The given data was invalid.",
"errors": {}
}{
"message": "Too Many Attempts."
}{
"message": "Server Error"
}{
"message": "Service Unavailable"
}Autorizace
Bearer token vytvorený pre konkrétnu firmu v Integrácie → API.
Parametry cesty
ID kontaktnej aktivity.
551
Tělo
Payload pre aktualizáciu CRM udalosti. Meniteľné sú iba metadata, voliteľné nové attachmentUploadTokens[] a deletedAttachmentIds[]. Polia type, businessCaseId, clientId a supplierId sú pri update zakázané.
Variabilný payload podľa typu existujúcej CRM udalosti. Do requestu neposielajte snapshot polia ani relatedDocument; tie backend vypočíta alebo uloží sám.
Show child attributes
Show child attributes
["eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0="]
[9001]
Odpověď
CRM udalosť bola aktualizovaná.
Unified CRM udalosť.
Interné ID CRM udalosti.
551
Typ CRM udalosti.
note, email, phone_call, document_linked, document_created, document_updated, document_deleted, document_payment_added "note"
Metadata CRM udalosti pripravené pre Fintoro API response.
Show child attributes
Show child attributes
Show child attributes
Show child attributes
ID obchodného prípadu, ak je aktivita naviazaná na obchodný prípad.
501
ID klienta, ak je aktivita naviazaná priamo na klienta mimo obchodného prípadu.
101
ID dodávateľa, ak je aktivita naviazaná priamo na dodávateľa mimo obchodného prípadu.
151
Dátum a čas vytvorenia CRM udalosti.
"2026-03-10T10:00:00+01:00"
Dátum a čas poslednej úpravy CRM udalosti.
"2026-03-10T10:30:00+01:00"
curl --request PATCH \
--url https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"metadata": {
"content": "Follow-up call summary",
"email": "crm@example.test",
"personName": "John Caller",
"phoneNumber": "+421900000000",
"documentType": "invoice",
"documentId": 301
},
"attachmentUploadTokens": [
"eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0="
],
"deletedAttachmentIds": [
9001
]
}
'import requests
url = "https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}"
payload = {
"metadata": {
"content": "Follow-up call summary",
"email": "crm@example.test",
"personName": "John Caller",
"phoneNumber": "+421900000000",
"documentType": "invoice",
"documentId": 301
},
"attachmentUploadTokens": ["eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0="],
"deletedAttachmentIds": [9001]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
metadata: {
content: 'Follow-up call summary',
email: 'crm@example.test',
personName: 'John Caller',
phoneNumber: '+421900000000',
documentType: 'invoice',
documentId: 301
},
attachmentUploadTokens: ['eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0='],
deletedAttachmentIds: [9001]
})
};
fetch('https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'metadata' => [
'content' => 'Follow-up call summary',
'email' => 'crm@example.test',
'personName' => 'John Caller',
'phoneNumber' => '+421900000000',
'documentType' => 'invoice',
'documentId' => 301
],
'attachmentUploadTokens' => [
'eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0='
],
'deletedAttachmentIds' => [
9001
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}"
payload := strings.NewReader("{\n \"metadata\": {\n \"content\": \"Follow-up call summary\",\n \"email\": \"crm@example.test\",\n \"personName\": \"John Caller\",\n \"phoneNumber\": \"+421900000000\",\n \"documentType\": \"invoice\",\n \"documentId\": 301\n },\n \"attachmentUploadTokens\": [\n \"eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0=\"\n ],\n \"deletedAttachmentIds\": [\n 9001\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"metadata\": {\n \"content\": \"Follow-up call summary\",\n \"email\": \"crm@example.test\",\n \"personName\": \"John Caller\",\n \"phoneNumber\": \"+421900000000\",\n \"documentType\": \"invoice\",\n \"documentId\": 301\n },\n \"attachmentUploadTokens\": [\n \"eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0=\"\n ],\n \"deletedAttachmentIds\": [\n 9001\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.fintoro.sk/api/public/v1/contact-activity-logs/{contactActivityLog}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"metadata\": {\n \"content\": \"Follow-up call summary\",\n \"email\": \"crm@example.test\",\n \"personName\": \"John Caller\",\n \"phoneNumber\": \"+421900000000\",\n \"documentType\": \"invoice\",\n \"documentId\": 301\n },\n \"attachmentUploadTokens\": [\n \"eyJpdiI6Ik9wYXF1ZS1Ub2tlbi0xIn0=\"\n ],\n \"deletedAttachmentIds\": [\n 9001\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": 551,
"type": "note",
"metadata": {
"content": "Follow-up call summary",
"email": "crm@example.test",
"personName": "John Caller",
"phoneNumber": "+421900000000",
"documentNumberSnapshot": "20260001",
"documentPriceSnapshot": 121,
"documentCurrencySnapshot": {
"id": 1,
"symbol": "EUR",
"name": "Euro",
"mark": "€"
},
"paidAmount": 25.5,
"relatedDocument": {
"documentType": "invoice",
"documentId": 301,
"name": "Faktúra 20260001",
"number": "20260001",
"issueDate": "2026-03-10",
"totalWithVat": 121,
"currency": {
"id": 1,
"symbol": "EUR",
"name": "Euro",
"mark": "€"
}
}
},
"attachments": [
{
"id": 9001,
"name": "note.pdf",
"mimeType": "application/pdf",
"url": "https://cdn.fintoro.sk/contact-activity-attachments/note.pdf"
}
],
"businessCaseId": 501,
"clientId": 101,
"supplierId": 151,
"createdAt": "2026-03-10T10:00:00+01:00",
"updatedAt": "2026-03-10T10:30:00+01:00"
}{
"message": "This action is unauthorized."
}{
"message": "No query results for model."
}{
"message": "The given data was invalid.",
"errors": {}
}{
"message": "Too Many Attempts."
}{
"message": "Server Error"
}{
"message": "Service Unavailable"
}
