Skip to content

Commit 8085aa5

Browse files
alban bertoliniclaude
andcommitted
feat: add Claude skills for Forest Admin MCP
Add a dedicated folder for Claude Code skills that enhance AI interactions with Forest Admin: - forest-mcp: Guides Claude to effectively query Forest Admin data through MCP tools (list, listRelated, describeCollection) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent e746e99 commit 8085aa5

2 files changed

Lines changed: 149 additions & 0 deletions

File tree

claude-skills/README.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Claude Skills for Forest Admin
2+
3+
This directory contains Claude Code skills that enhance AI interactions with Forest Admin.
4+
5+
## Available Skills
6+
7+
### forest-mcp
8+
9+
A skill that guides Claude to effectively query Forest Admin data through MCP tools.
10+
11+
**Installation:**
12+
13+
Copy the `forest-mcp` folder to your Claude skills directory:
14+
```bash
15+
cp -r forest-mcp ~/.claude/skills/
16+
```
17+
18+
Or create a symlink:
19+
```bash
20+
ln -s $(pwd)/forest-mcp ~/.claude/skills/forest-mcp
21+
```
22+
23+
**Usage:**
24+
25+
Once installed, Claude will automatically use this skill when you ask questions like:
26+
- "Find all users with status active"
27+
- "Show orders from last week"
28+
- "How many products are in stock?"
29+
30+
## Creating New Skills
31+
32+
Skills are defined by a `SKILL.md` file with YAML frontmatter:
33+
34+
```markdown
35+
---
36+
name: skill-name
37+
description: When to trigger this skill...
38+
---
39+
40+
# Skill Title
41+
42+
Instructions for Claude...
43+
```
44+
45+
See the [Claude Code documentation](https://docs.anthropic.com/en/docs/claude-code) for more details on skill creation.

claude-skills/forest-mcp/SKILL.md

Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
---
2+
name: forest-mcp
3+
description: Query Forest Admin data through MCP tools. Use when the user wants to search, filter, or explore data from their Forest Admin database. Triggers on questions like "find all users", "show orders from last week", "how many products", or any data exploration request.
4+
---
5+
6+
# Forest Admin MCP
7+
8+
Query Forest Admin data as if it were a database, with an abstraction layer that handles authentication, filtering, and relationships.
9+
10+
## Available Tools
11+
12+
| Tool | Purpose |
13+
|------|---------|
14+
| `describeCollection` | Get collection schema (fields, types, operators, relations) |
15+
| `list` | Query records from a collection |
16+
| `listRelated` | Query records from a one-to-many or many-to-many relation |
17+
18+
## Workflow
19+
20+
1. **Always start with `describeCollection`** to understand the collection structure before querying
21+
2. Use `list` for direct collection queries
22+
3. Use `listRelated` to traverse relationships (e.g., "orders of user 123")
23+
24+
## Filter Syntax
25+
26+
```json
27+
// Simple condition
28+
{ "field": "status", "operator": "Equal", "value": "active" }
29+
30+
// Combined conditions
31+
{
32+
"aggregator": "And",
33+
"conditions": [
34+
{ "field": "status", "operator": "Equal", "value": "active" },
35+
{ "field": "age", "operator": "GreaterThan", "value": 18 }
36+
]
37+
}
38+
```
39+
40+
### Common Operators
41+
42+
| Category | Operators |
43+
|----------|-----------|
44+
| Comparison | `Equal`, `NotEqual`, `LessThan`, `GreaterThan`, `LessThanOrEqual`, `GreaterThanOrEqual` |
45+
| String | `Contains`, `StartsWith`, `EndsWith`, `IContains` (case-insensitive) |
46+
| Array | `In`, `NotIn`, `IncludesAll` |
47+
| Null | `Present`, `Blank`, `Missing` |
48+
| Date | `Today`, `Yesterday`, `Before`, `After`, `PreviousWeek`, `PreviousMonth` |
49+
50+
### Nested Fields
51+
52+
Use `@@@` separator for relation fields:
53+
```json
54+
{ "field": "customer@@@email", "operator": "Contains", "value": "@gmail.com" }
55+
```
56+
57+
## Examples
58+
59+
**"Find active users created this month"**
60+
```
61+
1. describeCollection({ collectionName: "users" })
62+
2. list({
63+
collectionName: "users",
64+
filters: {
65+
aggregator: "And",
66+
conditions: [
67+
{ field: "status", operator: "Equal", value: "active" },
68+
{ field: "createdAt", operator: "PreviousMonth" }
69+
]
70+
}
71+
})
72+
```
73+
74+
**"Show orders for user 42"**
75+
```
76+
1. describeCollection({ collectionName: "users" }) // to find relation name
77+
2. listRelated({
78+
collectionName: "users",
79+
relationName: "orders",
80+
parentRecordId: 42
81+
})
82+
```
83+
84+
**"Count pending orders over $100"**
85+
```
86+
list({
87+
collectionName: "orders",
88+
filters: {
89+
aggregator: "And",
90+
conditions: [
91+
{ field: "status", operator: "Equal", value: "pending" },
92+
{ field: "total", operator: "GreaterThan", value: 100 }
93+
]
94+
},
95+
enableCount: true
96+
})
97+
```
98+
99+
## Tips
100+
101+
- Use `enableCount: true` when user asks "how many" or needs totals
102+
- Use `fields: ["id", "name"]` to reduce payload when only specific fields needed
103+
- Use `search` parameter for full-text search across searchable fields
104+
- Check `isSortable` from describeCollection before using sort

0 commit comments

Comments
 (0)