Skip to content

Commit c376567

Browse files
docs: add v3.38.0 release notes (#475)
Co-authored-by: Roo Code <roomote@roocode.com>
1 parent 246c7a3 commit c376567

File tree

7 files changed

+157
-8
lines changed

7 files changed

+157
-8
lines changed

docs/features/experimental/custom-tools.md

Lines changed: 87 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
description: Define TypeScript/JavaScript tools that extend Roo's capabilities beyond built-in tools, enabling project-specific workflows and team standardization.
2+
description: Define TypeScript/JavaScript tools that extend Roo's capabilities beyond built-in tools, with npm dependency support and per-tool environment variables.
33
keywords:
44
- experimental features
55
- custom tools
@@ -8,6 +8,8 @@ keywords:
88
- tool extension
99
- defineCustomTool
1010
- workflow automation
11+
- npm dependencies
12+
- environment variables
1113
image: /img/social-share.jpg
1214
---
1315
# Custom Tools
@@ -82,12 +84,95 @@ Tools from both directories are loaded. Tools with the same name in `.roo/tools/
8284

8385
---
8486

87+
## Using npm Dependencies
88+
89+
Custom tools can use npm packages. Install dependencies in the same folder as your tool, and imports will resolve normally.
90+
91+
```bash
92+
# From your tool directory
93+
cd .roo/tools/
94+
npm init -y
95+
npm install axios lodash
96+
```
97+
98+
Then import in your tool:
99+
100+
```typescript
101+
import { parametersSchema as z, defineCustomTool } from "@roo-code/types"
102+
import axios from "axios"
103+
104+
export default defineCustomTool({
105+
name: "fetch_api",
106+
description: "Fetch data from an API endpoint",
107+
parameters: z.object({
108+
url: z.string().describe("API endpoint URL"),
109+
}),
110+
async execute({ url }) {
111+
const response = await axios.get(url)
112+
return JSON.stringify(response.data, null, 2)
113+
}
114+
})
115+
```
116+
117+
---
118+
119+
## Per-Tool Environment Variables
120+
121+
Tools automatically load a `.env` file from the same folder. This lets you store API keys and secrets without hardcoding them.
122+
123+
**Setup:**
124+
125+
1. Create a `.env` file next to your tool:
126+
```
127+
.roo/tools/
128+
├── my-tool.ts
129+
├── .env # Loaded automatically
130+
└── package.json
131+
```
132+
133+
2. Add your secrets:
134+
```bash
135+
# .roo/tools/.env
136+
SLACK_WEBHOOK_URL=https://hooks.slack.com/services/XXX
137+
API_SECRET=your-secret-key
138+
```
139+
140+
3. Access them via `process.env`:
141+
```typescript
142+
import { parametersSchema as z, defineCustomTool } from "@roo-code/types"
143+
144+
export default defineCustomTool({
145+
name: "notify_slack",
146+
description: "Send a notification to Slack",
147+
parameters: z.object({
148+
message: z.string().describe("Message to send"),
149+
}),
150+
async execute({ message }) {
151+
const webhookUrl = process.env.SLACK_WEBHOOK_URL
152+
if (!webhookUrl) {
153+
return "Error: SLACK_WEBHOOK_URL not set in .env"
154+
}
155+
156+
const response = await fetch(webhookUrl, {
157+
method: "POST",
158+
headers: { "Content-Type": "application/json" },
159+
body: JSON.stringify({ text: message }),
160+
})
161+
162+
return response.ok ? "Message sent" : `Failed: ${response.status}`
163+
}
164+
})
165+
```
166+
167+
**Security:** Ensure your `.env` file is ignored by version control to keep secrets safe.
168+
169+
---
170+
85171
## Limits
86172

87173
- **No approval prompts**: Tools are auto-approved when the feature is enabled—security trade-off for convenience
88174
- **String-only results**: Tools must return strings (Roo's protocol constraint)
89175
- **No interactive input**: Tools can't prompt the user mid-execution
90-
- **No npm packages**: Tools are transpiled in isolation; use Node.js built-ins only
91176
- **Cache invalidation**: Tool updates may require reloading the window
92177

93178
**vs. MCP:** [MCP](/features/mcp/overview) is for external services (search, APIs). Custom tools are for in-repo logic you control directly. MCP is more extensible; custom tools are lighter weight for project-specific actions.

docs/features/slash-commands.mdx

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@ Please perform a thorough security review of the selected code:
123123
**Frontmatter Fields:**
124124
- **`description`**: Appears in the command menu to help users understand the command's purpose
125125
- **`argument-hint`**: (Optional) Provides a hint about expected arguments when using the command. See [Argument Hints](#argument-hints) for detailed information
126+
- **`mode`**: (Optional) Mode slug to switch to before running the command (e.g., `code`, `architect`). Roo switches to this mode first, then executes the command content in that mode's context
126127

127128
---
128129

@@ -192,6 +193,25 @@ This will display as `/api-endpoint <endpoint-name> <http-method>` in the comman
192193

193194
## Examples and Use Cases
194195

196+
**Mode-Targeting Commands**
197+
198+
Use the `mode` field to ensure a command runs in a specific mode context:
199+
200+
```yaml
201+
---
202+
description: Analyze architecture and propose improvements
203+
mode: architect
204+
---
205+
206+
Review the current system architecture and suggest improvements for:
207+
- Scalability bottlenecks
208+
- Component coupling
209+
- Security boundaries
210+
- Data flow optimization
211+
```
212+
213+
When you run this command, Roo switches to Architect mode first, then processes the command content with Architect's role definition and tool restrictions.
214+
195215
**Development Workflows**
196216

197217
**API Endpoint Generator**

docs/providers/openrouter.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,6 @@ For the complete, up-to-date model list with pricing and capabilities, see [Open
4747

4848
---
4949

50-
## Supported Transforms
51-
52-
OpenRouter provides an [optional "middle-out" message transform](https://openrouter.ai/docs/features/message-transforms) to help with prompts that exceed the maximum context size of a model. You can enable it by checking the "Compress prompts and message chains to the context size" box.
53-
54-
---
55-
5650
## Tips and Notes
5751

5852
* **Model Selection:** OpenRouter offers a wide range of models. Experiment to find the best one for your needs.

docs/update-notes/index.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@ If you want to live on the edge and try things out before it's released, we have
2222

2323
---
2424

25+
### Version 3.38
26+
27+
* [3.38.0](/update-notes/v3.38.0) (2025-12-27)
28+
29+
---
30+
2531
### Version 3.37
2632

2733
* [3.37](/update-notes/v3.37) (2025-12-22)

docs/update-notes/v3.38.0.mdx

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
---
2+
description: Adds Agent Skills, improves slash command behavior, and streamlines providers and file reading.
3+
keywords:
4+
- roo code 3.38.0
5+
- new features
6+
- bug fixes
7+
image: /img/v3.38.0/v3.38.0.png
8+
---
9+
10+
# Roo Code 3.38.0 Release Notes (2025-12-27)
11+
12+
This release adds Agent Skills, improves slash command behavior, and streamlines providers and file reading.
13+
14+
<img src="/img/v3.38.0/v3.38.0.png" alt="Roo Code v3.38.0 Release" width="600" />
15+
16+
## Agent Skills
17+
18+
Roo now supports Agent Skills, which are portable skill folders containing instructions, scripts, and resources that the agent can discover and load on demand. This lets you package repeatable workflows and domain knowledge once and reuse them across projects to make results more consistent and reliable. ([#10335](https://github.com/RooCodeInc/Roo-Code/pull/10335)):
19+
20+
> **📚 Documentation**: See [Skills](/features/skills) for setup and usage.
21+
22+
## QOL Improvements
23+
24+
* Slash commands can declare a target mode in their front matter, so triggering a command can switch Roo to the right mode first ([#10344](https://github.com/RooCodeInc/Roo-Code/pull/10344)).
25+
* Removes the legacy “simple read file” tool path so file reading consistently uses the standard `read_file` tool ([#10254](https://github.com/RooCodeInc/Roo-Code/pull/10254)).
26+
27+
## Bug Fixes
28+
29+
* Fixes an issue where some Claude Sonnet 4.5 requests could fail with HTTP 400 errors after context condensing ([#10359](https://github.com/RooCodeInc/Roo-Code/pull/10359)).
30+
31+
## Misc Improvements
32+
33+
* Custom tools can import npm packages, and can load secrets from a same-folder `.env` file ([#10336](https://github.com/RooCodeInc/Roo-Code/pull/10336)).
34+
35+
## Provider Updates
36+
37+
* Removes the “OpenRouter Transforms” setting and stops sending the `transforms` parameter on OpenRouter requests ([#10341](https://github.com/RooCodeInc/Roo-Code/pull/10341)).

sidebars.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,13 @@ const sidebars: SidebarsConfig = {
172172
label: 'Extension Release Notes',
173173
items: [
174174
'update-notes/index',
175+
{
176+
type: 'category',
177+
label: '3.38',
178+
items: [
179+
{ type: 'doc', id: 'update-notes/v3.38.0', label: '3.38.0' },
180+
],
181+
},
175182
{
176183
type: 'category',
177184
label: '3.37',

static/img/v3.38.0/v3.38.0.png

1.91 MB
Loading

0 commit comments

Comments
 (0)