Adds three new documentation pages for major shipped features that had no docs, and updates the platform controls index to reflect current state. ## New pages ### Extending Agents (`extending-agents.md`) Covers two workspace-level extension mechanisms: - **Skills** — `.agents/skills/<name>/SKILL.md` directory structure, frontmatter format, auto-discovery, `read_skill`/`read_skill_file` tools, size limits, lazy loading - **Workspace MCP tools** — `.mcp.json` format, stdio and HTTP transports, tool name prefixing, discovery lifecycle and caching ### MCP Servers (`platform-controls/mcp-servers.md`) Admin MCP server configuration: - CRUD via **Agents** > **Settings** > **MCP Servers** - Four auth modes: none, OAuth2 (with auto-discovery), API key, custom headers - Availability policies: `force_on`, `default_on`, `default_off` - Tool governance via allow/deny lists - Permission model and secret redaction ### Usage & Insights (`platform-controls/usage-insights.md`) Three admin dashboards: - **Usage limits** — spend caps with per-user and per-group overrides, priority hierarchy, enforcement behavior - **Cost tracking** — per-user rollup with token breakdowns, date filtering, per-model and per-chat drill-down ## Updated files - **`platform-controls/index.md`** — Moved MCP servers, usage limits, and analytics from "Where we are headed" into "What platform teams control today" with links to the new pages. Removed the tool customization roadmap section (now covered by MCP servers page). - **`manifest.json`** — Added nav entries for all three new pages. ## Resulting nav hierarchy ``` Coder Agents ├── Getting Started ├── Early Access ├── Architecture ├── Models ├── Platform Controls │ ├── Template Optimization │ ├── MCP Servers ← NEW │ └── Usage & Insights ← NEW ├── Extending Agents ← NEW └── Chats API ``` --- *PR generated with Coder Agents*
3.2 KiB
Usage and Analytics
Coder provides two admin-only views for monitoring and controlling agent spend: usage limits and cost tracking.
Usage limits
Navigate to Agents > Settings > Limits.
Usage limits cap how much each user can spend on LLM usage within a rolling time period. When enabled, the system checks the user's current spend before processing each chat message.
Configuration
- Enable/disable toggle — master on/off for the entire limit system.
- Period —
day,week, ormonth. Periods are UTC-aligned: midnight UTC for daily, Monday start for weekly, first of the month for monthly. - Default limit — deployment-wide default in dollars. Applies to all users who do not have a more specific override. Leave unset for no limit.
- Per-user overrides — set a custom dollar limit for an individual user. Takes highest priority.
- Per-group overrides — set a limit for a group. When a user belongs to multiple groups, the lowest group limit applies.
Priority hierarchy
The system resolves a user's effective limit in this order:
- Individual user override (highest priority)
- Minimum group limit across all of the user's groups
- Global default limit
- No limit (if limits are disabled or no value is configured)
Enforcement
- Checked before each chat message is processed.
- When current spend meets or exceeds the limit, the chat returns a 409 Conflict response and the message is blocked.
- Fail-open: if the limit query itself fails, the message is allowed through.
- Brief overage is possible when concurrent messages are in flight, because cost is determined only after the LLM returns.
User-facing status
Users can view their own spend status, including whether a limit is active, their effective limit, current spend, and when the current period resets.
Note
The admin configuration page shows the count of models without pricing data. Models missing pricing cannot be tracked accurately against limits.
Cost tracking
Navigate to Agents > Settings > Usage.
This view shows deployment-wide LLM chat costs with per-user drill-down.
Top-level view
A per-user rollup table with the following columns:
| Column | Description |
|---|---|
| Total cost | Aggregate dollar spend for the user |
| Messages | Number of chat messages sent |
| Chats | Number of distinct chat sessions |
| Input tokens | Total input tokens consumed |
| Output tokens | Total output tokens consumed |
| Cache read tokens | Tokens served from cache |
| Cache write tokens | Tokens written to cache |
The table supports date range filtering (default: last 30 days), search by name or username, and pagination.
Per-user detail view
Select a user to see:
- Summary cards — total cost, token breakdowns, and message counts.
- Usage limit progress — if a limit is active, a color-coded progress bar shows current spend relative to the limit.
- Per-model breakdown — table of costs and token usage by model.
- Per-chat breakdown — table of costs and token usage by chat session.