Історія
Що й коли сталося із записом і хто це зробив: історія угоди, історія контакту та журнал подій усієї організації. Зміни компаній і задач — у журналі.
Журнал подій
GET /activity-log
Усі зміни в організації, нові зверху, сторінками: угоди, контакти, компанії й задачі, коментарі, налаштування, команда, мотивація та вивантаження угод — хто, коли, у якому записі й що змінив; імпортована історія — з автором і часом із попередньої системи. Фільтри: хто (actorIds, actorGroups), які записи (kinds: deal, contact, company, task…), що сталося (actions), яке поле (field), період (from, to). Історія компаній і задач — тут, з kinds=company чи kinds=task.
Параметри запиту
actionsstring[]кількість ≤ 8 · без повторів
Значення:
createdchangedstageassigneddeletedrestoredcompletedcommentactorGroupsstring[]кількість ≤ 3 · без повторів
Значення:
importautomationsystemactorIdsstring[] · uuidкількість ≤ 50 · без повторів
cursorstringдовжина 1–512
fieldstringшаблон
^(?:[A-Za-z]{1,40}|cf:[0-9a-fA-F-]{36})$fromstring · date-timekindsstring[]кількість ≤ 7 · без повторів
Значення:
dealcontactcompanytasksettingsteamcompensationlimitinteger1–100 · типово
50tostring · date-time
Приклад запиту
curl 'https://your-company.altahub.ai/api/v1/activity-log' \
-H 'Authorization: Bearer alta_…'const response = await fetch('https://your-company.altahub.ai/api/v1/activity-log', {
method: 'GET',
headers: {
Authorization: 'Bearer alta_…',
},
});
const data = await response.json();import requests
response = requests.get(
"https://your-company.altahub.ai/api/v1/activity-log",
headers={"Authorization": "Bearer alta_…"},
)
data = response.json()<?php
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://your-company.altahub.ai/api/v1/activity-log', [
'headers' => ['Authorization' => 'Bearer alta_…'],
]);
$data = json_decode((string) $response->getBody(), true);Відповідь 200
Успішна відповідь.
{
"items": [
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000055",
"at": "2026-10-24T16:45:00Z",
"actor": {
"kind": "member",
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник",
"former": false
},
"importedFrom": null,
"record": {
"type": "task",
"id": "0192f3a1-7c2e-7b4d-9a61-00000000003c",
"title": "Передзвонити щодо рахунку",
"state": "live"
},
"kind": "task",
"history": null,
"task": {
"id": "0192f3a1-7c2e-7b4d-9a61-00000000003c",
"title": "Передзвонити щодо рахунку",
"kind": "call",
"type": null,
"event": "completed",
"attributes": [],
"outcome": "call",
"next": {
"id": "0192f3a1-7c2e-7b4d-9a61-00000000003d",
"title": "Надіслати рахунок",
"dueAt": "2026-10-29T09:00:00Z"
},
"reschedule": null
},
"comment": null,
"settings": null,
"team": null,
"compensation": null,
"export": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000056",
"at": "2026-10-22T09:05:00Z",
"actor": {
"kind": "member",
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник",
"former": false
},
"importedFrom": null,
"record": {
"type": "deal",
"id": "0192f3a1-7c2e-7b4d-9a61-000000000014",
"title": "Кавомашини для мережі кав’ярень",
"state": "live"
},
"kind": "comment",
"history": null,
"task": null,
"comment": {
"preview": "Клієнтка просить рахунок до п’ятниці",
"deleted": false
},
"settings": null,
"team": null,
"compensation": null,
"export": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000052",
"at": "2026-10-21T12:40:00Z",
"actor": {
"kind": "member",
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник",
"former": false
},
"importedFrom": null,
"record": {
"type": "deal",
"id": "0192f3a1-7c2e-7b4d-9a61-000000000014",
"title": "Кавомашини для мережі кав’ярень",
"state": "live"
},
"kind": "history",
"history": {
"event": "moved",
"via": "manual",
"stage": {
"from": {
"id": "0192f3a1-7c2e-7b4d-9a61-00000000001f",
"name": "Новий запит"
},
"to": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000020",
"name": "Переговори"
}
},
"status": null,
"owner": null,
"amount": null,
"fields": [],
"summary": null,
"attributes": []
},
"task": null,
"comment": null,
"settings": null,
"team": null,
"compensation": null,
"export": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000057",
"at": "2026-10-20T08:15:00Z",
"actor": {
"kind": "member",
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник",
"former": false
},
"importedFrom": null,
"record": {
"type": "contact",
"id": "0192f3a1-7c2e-7b4d-9a61-00000000000a",
"title": "Олена Коваль",
"state": "live"
},
"kind": "history",
"history": {
"event": "updated",
"via": "manual",
"stage": null,
"status": null,
"owner": null,
"amount": null,
"fields": [],
"summary": null,
"attributes": [
{
"key": "jobTitle",
"label": null,
"from": null,
"to": "Менеджерка із закупівель",
"fieldType": null,
"decimals": null
}
]
},
"task": null,
"comment": null,
"settings": null,
"team": null,
"compensation": null,
"export": null
}
],
"nextCursor": null,
"searchedTo": null
}Поля відповіді
itemsobject[]Вкладені поля: 13
actorobjectВкладені поля: 4
formerbooleanidstring · uuid | nullkindstringЗначення:
memberautomationimportsystemnamestring | null
atstring · date-timecommentobject | nullВкладені поля: 2
deletedbooleanpreviewstring | null
compensationobject | nullВкладені поля: 3
attributesobject[]Вкладені поля: 6
decimalsinteger | null0–4
fieldTypestring | nullЗначення:
textlong_textnumberdatedatetimebooleanchoicemulti_choiceurlmoneybirthdayaddressfromstring | nullkeystringlabelstring | nulltostring | null
eventstringЗначення:
plan_createdplan_changedplan_archivedplan_restoredassignment_setassignment_removedstart_date_setsettings_changedadjustment_addedadjustment_canceledpayout_recordedpayout_canceledperiod_closedrecalculatedrole_createdrole_changedrole_deletedmemberobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
exportobject | nullВкладені поля: 4
dealsinteger≥ 0
formatstringЗначення:
xlsxcsvpipelineobject | nullВкладені поля: 2
idstring · uuidnamestring
scopestringЗначення:
allfilter
historyobject | nullВкладені поля: 11
amountobject | nullВкладені поля: 2
fromobjectВкладені поля: 2
amountstringcurrencystring
toobjectВкладені поля: 2
amountstringcurrencystring
attributesobject[]Вкладені поля: 6
decimalsinteger | null0–4
fieldTypestring | nullЗначення:
textlong_textnumberdatedatetimebooleanchoicemulti_choiceurlmoneybirthdayaddressfromstring | nullkeystringlabelstring | nulltostring | null
eventstringЗначення:
createdupdatedmovedowner_changedcomment_editedcomment_deleteddeletedrestoredcomment_pinnedcomment_unpinnedpayment_recordedpayment_changedpayment_canceledpayment_refundedpayment_requestedpayment_request_paidpayment_request_expiredpayment_request_canceledpayment_request_failedpayment_consent_givenpayment_credit_changedarchivedfieldsstring[]Значення:
titledescriptioncontactIdcompanyIdexpectedCloseDateownerobject | nullВкладені поля: 2
fromobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
toobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
stageobject | nullВкладені поля: 2
fromobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
toobjectВкладені поля: 2
idstring · uuid | nullnamestring
statusobject | nullВкладені поля: 2
fromstringЗначення:
openwonlosttostringЗначення:
openwonlost
summarystring | nullviastring | nullЗначення:
manualimportformmergeobjectВкладені поля: 2
droppedobject[]кількість ≤ 400
Вкладені поля: 4
keystringlabelstring | nullrecordstringvaluestring
recordsobject[]кількість ≤ 4
Вкладені поля: 3
idstring · uuidnamestringnumberinteger≥ 1
paymentobjectВкладені поля: 3
paymentIdstring · uuid | nullpaymentRequestIdstring · uuid | nullrefundIdstring · uuid | null
idstring · uuidimportedFromstring | nullkindstringЗначення:
historytaskcommentsettingsteamcompensationexportrecordobjectВкладені поля: 4
idstring · uuid | nullstatestringЗначення:
livearchiveddeletedtitlestringtypestringЗначення:
dealcontactcompanytasksettingsteamcompensationexport
settingsobject | nullВкладені поля: 3
areastringЗначення:
organizationpipelinefieldcurrency_rateaccess_rolecurrency_rate_auto_fillmarketing_spendmigrationpayment_methodpayment_method_grouptagtask_typeproductproduct_categoryproduct_pricecoupontax_ratebilling_entityattributesobject[]Вкладені поля: 6
decimalsinteger | null0–4
fieldTypestring | nullЗначення:
textlong_textnumberdatedatetimebooleanchoicemulti_choiceurlmoneybirthdayaddressfromstring | nullkeystringlabelstring | nulltostring | null
eventstringЗначення:
createdupdateddeletedarchivedrestored
taskobject | nullВкладені поля: 9
attributesobject[]Вкладені поля: 6
decimalsinteger | null0–4
fieldTypestring | nullЗначення:
textlong_textnumberdatedatetimebooleanchoicemulti_choiceurlmoneybirthdayaddressfromstring | nullkeystringlabelstring | nulltostring | null
eventstringЗначення:
createdupdatedrescheduledreassignedcompletedreopenedcanceleddeletedrestoredidstring · uuidkindstringЗначення:
taskcallmeetingemailreminderchatnextobject | nullВкладені поля: 4
dueAtstring · date-time | nullidstring · uuidtitlestringallDayboolean
outcomestring | nullЗначення:
callmessagemeetingno_answerno_contactrescheduleobject | nullВкладені поля: 2
notestring | nullreasonstring | nullЗначення:
client_askedno_answerno_timeother
titlestringtypeobject | nullВкладені поля: 3
iconstringidstring · uuidnamestring
teamobject | nullВкладені поля: 6
emailstring | nulleventstringЗначення:
invitation_issuedinvitation_revokedinvitation_acceptedmembership_createdmembership_disabledmembership_enabledmembership_role_changedmembership_dismissedmembership_restoredmembership_renamedhandedOverToobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
memberobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
roleobject | nullВкладені поля: 2
fromstring | nulltostring
roleNameobject | nullВкладені поля: 4
fromstring | nullfromSystemKeystring | nullЗначення:
owneradminmanagertostring | nulltoSystemKeystring | nullЗначення:
owneradminmanager
nextCursorstring | nullsearchedTostring · date-time | null
Історія контакту
GET /contacts/{contactId}/activity
Усе, що сталося з контактом, нові зверху, сторінками: створення та кожна зміна полів і тегів (що було і що стало), коментарі, що сталося з його задачами. only залишає одне: notes, history або tasks. Чати й дзвінки через API недоступні.
Параметри шляху
contactIdstring · uuid обов’язково
Параметри запиту
cursorstringдовжина 1–512
limitinteger1–100 · типово
30onlystringЗначення:
noteshistorytasks
Приклад запиту
curl 'https://your-company.altahub.ai/api/v1/contacts/{contactId}/activity' \
-H 'Authorization: Bearer alta_…'const response = await fetch('https://your-company.altahub.ai/api/v1/contacts/{contactId}/activity', {
method: 'GET',
headers: {
Authorization: 'Bearer alta_…',
},
});
const data = await response.json();import requests
response = requests.get(
"https://your-company.altahub.ai/api/v1/contacts/{contactId}/activity",
headers={"Authorization": "Bearer alta_…"},
)
data = response.json()<?php
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://your-company.altahub.ai/api/v1/contacts/{contactId}/activity', [
'headers' => ['Authorization' => 'Bearer alta_…'],
]);
$data = json_decode((string) $response->getBody(), true);Відповідь 200
Успішна відповідь.
{
"items": [
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000058",
"type": "note",
"at": "2026-10-24T16:45:00Z",
"actor": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник"
},
"note": {
"body": "Зручніше писати в Telegram",
"editedAt": null,
"version": 1,
"mentions": [],
"pinned": null,
"attachments": []
},
"history": null,
"task": null,
"call": null,
"message": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-00000000003c",
"type": "task",
"at": "2026-10-21T12:40:00Z",
"actor": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник"
},
"note": null,
"history": null,
"task": {
"id": "0192f3a1-7c2e-7b4d-9a61-00000000003c",
"title": "Передзвонити щодо рахунку",
"kind": "call",
"type": null,
"event": "created",
"attributes": [],
"outcome": null,
"next": null,
"reschedule": null
},
"call": null,
"message": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000054",
"type": "history",
"at": "2026-10-20T08:15:00Z",
"actor": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000001",
"name": "Андрій Шевченко"
},
"note": null,
"history": {
"event": "created",
"via": "manual",
"stage": null,
"status": null,
"owner": null,
"amount": null,
"fields": [],
"summary": null,
"attributes": [
{
"key": "phone",
"label": null,
"from": null,
"to": "+380501234567",
"fieldType": null,
"decimals": null
}
]
},
"task": null,
"call": null,
"message": null
}
],
"nextCursor": null,
"pinned": []
}Поля відповіді
itemsobject[]Вкладені поля: 11
actorobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
atstring · date-timecallobject | nullВкладені поля: 8
clientNumberstring | nulldirectionstringЗначення:
incomingoutgoingdurationSecondsinteger | null≥ 0
idstring · uuidinProgressbooleanrecordingbooleanresultstring | nullЗначення:
answeredno_answerbusyunreachablefailedtalkSecondsinteger | null≥ 0
historyobject | nullВкладені поля: 11
amountobject | nullВкладені поля: 2
fromobjectВкладені поля: 2
amountstringcurrencystring
toobjectВкладені поля: 2
amountstringcurrencystring
attributesobject[]Вкладені поля: 6
decimalsinteger | null0–4
fieldTypestring | nullЗначення:
textlong_textnumberdatedatetimebooleanchoicemulti_choiceurlmoneybirthdayaddressfromstring | nullkeystringlabelstring | nulltostring | null
eventstringЗначення:
createdupdatedmovedowner_changedcomment_editedcomment_deleteddeletedrestoredcomment_pinnedcomment_unpinnedpayment_recordedpayment_changedpayment_canceledpayment_refundedpayment_requestedpayment_request_paidpayment_request_expiredpayment_request_canceledpayment_request_failedpayment_consent_givenpayment_credit_changedarchivedfieldsstring[]Значення:
titledescriptioncontactIdcompanyIdexpectedCloseDateownerobject | nullВкладені поля: 2
fromobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
toobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
stageobject | nullВкладені поля: 2
fromobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
toobjectВкладені поля: 2
idstring · uuid | nullnamestring
statusobject | nullВкладені поля: 2
fromstringЗначення:
openwonlosttostringЗначення:
openwonlost
summarystring | nullviastring | nullЗначення:
manualimportformmergeobjectВкладені поля: 2
droppedobject[]кількість ≤ 400
Вкладені поля: 4
keystringlabelstring | nullrecordstringvaluestring
recordsobject[]кількість ≤ 4
Вкладені поля: 3
idstring · uuidnamestringnumberinteger≥ 1
paymentobjectВкладені поля: 3
paymentIdstring · uuid | nullpaymentRequestIdstring · uuid | nullrefundIdstring · uuid | null
idstring · uuidmessageobject | nullВкладені поля: 2
chatobjectВкладені поля: 3
accountobjectВкладені поля: 4
displayNamestringidstring · uuidownerobjectВкладені поля: 2
idstring · uuidnamestring
usernamestring | null
idstring · uuidproviderstringЗначення:
telegram
entryobject | nullВкладені поля: 15
atstring · date-timeauthorobject | nullВкладені поля: 2
idstring · uuidnamestring
callobject | nullВкладені поля: 3
answeredboolean | nulldirectionstringЗначення:
inoutsecondsinteger | null≥ 0
dealIdstring · uuid | nulldeletedbooleandirectionstringЗначення:
inouteditedAtstring · date-time | nullfailurestring | nullfilesobject[]Вкладені поля: 11
contentTypestring | nulldurationSecondsinteger | null≥ 0
gonebooleanhasPreviewbooleanheightinteger | null≥ 1
idstring · uuidkindstringЗначення:
photovoiceaudiovideovideo_notedocumentstickernamestring | nullsizeBytesinteger | null≥ 0
waveforminteger[] | nullкількість ≤ 128 · 0–31
widthinteger | null≥ 1
idstring · uuidkindstringЗначення:
textmediacallotheroriginstringЗначення:
clientaltadevicehistoryotherKindstring | nullЗначення:
stickerlocationcontactpollgameunsupportedstatusstring | nullЗначення:
queuedsendingsentreadfailedcancelledtextstring | null
noteobject | nullВкладені поля: 6
attachmentsobject[]The comment's files in their order (empty without files): id, name, size in bytes, type, and an audio's or a video's length. A signed-in member opens one through GET /note-files/{id}; an API key sees them here but does not open them.
Вкладені поля: 5
contentTypestringdurationSecondsinteger | null0–86400
idstring · uuidnamestringдовжина 1–255
sizeinteger≥ 1
bodystringeditedAtstring · date-time | nullmentionsobject[]Вкладені поля: 3
memberIdstring · uuid | nullnamestringtextstring
pinnedobject | nullВкладені поля: 2
atstring · date-timebyobjectВкладені поля: 2
idstring · uuid | nullnamestring
versioninteger≥ 1
taskobject | nullВкладені поля: 9
attributesobject[]Вкладені поля: 6
decimalsinteger | null0–4
fieldTypestring | nullЗначення:
textlong_textnumberdatedatetimebooleanchoicemulti_choiceurlmoneybirthdayaddressfromstring | nullkeystringlabelstring | nulltostring | null
eventstringЗначення:
createdupdatedrescheduledreassignedcompletedreopenedcanceleddeletedrestoredidstring · uuidkindstringЗначення:
taskcallmeetingemailreminderchatnextobject | nullВкладені поля: 4
dueAtstring · date-time | nullidstring · uuidtitlestringallDayboolean
outcomestring | nullЗначення:
callmessagemeetingno_answerno_contactrescheduleobject | nullВкладені поля: 2
notestring | nullreasonstring | nullЗначення:
client_askedno_answerno_timeother
titlestringtypeobject | nullВкладені поля: 3
iconstringidstring · uuidnamestring
typestringЗначення:
notehistorytaskcallmessagecallAnalysisobjectВкладені поля: 1
transcriptobjectВкладені поля: 1
statestringЗначення:
queuedtranscribinghelddonefailed
paymentReportobjectВкладені поля: 9
cardobject | nullВкладені поля: 3
brandstring | nullissuerstring | nullmaskedNumberstring | null
methodstring | nulloccurredAtstring · date-timeorderReferencestring | nullpayerstring | nullpayerEmailstring | nullpayerPhonestring | nullproductCountinteger≥ 0
productsobject[]кількість ≤ 20
Вкладені поля: 4
amountstringшаблон
^[0-9]+\.[0-9]{2}$currencystringшаблон
^[A-Z]{3}$namestringquantitystring
nextCursorstring | nullpinnedobject[]кількість ≤ 3
Вкладені поля: 11
actorobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
atstring · date-timecallobject | nullВкладені поля: 8
clientNumberstring | nulldirectionstringЗначення:
incomingoutgoingdurationSecondsinteger | null≥ 0
idstring · uuidinProgressbooleanrecordingbooleanresultstring | nullЗначення:
answeredno_answerbusyunreachablefailedtalkSecondsinteger | null≥ 0
historyobject | nullВкладені поля: 11
amountobject | nullВкладені поля: 2
fromobjectВкладені поля: 2
amountstringcurrencystring
toobjectВкладені поля: 2
amountstringcurrencystring
attributesobject[]Вкладені поля: 6
decimalsinteger | null0–4
fieldTypestring | nullЗначення:
textlong_textnumberdatedatetimebooleanchoicemulti_choiceurlmoneybirthdayaddressfromstring | nullkeystringlabelstring | nulltostring | null
eventstringЗначення:
createdupdatedmovedowner_changedcomment_editedcomment_deleteddeletedrestoredcomment_pinnedcomment_unpinnedpayment_recordedpayment_changedpayment_canceledpayment_refundedpayment_requestedpayment_request_paidpayment_request_expiredpayment_request_canceledpayment_request_failedpayment_consent_givenpayment_credit_changedarchivedfieldsstring[]Значення:
titledescriptioncontactIdcompanyIdexpectedCloseDateownerobject | nullВкладені поля: 2
fromobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
toobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
stageobject | nullВкладені поля: 2
fromobject | nullВкладені поля: 2
idstring · uuid | nullnamestring
toobjectВкладені поля: 2
idstring · uuid | nullnamestring
statusobject | nullВкладені поля: 2
fromstringЗначення:
openwonlosttostringЗначення:
openwonlost
summarystring | nullviastring | nullЗначення:
manualimportformmergeobjectВкладені поля: 2
droppedobject[]кількість ≤ 400
Вкладені поля: 4
keystringlabelstring | nullrecordstringvaluestring
recordsobject[]кількість ≤ 4
Вкладені поля: 3
idstring · uuidnamestringnumberinteger≥ 1
paymentobjectВкладені поля: 3
paymentIdstring · uuid | nullpaymentRequestIdstring · uuid | nullrefundIdstring · uuid | null
idstring · uuidmessageobject | nullВкладені поля: 2
chatobjectВкладені поля: 3
accountobjectВкладені поля: 4
displayNamestringidstring · uuidownerobjectВкладені поля: 2
idstring · uuidnamestring
usernamestring | null
idstring · uuidproviderstringЗначення:
telegram
entryobject | nullВкладені поля: 15
atstring · date-timeauthorobject | nullВкладені поля: 2
idstring · uuidnamestring
callobject | nullВкладені поля: 3
answeredboolean | nulldirectionstringЗначення:
inoutsecondsinteger | null≥ 0
dealIdstring · uuid | nulldeletedbooleandirectionstringЗначення:
inouteditedAtstring · date-time | nullfailurestring | nullfilesobject[]Вкладені поля: 11
contentTypestring | nulldurationSecondsinteger | null≥ 0
gonebooleanhasPreviewbooleanheightinteger | null≥ 1
idstring · uuidkindstringЗначення:
photovoiceaudiovideovideo_notedocumentstickernamestring | nullsizeBytesinteger | null≥ 0
waveforminteger[] | nullкількість ≤ 128 · 0–31
widthinteger | null≥ 1
idstring · uuidkindstringЗначення:
textmediacallotheroriginstringЗначення:
clientaltadevicehistoryotherKindstring | nullЗначення:
stickerlocationcontactpollgameunsupportedstatusstring | nullЗначення:
queuedsendingsentreadfailedcancelledtextstring | null
noteobject | nullВкладені поля: 6
attachmentsobject[]The comment's files in their order (empty without files): id, name, size in bytes, type, and an audio's or a video's length. A signed-in member opens one through GET /note-files/{id}; an API key sees them here but does not open them.
Вкладені поля: 5
contentTypestringdurationSecondsinteger | null0–86400
idstring · uuidnamestringдовжина 1–255
sizeinteger≥ 1
bodystringeditedAtstring · date-time | nullmentionsobject[]Вкладені поля: 3
memberIdstring · uuid | nullnamestringtextstring
pinnedobject | nullВкладені поля: 2
atstring · date-timebyobjectВкладені поля: 2
idstring · uuid | nullnamestring
versioninteger≥ 1
taskobject | nullВкладені поля: 9
attributesobject[]Вкладені поля: 6
decimalsinteger | null0–4
fieldTypestring | nullЗначення:
textlong_textnumberdatedatetimebooleanchoicemulti_choiceurlmoneybirthdayaddressfromstring | nullkeystringlabelstring | nulltostring | null
eventstringЗначення:
createdupdatedrescheduledreassignedcompletedreopenedcanceleddeletedrestoredidstring · uuidkindstringЗначення:
taskcallmeetingemailreminderchatnextobject | nullВкладені поля: 4
dueAtstring · date-time | nullidstring · uuidtitlestringallDayboolean
outcomestring | nullЗначення:
callmessagemeetingno_answerno_contactrescheduleobject | nullВкладені поля: 2
notestring | nullreasonstring | nullЗначення:
client_askedno_answerno_timeother
titlestringtypeobject | nullВкладені поля: 3
iconstringidstring · uuidnamestring
typestringЗначення:
notehistorytaskcallmessagecallAnalysisobjectВкладені поля: 1
transcriptobjectВкладені поля: 1
statestringЗначення:
queuedtranscribinghelddonefailed
paymentReportobjectВкладені поля: 9
cardobject | nullВкладені поля: 3
brandstring | nullissuerstring | nullmaskedNumberstring | null
methodstring | nulloccurredAtstring · date-timeorderReferencestring | nullpayerstring | nullpayerEmailstring | nullpayerPhonestring | nullproductCountinteger≥ 0
productsobject[]кількість ≤ 20
Вкладені поля: 4
amountstringшаблон
^[0-9]+\.[0-9]{2}$currencystringшаблон
^[A-Z]{3}$namestringquantitystring
Історія угоди
GET /deals/{dealId}/activity
Усе, що сталося з угодою, нові зверху, сторінками: створення, переходи етапами, виграш, програш і повторне відкриття, зміна відповідального, суми, кожного поля й тегів (що було і що стало), коментарі, що сталося з її задачами, оплати. У кожного запису — хто (actor), коли (at) і що (history, note або task). only залишає одне: notes — коментарі, history — зміни, tasks — задачі, payments — оплати, changes — правки назви, суми, тегів і власних полів (без створення угоди; у кожному записі лише ці правки). Чати й дзвінки через API недоступні.
Параметри шляху
dealIdstring · uuid обов’язково
Параметри запиту
cursorstringдовжина 1–512
limitinteger1–100 · типово
30onlystringЗначення:
noteshistorytasksmainpaymentschanges
Приклад запиту
curl 'https://your-company.altahub.ai/api/v1/deals/{dealId}/activity' \
-H 'Authorization: Bearer alta_…'const response = await fetch('https://your-company.altahub.ai/api/v1/deals/{dealId}/activity', {
method: 'GET',
headers: {
Authorization: 'Bearer alta_…',
},
});
const data = await response.json();import requests
response = requests.get(
"https://your-company.altahub.ai/api/v1/deals/{dealId}/activity",
headers={"Authorization": "Bearer alta_…"},
)
data = response.json()<?php
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://your-company.altahub.ai/api/v1/deals/{dealId}/activity', [
'headers' => ['Authorization' => 'Bearer alta_…'],
]);
$data = json_decode((string) $response->getBody(), true);Відповідь 200
Успішна відповідь.
{
"items": [
{
"id": "0192f3a1-7c2e-7b4d-9a61-00000000003c",
"type": "task",
"at": "2026-10-24T16:45:00Z",
"actor": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник"
},
"note": null,
"history": null,
"task": {
"id": "0192f3a1-7c2e-7b4d-9a61-00000000003c",
"title": "Передзвонити щодо рахунку",
"kind": "call",
"type": null,
"event": "completed",
"attributes": [],
"outcome": "call",
"next": {
"id": "0192f3a1-7c2e-7b4d-9a61-00000000003d",
"title": "Надіслати рахунок",
"dueAt": "2026-10-29T09:00:00Z"
},
"reschedule": null
},
"call": null,
"message": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000059",
"type": "history",
"at": "2026-10-23T10:30:00Z",
"actor": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник"
},
"note": null,
"history": {
"event": "payment_recorded",
"via": null,
"stage": null,
"status": null,
"owner": null,
"amount": null,
"fields": [],
"summary": null,
"attributes": [
{
"key": "payment",
"label": null,
"from": null,
"to": "12000.00 UAH",
"fieldType": "money",
"decimals": null
},
{
"key": "paymentStatus",
"label": null,
"from": null,
"to": "paid",
"fieldType": null,
"decimals": null
},
{
"key": "paidAt",
"label": null,
"from": null,
"to": "2026-10-23",
"fieldType": null,
"decimals": null
},
{
"key": "paymentMethod",
"label": null,
"from": null,
"to": "Картка",
"fieldType": null,
"decimals": null
}
],
"payment": {
"paymentId": "0192f3a1-7c2e-7b4d-9a61-0000000000b3",
"refundId": null,
"paymentRequestId": null
}
},
"task": null,
"call": null,
"message": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000050",
"type": "note",
"at": "2026-10-22T09:05:00Z",
"actor": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник"
},
"note": {
"body": "Клієнтка просить рахунок до п’ятниці",
"editedAt": null,
"version": 1,
"mentions": [],
"pinned": null,
"attachments": []
},
"history": null,
"task": null,
"call": null,
"message": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000053",
"type": "history",
"at": "2026-10-21T12:45:00Z",
"actor": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник"
},
"note": null,
"history": {
"event": "updated",
"via": "manual",
"stage": null,
"status": null,
"owner": null,
"amount": {
"from": {
"amount": "10000.00",
"currency": "UAH"
},
"to": {
"amount": "12000.00",
"currency": "UAH"
}
},
"fields": [],
"summary": null,
"attributes": [
{
"key": "cf:0192f3a1-7c2e-7b4d-9a61-000000000032",
"label": "Місто доставки",
"from": null,
"to": "Київ",
"fieldType": "text",
"decimals": null
}
]
},
"task": null,
"call": null,
"message": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000052",
"type": "history",
"at": "2026-10-21T12:40:00Z",
"actor": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000002",
"name": "Ірина Мельник"
},
"note": null,
"history": {
"event": "moved",
"via": "manual",
"stage": {
"from": {
"id": "0192f3a1-7c2e-7b4d-9a61-00000000001f",
"name": "Новий запит"
},
"to": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000020",
"name": "Переговори"
}
},
"status": null,
"owner": null,
"amount": null,
"fields": [],
"summary": null,
"attributes": []
},
"task": null,
"call": null,
"message": null
},
{
"id": "0192f3a1-7c2e-7b4d-9a61-000000000051",
"type": "history",
"at": "2026-10-20T08:15:00Z",
"actor": {
"id": "0192f3a1-7c2e-7b4d-9a61-000000000001",
"name": "Андрій Шевченко"
},
"note": null,
"history": {
"event": "created",
"via": "manual",
"stage": {
"from": null,
"to": {
"id": "0192f3a1-7c2e-7b4d-9a61-00000000001f",
"name": "Новий запит"
}
},
"status": null,
"owner": null,
"amount": null,
"fields": [],
"summary": null,
"attributes": []
},
"task": null,
"call": null,
"message": null
}
],
"nextCursor": null,
"pinned": []
}Поля — як у відповіді Історія контакту
Пов’язати коментар з його копією в іншій системі
PUT /notes/{noteId}/copies/{source}/{externalId}
Для сервісу, який копіює коментарі з Alta в іншу систему: після того як копію створено там, він повідомляє її id. source — ваше слово для системи (малі латинські літери, цифри, - і _), externalId — id копії там. Імпорт з цієї системи впізнає копію за цим id і відповідає цим коментарем, а не приносить його вдруге; тому в тексті копії не потрібен рядок з посиланням на коментар. Якщо імпорт встиг принести копію раніше, ніж прийшов зв’язок, і вона точно повторює коментар, її приховано як дубль (duplicateHidden: true). Перший зв’язок — created, той самий запит ще раз нічого не змінює (unchanged), тому повтор безпечний. Пов’язати можна лише коментар, написаний в Alta: для принесеного імпортом — 409 CONFLICT (note_imported); копія, вже пов’язана з іншим коментарем, — 409 CONFLICT (copy_of_another_comment). Потрібен ключ з правом запису і право «Імпорт даних» у ролі автора ключа (у власника й адміністратора воно є), інакше — 403 FORBIDDEN.
Параметри шляху
externalIdstring обов’язководовжина 1–200 · шаблон
^\S+$noteIdstring · uuid обов’язковоsourcestring обов’язковошаблон
^[a-z0-9_-]{1,40}$
Приклад запиту
curl -X PUT 'https://your-company.altahub.ai/api/v1/notes/{noteId}/copies/{source}/{externalId}' \
-H 'Authorization: Bearer alta_…' \
-H 'Content-Type: application/json' \
-d '{}'const response = await fetch('https://your-company.altahub.ai/api/v1/notes/{noteId}/copies/{source}/{externalId}', {
method: 'PUT',
headers: {
Authorization: 'Bearer alta_…',
'Content-Type': 'application/json',
},
body: JSON.stringify({}),
});
const data = await response.json();import requests
response = requests.put(
"https://your-company.altahub.ai/api/v1/notes/{noteId}/copies/{source}/{externalId}",
headers={"Authorization": "Bearer alta_…"},
json={},
)
data = response.json()<?php
$client = new \GuzzleHttp\Client();
$response = $client->request('PUT', 'https://your-company.altahub.ai/api/v1/notes/{noteId}/copies/{source}/{externalId}', [
'headers' => ['Authorization' => 'Bearer alta_…'],
'json' => new \stdClass(),
]);
$data = json_decode((string) $response->getBody(), true);Відповідь 200
Успішна відповідь.
{
"noteId": "0192f3a1-7c2e-7b4d-9a61-000000000050",
"outcome": "created",
"duplicateHidden": false
}Поля відповіді
duplicateHiddenbooleannoteIdstring · uuidoutcomestringЗначення:
createdunchanged