Evolutrix CRM Rest API | Automation (1.0.0)
Download OpenAPI specification:Download
Модуль AntCRM - Automation расширяет возможности Ant CRM, добавляя новый функционал: - автоматизация бизнес процессов
index
Возвращает список триггеров
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
query Parameters
| group | string Example: group=lead Машинное название группы |
Responses
Response samples
- 200
- 401
- 403
{- "success": true,
- "data": {
- "triggers": [
- {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadCreateTrigger",
- "title": "Создание обращения",
- "group": "lead",
- "group_title": "Обращения"
}, - {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadUpdateTrigger",
- "title": "Изменение обращения",
- "group": "lead",
- "group_title": "Обращения"
}, - {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadDeleteTrigger",
- "title": "Удаление обращения",
- "group": "lead",
- "group_title": "Обращения"
}, - {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\CalendarEventUpdateTrigger",
- "title": "Изменение календарного события",
- "group": "calendar_event",
- "group_title": "События календаря"
}, - {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\CalendarEventCreateTrigger",
- "title": "Создание календарного события",
- "group": "calendar_event",
- "group_title": "События календаря"
}, - {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\CalendarEventDeleteTrigger",
- "title": "Удаление календарного события",
- "group": "calendar_event",
- "group_title": "События календаря"
}, - {
- "class": "AntCRM\\Tasks\\App\\Automations\\Triggers\\TaskCreateTrigger",
- "title": "Создание задачи",
- "group": "task",
- "group_title": "Задачи"
}, - {
- "class": "AntCRM\\Tasks\\App\\Automations\\Triggers\\TaskUpdateTrigger",
- "title": "Изменение задачи",
- "group": "task",
- "group_title": "Задачи"
}, - {
- "class": "AntCRM\\Tasks\\App\\Automations\\Triggers\\TaskDeleteTrigger",
- "title": "Удаление задачи",
- "group": "task",
- "group_title": "Задачи"
}
]
}, - "message": "ОК"
}index
Возвращает список условий
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
query Parameters
required | AntCRM\Automation\App\Automations\Triggers\LeadCreateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\LeadUpdateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\LeadDeleteTrigger (string) or AntCRM\Automation\App\Automations\Triggers\CalendarEventUpdateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\CalendarEventCreateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\CalendarEventDeleteTrigger (string) or AntCRM\Tasks\App\Automations\Triggers\TaskCreateTrigger (string) or AntCRM\Tasks\App\Automations\Triggers\TaskUpdateTrigger (string) or AntCRM\Tasks\App\Automations\Triggers\TaskDeleteTrigger (string) Examples:
Класс триггера |
Responses
Response samples
- 200
- 401
- 403
{- "success": true,
- "data": [
- {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusInCondition",
- "title": "В статусе"
}, - {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\CalendarEventCondition",
- "title": "Есть календарное событие"
}, - {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\CalendarEventNotCondition",
- "title": "Нет календарного события"
}, - {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\TypeInCondition",
- "title": "Имеет тип"
}, - {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\TagInCondition",
- "title": "Имеет метку"
}
], - "message": "ОК"
}index
Возвращает список действий
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
Responses
Response samples
- 200
- 401
- 403
{- "success": true,
- "data": {
- "actions": [
- {
- "class": "AntCRM\\Automation\\App\\Automations\\Actions\\CalendarEventCreateAction",
- "title": "Создание события в календаре",
- "group": "calendar",
- "group_title": "Календарь"
}, - {
- "class": "AntCRM\\Tasks\\App\\Automations\\Actions\\TaskCreateAction",
- "title": "Создать задачу",
- "group": "tasks",
- "group_title": "Задачи"
}, - {
- "class": "AntCRM\\Communication\\App\\Automations\\Actions\\ChatMessageSendAction",
- "title": "Отправка сообщения в чат",
- "group": "chat",
- "group_title": "Чаты"
}
]
}, - "message": "ОК"
}trigger_fields
Возвращает список полей доступных у триггера, которые можно использовать в действии
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
query Parameters
required | AntCRM\Automation\App\Automations\Actions\CalendarEventCreateAction (string) or AntCRM\Tasks\App\Automations\Actions\TaskCreateAction (string) or AntCRM\Communication\App\Automations\Actions\ChatMessageSendAction (string) Examples:
Класс действия |
required | AntCRM\Automation\App\Automations\Triggers\LeadCreateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\LeadUpdateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\LeadDeleteTrigger (string) or AntCRM\Automation\App\Automations\Triggers\CalendarEventUpdateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\CalendarEventCreateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\CalendarEventDeleteTrigger (string) or AntCRM\Tasks\App\Automations\Triggers\TaskCreateTrigger (string) or AntCRM\Tasks\App\Automations\Triggers\TaskUpdateTrigger (string) or AntCRM\Tasks\App\Automations\Triggers\TaskDeleteTrigger (string) Examples:
Класс триггера |
Responses
Response samples
- 200
- 401
- 403
{- "success": true,
- "data": [
- {
- "code": "client_ids",
- "title": "Клиенты"
}, - {
- "code": "user_ids",
- "title": "Специалисты"
}, - {
- "code": "lead_ids",
- "title": "Обращения"
}, - {
- "code": "tag_ids",
- "title": "Метки"
}
], - "message": "ОК"
}index
Возвращает список сценариев
- Возвращается не более 3 условий сценария автоматизации
- Возвращается не более 3 действий сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
query Parameters
| page | integer Example: page=1 Номер страницы |
| cursor | string Example: cursor=123456 Курсор для пагинации |
| per_page | integer Default: 10 Enum: 10 25 50 Example: per_page=25 Количество элементов на странице |
| sort_by | string Value: ["id","name","description","created_at","updated_at"] Example: sort_by=name Поле для сортировки |
| descending | boolean Example: descending=true Сортировка по убыванию |
| search | string Example: search=welcome Поисковая строка |
| ids | Array of integers Example: ids=1&ids=2&ids=3 Массив идентификаторов. В случае передачи этого параметра игнорирует прочие параметры и возвращает сущности с указанными идентификаторами. Не более 50 идентификаторов в одном запросе. |
| group | string Example: group=lead Машинное название группы триггера |
Responses
Response samples
- 200
- 401
- 403
{- "success": true,
- "data": {
- "automation_scenarios": [
- [
- {
- "id": 7,
- "name": "Создание задачи",
- "created_at": "2023-01-01T00:00:00",
- "updated_at": "2023-01-01T00:00:00",
- "description": "Прозвон клиента админами с выяснением что он решил",
- "trigger": {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadCreateTrigger",
- "title": "Создание обращения"
}, - "is_active": true,
- "is_periodical": false,
- "condition_operator": "and",
- "user_id": 1,
- "delay_unit": "minutes",
- "delay_value": 5,
- "conditions": [
- {
- "id": 2,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusInCondition",
- "title": "В статусе"
}, - "params": {
- "status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 3,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\CalendarEventCondition",
- "title": "Есть календарное событие"
}, - "params": {
- "type_ids": [
- 1,
- 2,
- 3,
- 4
], - "type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "status_ids": [
- 1,
- 2,
- 3,
- 4
], - "status_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids.*": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 4,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\CalendarEventNotCondition",
- "title": "Нет календарного события"
}, - "params": {
- "type_ids": [
- 1,
- 2,
- 3,
- 4
], - "type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "status_ids": [
- 1,
- 2,
- 3,
- 4
], - "status_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids.*": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 5,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\TypeInCondition",
- "title": "Имеет тип"
}, - "params": {
- "type_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 6,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\TagInCondition",
- "title": "Имеет метку"
}, - "params": {
- "tag_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}
], - "actions": [
- {
- "id": 2,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "delay_value": 10,
- "delay_unit": "minutes",
- "action": {
- "class": "AntCRM\\Tasks\\App\\Automations\\Actions\\TaskCreateAction",
- "title": "Создать задачу",
- "group": "tasks",
- "group_title": "Задачи"
}, - "params": {
- "title": "Выполнить интеграцию",
- "description": "Ключевая цель",
- "result": "Действуйте согласно",
- "priority": 11,
- "type_id": 16,
- "status_id": 11,
- "participants": [
- 12
], - "executors": [
- 7
], - "tags": [
- 15
], - "deadline_interval": {
- "delay_value": 7,
- "delay_unit": "minutes"
}, - "extended_fields": [
- "client_ids"
]
}
}
]
}, - {
- "id": 15,
- "name": "Создание задачи",
- "created_at": "2023-01-01T00:00:00",
- "updated_at": "2023-01-01T00:00:00",
- "description": "Прозвон клиента админами с выяснением что он решил",
- "trigger": {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadUpdateTrigger",
- "title": "Изменение обращения"
}, - "is_active": true,
- "is_periodical": false,
- "condition_operator": "and",
- "user_id": 1,
- "delay_unit": "minutes",
- "delay_value": 5,
- "conditions": [
- {
- "id": 8,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusInCondition",
- "title": "В статусе"
}, - "params": {
- "status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 9,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusChangedCondition",
- "title": "Статус изменился"
}, - "params": {
- "after_status_ids": [
- 1,
- 2,
- 3,
- 4
], - "before_status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 10,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\CalendarEventCondition",
- "title": "Есть календарное событие"
}, - "params": {
- "type_ids": [
- 1,
- 2,
- 3,
- 4
], - "type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "status_ids": [
- 1,
- 2,
- 3,
- 4
], - "status_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids.*": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 11,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\CalendarEventNotCondition",
- "title": "Нет календарного события"
}, - "params": {
- "type_ids": [
- 1,
- 2,
- 3,
- 4
], - "type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "status_ids": [
- 1,
- 2,
- 3,
- 4
], - "status_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids.*": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 12,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\TypeInCondition",
- "title": "Имеет тип"
}, - "params": {
- "type_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 13,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\TypeChangedCondition",
- "title": "Тип изменился"
}, - "params": {
- "after_type_ids": [
- 1,
- 2,
- 3,
- 4
], - "before_type_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 14,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\TagInCondition",
- "title": "Имеет метку"
}, - "params": {
- "tag_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}
], - "actions": [
- {
- "id": 2,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "delay_value": 10,
- "delay_unit": "minutes",
- "action": {
- "class": "AntCRM\\Tasks\\App\\Automations\\Actions\\TaskCreateAction",
- "title": "Создать задачу",
- "group": "tasks",
- "group_title": "Задачи"
}, - "params": {
- "title": "Выполнить интеграцию",
- "description": "Ключевая цель",
- "result": "Действуйте согласно",
- "priority": 11,
- "type_id": 16,
- "status_id": 11,
- "participants": [
- 12
], - "executors": [
- 7
], - "tags": [
- 15
], - "deadline_interval": {
- "delay_value": 7,
- "delay_unit": "minutes"
}, - "extended_fields": [
- "client_ids"
]
}
}
]
}
]
], - "meta": {
- "current_page": 3,
- "from": 1,
- "last_page": 5,
- "links": [
- {
- "label": "« Назад",
- "active": false
}, - {
- "url": "/api/v1.0.0/ant-automation/scenarios?per_page=10&page=2",
- "label": "2",
- "active": false
}, - {
- "url": "/api/v1.0.0/ant-automation/scenarios?per_page=10&page=3",
- "label": "3",
- "active": false
}, - {
- "url": "/api/v1.0.0/ant-automation/scenarios?per_page=10&page=2",
- "label": "Вперёд »",
- "active": false
}
], - "path": "/api/v1.0.0/ant-automation/scenarios/resource",
- "per_page": 15,
- "to": 15,
- "total": 75
}, - "links": {
- "first": "/api/v1.0.0/ant-automation/scenarios?per_page=10&page=1",
- "last": "/api/v1.0.0/ant-automation/scenarios?per_page=10&page=10",
- "next": "/api/v1.0.0/ant-automation/scenarios?per_page=10&page=2"
}
}, - "message": "ОК"
}store
Создание сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
- SCENARIO_STORE
Authorizations:
Request Body schema: application/json
Данные для создания нового сценария
required | AntCRM\Automation\App\Automations\Triggers\LeadCreateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\LeadUpdateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\LeadDeleteTrigger (string) or AntCRM\Automation\App\Automations\Triggers\CalendarEventUpdateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\CalendarEventCreateTrigger (string) or AntCRM\Automation\App\Automations\Triggers\CalendarEventDeleteTrigger (string) or AntCRM\Tasks\App\Automations\Triggers\TaskCreateTrigger (string) or AntCRM\Tasks\App\Automations\Triggers\TaskUpdateTrigger (string) or AntCRM\Tasks\App\Automations\Triggers\TaskDeleteTrigger (string) |
| name required | string Название сценария |
| description required | string Описание сценария |
| is_active | boolean Активен ли сценарий |
| delay_value | integer Значение задержки выполнения |
| delay_unit | string Enum: "minutes" "days" "months" "years" Единица измерения задержки |
| is_periodical | boolean Является ли сценарий периодическим |
| condition_operator | string Enum: "and" "or" Логический оператор для условий |
Responses
Request samples
- Payload
{- "name": "Создание чего-то",
- "trigger_class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadCreateTrigger",
- "description": "Прозвон клиента админами с выяснением что он решил",
- "is_active": true,
- "delay_value": 8,
- "delay_unit": "years",
- "is_periodical": false,
- "condition_operator": "and"
}Response samples
- 200
- 400
- 401
- 403
{- "success": true,
- "data": {
- "id": 2,
- "name": "Создание задачи",
- "created_at": "2023-01-01T00:00:00",
- "updated_at": "2023-01-01T00:00:00",
- "description": "Прозвон клиента админами с выяснением что он решил",
- "trigger": {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadCreateTrigger",
- "title": "Создание обращения"
}, - "is_active": true,
- "is_periodical": false,
- "condition_operator": "and",
- "user_id": 1,
- "delay_unit": "minutes",
- "delay_value": 5
}, - "message": "ОК"
}update
Изменение сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
- SCENARIO_STORE
Authorizations:
path Parameters
| scenario required | integer Example: 1 Идентификатор сценария |
Request Body schema: application/json
Данные для изменения сценария
| name required | string Название сценария |
| description required | string Описание сценария |
| is_active required | boolean Активен ли сценарий |
| delay_value required | integer Значение задержки выполнения |
| delay_unit required | string Enum: "minutes" "days" "months" "years" Единица измерения задержки |
| is_periodical required | boolean Является ли сценарий периодическим |
| condition_operator required | string Enum: "and" "or" Логический оператор для условий |
Responses
Request samples
- Payload
{- "name": "Создание задачи",
- "description": "Прозвон клиента админами с выяснением что он решил",
- "is_active": true,
- "delay_value": 5,
- "delay_unit": "minutes",
- "is_periodical": false,
- "condition_operator": "and"
}Response samples
- 200
- 400
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 2,
- "name": "Создание задачи",
- "created_at": "2023-01-01T00:00:00",
- "updated_at": "2023-01-01T00:00:00",
- "description": "Прозвон клиента админами с выяснением что он решил",
- "trigger": {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadCreateTrigger",
- "title": "Создание обращения"
}, - "is_active": true,
- "is_periodical": false,
- "condition_operator": "and",
- "user_id": 1,
- "delay_unit": "minutes",
- "delay_value": 5
}, - "message": "ОК"
}show
Возвращает данные сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
path Parameters
| scenario required | integer Example: 1 Идентификатор сценария |
Responses
Response samples
- 200
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 2,
- "name": "Создание задачи",
- "created_at": "2023-01-01T00:00:00",
- "updated_at": "2023-01-01T00:00:00",
- "description": "Прозвон клиента админами с выяснением что он решил",
- "trigger": {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadCreateTrigger",
- "title": "Создание обращения"
}, - "is_active": true,
- "is_periodical": false,
- "condition_operator": "and",
- "user_id": 1,
- "delay_unit": "minutes",
- "delay_value": 5
}, - "message": "ОК"
}destroy
Удаление сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
- SCENARIO_DESTROY
Authorizations:
path Parameters
| scenario required | integer Example: 1 Идентификатор сценария |
Responses
Response samples
- 200
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 2,
- "name": "Создание задачи",
- "created_at": "2023-01-01T00:00:00",
- "updated_at": "2023-01-01T00:00:00",
- "description": "Прозвон клиента админами с выяснением что он решил",
- "trigger": {
- "class": "AntCRM\\Automation\\App\\Automations\\Triggers\\LeadCreateTrigger",
- "title": "Создание обращения"
}, - "is_active": true,
- "is_periodical": false,
- "condition_operator": "and",
- "user_id": 1,
- "delay_unit": "minutes",
- "delay_value": 5
}, - "message": "ОК"
}scenario groups
Возвращает список групп сценариев
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
Responses
Response samples
- 200
- 401
- 403
{- "success": true,
- "data": {
- "automation_scenario_groups": [
- {
- "code": "lead",
- "title": "Обращения"
}, - {
- "code": "calendar_event",
- "title": "События календаря"
}, - {
- "code": "task",
- "title": "Задачи"
}
]
}, - "message": "ОК"
}index
Возвращает список условий сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
path Parameters
| scenario required | integer Example: 1 Идентификатор сценария |
query Parameters
| page | integer Example: page=1 Номер страницы |
| cursor | string Example: cursor=123456 Курсор для пагинации |
| per_page | integer Default: 10 Enum: 10 25 50 Example: per_page=25 Количество элементов на странице |
| sort_by | string Value: ["id","condition_class","created_at","updated_at"] Example: sort_by=condition_class Поле для сортировки |
| descending | boolean Example: descending=true Сортировка по убыванию |
| search | string Example: search=welcome Поисковая строка |
| ids | Array of integers Example: ids=1&ids=2&ids=3 Массив идентификаторов. В случае передачи этого параметра игнорирует прочие параметры и возвращает сущности с указанными идентификаторами. Не более 50 идентификаторов в одном запросе. |
Responses
Response samples
- 200
- 401
- 403
- 404
{- "success": true,
- "data": [
- {
- "id": 2,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusInCondition",
- "title": "В статусе"
}, - "params": {
- "status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 3,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\CalendarEventCondition",
- "title": "Есть календарное событие"
}, - "params": {
- "type_ids": [
- 1,
- 2,
- 3,
- 4
], - "type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "status_ids": [
- 1,
- 2,
- 3,
- 4
], - "status_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids.*": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 4,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\CalendarEventNotCondition",
- "title": "Нет календарного события"
}, - "params": {
- "type_ids": [
- 1,
- 2,
- 3,
- 4
], - "type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_type_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "status_ids": [
- 1,
- 2,
- 3,
- 4
], - "status_ids.*": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids": [
- 1,
- 2,
- 3,
- 4
], - "exclude_status_ids.*": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 5,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\TypeInCondition",
- "title": "Имеет тип"
}, - "params": {
- "type_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - {
- "id": 6,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\TagInCondition",
- "title": "Имеет метку"
}, - "params": {
- "tag_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}
], - "message": "ОК"
}store
Добавление условия в сценарий автоматизации
Требуются права доступа:
- SCENARIO_SHOW
- SCENARIO_STORE
Authorizations:
path Parameters
| scenario required | integer Example: 1 Идентификатор сценария |
Request Body schema: application/json
Данные для добавления условия в сценарий
| condition_class | string Класс условия сценария |
object |
Responses
Request samples
- Payload
{- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusInCondition",
- "params": {
- "status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}Response samples
- 200
- 400
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 123,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusInCondition",
- "title": "В статусе"
}, - "params": {
- "status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - "message": "ОК"
}update
Изменение условия для сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
- SCENARIO_STORE
Authorizations:
path Parameters
| condition required | integer Example: 1 Идентификатор условия в сценарии |
Request Body schema: application/json
Данные для изменения условия в сценарий
object | |||
| |||
Responses
Request samples
- Payload
{- "params": {
- "status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}Response samples
- 200
- 400
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 123,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusInCondition",
- "title": "В статусе"
}, - "params": {
- "status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - "message": "ОК"
}show
Возвращает данные условия из сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
path Parameters
| condition required | integer Example: 1 Идентификатор условия в сценарии |
Responses
Response samples
- 200
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 123,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusInCondition",
- "title": "В статусе"
}, - "params": {
- "status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - "message": "ОК"
}destroy
Удаление условия из сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
- SCENARIO_DESTROY
Authorizations:
path Parameters
| condition required | integer Example: 1 Идентификатор условия в сценарии |
Responses
Response samples
- 200
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 123,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "condition": {
- "class": "AntCRM\\Automation\\App\\Automations\\Conditions\\StatusInCondition",
- "title": "В статусе"
}, - "params": {
- "status_ids": [
- 1,
- 2,
- 3,
- 4
]
}
}, - "message": "ОК"
}index
Возвращает список действий сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
path Parameters
| scenario required | integer Example: 1 Идентификатор сценария |
query Parameters
| page | integer Example: page=1 Номер страницы |
| cursor | string Example: cursor=123456 Курсор для пагинации |
| per_page | integer Default: 10 Enum: 10 25 50 Example: per_page=25 Количество элементов на странице |
| sort_by | string Value: ["id","action_class","delay_value","delay_unit","created_at","updated_at"] Example: sort_by=action_class Поле для сортировки |
| descending | boolean Example: descending=true Сортировка по убыванию |
| search | string Example: search=welcome Поисковая строка |
| ids | Array of integers Example: ids=1&ids=2&ids=3 Массив идентификаторов. В случае передачи этого параметра игнорирует прочие параметры и возвращает сущности с указанными идентификаторами. Не более 50 идентификаторов в одном запросе. |
Responses
Response samples
- 200
- 401
- 403
- 404
{- "success": true,
- "data": [
- {
- "id": 2,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "delay_value": 10,
- "delay_unit": "minutes",
- "action": {
- "class": "AntCRM\\Automation\\App\\Automations\\Actions\\CalendarEventCreateAction",
- "title": "Создание события в календаре",
- "group": "calendar",
- "group_title": "Календарь"
}, - "params": {
- "title": "Получить подтверждение",
- "description": "Требуется уточнение",
- "end_interval_minute": 14,
- "type_id": 19,
- "status_id": 18,
- "clients": [
- 8
], - "leads": [
- 9
], - "users": [
- 7
], - "tags": [
- 12
], - "start_interval": {
- "delay_value": 18,
- "delay_unit": "minutes"
}, - "extended_fields": [
- "client_ids"
]
}
}
], - "message": "ОК"
}store
Добавление действия в сценарий автоматизации
Требуются права доступа:
- SCENARIO_SHOW
- SCENARIO_STORE
Authorizations:
path Parameters
| scenario required | integer Example: 1 Идентификатор сценария |
Request Body schema: application/json
Данные для добавления действия в сценарий
| action_class required | string Класс действия сценария: |
| delay_value required | integer Значение задержки выполнения |
| delay_unit required | string Value: ["minutes","days","months","years"] Единица измерения задержки |
required | object Параметры действия |
Responses
Request samples
- Payload
{- "action_class": "AntCRM\\Automation\\App\\Automations\\Actions\\CalendarEventCreateAction",
- "delay_value": 3,
- "delay_unit": "days",
- "params": {
- "title": "Проверка совместимости",
- "description": "Проверка совместимости",
- "end_interval_minute": 9,
- "type_id": 10,
- "status_id": 5,
- "clients": [
- 15
], - "leads": [
- 5
], - "users": [
- 15
], - "tags": [
- 16
], - "start_interval": {
- "delay_value": 19,
- "delay_unit": "minutes"
}, - "extended_fields": [
- "client_ids",
- "lead_ids",
- "user_ids",
- "tag_ids"
]
}
}Response samples
- 200
- 400
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 1,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "delay_value": 10,
- "delay_unit": "minutes",
- "action": {
- "class": "AntCRM\\Automation\\App\\Automations\\Actions\\CalendarEventCreateAction",
- "title": "Создание события в календаре",
- "group": "calendar",
- "group_title": "Календарь"
}, - "params": {
- "title": "Действуйте согласно",
- "description": "Проверка совместимости",
- "end_interval_minute": 18,
- "type_id": 14,
- "status_id": 15,
- "clients": [
- 7
], - "leads": [
- 19
], - "users": [
- 5
], - "tags": [
- 10
], - "start_interval": {
- "delay_value": 7,
- "delay_unit": "minutes"
}, - "extended_fields": [
- "client_ids"
]
}
}, - "message": "ОК"
}update
Изменения действия в сценарии автоматизации
Требуются права доступа:
- SCENARIO_SHOW
- SCENARIO_STORE
Authorizations:
path Parameters
| action required | integer Example: 1 Идентификатор действия в сценарии |
Request Body schema: application/json
Данные для обновления действия в сценарий
| delay_value required | integer Значение задержки выполнения |
| delay_unit required | string Value: ["minutes","days","months","years"] Единица измерения задержки |
required | object Параметры действия |
Responses
Request samples
- Payload
{- "delay_value": 1,
- "delay_unit": "months",
- "params": {
- "title": "Выполнить интеграцию",
- "description": "Выполнить интеграцию",
- "end_interval_minute": 10,
- "type_id": 16,
- "status_id": 15,
- "clients": [
- 7
], - "leads": [
- 20
], - "users": [
- 19
], - "tags": [
- 20
], - "start_interval": {
- "delay_value": 10,
- "delay_unit": "minutes"
}, - "extended_fields": [
- "client_ids",
- "lead_ids",
- "user_ids",
- "tag_ids"
]
}
}Response samples
- 200
- 400
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 1,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "delay_value": 10,
- "delay_unit": "minutes",
- "action": {
- "class": "AntCRM\\Automation\\App\\Automations\\Actions\\CalendarEventCreateAction",
- "title": "Создание события в календаре",
- "group": "calendar",
- "group_title": "Календарь"
}, - "params": {
- "title": "Запустить сбор данных",
- "description": "Действуйте согласно",
- "end_interval_minute": 9,
- "type_id": 11,
- "status_id": 10,
- "clients": [
- 6
], - "leads": [
- 19
], - "users": [
- 17
], - "tags": [
- 10
], - "start_interval": {
- "delay_value": 18,
- "delay_unit": "minutes"
}, - "extended_fields": [
- "client_ids"
]
}
}, - "message": "ОК"
}show
Возвращает данные действия из сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
Authorizations:
path Parameters
| action required | integer Example: 1 Идентификатор действия в сценарии |
Responses
Response samples
- 200
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 1,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "delay_value": 10,
- "delay_unit": "minutes",
- "action": {
- "class": "AntCRM\\Automation\\App\\Automations\\Actions\\CalendarEventCreateAction",
- "title": "Создание события в календаре",
- "group": "calendar",
- "group_title": "Календарь"
}, - "params": {
- "title": "Действуйте согласно",
- "description": "Запустить сбор данных",
- "end_interval_minute": 14,
- "type_id": 11,
- "status_id": 9,
- "clients": [
- 12
], - "leads": [
- 13
], - "users": [
- 18
], - "tags": [
- 10
], - "start_interval": {
- "delay_value": 18,
- "delay_unit": "minutes"
}, - "extended_fields": [
- "client_ids"
]
}
}, - "message": "ОК"
}destroy
Удаление действия из сценария автоматизации
Требуются права доступа:
- SCENARIO_SHOW
- SCENARIO_DESTROY
Authorizations:
path Parameters
| action required | integer Example: 1 Идентификатор действия в сценарии |
Responses
Response samples
- 200
- 401
- 403
- 404
{- "success": true,
- "data": {
- "id": 1,
- "created_at": "2025-07-31T15:30:00",
- "updated_at": "2025-07-31T15:35:00",
- "delay_value": 10,
- "delay_unit": "minutes",
- "action": {
- "class": "AntCRM\\Automation\\App\\Automations\\Actions\\CalendarEventCreateAction",
- "title": "Создание события в календаре",
- "group": "calendar",
- "group_title": "Календарь"
}, - "params": {
- "title": "Ключевая цель",
- "description": "Произвести корректировку",
- "end_interval_minute": 7,
- "type_id": 9,
- "status_id": 18,
- "clients": [
- 15
], - "leads": [
- 13
], - "users": [
- 11
], - "tags": [
- 18
], - "start_interval": {
- "delay_value": 12,
- "delay_unit": "minutes"
}, - "extended_fields": [
- "client_ids"
]
}
}, - "message": "ОК"
}