---
title: "PostHog"
description: "Inspect saved insight definitions and feature flag configuration in PostHog US or EU Cloud. Four read-only commands send one request each. Insight reads force cached access and never run fresh analytics queries. Lists re"
---

> Documentation Index
> Fetch the complete documentation index at: https://help.tooluse.net/llms.txt
> Use this file to discover all available pages before exploring further.

# PostHog

<p>Inspect saved insights and feature flag configuration. Review existing analytics context without running fresh queries or evaluating flags.</p>

<h2>Example workflows</h2>

<p>Copy a prompt into your connected AI client after connecting this integration. Choose resources you can access and review the supported command before running it.</p>

<h3>Review saved insights</h3>

<pre><code class="language-text" data-workflow-prompt>List 20 saved PostHog insights from project 42, starting at offset 0. Group them by the question they measure and identify which I should inspect for an activation review. Use saved insight definitions only; do not run fresh queries or create insights.</code></pre>
<p><a href="https://tooluse.net/tools/integrations/posthog?command=posthog.insights.list">Explore this command: posthog.insights.list</a></p>

<h3>Check feature flag configuration</h3>

<pre><code class="language-text" data-workflow-prompt>Read one page of 20 feature flags in PostHog project 42. Summarize their saved configuration and highlight flags that merit a closer review. Do not evaluate, enable, disable or modify a flag.</code></pre>
<p><a href="https://tooluse.net/tools/integrations/posthog?command=posthog.flags.list">Explore this command: posthog.flags.list</a></p>

<details data-command-index><summary>What you can do (4)</summary>
<h2>What you can do</h2>
<p>Available commands: 4 (4 read, 0 write). Enable only the commands your application needs.</p>
<div class="nb-table-scroll"><table>
<thead>
<tr>
<th>Command</th>
<th>Effect</th>
</tr>
</thead>
<tbody><tr>
<td><a href="https://help.tooluse.net/integrations/posthog#command-posthog-insights-list">List one page of saved insights</a> — <code>posthog.insights.list</code></td>
<td>Read</td>
</tr>
<tr>
<td><a href="https://help.tooluse.net/integrations/posthog#command-posthog-insights-get">Read one saved insights</a> — <code>posthog.insights.get</code></td>
<td>Read</td>
</tr>
<tr>
<td><a href="https://help.tooluse.net/integrations/posthog#command-posthog-flags-list">List one page of feature flags</a> — <code>posthog.flags.list</code></td>
<td>Read</td>
</tr>
<tr>
<td><a href="https://help.tooluse.net/integrations/posthog#command-posthog-flags-get">Read one feature flags</a> — <code>posthog.flags.get</code></td>
<td>Read</td>
</tr>
</tbody></table>
</div>
</details>
<h2>Connect and use</h2>

<p><a href="https://tooluse.net/tools/integrations/posthog?connect=own">Connect and use</a></p>
<p>This connection uses your provider account.</p>
<p>Connect this integration, enter your provider credentials, choose commands and save. Complete provider authorization if prompted.</p>
<h2>Get your provider credentials</h2>
<p>Follow these steps for PostHog, then enter the issued values in the connection form below.</p>
<ol>
<li><p>In PostHog, open Personal settings &gt; Personal API keys. Create a dedicated personal key limited to the required project with insight:read and feature_flag:read. Public phc_ project tokens cannot authorize these commands.</p>
</li>
<li><p>Choose your US or EU Cloud region in Tooluse.net, enter the personal key and select the reads you need. Self-hosted instances are not supported by this connector.</p>
</li>
<li><p>List commands require an explicit limit of 1–100 and an offset. Insights return saved definitions from the cache. Inspect feature flag configuration without evaluating or changing it. Disconnect here and revoke the personal key in PostHog when finished.</p>
</li>
</ol>
<p><a href="https://posthog.com/docs/api/personal-api-keys">Official credential setup</a></p>
<h2>Where to enter credentials</h2>
<p>In the integration page, sign in, choose your workspace and open Connect. If a <strong>Credentials</strong> choice is shown, select <strong>Use my credentials</strong>. Fill the following connection fields and save. Provider credentials belong in this form, never in an MCP configuration or tool input.</p>
<div class="nb-table-scroll"><table>
<thead>
<tr>
<th>Connection field</th>
<th>Requirement</th>
</tr>
</thead>
<tbody><tr>
<td>PostHog Cloud region</td>
<td>Required</td>
</tr>
<tr>
<td>PostHog personal API key</td>
<td>Required</td>
</tr>
</tbody></table>
</div><p>Open API keys and create a Tooluse.net key for the enabled commands.</p>
<p>Set TOOLUSE_API_KEY in your client and use the shared MCP configuration.</p>
<p><a href="https://help.tooluse.net/clients">Configure Claude Code, Codex or Cursor once</a></p>

<h2>Permissions and results</h2>

<p>If you have more than one workspace, check the selected workspace in the connection or API-key dialog before saving. Roles, enabled commands, expiry and revocation use Tooluse.net&#39;s existing permissions. Disabling a connection or revoking a key immediately prevents new calls.</p>

<p>Send one Claude tool_use block per request. Keep the same Idempotency-Key when retrying the same request; use a new key for a new call. The response includes the shared Tooluse.net receipt and Claude tool_result. Check both HTTP status and the returned tool result before treating a call as successful.</p>

<p>Your connection&#39;s daily allowance and key permissions also apply. Adding a connection does not make a provider request.</p>

<p>Calls return the shared execution receipt and a Claude tool_result. Provider output varies by operation; consult the provider documentation for its response fields. Unconfirmed calls should be checked before retrying.</p>

<h2>Call from your client</h2>

<p>Use the shared MCP configuration. Refresh your client&#39;s tool list after saving the connection or changing key permissions, then call the returned tool name with the example input below.</p>

<p><a href="https://help.tooluse.net/clients">Configure Claude Code, Codex or Cursor once</a></p>

<h2>Discover your enabled tools</h2>

<p>List permitted tools in Claude format. Read every page using page and size (maximum 100) until all results have been received. Use the returned name, not a catalog capability identifier, in the tool_use block.</p>

<pre><code class="language-bash">curl 'https://api.tooluse.net/v1/tools' \
  -H "Authorization: Bearer $TOOLUSE_API_KEY"
</code></pre>

<p>Find this command in the tool list permitted by your key. Replace svc_FROM_YOUR_TOOL_LIST with its returned name. Use a new Idempotency-Key for each new call and retain it when retrying that same call.</p>

<h2>HTTP call</h2>

<pre><code class="language-bash">curl 'https://api.tooluse.net/v1/tool-calls' \
  -H "Authorization: Bearer $TOOLUSE_API_KEY" \
  -H 'Content-Type: application/json' \
  -H 'Idempotency-Key: replace-with-a-new-call-id' \
  --data '{
  "type": "tool_use",
  "id": "toolu_example",
  "name": "svc_FROM_YOUR_TOOL_LIST",
  "input": {
    "path": {
      "project_id": 42
    },
    "query": {
      "limit": 20,
      "offset": 0
    }
  }
}'
</code></pre>

<p>Send one Claude tool_use block per request. Keep the same Idempotency-Key when retrying the same request; use a new key for a new call. The response includes the shared Tooluse.net receipt and Claude tool_result. Check both HTTP status and the returned tool result before treating a call as successful.</p>

<h2>Commands</h2>

<details id="command-posthog-insights-list">
<summary><span>List one page of saved insights — <code>posthog.<wbr>insights.<wbr>list</code></span></summary>
<p>Reads saved metadata only. Insight refresh is pinned to force_cache; no analytics query is launched.</p>
<p>This is a read operation. Provider rate limits and data access rules still apply.</p>

<p><a href="https://tooluse.net/tools/integrations/posthog?connect=own&amp;command=posthog.insights.list">Connect and use</a></p>

<p><strong>Parameters</strong></p>

<p>Requiredness is local to the containing object. A required child is required only when its parent object or array item is provided. Alternative schemas are identified in the Constraints column; the linked full JSON Schema is authoritative.</p>

<div class="nb-table-scroll"><table>
<thead>
<tr>
<th>Parameter</th>
<th>Type</th>
<th>Required in parent</th>
<th>Description</th>
<th>Constraints</th>
</tr>
</thead>
<tbody><tr>
<td><code>path</code></td>
<td>object</td>
<td>Required</td>
<td></td>
<td><code>additionalProperties: false</code></td>
</tr>
<tr>
<td><code>path.project_id</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 1; maximum: 9007199254740991</code></td>
</tr>
<tr>
<td><code>query</code></td>
<td>object</td>
<td>Required</td>
<td></td>
<td><code>additionalProperties: false</code></td>
</tr>
<tr>
<td><code>query.limit</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 1; maximum: 100</code></td>
</tr>
<tr>
<td><code>query.offset</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 0; maximum: 100000</code></td>
</tr>
</tbody></table>
</div>
<p><strong>Full JSON Schema</strong></p>

<p><a href="https://api.tooluse.net/v1/integrations/posthog/commands/posthog.insights.list">Full JSON Schema</a></p>

<p><strong>Example input</strong></p>

<pre><code class="language-json">{
  "path": {
    "project_id": 42
  },
  "query": {
    "limit": 20,
    "offset": 0
  }
}
</code></pre>

<p>At most 1 provider requests per invocation; timeout: 20 seconds.</p>

</details>
<details id="command-posthog-insights-get">
<summary><span>Read one saved insights — <code>posthog.<wbr>insights.<wbr>get</code></span></summary>
<p>Reads saved metadata only. Insight refresh is pinned to force_cache; no analytics query is launched.</p>
<p>This is a read operation. Provider rate limits and data access rules still apply.</p>

<p><a href="https://tooluse.net/tools/integrations/posthog?connect=own&amp;command=posthog.insights.get">Connect and use</a></p>

<p><strong>Parameters</strong></p>

<p>Requiredness is local to the containing object. A required child is required only when its parent object or array item is provided. Alternative schemas are identified in the Constraints column; the linked full JSON Schema is authoritative.</p>

<div class="nb-table-scroll"><table>
<thead>
<tr>
<th>Parameter</th>
<th>Type</th>
<th>Required in parent</th>
<th>Description</th>
<th>Constraints</th>
</tr>
</thead>
<tbody><tr>
<td><code>path</code></td>
<td>object</td>
<td>Required</td>
<td></td>
<td><code>additionalProperties: false</code></td>
</tr>
<tr>
<td><code>path.project_id</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 1; maximum: 9007199254740991</code></td>
</tr>
<tr>
<td><code>path.id</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 1; maximum: 9007199254740991</code></td>
</tr>
</tbody></table>
</div>
<p><strong>Full JSON Schema</strong></p>

<p><a href="https://api.tooluse.net/v1/integrations/posthog/commands/posthog.insights.get">Full JSON Schema</a></p>

<p><strong>Example input</strong></p>

<pre><code class="language-json">{
  "path": {
    "project_id": 42,
    "id": 7
  }
}
</code></pre>

<p>At most 1 provider requests per invocation; timeout: 20 seconds.</p>

</details>
<details id="command-posthog-flags-list">
<summary><span>List one page of feature flags — <code>posthog.<wbr>flags.<wbr>list</code></span></summary>
<p>Reads saved metadata only. Insight refresh is pinned to force_cache; no analytics query is launched.</p>
<p>This is a read operation. Provider rate limits and data access rules still apply.</p>

<p><a href="https://tooluse.net/tools/integrations/posthog?connect=own&amp;command=posthog.flags.list">Connect and use</a></p>

<p><strong>Parameters</strong></p>

<p>Requiredness is local to the containing object. A required child is required only when its parent object or array item is provided. Alternative schemas are identified in the Constraints column; the linked full JSON Schema is authoritative.</p>

<div class="nb-table-scroll"><table>
<thead>
<tr>
<th>Parameter</th>
<th>Type</th>
<th>Required in parent</th>
<th>Description</th>
<th>Constraints</th>
</tr>
</thead>
<tbody><tr>
<td><code>path</code></td>
<td>object</td>
<td>Required</td>
<td></td>
<td><code>additionalProperties: false</code></td>
</tr>
<tr>
<td><code>path.project_id</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 1; maximum: 9007199254740991</code></td>
</tr>
<tr>
<td><code>query</code></td>
<td>object</td>
<td>Required</td>
<td></td>
<td><code>additionalProperties: false</code></td>
</tr>
<tr>
<td><code>query.limit</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 1; maximum: 100</code></td>
</tr>
<tr>
<td><code>query.offset</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 0; maximum: 100000</code></td>
</tr>
</tbody></table>
</div>
<p><strong>Full JSON Schema</strong></p>

<p><a href="https://api.tooluse.net/v1/integrations/posthog/commands/posthog.flags.list">Full JSON Schema</a></p>

<p><strong>Example input</strong></p>

<pre><code class="language-json">{
  "path": {
    "project_id": 42
  },
  "query": {
    "limit": 20,
    "offset": 0
  }
}
</code></pre>

<p>At most 1 provider requests per invocation; timeout: 20 seconds.</p>

</details>
<details id="command-posthog-flags-get">
<summary><span>Read one feature flags — <code>posthog.<wbr>flags.<wbr>get</code></span></summary>
<p>Reads saved metadata only. Insight refresh is pinned to force_cache; no analytics query is launched.</p>
<p>This is a read operation. Provider rate limits and data access rules still apply.</p>

<p><a href="https://tooluse.net/tools/integrations/posthog?connect=own&amp;command=posthog.flags.get">Connect and use</a></p>

<p><strong>Parameters</strong></p>

<p>Requiredness is local to the containing object. A required child is required only when its parent object or array item is provided. Alternative schemas are identified in the Constraints column; the linked full JSON Schema is authoritative.</p>

<div class="nb-table-scroll"><table>
<thead>
<tr>
<th>Parameter</th>
<th>Type</th>
<th>Required in parent</th>
<th>Description</th>
<th>Constraints</th>
</tr>
</thead>
<tbody><tr>
<td><code>path</code></td>
<td>object</td>
<td>Required</td>
<td></td>
<td><code>additionalProperties: false</code></td>
</tr>
<tr>
<td><code>path.project_id</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 1; maximum: 9007199254740991</code></td>
</tr>
<tr>
<td><code>path.id</code></td>
<td>integer</td>
<td>Required</td>
<td></td>
<td><code>minimum: 1; maximum: 9007199254740991</code></td>
</tr>
</tbody></table>
</div>
<p><strong>Full JSON Schema</strong></p>

<p><a href="https://api.tooluse.net/v1/integrations/posthog/commands/posthog.flags.get">Full JSON Schema</a></p>

<p><strong>Example input</strong></p>

<pre><code class="language-json">{
  "path": {
    "project_id": 42,
    "id": 7
  }
}
</code></pre>

<p>At most 1 provider requests per invocation; timeout: 20 seconds.</p>

</details>
<h2>Errors</h2>

<p>Check the key&#39;s expiry, revocation, workspace and allowed operations.</p>

<p>Reuse the same idempotency key only for the same request.</p>

<p>The connection or provider limit has been reached. Check the receipt before retrying.</p>

<h2>Test the connection</h2>

<p>Open the integration&#39;s commands below to inspect parameters and examples. Start with a read command for an account or resource you can access. Refresh your client&#39;s tool list, use the returned tool name, and check the execution result and usage. Provider charges and permissions still apply. Never test a write against production data without reviewing it.</p>

<p><a href="https://posthog.com/docs/api">Official provider documentation</a></p>

Source: https://help.tooluse.net/integrations/posthog/index.mdx
