---
title: "Connect Amocrm Channel"
method: POST
path: "/api/channels/amocrm/connect"
tags: ["channels", "channels", "amocrm"]
---

# Connect Amocrm Channel

`POST /api/channels/amocrm/connect`

## Request

- Base URL: `https://api.dialogbrain.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.dialogbrain.com/api/channels/amocrm/connect`
- Auth: none declared

Connect an amoCRM Chat channel (amoJo).

Steps:
1. Fetch amojo_id from the workspace's amoCRM REST integration
2. Call AmojoClient.connect_channel() to get scope_id
3. Store credentials (encrypted) in workspace_secrets
4. Return scope_id + webhook URL

Either integration_id OR amocrm_account_id must be provided.

## Request body

- AmocrmConnectRequest: Request to connect an amoCRM Chat channel.
  - `integration_id` integer, nullable: Workspace's existing amoCRM REST integration ID (for OAuth token + account lookup)
  - `amocrm_account_id` string, nullable: amoCRM account ID (e.g. '32866990'). Fetched from REST API if integration_id provided.
  - `channel_id` string, required: amoJo channel ID from amoCRM Chat UI
  - `channel_secret` string, required: amoJo channel secret (for HMAC signing)
  - `base_domain` string: amoJo domain (amocrm.ru or kommo.com)
  - `title` string: Title for the channel in amoJo

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/dialogbrain/apis/dialogbrain-v2-api-gateway.md) · [All operations](https://skmtc.dev/dialogbrain/apis/dialogbrain-v2-api-gateway/llms.txt) · [OpenAPI document](https://skmtc.dev/dialogbrain/apis/dialogbrain-v2-api-gateway/revisions/77bef09a9209?raw)
