@posthog/cli 0.7.22 → 0.7.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/README.md +38 -0
- package/lib/.gitignore +2 -0
- package/npm-shrinkwrap.json +2 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -55,3 +55,41 @@ Commands require different API scopes. Make sure to set these scopes on your per
|
|
|
55
55
|
| `exp endpoints push` | `endpoint:write`, `insight_variable:write` |
|
|
56
56
|
| `exp endpoints run` | `query:read` |
|
|
57
57
|
| `exp tasks` | `task:read` |
|
|
58
|
+
|
|
59
|
+
## Agent-first API tools
|
|
60
|
+
|
|
61
|
+
`posthog-cli api` exposes PostHog's MCP tool catalog through a shell-friendly interface for coding agents:
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
posthog-cli api --agent-help
|
|
65
|
+
posthog-cli api search feature-flag
|
|
66
|
+
posthog-cli api info feature-flag-get-all
|
|
67
|
+
posthog-cli api schema query-trends series
|
|
68
|
+
posthog-cli api call --json feature-flag-get-all '{"limit":5}'
|
|
69
|
+
posthog-cli api call --dry-run feature-flags-bulk-delete-create '{"ids":[123]}'
|
|
70
|
+
posthog-cli api skill list
|
|
71
|
+
posthog-cli api skill install audit
|
|
72
|
+
posthog-cli api agents-md install
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
Destructive tools require `--confirm` when executed. Use `--dry-run` before mutations.
|
|
76
|
+
|
|
77
|
+
`posthog-cli api --agent-help` prints the full agent-facing guide — the same exec tool reference the PostHog MCP server serves, rewritten for CLI invocation — so agents can load it into context before interacting with PostHog APIs.
|
|
78
|
+
|
|
79
|
+
### Agent steering instructions
|
|
80
|
+
|
|
81
|
+
Install the PostHog CLI steering instructions into the agent instructions file for your project:
|
|
82
|
+
|
|
83
|
+
```bash
|
|
84
|
+
posthog-cli api agents-md install
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
By default this updates `AGENTS.md` in the current directory. If your agent reads a different instructions file, pass it explicitly:
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
posthog-cli api agents-md install --path path/to/AGENTS.md
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
The installed instructions come from the shared snippet at [`services/mcp/src/cli/agents-md-snippet.md`](../services/mcp/src/cli/agents-md-snippet.md), so the installer and this README point at the same source of truth.
|
|
94
|
+
|
|
95
|
+
The snippet is written as a `<posthog>...</posthog>` block. Rerunning the install replaces the existing block in place, so upgrading the CLI and reinstalling refreshes stale instructions without duplicating them.
|
package/lib/.gitignore
ADDED
package/npm-shrinkwrap.json
CHANGED
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"hasInstallScript": true,
|
|
20
20
|
"license": "MIT",
|
|
21
21
|
"name": "@posthog/cli",
|
|
22
|
-
"version": "0.7.
|
|
22
|
+
"version": "0.7.23"
|
|
23
23
|
},
|
|
24
24
|
"node_modules/detect-libc": {
|
|
25
25
|
"engines": {
|
|
@@ -48,5 +48,5 @@
|
|
|
48
48
|
}
|
|
49
49
|
},
|
|
50
50
|
"requires": true,
|
|
51
|
-
"version": "0.7.
|
|
51
|
+
"version": "0.7.23"
|
|
52
52
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"artifactDownloadUrls": [
|
|
3
|
-
"https://github.com/PostHog/posthog/releases/download/posthog-cli/v0.7.
|
|
3
|
+
"https://github.com/PostHog/posthog/releases/download/posthog-cli/v0.7.23"
|
|
4
4
|
],
|
|
5
5
|
"bin": {
|
|
6
6
|
"posthog-cli": "run-posthog-cli.js"
|
|
@@ -114,7 +114,7 @@
|
|
|
114
114
|
"zipExt": ".tar.gz"
|
|
115
115
|
}
|
|
116
116
|
},
|
|
117
|
-
"version": "0.7.
|
|
117
|
+
"version": "0.7.23",
|
|
118
118
|
"volta": {
|
|
119
119
|
"node": "18.14.1",
|
|
120
120
|
"npm": "9.5.0"
|