posthog-cli api: `call`, `info` and `search` read `--help` as a tool name

Open Beginner friendly
#129,166 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

@lazerg is already working on this.

Since Nov 8, 2026.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
67/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
node.js, typescript
Domain
cli

Research direction

The issue names no source files or tests. Start by locating the posthog-cli API subcommand handlers for call, info, and search, then check how their arguments are parsed. Done means --help and -h show usage for call and info, and search --help shows usage instead of searching for those words.

Written by the indexing model from the issue text.

Description

Version: @posthog/cli 0.19.0, the newest on npm on 4 November 2026.

What happens: api --help prints help, but its subcommands take --help or -h as their first argument.

  • posthog-cli api call --help prints Error: Unknown tool: "--help". Run "search --help" to find the current tool name before claiming the capability is unavailable.
  • posthog-cli api info --help prints the same error.
  • posthog-cli api call -h prints it for "-h".
  • posthog-cli api search --help searches for the words --help and returns {"matches":[]}.

The error's own advice, search --help, hits the same defect, so an agent following it never reaches the subcommand's usage.

Expected: --help and -h print each subcommand's usage, as api --help does.

Dominant language
Python
Stars
40.8k
Forks
3.6k
Avg merge
6h 43m
Merged PRs (30d)
254

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from PostHog/posthog

All issues in PostHog/posthog

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.