/pachca:pachcafrom Pachca
Helps connect Pachca team chat to Claude Code or other agents via MCP, CLI, or token. Troubleshoots 401/403 errors and missing tools.
Ships in Pachca. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Pachca is a team chat app: a workspace of employees with chats, channels, threads, reminders, tags and bots.
All of it is reachable through one public API, exposed three ways: the MCP server (a pachca_* tool per API
method), the CLI @pachca/cli (a pachca <section> <action> command per method) and the REST API. This skill
gets you connected, explains why something is or is not available, and routes you to the skill for the work.
401, 402 or 403, or a tool the user expects is missing.user), multi-guest (multi_guest), guest (guest). The owner
also has role: admin, so the user object does not tell the owner apart. Guests get no API access at all:
no token, no CLI, no MCP.Every path calls the same API methods with the same rights.
| Who works with Pachca, and where | Use |
|---|---|
| An employee, from an agent app (Claude, Claude Code, Cursor, VS Code, Codex) | MCP server |
| An agent that runs terminal commands and needs to save context | CLI |
| Your own integration or service | REST API or SDK → pachca-api |
| An agent that lives in Pachca and is called by @mention or in a DM | a bot → pachca-ai-agent |
If MCP tools are already connected, use them. The CLI is the terminal alternative: it spends less context
(the agent learns commands from --help) but needs a shell.
Address https://mcp.pachca.com/mcp, transport Streamable HTTP. Choose how to sign in:
| Way | Fits | Acts as | Lifetime |
|---|---|---|---|
| Browser, consent screen | Claude Code, the Claude app, VS Code, GitHub Copilot CLI, Codex, the ChatGPT desktop app (through Codex) | the employee who approved | 1 hour, refreshes itself |
Personal token in Authorization: Bearer <token> | Cursor, SourceCraft Code Assistant, Qwen Code, GigaCode CLI, OpenCode, Devin Desktop, Cline, Kilo Code, Gemini CLI, nobody to sign in (CI) | the token owner | until deleted |
Bot token in Authorization: Bearer <token> | an agent with no employee present: a server, Yandex AI Studio, GigaChat | the bot | until deleted |
With the Pachca plugin the server is already configured: do not add a second one by hand, do what the
table says for your client. Check the list (claude mcp list, codex mcp list, copilot mcp list,
agent mcp list in Cursor). In Claude Code a server added by hand at the same address hides the plugin's
server.
| Client | Plugin's server | Sign in |
|---|---|---|
| Claude Code | plugin:pachca:pachca | /mcp, or claude mcp login plugin:pachca:pachca in the terminal. Installed from the shell during a session: /reload-plugins first |
| Claude app, Cowork | on the plugin's Connectors tab | Add, then Connect there. On Team and Enterprise the organization owner adds the connector first, members only press Connect |
| VS Code, GitHub Copilot CLI | pachca | the browser opens on first use. To retry in Copilot CLI: /mcp auth pachca |
| Cursor | plugin-pachca-pachca | no sign-in: it sends the token from PACHCA_TOKEN. Put a personal token there, restart Cursor |
| Codex | pachca | codex mcp login pachca (--no-browser prints the link) |
Without the plugin, Claude Code and Codex:
# Claude Code
claude mcp add --transport http pachca https://mcp.pachca.com/mcp # then /mcp; --scope user: all projects
claude mcp login pachca # from the terminal; with no browser, prints the link
# Codex: CLI, IDE extension and ChatGPT desktop app share it. Adding starts the browser sign-in
codex mcp add pachca --url https://mcp.pachca.com/mcp
codex mcp login pachca # retry; --no-browser prints the link
# Codex where nobody can sign in (CI): a personal token. Replaces a server of the same name, the plugin's too
codex mcp add pachca --url https://mcp.pachca.com/mcp --bearer-token-env-var PACHCA_TOKEN
GitHub Copilot CLI and VS Code, Gemini CLI, Devin, Qwen Code, GigaCode CLI, Cursor, OpenCode, the Claude app, the other clients, and installing the skills without the plugin: references/mcp-clients.md.
Do it right:
Dynamic client registration not supported, so ask the person to update it
(codex --version). If sign-in still fails or the client asks you to register a client, connect with a
personal token in the header instead.codex mcp login --scopes, scopes in the client's config):
the program asks for the scopes and the consent screen only shows them, with no choice. A narrowed
connection lists the same tools and refuses the rest with insufficient_scope. A missing scope takes a new
sign-in without the narrowing; retrying the call does not help. To limit an agent, give it a read-only
personal token instead (below).pachca-main, pachca-partner),
each with a personal token created in its own workspace.insufficient_scope.PACHCA_TOKEN, never in a config file that lands in the
repository. The program reads it from the environment it was started in: set it in the shell profile (on
Windows, in the system environment variables) and restart the program. An app started outside the terminal,
such as the ChatGPT desktop app, may still not see it.Needs Node.js 20+.
npm install -g @pachca/cli
pachca auth login # an employee at the terminal confirms in the browser
export PACHCA_TOKEN=YOUR_ACCESS_TOKEN # CI, scripts, agents: a ready token, no login step
npx -y @pachca/cli users list # one-off run without installing, token from PACHCA_TOKEN
pachca auth login prints an address and a code and waits for approval; --no-browser prints them
without opening a browser. The token lives an hour and refreshes itself. Its scopes are the whole catalog
cut by your role at the moment of approval, and they do not grow later.pachca auth login without --token needs a person at a terminal. Your own shell is usually not one (no
TTY), and CI is not either: the command fails at once with "Token required in non-interactive mode", and a
retry fails the same way. Ask the user to run pachca auth login in their own terminal window (for the
MCP server, /mcp in Claude Code), wait for them, then check with pachca auth status. Never ask for a
token in the conversation. The user saves a ready token in their own terminal (next bullet) or puts
PACHCA_TOKEN in the environment the agent starts from. CI and unattended agents take PACHCA_TOKEN from
their secrets and add --no-input.pbpaste | pachca auth login --token -. An argument
stays in shell history and in the process list.--token, --profile, PACHCA_TOKEN, PACHCA_PROFILE, the active profile. A
forgotten PACHCA_TOKEN silently wins over PACHCA_PROFILE and the active profile; name the profile with
--profile to be sure which workspace a command hits.pachca commands, pachca <section> <action> --help, pachca api ls,
pachca api POST /messages --describe. Add -o json for machine-readable output.Base URL https://api.pachca.com/api/shared/v1, header Authorization: Bearer <token>, JSON bodies. Personal
token: Интеграции > API; bot token: the API tab of the bot card. The value is shown once. Response
shapes, pagination, limits, errors, uploads and SDKs → pachca-api.
| Task | Token |
|---|---|
| You or your agent on your own machine, an MCP client app | personal: CLI login, MCP browser sign-in, or a personal token in the header |
| A script or personal automation acting as you | personal, created in the UI |
| No employee present: CI, server, cloud worker, chat bot, notifications | bot, with only the scopes it needs |
| A bot that needs an employee's own data: their reminders, their chats | by authorization (OAuth) → pachca-oauth |
Owner, admin, employee and multi-guest; guests never. By default only admins may connect as themselves: the
workspace setting Кто может создавать персональные токены starts at "Только администраторы" and closes
personal tokens, CLI login, browser MCP sign-in and bot authorization on the consent screen for everyone else.
Bots and their tokens fall under a separate setting, Кто может создавать интеграции, open to employees by
default. If the consent screen says «Доступ к API ограничен администраторами пространства», an admin must
switch the personal-token setting to Все сотрудники (→ pachca-admin). Do not look for another sign-in
way around it.
Do this before real work and after any 401 or 403.
Over MCP the server's instructions already say whom you act as, in a line like
You act as <name> (<id>), personal token, owner: the account, its id, the token kind and, for a personal
token, the workspace role, where the owner reads owner. Every tool result ends with a footer repeating the
name, id and token kind. Do not call a tool only to learn who you are, and do not ask whether the user is the
owner. The plan is not in that line: a listed pachca_list_company_chats or pachca_get_audit_events means
the owner on «Корпорация». If the line did not reach you (some clients drop server instructions) or the role
may have changed, use step 1.
pachca_get_my_card, CLI pachca profile get. You get the name, id and
workspace role (the owner shows as admin here). With a bot token it is the bot's own profile.pachca_get_token_info, CLI
pachca oauth token-info for any token. pachca auth status also shows the sign-in method and time left,
but it reads only the saved profile and the scopes saved at login: add --remote to ask the server.Each call passes five checks, and any one can refuse:
The MCP server lists only the tools that fit the token's role, plan and kind. Some programs show only part of
it. A list of Pachca tools that stops part-way through the alphabet was cut by the program, not by Pachca: in
Codex a plugin older than 1.0.5 gets only 64 KB of tool descriptions, so update it
(codex plugin marketplace upgrade pachca, then a new session) or add the server by hand with
codex mcp add pachca --url https://mcp.pachca.com/mcp. Codex also hides every MCP tool behind its tool search
once all servers together have more than 100, and that search can miss a tool asked for among others. VS Code
folds a server's tools into a group once the chat has 64 tools or more: call the group's activate_… tool to
open it. Before you call a tool missing, search
for it by its exact name alone, such as pachca_send_message. A tool that this search does not find is the answer,
not a glitch: tell the user which role, plan or token kind the action needs, and do not reach for the same
result through other tools. Owner privileges, multi-guest limits and role changes:
references/access-model.md.
| Response | Meaning | What to do |
|---|---|---|
401 | no token, expired or revoked (also when its owner was made a guest) | reconnect (/mcp in Claude Code, pachca auth login); a header token may have been deleted |
403 insufficient_scope | the token lacks the scope the response names | personal token from the UI: add it in the token menu on Интеграции > API; bot token: in the bot settings; MCP browser sign-in or CLI login: sign in anew, a plain reconnect keeps the old scopes |
403 role_forbidden | scope present, the role forbids the action | only an admin changing the role helps; reconnecting does not |
403 access_denied | the token belongs to a guest, a suspended or a deleted employee | use another account |
other 403 | not a member of the chat, chat role too low, or a plan feature | check membership and chat role first |
402 | the workspace is suspended: the plan's message limit is used up | tell the user; most methods refuse until it is paid |
404 | no such object, or one of another workspace; a chat of your workspace closed to you answers 403 | find the id with search or a list |
429, "Wait N s before repeating" | rate limit | wait the given time, then retry |
pachca-messaging)..md; llms-full.txt rarely fits whole, take sections.role: admin as "owner". Closed chats are member-only for
every role; only the owner gets the members of any chat, and on «Корпорация» also the list of all chats and
an export./mcp > Reconnect in Claude Code, or restart the client). If the new tool then
answers insufficient_scope, sign in again.~/.config/pachca/config.toml. In CI pass PACHCA_TOKEN instead of logging in.pachca-messaging).pachca-oauth).| Task | Skill |
|---|---|
| Write, reply, mention, draft, schedule, send files, reactions, pins, «Важное» | pachca-messaging |
| Find messages, chats, people; read a thread; digests; decisions and reminders from a discussion | pachca-search |
| Watch a thread from this session and reply in it as new messages come, through the CLI | pachca-watch-thread |
| Owner or admin: employees, tags, channels, roles, API access, all tokens, audit log, export, DLP | pachca-admin |
| Build a bot or integration: webhooks, events, tokens, scopes, buttons, forms, unfurling | pachca-bots |
| An AI agent that lives in Pachca as a bot and answers in threads | pachca-ai-agent |
| An app acting for each employee: OAuth with PKCE, refresh, revocation | pachca-oauth |
| Direct API, SDK, CLI in scripts and CI: pagination, limits, errors, uploads | pachca-api |
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
9 skills in this plugin
/pachca-adminАдминистрирование пространства Пачки: сотрудники (пригласить, сменить роль, приостановить, удалить), теги и участники чатов, доступ к API и «Все токены», журнал аудита, экспорт, DLP, безопасный контур и шифрование, и что требует владельца, администратора или «Корпорации». Load before a tool call that changes an employee: delete only after a yes to your question. Когда: «пригласи сотрудника», «уволь / удали сотрудника», «сделай администратором», «добавь в тег», «добавь / удали участника чата», «кто в закрытом канале, где я не состою», «доступ к API ограничен», «отзови доступ сотрудника к API», «журнал аудита», «выгрузи переписку», «правило DLP», "invite an employee", "offboard a user", "change role", "add or remove chat members", "let employees create tokens", "export messages". Not for: a missing tool or a general 401/403 → pachca; who is in a tag or chat → pachca-search; writing messages → pachca-messaging; a bot's own token → pachca-bots; an app acting for employees → pachca-oauth; scripts → pachca-api./pachca-ai-agentРешить, бот или MCP, и сделать AI-агента в Пачке в виде бота: его зовут упоминанием в чате или треде либо пишут ему в личный чат, он собирает контекст треда, показывает таймер agent-thinking, отвечает в треде и оформляет длинный ответ карточкой .md. Когда: «AI-агент в Пачке», «агент отвечает по упоминанию в треде», «агент не слышит упоминание», «бот-агент в личных сообщениях», «как агенту собрать контекст треда», «реакция agent-thinking», «длинный ответ агента карточкой .md», «бот или MCP», "AI agent bot in Pachca", "agent replies when mentioned", "agent does not hear a mention", "read thread context", "thinking indicator", "agent reply as an .md card", "bot vs MCP". Not for: working in Pachca from Claude or Cursor through MCP → pachca, pachca-messaging, pachca-search; drafts and scheduled messages (a bot cannot make them), sending a file or report from Claude, Cursor or the CLI → pachca-messaging; webhooks, tokens and settings of any bot → pachca-bots; acting on behalf of an employee → pachca-oauth.npx claudepluginhub pachca/openapi --plugin pachcaOther plugins' skills for the same job