
Bitrix24 AI 代理技能:webhook/OAuth、事件、重试、安全护栏和操作模式
概览
紧凑、面向生产的技能包,用于连接 AI 代理与 Bitrix24 REST。 - 快速启动真实 API 调用。- 默认执行安全,包含允许列表、风险确认和审计日志。- 模块化能力包代替一个超大型单体。- 支持webhook和OAuth流程。 - 通用在线文档:https://apidocs.bitrix24.com - 主文档仓库:https://github.com/bitrix24/b24restdocs - 开发者中心(SDK,工具):https://github.com/bitrix24/bitrix24-dev-hub - MCP文档:https://github.com/bitrix24/b24restdocs/blob/main/sdk/mcp.md 简短规则:- 运行时写入:webhook 或 OAuth。- 跨门户产品:OAuth。- 事件触发入口点:输出 webhook + 你的队列。- 更好的代理方法准确性:MCP。 来源:https://helpdesk.bitrix24.com/open/25866707/ 额外设置参考:https://helpdesk.bitrix24.com/open/21133100/ 1. 在 Bitrix24 中启用外部 AI 连接(仅管理员):- 打开账户菜单 ->设置 -> MCP 服务器。
概述(AI 翻译)
紧凑、面向生产的技能包,用于连接 AI 代理与 Bitrix24 REST。
为什么是这个群
- 快速启动,用于真实 API 调用。
- 默认安全执行,包含允许列表、风险确认和审计日志。
- 模块化能力包,取代一个超大整体。
- 支持webhook和OAuth流。
官方文档来源
- 通用在线文档:https://apidocs.bitrix24.com
- 主文档仓库:https://github.com/bitrix24/b24restdocs
- 开发者中心(SDK,工具):https://github.com/bitrix24/bitrix24-dev-hub
- MCP文档:https://github.com/bitrix24/b24restdocs/blob/main/sdk/mcp.md
项目布局
认证模型:何时使用什么
| 选项 | 使用时 | 不理想时使用 |
|---|---|---|
| 入侵的Webhook | 一个门户,快速内部自动化 | 多租户应用模型,仅应用上下文方法 |
| OAuth 应用 | 多门户缩放、应用生命周期、受控令牌轮换 | 非常小的单门户脚本,设置速度最为重要 |
| 外出的Webhook | 需要从门户事件推送触发到处理器 | 你需要保证开箱即用的重试/重放 |
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
Bitrix24 Agent Skill Pack
Compact, production-oriented skill pack for connecting AI agents to Bitrix24 REST.
Why this pack
- Fast start for real API calls.
- Safe-by-default execution with allowlist, risk confirmations, and audit log.
- Modular capability packs instead of one oversized monolith.
- Works with webhook and OAuth flows.
Official docs source
- Universal online docs: https://apidocs.bitrix24.com
- Main documentation repo: https://github.com/bitrix24/b24restdocs
- Developer hub (SDKs, tools): https://github.com/bitrix24/bitrix24-dev-hub
- MCP docs: https://github.com/bitrix24/b24restdocs/blob/main/sdk/mcp.md
Project layout
skills/bitrix24-agent/
SKILL.md
references/
bitrix24.md
packs.md
catalog-*.md
chains-*.md
scripts/
bitrix24_client.py
offline_sync_worker.py
agents/openai.yaml
Auth model: when to use what
| Option | Use when | Not ideal when |
|---|---|---|
| Incoming webhook | One portal, quick internal automation | Multi-tenant app model, app-context-only methods |
| OAuth app | Multi-portal scaling, app lifecycle, controlled token rotation | Very small one-portal scripts where setup speed matters most |
| Outgoing webhook | Need push trigger from portal events to your handler | You need guaranteed retry/replay out of the box |
| MCP server | Need better method/field discovery for agent generation quality | You treat MCP as transactional runtime for business writes |
Short rule:
- Runtime writes: webhook or OAuth.
- Cross-portal product: OAuth.
- Event trigger entrypoint: outgoing webhook + your queue.
- Better agent method accuracy: MCP.
Bitrix24 setup for external systems (quick admin manual)
Source: https://helpdesk.bitrix24.com/open/25866707/ Additional setup reference: https://helpdesk.bitrix24.com/open/21133100/
- Enable external AI connections in Bitrix24 (admin only):
- Open account menu ->
Settings->MCP servers. - Turn on
Allow connection of external AIs to Bitrix24. - Save.
- Connect an external assistant:
- The MCP endpoint is region/deployment-specific — read it from your portal’s
Settings->MCP serverspage rather than hardcoding a global host (thehttps://mcp.bitrix24.com/mcp/form is the cloud default; .ru/.eu/other regions, data-residency and on-premise differ). - OAuth path (assistant supports OAuth): create connector/app in assistant UI, set the MCP URL from your portal, choose
OAuth. - Token path (assistant has no OAuth): in Bitrix24 open
Apps->MCP connections->Get connection token, copy token to assistant connector, use the MCP URL from your portal.
Use the official MCP for method/field discovery; use this skill’s governed CLI for safe transactional writes (allowlist, confirm gates, plan/execute, idempotency, audit).
- Validate access model:
- Commands run on explicit user request.
- Actions follow the connected user’s Bitrix24 permissions.
- Disable or revoke when needed:
推荐工具
换一个关键词,或者移除筛选条件。
安装
npx skillfish add vrtalex/bitrix24-skill