On this page
Concepts
Agim is a lightweight hub that connects messengers, the Web console, and agents. You can send a message from WeChat, Feishu, DingTalk, Telegram, or the Web console, then let Claude Code, Codex, Cursor, Kimi Code, Qoder, PI, MiMo Code, Antigravity, OpenCode, or the built-in Agim Agent handle the work.
It does not replace the agents you already use or force your workflow into a heavy backend. Agim handles routing, sessions, approval, memory, recovery, and audit so “send a task in chat” becomes a reliable operating model.
- Entry points: IM, Web console, and terminal TUI all use the same service.
- Agent dispatch: keep one sticky agent or switch agents inside a conversation.
- Safety controls: file, shell, and network actions can ask for approval first.
- Long-running work: reminders, goals, schedules, background jobs, and recovery are handled by Agim.
- Local data: configuration, sessions, memory, and audit logs live
under
~/.agimby default.
Quick start
For the full script, npm, and source install paths, see the install page . For a first run, get Web plus one agent working before connecting messengers.
npm install -g agim-cli
agim go
agim web
agim doctor -
agim gochecks the environment, helps configure one usable agent, and starts the service. - If Claude Code, Codex, Cursor, or another CLI agent is already installed, Agim will try to detect it.
- If no CLI agent is installed yet, configure a model API and use the built-in Agim Agent.
- Once Web chat works, connect WeChat, Feishu, DingTalk, Telegram, or email notifications from Settings.
Messengers
You do not need to enable every messenger at once. Start with the channel you use most, verify message delivery, approvals, and agent replies, then add more entry points.
| Entry | What to prepare | Best for |
|---|---|---|
| WeChat / WeCom | Connect by QR login or enterprise app authorization. Works well for personal use, teams, and mobile-first workflows. | Daily chat, approvals, reminders, and long-running task updates. |
| Feishu / Lark | Create a self-built enterprise app, then provide App ID, Secret, and event settings. | Team collaboration, group @mentions, approval cards, files, and images. |
| DingTalk | Use an enterprise internal app with Stream mode, not a one-way group webhook bot. | Enterprise groups, mobile approvals, voice, and image handling. |
| Telegram / Discord | Optional global IM channels. Enable them, then connect with a bot token or app credentials. | International teams, open-source communities, and backup notifications. |
| Configure SMTP sending credentials. | Reminders, alerts, and long-running task completion notices. | |
| Web console | Start Agim and open the local web URL. | First-run testing, agent setup, task review, approvals, and logs. |
A practical rollout order is: Web console first, then IM; direct messages first, then groups; text first, then files, images, and voice. It makes troubleshooting much easier.
Mainstream agents
Agim puts different agents on the same message bus. You can set a default agent or switch within a conversation. These are the main supported backends today.
| Agent | Command | What to prepare | Best for |
|---|---|---|---|
| Agim Agent | /agim, /na, /llm | No extra CLI required. Configure a model API and it is ready. | Default assistant, Q&A, summaries, reminders, lightweight tools, and users without a CLI agent installed. |
| Claude Code | /cc, /claude | Install Claude Code and complete its login flow. | Code understanding, project edits, and complex multi-step work. |
| Codex | /cx, /codex | Install and sign in to the Codex CLI. | Code review, edits, tests, and local repository work. |
| Cursor | /cs, /cursor | Install cursor-agent, then configure OAuth or an API key. | Teams already using the Cursor workflow. |
| Kimi Code | /kimi, /km | Install the Kimi Code CLI and complete first login. | Chinese code and documentation workflows. |
| Qoder | /qd, /qodercli | Install Qoder CLI and sign in. | Remote control for existing Qoder users. |
| PI | /pi, /pi-agent | Install the PI CLI and complete authentication. | Teams with an existing PI workflow. |
| MiMo Code | /mo, /mimo-code | Install MiMo Code CLI and sign in. | MiMo ecosystem and China-friendly model workflows. |
| Antigravity | /agy, /ag | Install the Antigravity CLI and complete first authorization. | Google-flavored agent workflows. |
| OpenCode | /oc | Install OpenCode and complete authentication. | Self-hosted, open-source, and controlled environments. |
Pick the agent you know best as the default. Once stable, add the others as specialist tools: Codex for tests, Claude Code for deeper planning, Agim Agent for everyday Q&A.
Agim Agent (built-in)
Agim Agent is built in. It does not require an external CLI. Configure a model API and it can talk to OpenAI-compatible, Anthropic-compatible, Ollama, vLLM, or common China-friendly model providers.
It is a good default assistant for Q&A, summaries, reminders, memory, lightweight files, and tool calls. If you have not installed Claude Code, Codex, Cursor, or another mainstream agent yet, Agim Agent lets the whole system run first.
-
Model settings live in
llmBackendsandllmRoles; secrets are stored separately. -
Its role file can live at
~/.agim-workspaces/native/AGENTS.mdand reloads without a restart. - It uses the same approval, audit, memory, reminder, and recovery features as the CLI agents.
Common commands
These are the commands you will use most often. In practice, you do not need to memorize all of them; many capabilities can also be triggered in natural language.
| Command | Description |
|---|---|
agim go | Recommended first run: checks the environment, helps configure one agent, then starts Web and the service. |
agim web | Open the Web console for testing, setup, and task review. |
agim doctor | Check Node, CLI agents, config files, ports, and common dependencies. |
agim config | Reopen the setup wizard for messengers, agents, model APIs, and Web port settings. |
agim start / status / restart / stop | Manage the service according to the current run mode. |
/agents | Show the agents currently available. |
/cc, /cx, /cs, /kimi, /qd, /pi, /mo, /agy, /agim | Switch the current conversation to a specific agent. |
/new | Start a fresh conversation and clear the current context and sticky agent. |
/remind | Create one-shot or recurring reminders delivered through IM or email. |
/memo | Manage long-term memory. You can also say “remember that...” and let the agent save it. |
/goal or /long_task | Set a sustained goal for the current thread so later turns stay focused. |
/heartbeat | Ask the agent to check regularly whether anything needs attention. |
/job or /tasks | Review background jobs, long-running work, and schedules. |
/audit or /stats | Inspect invocation history, cost, latency, and runtime status. |
Long-running work & goals
IM is great for assigning work, but long-running work should not depend on one chat message. Agim models it as recoverable goals, reminders, schedules, background jobs, and outbound delivery.
- Goals: use
/goalor/long_taskto keep the current thread focused on one sustained objective. - Reminders: use
/remindfor one-shot or recurring reminders, or ask the agent in natural language. - Schedules: use
/cronto run an agent periodically for reports, checks, or batch work. - Background jobs: longer tasks enter the job board and can be
reviewed from Web or
/job. - Reliable delivery: replies go through a local outbox before reaching IM or Web, so restarts can recover.
In daily use, the point is simple: you can break complex work into steps, and Agim keeps enough state to bring the result back to the original conversation.
Security & approval
Agim does not rely on the model “being careful.” Safety is enforced at the service layer, between the agent and the real system.
- Approval: file writes, shell commands, and network access can surface an approval card first.
- Sensitive-path protection: secrets, config, system accounts, and agent instruction files are blocked from being read out and sent back to IM.
- Web auth: the Web console supports token access control. Put public deployments behind a reverse proxy and TLS.
- Admins: restart, stop, and high-risk settings should be limited to administrator accounts.
- Audit: invocations, results, latency, and errors are recorded for review and troubleshooting.
For local personal use, defaults are a good start. For a team or server deployment, configure admins, Web access, and backups early.
Configuration
Most settings can be changed through agim go, agim config,
or Web Settings. You usually only need the files for automation, migration, or
troubleshooting.
| Path | Purpose |
|---|---|
~/.agim/config.json | Main config: enabled messengers, agents, Web port, default agent, remote agents, and more. |
~/.agim/llm-secrets.json | Model API keys used by Agim Agent. |
~/.agim/env | Environment-style settings such as SMTP, map services, and optional feature flags. |
~/.agim-workspaces/<agent>/ | Separate workspace, role files, and long-term context for each agent. |
Recommended practice: let the wizard write config, use Web to inspect status, and
back up ~/.agim before manual edits.
Web console
The Web console is the best place for first setup and day-to-day status checks. It is more than chat: it also covers configuration, audit, and task review.
- Chat: talk to an agent in the browser and verify model, approval, and reply delivery.
- Settings: enable messengers, choose the default agent, configure model APIs, and manage remote agents.
- Tasks: review long-running tasks, schedules, background jobs, and retries.
- Memory: inspect and maintain facts, memos, and user profile memory.
- Audit: troubleshoot which agent ran, what happened, and whether it failed.
For local use, open it directly. For a server, expose it through a reverse proxy with HTTPS and keep token auth enabled.
Terminal UI (TUI)
agim tui is a local terminal chat interface. It does not depend on IM
and is useful for server-side debugging, model setup checks, or a quick local
conversation.
agim tui
agim tui --agent codex
agim tui --agent native
agim tui --resume last
TUI is especially useful for troubleshooting: if TUI works but IM does not, check messenger credentials or callbacks. If TUI also fails, check agent installation, login, and model settings first.
Skills
A skill is a reusable capability pack for agents, usually a SKILL.md
plus scripts, references, or templates. It is for stable working methods you do not
want to repeat in every chat.
-
Place a skill at
~/.agim/skills/<name>/SKILL.md, and Agim can let agents read it when needed. - A skill can describe procedures, constraints, examples, and referenced scripts or assets.
- CLI agents and Agim Agent can use the same skill set.
Examples: daily reports, PR review rules, customer support tone, and internal system procedures.
Service lifecycle
The common path is to get Agim running with agim go, then choose
foreground, background, or systemd depending on where it runs.
| Mode | Best for | Common command |
|---|---|---|
| Foreground | Local debugging and live logs. | agim start |
| Background | A personal machine that stays on. | agim start --bg |
| systemd | Linux servers, team deployment, and startup on boot. | systemctl restart agim |
For routine checks, start with agim status and agim doctor
. To change setup, use agim config or Web Settings.
Architecture
From a user perspective, Agim works like this: entry points receive messages, routing selects an agent, the safety layer handles approval and audit, then delivery sends the result back where it came from.
IM / Web / TUI
│
▼
Agim Router ── Session / Memory / Goal
│
▼
Approval / Audit / Recovery
│
▼
Agents: CLI Agent / Agim Agent / Remote Agent
│
▼
Outbox → IM / Web / Notification That is why the recommended first step is Web plus one agent. Once the core path works, add more messengers, agents, and team rules.