npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@polza-ai/bitrix-cli

v0.1.1

Published

CLI tool for Bitrix24 CRM — for humans and AI agents

Readme

Bitrix24 CLI

CLI для Bitrix24 CRM — для людей и AI-агентов.

Полный CRUD для сделок, лидов, контактов и компаний. Все команды поддерживают --json для машинного вывода.

Установка

npm install -g @polza-ai/bitrix-cli

Быстрый старт

# Настроить подключение (webhook)
bitrix init

# Проверить подключение
bitrix whoami

# Список сделок
bitrix deals

# Создать сделку
bitrix deal-add -t "Новая сделка" --amount 100000 --currency RUB

Авторизация

Webhook (рекомендуется)

  1. В Битрикс24: Приложения → Вебхуки → Добавить входящий вебхук
  2. Выберите нужные права доступа (CRM, пользователи)
  3. Скопируйте URL вида https://ваш-домен.bitrix24.ru/rest/1/xxxxxxxxx/
  4. Запустите bitrix init и вставьте URL

OAuth

bitrix init --oauth

Потребуется домен Bitrix24 и access token вашего приложения.

Команды

Общие

| Команда | Описание | |---------|----------| | bitrix init | Настроить подключение | | bitrix whoami | Текущий пользователь |

Сделки

bitrix deals                              # список сделок
bitrix deals --stage WON --limit 10       # фильтр по стадии
bitrix deal 123                           # детали сделки
bitrix deal-add -t "Сделка" --amount 5000 # создать
bitrix deal-update 123 --stage WON        # обновить
bitrix deal-delete 123                    # удалить

Лиды

bitrix leads                              # список лидов
bitrix leads --status NEW                 # фильтр по статусу
bitrix lead 42                            # детали лида
bitrix lead-add -t "Лид" --phone +79991234567
bitrix lead-update 42 --status IN_PROCESS
bitrix lead-delete 42

Контакты

bitrix contacts                           # список контактов
bitrix contact 10                         # детали контакта
bitrix contact-add --name "Иван" --last-name "Петров" --phone +79991234567
bitrix contact-update 10 --email [email protected]
bitrix contact-delete 10

Компании

bitrix companies                          # список компаний
bitrix company 5                          # детали компании
bitrix company-add -t "ООО Рога и копыта" --industry IT
bitrix company-update 5 --title "Новое название"
bitrix company-delete 5

Активности CRM

bitrix activities --entity-type deal --entity-id 123    # список
bitrix activity-add --entity-type deal --entity-id 123 -s "Позвонить клиенту"

Таймлайн

bitrix timeline-add --entity-type deal --entity-id 123 -c "Комментарий"

JSON-вывод для AI-агентов

Все команды поддерживают флаг --json:

bitrix deals --json
{
  "ok": true,
  "data": [
    {
      "ID": "1",
      "TITLE": "Сделка",
      "STAGE_ID": "NEW",
      "OPPORTUNITY": "50000",
      "CURRENCY_ID": "RUB"
    }
  ]
}

При ошибке:

{
  "ok": false,
  "error": {
    "code": "AUTH_ERROR",
    "message": "Нет доступа."
  }
}

MCP-сервер документации

Для AI-инструментов доступен MCP-сервер с актуальной документацией Bitrix24 REST API:

# Claude Code
claude mcp add --transport http b24-dev-mcp https://mcp-dev.bitrix24.tech/mcp

Разработка

git clone https://github.com/polza-ai/bitrix-cli.git
cd bitrix-cli
npm install
npm run dev -- whoami          # запуск через tsx
npm run build                  # компиляция
npm run typecheck              # проверка типов

Лицензия

MIT