crm-cli 标志

crm-cli

社区
jdanielnd

Your contacts, in your terminal.

发布者jdanielnd
代码仓库crm-cli
语言Go
复刻数
6
星标数
36
可用工具
0
传输类型stdio
分类
链接
  • 将工具接入 AI 工作流

    crm-cli 提供 MCP 功能,可供兼容的 AI 客户端和智能体使用。

  • 0 个可用工具

    浏览下方可调用的操作;如果服务器提供了名称和描述,也会一并显示。

  • 可直接复制的配置

    使用安装配置片段,在您首选的 MCP 客户端中配置此服务器。

  • 开源社区热度

    关联的代码仓库有 36 个 Star 和 6 个 Fork。

crm — your contacts, in your terminal.

crm banner

CI Go Report Card License: MIT

A local-first personal CRM that lives in your terminal. Manage contacts, organizations, interactions, deals, and tasks — all from the command line. Ships with a built-in MCP server so AI agents like Claude can read and update your CRM directly.

Single static binary. SQLite database. No cloud. No accounts. Your data stays on your machine.

Features

  • People & Organizations — contacts with full profiles, linked to companies
  • Interaction Log — track calls, emails, meetings, notes, and messages
  • Deals & Pipeline — sales opportunities with stages, values, and a pipeline view
  • Tasks — follow-ups with due dates, priorities, and completion tracking
  • Tags — labels on any entity for flexible organization
  • Relationships — person-to-person links (colleague, mentor, referred-by, …)
  • Full-Text Search — find anything across all entities instantly
  • Context Briefing — one command to get everything about a person before a meeting
  • AI-Ready — built-in MCP server for Claude and other AI agents
  • Multiple Output Formats — table, JSON, CSV, TSV — pipe into anything
  • Zero Dependencies — single binary, pure-Go SQLite, runs anywhere

Install

bash
# Homebrew (macOS/Linux)
brew install jdanielnd/tap/crm

# Go
go install github.com/jdanielnd/crm-cli/cmd/crm@latest

# Or download a binary from GitHub Releases
# https://github.com/jdanielnd/crm-cli/releases

Quick Start

bash
# Add a company
crm org add "Acme Corp" --domain acme.com

# Add a contact and link them to the org
crm person add "Jane Smith" --email jane@example.com --org 1

# Log a call
crm log call 1 --subject "Intro call"

# Get a full briefing before your next meeting
crm context 1

# See your dashboard
crm status

Commands

People

bash
crm person add "Jane Smith" --email jane@example.com --phone 555-1234 --org 1
crm person list                          # all contacts
crm person list --tag vip --limit 10     # filtered
crm person show 1                        # full details
crm person edit 1 --title "CTO" --company "Acme Corp"
crm person delete 1                      # soft-delete (recoverable)

Organizations

bash
crm org add "Acme Corp" --domain acme.com --industry SaaS
crm org list
crm org show 1 --with-people             # show org + its members
crm org edit 1 --domain acme.io
crm org delete 1

Interactions

bash
crm log call 1 --subject "Discussed roadmap" --content "Agreed on Q2 timeline"
crm log email 1 --subject "Follow-up" --direction outbound
crm log meeting 1 2 --subject "Product demo" --at "2026-03-05 14:00"
crm log note 1 --subject "Quick check-in" --content "Seemed interested"
crm log list --person 1 --limit 5        # recent interactions with person

Deals

bash
crm deal add "Website Redesign" --value 15000 --person 1 --stage proposal
crm deal list --open                     # exclude won/lost
crm deal list --stage proposal
crm deal show 1
crm deal edit 1 --stage won --closed-at 2026-03-15
crm deal delete 1
crm deal pipeline                        # summary by stage

Tasks

bash
crm task add "Follow up on proposal" --person 1 --due 2026-03-14 --priority high
crm task list                            # open tasks
crm task list --overdue                  # past due
crm task list --all                      # include completed
crm task show 1
crm task edit 1 --priority medium
crm task done 1                          # mark completed
crm task delete 1

Tags

bash
crm tag apply person 1 "vip"
crm tag apply deal 1 "q2"
crm tag show person 1                    # tags on a person
crm tag remove person 1 "vip"
crm tag list                             # all tags
crm tag delete "old-tag"                 # remove tag entirely

Relationships

bash
crm person relate 1 2 --type colleague --notes "Met at ReactConf"
crm person relationships 1               # list all relationships
crm person unrelate 1                    # remove by relationship ID

Relationship types: colleague, friend, manager, mentor, referred-by

Search

bash
crm search "jane"                        # searches people, orgs, interactions, deals
crm search "roadmap" --type interaction  # filter by entity type

Context Briefing

bash
crm context 1                            # full briefing by person ID
crm context "Jane Smith"                 # or by name

Returns person profile, organization, recent interactions, open deals, pending tasks, relationships, and tags — everything you need before a meeting.

Dashboard

bash
crm status

Shows contact/org counts, open deals with total value, task counts, overdue items, pipeline breakdown, and recent activity.

Output Formats

Every command supports --format / -f:

bash
crm person list                          # table (default in TTY)
crm person list -f json                  # JSON (default when piped)
crm person list -f csv                   # CSV
crm person list -f tsv                   # TSV

Use -q / --quiet for minimal output (just IDs), useful for scripting:

bash
crm person list --tag vip -q | xargs -I{} crm tag apply person {} "priority"

Piping & Composition

crm follows Unix conventions — data to stdout, messages to stderr, structured exit codes — so it plays well with other tools:

bash
# Bulk tag everyone at an org
crm person list -f json | jq '.[] | select(.org_id == 1) | .id' | xargs -I{} crm tag apply person {} "acme-team"

# Interactive selection with fzf
crm person list -f tsv | fzf | cut -f1 | xargs crm person show

# Export contacts to CSV
crm person list -f csv > contacts.csv

# Overdue task notifications
crm task list --overdue -f json | jq -r '.[] | "OVERDUE: \(.title)"'

Exit codes: 0 success, 1 error, 2 usage, 3 not found, 4 conflict, 10 database error.

AI Integration (MCP Server)

crm includes a built-in MCP server so AI agents can query and update your CRM over a structured protocol.

Claude Code

bash
claude mcp add crm -- crm mcp serve

Then copy AGENT.md into your project as CLAUDE.md so Claude knows how to use the CRM effectively.

Claude Desktop (macOS)

  1. Open the config file at ~/Library/Application Support/Claude/claude_desktop_config.json

  2. Add the CRM server (if the file already has other servers, add the "crm" entry inside the existing mcpServers object):

json
{
  "mcpServers": {
    "crm": {
      "command": "/opt/homebrew/bin/crm",
      "args": ["mcp", "serve"]
    }
  }
}

Note: Use the full path to the binary. Homebrew on Apple Silicon installs to /opt/homebrew/bin/crm, on Intel Macs to /usr/local/bin/crm. Run which crm to find yours.

  1. Restart Claude Desktop

  2. Create a new Project, click the project settings, and paste the contents of AGENT.md into the project instructions. This teaches Claude when to log interactions, how to maintain contact summaries, tagging conventions, and more.

Available Tools

ToolDescription
crm_person_searchSearch people by name, email, tag, org
crm_person_getGet full details for a person
crm_person_createCreate a new person
crm_person_updateUpdate person fields
crm_person_deleteDelete (archive) a person
crm_person_relateCreate relationship between people
crm_org_searchSearch organizations
crm_org_getGet org details with members
crm_interaction_logLog a call, email, meeting, or note
crm_interaction_listList interactions for a person
crm_searchCross-entity full-text search
crm_contextFull person briefing
crm_deal_createCreate a deal
crm_deal_updateUpdate deal stage/fields
crm_task_createCreate a task
crm_task_listList open tasks
crm_tag_applyApply a tag
crm_statsCRM summary stats

Example AI Workflow

After a meeting, tell Claude:

"Just had a great meeting with Jane. We agreed on the timeline, she'll sign next week."

Claude can:

  1. Log the interaction with crm_interaction_log
  2. Update the deal stage with crm_deal_update
  3. Create a follow-up task with crm_task_create
  4. Update Jane's summary with crm_person_update

The summary field on contacts acts as a living dossier that AI agents maintain — reading it before meetings for context, updating it after interactions with new facts and preferences.

Configuration

The database lives at ~/.crm/crm.db by default. Override with:

bash
# Flag (highest priority)
crm --db /path/to/crm.db person list

# Environment variable
export CRM_DB=/path/to/crm.db

The database and directory are auto-created on first use.

iCloud Sync (macOS)

Point your database to iCloud Drive for automatic backup across machines:

bash
export CRM_DB="$HOME/Library/Mobile Documents/com~apple~CloudDocs/crm/crm.db"

SQLite WAL mode handles concurrent reads well, but avoid writing from two machines simultaneously.

Building from Source

bash
git clone https://github.com/jdanielnd/crm-cli.git
cd crm-cli
go build -o crm ./cmd/crm
go test ./...

Requires Go 1.23+. No CGO — builds anywhere Go runs.

Tech Stack

ComponentChoice
LanguageGo
DatabaseSQLite via modernc.org/sqlite (pure Go, no CGO)
CLICobra
MCPmcp-go
SearchSQLite FTS5

License

MIT

将 crm-cli MCP 与多个 AI 模型配合使用

TypingMind 在工作区级别连接 MCP 工具,因此连接 crm-cli 后,您就可以在 TypingMind 中搭配不同的 AI 模型使用,无需为每个模型单独设置。 此 MCP 通过您设备上的 TypingMind MCP 连接器在本地运行。

本地连接器设置指南

如果 MCP 服务器需要访问您电脑上的本地文件、应用或私有资源,请选择此方式。

1

打开 MCP 设置

在 TypingMind 中,依次前往“设置”、“高级设置”和“模型上下文协议”,然后选择“设置连接器”。

  1. 在您的浏览器中打开 TypingMind。
  2. 点击“设置”图标。
  3. 进入“高级设置”。
  4. 打开“模型上下文协议”部分。
  5. 点击“设置连接器”,然后选择“此设备”。
TypingMind MCP 连接器设置界面,已选择“此设备”
2

运行连接器命令

选择“此设备”,从 TypingMind 复制命令并在终端中运行。使用 MCP 时,请保持该进程运行。

  1. 复制 TypingMind 显示的设置命令。
  2. 在 macOS 上打开“终端”,或在 Windows 上打开 Windows Terminal。
  3. 粘贴并运行命令。
  4. 如果终端询问您是否继续,请确认安装软件包。
  5. 使用 MCP 工具时,请保持终端窗口及其中的进程运行。
3

将 crm-cli 添加为服务器

当连接器状态为“就绪”时,点击“编辑服务器”,然后粘贴 MCP 服务器配置。

  1. 等待连接器状态显示为“就绪”。
  2. 点击“编辑服务器”。
  3. 粘贴 crm-cli MCP 服务器配置。
  4. 保存服务器列表。
  5. 如需确认连接器是否仍处于就绪状态,请刷新。
TypingMind MCP 设置界面,显示正在运行的服务器和“编辑服务器”按钮
{
  "mcpServers": {
    "crm-cli": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

在不同模型中使用同一连接

保存服务器列表,打开“插件”,启用 crm-cli MCP 工具,然后在 TypingMind 中选择任意受支持的 AI 模型,即可在聊天中使用这些工具,或将其分配给智能体。

  1. 在 TypingMind 中打开“插件”页面。
  2. 启用 crm-cli MCP 工具。
  3. 开始聊天并选择您想使用的 AI 模型。
  4. 在聊天中使用 MCP 工具,或将其分配给 AI 智能体。
  5. 根据需要随时切换到其他 AI 模型,无需重新连接 MCP。
在 TypingMind 聊天中使用已启用的 MCP 工具和选定的 AI 模型
您能使用 crm-cli 帮我完成这项任务吗?
crm-cli
当然。我已阅读。
以下是我使用 crm-cli 得到的结果。

常见问题

crm-cli MCP 服务器有什么用途?

crm-cli 是一个 MCP 服务器,可让兼容的 AI 客户端连接外部工具并获取上下文。在 TypingMind 中,只需添加一次此 MCP 服务器,即可在您的 AI 工作区中使用其工具。

可以在 TypingMind 中让多个 AI 模型使用 crm-cli MCP 吗?

可以。TypingMind 在工作区层面连接 MCP 工具,因此您可以让 Claude、ChatGPT、Gemini 等不同 AI 模型,或您在 TypingMind 中配置的其他模型使用 crm-cli,而无需为每个模型单独配置 MCP 服务器。

为什么在 TypingMind 中使用 crm-cli MCP?

TypingMind 将多个 AI 模型、提示词、插件、AI 智能体、API 密钥和 MCP 工具整合到同一个工作区中,是优秀的大语言模型聊天前端之一。连接 crm-cli 后,您可以在偏好的不同模型中使用其 MCP 工具,同时在 TypingMind 中井然有序地管理聊天工作流程。

如何将 crm-cli MCP 连接到 TypingMind?

crm-cli 通过 TypingMind 本地 MCP 连接器运行。当 MCP 服务器需要访问您计算机上的本地文件、桌面应用、命令行工具或私有资源时,这种方式最合适。

crm-cli MCP 在 TypingMind 中提供哪些工具?

crm-cli 提供 MCP 功能,您可以在 TypingMind 的插件页面启用这些功能,然后在聊天中使用,或将其分配给 AI 智能体。

使用 crm-cli MCP 需要向 TypingMind 提供我的 API 密钥吗?

不需要。TypingMind 采用本地优先的设计,让您自行掌控模型提供商、API 密钥、提示词和 MCP 配置。如果 crm-cli 需要身份验证,请在创建连接时,为该 MCP 服务器添加所需的请求头、OAuth 设置或本地配置。

相关 MCP 服务器

查看全部

立即创建您自己的 AI 工作区

订阅我们的电子简报,获取新功能和后续赠奖活动的通知 👇