> **Building with AI coding agents?** Install the authstack plugin with one command. This equips your agent with accurate Scalekit implementation patterns.
>
> **Recommended** (the `-y` flags skip prompts, so the command runs without an interactive terminal):
> ```bash
> npx -y @scalekit-inc/cli setup -y
> ```
>
> Global:
> ```bash
> npm install -g @scalekit-inc/cli
> scalekit setup -y
> ```
>
> Supports Claude Code, Cursor, GitHub Copilot, Codex + skills for other Agent Skills-compatible agents in `~/.agents/skills`.
> Skills: integrate-agentkit, implement-saaskit, add-mcp-oauth, implement-sso, implement-scim.
> [Full setup guide](https://docs.scalekit.com/dev-kit/build-with-ai/)

---

# Connect AI agents to the LogRocket MCP server

The LogRocket MCP connector routes your AI agent's tool calls to LogRocket's own MCP server through Scalekit. Each user signs in to LogRocket once, and Scalekit stores and refreshes their tokens, so your agent never handles credentials. It comes with 9 tools.

**Authentication:** OAuth2.1/DCR
**Categories:** Analytics, Monitoring, Developer Tools
**Tools:** 9: 9 read, 0 write, 0 destructive
**Users sign in with:** OAuth
**OAuth app:** Scalekit's or your own
**Built by:** Vendor MCP
**Try it:** [Playground in the Scalekit dashboard](https://app.scalekit.com/ws/signup?sk_intent=playground&provider=LOGROCKETMCP)

## Setup

1. ### Install the SDK

   **Node.js**

   ```bash
   npm install @scalekit-sdk/node dotenv
   ```

   **Python**

   ```bash
   pip install scalekit-sdk-python python-dotenv
   ```

2. ### Set your credentials

   Add your Scalekit credentials to your `.env` file. Find values in **[app.scalekit.com](https://app.scalekit.com)** > **Developers** > **API Credentials**.

   ```sh title=".env"
   SCALEKIT_ENVIRONMENT_URL=<your-environment-url>
   SCALEKIT_CLIENT_ID=<your-client-id>
   SCALEKIT_CLIENT_SECRET=<your-client-secret>
   ```

3. ### Create the LogRocket MCP connection

   In **AgentKit > Connections**, create a LogRocket MCP connection. The name you give it is the `connection_name` your code passes. See [Configure connections](/agentkit/connections/).

   Scalekit credentials are available for LogRocket MCP server, so you don't need to register an OAuth app.

4. ### Authorize a user and make your first call

   **Node.js** (`quickstart.mts`)

   ```typescript
   import { ScalekitClient } from '@scalekit-sdk/node'
   import 'dotenv/config'
   import { createInterface } from 'node:readline/promises'

   const scalekit = new ScalekitClient(
     process.env.SCALEKIT_ENVIRONMENT_URL,
     process.env.SCALEKIT_CLIENT_ID,
     process.env.SCALEKIT_CLIENT_SECRET,
   )
   const actions = scalekit.actions

   const connector = 'logrocketmcp'
   const identifier = 'user_123'

   // Generate an authorization link for the user
   const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
   console.log('Authorize LogRocket MCP:', link)
   const rl = createInterface({ input: process.stdin, output: process.stdout })
   await rl.question('Press Enter after authorizing...')
   rl.close()

   // Make your first call
   const result = await actions.executeTool({
     connector,
     identifier,
     toolName: 'logrocketmcp_list_organizations',
     toolInput: {},
   })
   console.log(result)
   ```

   ```bash
   npx tsx quickstart.mts
   ```

   **Python** (`quickstart.py`)

   ```python
   import os
   from scalekit import ScalekitClient
   from dotenv import load_dotenv
   load_dotenv()

   scalekit_client = ScalekitClient(
       env_url=os.getenv("SCALEKIT_ENVIRONMENT_URL"),
       client_id=os.getenv("SCALEKIT_CLIENT_ID"),
       client_secret=os.getenv("SCALEKIT_CLIENT_SECRET"),
   )
   actions = scalekit_client.actions

   connection_name = "logrocketmcp"
   identifier = "user_123"

   # Generate an authorization link for the user
   link_response = actions.get_authorization_link(
       connection_name=connection_name,
       identifier=identifier,
   )
   print("Authorize LogRocket MCP:", link_response.link)
   input("Press Enter after authorizing...")

   # Make your first call
   result = actions.execute_tool(
       tool_input={},
       tool_name="logrocketmcp_list_organizations",
       connection_name=connection_name,
       identifier=identifier,
   )
   print(result)
   ```

   ```bash
   python quickstart.py
   ```

   Each user signs in once. See [Authorize a user](/agentkit/tools/authorize/) for the full flow and statuses.

## Tools

Pass the exact name to `execute_tool`, with an input like each tool's example. To ask for a tool that's missing, use the [request form](https://scalekitsupport.portal.usepylon.com/forms/request-a-connector-tool).

**Node.js**

```typescript
const result = await actions.executeTool({
  toolName: 'logrocketmcp_build_metric',
  toolInput: {
    organizationID: '<organizationID>',
    projectID: '<projectID>',
    query: 'checkout errors affecting Chrome users',
  },
  connector: 'logrocketmcp',
  identifier: 'user_123',
})
```

**Python**

```python
result = actions.execute_tool(
    tool_name="logrocketmcp_build_metric",
    tool_input={
        "organizationID": "<organizationID>",
        "projectID": "<projectID>",
        "query": "checkout errors affecting Chrome users",
    },
    connection_name="logrocketmcp",
    identifier="user_123",
)
```

`result.data` is the app's response as JSON, and `result.execution_id` (`executionId` in Node.js) is the ID of the call.

### `logrocketmcp_build_metric`

Build Metric · Read-only

Use this to query LogRocket analytics data. This tool translates your natural language query into a LogRocket metric (e.g., timeseries, table, conversion funnel) that is then used to find relevant data. It's best used for performing aggregate analysis (e.g., session totals over time, browser or country breakdowns, conversion rates between steps). Returns an object with a `metricDefinition` field indicating the LogRocket metric that was used to find the data and a `metricQueryResult` field containing the corresponding analytics data.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `organizationID` (`string`, required): The organization ID to run the query against. If not provided by the user, discover options using the list_organizations tool.
- `projectID` (`string`, required): The project ID to run the query against. If not provided by the user, discover options using the list_projects tool.
- `query` (`string`, required): Natural language query describing the analytics data you want to retrieve.
- `limit` (`integer`, optional): Maximum number of rows/buckets returned in metricQueryResult for top-N or table-style metrics (e.g., top countries, top pages, top users). Defaults to 20. This does not control sessionDefinitions and may be ignored for metric types that do not return ranked row buckets.
- `timezone` (`string`, optional): Optional IANA timezone (e.g., 'America/New_York'). Time buckets align to this timezone's calendar (e.g., daily buckets break at its midnight). When omitted, they align to UTC.

Example input: `{"organizationID":"<organizationID>","projectID":"<projectID>","query":"checkout errors affecting Chrome users"}`

### `logrocketmcp_find_issues`

Find Issues · Read-only

Use this to list a LogRocket project's issues. This includes error signals detected in session recordings, specifically JavaScript exceptions, network errors, rage clicks, dead clicks, frustrating network requests, error states, and mobile crash reports. Issues can be filtered by severity, triage status, issue type, and time range, and optionally refined with a natural language query. Returns an object with an `issues` field listing matching issues, each with its issue type, platform, event count, first/last seen dates, `triageStatus`, a `url` linking to the issue's detail page in the LogRocket dashboard, and an AI-generated `issueDescription` when one exists.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `organizationID` (`string`, required): The organization ID to run the query against. If not provided by the user, discover options using the list_organizations tool.
- `projectID` (`string`, required): The project ID to run the query against. If not provided by the user, discover options using the list_projects tool.
- `endDate` (`string`, optional): Optional ISO 8601 datetime for the end of the time range to search. Defaults to now.
- `issueTypes` (`array`, optional): Optional list of issue types to include. "exception" covers JavaScript exceptions and mobile errors, "networkError" failed network requests, "mobileCrash" mobile app crash reports, "rageClick" repeated frustrated clicks, "deadClick" clicks with no visible effect, "frustratingNetworkRequest" impatient user actions during slow requests, and "errorState" error pages and modals users encounter. Defaults to all issue types.
- `limit` (`integer`, optional): Maximum number of issues to fetch, applied before any natural language relevance filtering. Defaults to 30.
- `query` (`string`, optional): Optional natural language query used to refine results (e.g., "checkout errors affecting Chrome users"). When provided, additional filters are parsed from the query and results are filtered to those relevant to it. Omit to list issues using only the structured parameters.
- `severity` (`string`, optional): Optional severity filter. "severe" returns only issues where LogRocket detected significant user impact and generated an issue description; "notSevere" returns only issues without one; "any" returns both. Defaults to "severe". One of: `severe`, `notSevere`, `any`.
- `startDate` (`string`, optional): Optional ISO 8601 datetime for the start of the time range to search. Defaults to a lookback of one week. Issues data is only retained for 30 days: start dates older than that are clamped to 30 days ago, and time ranges ending more than 30 days ago return no issues.
- `triageStatuses` (`array`, optional): Optional list of triage statuses to include. Issues start as "untriaged" and can be triaged by users to "highImpact", "lowImpact", or "ignored". Defaults to ["untriaged"], matching the default dashboard issues view.

Example input: `{"organizationID":"<organizationID>","projectID":"<projectID>"}`

### `logrocketmcp_find_sessions`

Find Sessions · Read-only

Use this to find LogRocket sessions matching a natural language query. This tool translates your natural language query into LogRocket filters that are then used to find relevant sessions. It's best used for filtering sessions based on user ID or email, custom user traits, visited page or URL, custom events, text inputs, clicked on text or CSS selector, network errors, IP address, user location (e.g., country), and/or other basic metadata, in addition to over a specific date range (e.g., last week). Returns an object with a list of relevant sessions in the `sessionDefinitions` field, each with recording ID, session ID, session URL, date of recording as a Unix timestamp in milliseconds, and other basic metadata. The returned object will also include a `metricDefinition` field indicating which LogRocket filters were used to find the sessions.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `organizationID` (`string`, required): The organization ID to run the query against.

Should be inferred from user input if a slash-separated identifier of the form `<organizationID>/<projectID>` or a link to a LogRocket resource is provided. For example, a LogRocket session URL has the structure `https://app.logrocket.com/<organizationID>/<projectID>/s/<recordingID>/<sessionID>`. Similarly, links to other LogRocket resources (e.g., issues, metrics) will contain the organization ID as the first path segment.

If not provided by the user, discover options using the list_organizations tool. If multiple organizations are found, ask the user which one(s) they want to use before proceeding.
- `projectID` (`string`, required): The project ID to run the query against.

Should be inferred from user input if a slash-separated identifier of the form `<organizationID>/<projectID>` or a link to a LogRocket resource is provided. For example, a LogRocket session URL has the structure `https://app.logrocket.com/<organizationID>/<projectID>/s/<recordingID>/<sessionID>`. Similarly, links to other LogRocket resources (e.g., issues, metrics) will contain the project ID as the second path segment.

If not provided by the user, discover options using the list_projects tool. If multiple projects are found, ask the user which one(s) they want to use before proceeding.
- `query` (`string`, required): Natural language query describing the sessions you want to find.
- `limit` (`integer`, optional): Maximum number of sessions to return. Defaults to 10.
- `userTraits` (`array`, optional): Names of custom user traits to include for each session (e.g., ["plan", "deviceId"]). Values come from the session's latest identify call, preferring identified users over anonymous ones, not the user's current traits. Names match case-insensitively; traits that identify call did not set are omitted. Returned in each session's `userTraits` field.

Example input: `{"organizationID":"<organizationID>","projectID":"<projectID>","query":"checkout errors affecting Chrome users"}`

### `logrocketmcp_get_metric`

Get Metric · Read-only

Use this to fetch the data for an existing, saved LogRocket metric (timeseries, funnel, table, retention, or session count) over a specific time range. Unlike build_metric, this runs the saved metric's own definition rather than generating one from a natural language query, so results are deterministic. Prefer this tool whenever the user provides a link to a saved metric. Heatmap and path analysis metrics are not supported.

Returns an object with:
- `metricDefinition`: the saved metric's configuration (name, type, filters, grouping, time interval, and, for funnels, the ordered steps in `funnel.steps`), with its time range replaced by the requested one.
- `metricQueryResult`: the metric's data. Timeseries return `buckets` keyed by time bucket (and `fullRangeValues` or `fullRangeUniqueUsers` when values can't be summed across buckets). Funnels return `sessionCountTotal` and `funnelStepSessionCounts`, one count per step in `funnel.steps` order (users rather than sessions for cross-session funnels), or `groupedFunnelStepSessionCounts` when the funnel is grouped. Tables return ranked `buckets` with `totalBucketCount`. Retention returns `buckets` per retention interval. Session metrics return `sessionCountTotal`.
- `sessionDefinitions`: when `sessionLimit` is set, a sample of sessions behind the metric, each with a `sessionURL` linking to its replay. For timeseries and session count metrics these are sessions matching the metric's filters; for funnels they are sessions in the cohort selected by `funnelStep` and `funnelSessions`. Always null for table and retention metrics, and when `sessionLimit` is omitted.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `endDate` (`string`, required): ISO 8601 datetime for the end of the time range to query. Must be after startDate. Dates without a time or offset are interpreted as UTC.
- `metricURL` (`string`, required): Link to the saved metric in the LogRocket dashboard (e.g., `https://app.logrocket.com/<organizationID>/<projectID>/funnels/<metricID>` or `https://app.logrocket.com/<organizationID>/<projectID>/metrics/<dashboardID>/metric/<metricID>`). The organization and project are read from the link.
- `startDate` (`string`, required): ISO 8601 datetime for the start of the time range to query (e.g., "2026-10-01T00:00:00Z"). Dates without a time or offset are interpreted as UTC.
- `funnelSessions` (`string`, optional): Funnels only. `DROPPED_OFF` (default) returns sessions that completed `funnelStep` but not the next step. `REACHED` returns sessions that completed at least `funnelStep`. The last step has no drop-offs. One of: `DROPPED_OFF`, `REACHED`.
- `funnelStep` (`integer`, optional): Funnels only. Zero-based index into `funnel.steps`, matching the order of `funnelStepSessionCounts`, used to select which sessions to return. Omit to select drop-offs from any step (with `DROPPED_OFF`) or sessions that completed the whole funnel (with `REACHED`).
- `limit` (`integer`, optional): Maximum number of rows returned for table metrics. Defaults to 20. Ignored for other metric types.
- `sessionLimit` (`integer`, optional): Number of example sessions to return in `sessionDefinitions`. Omit unless the user wants to see or watch sessions, since it adds a query.
- `timezone` (`string`, optional): Optional IANA timezone (e.g., 'America/New_York'). Time buckets align to this timezone's calendar (e.g., daily buckets break at its midnight). When omitted, they align to UTC. Pass the timezone the user asks for, or otherwise the timezone they are working in when known. If unknown, omit it; a UTC offset alone doesn't identify a timezone, so a guessed value may be silently wrong.

Example input: `{"endDate":"<endDate>","metricURL":"https://app.logrocket.com/<organizationID>/<projectID>/funnels/<metricID>","startDate":"2026-10-01T00:00:00Z"}`

### `logrocketmcp_get_network_entries`

Get Network Entries · Read-only

Use this to retrieve raw network request and response pairs recorded during a single LogRocket session, identified by its recording ID and session ID, as a HAR 1.2 document. Prefer this tool over watch_sessions when you only need network data. The response is an object with `total`, `offset`, `limit`, and `har`; entries are sorted by request start time and paginated, so if `offset + limit < total`, call the tool again with a higher offset to fetch the next page.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `organizationID` (`string`, required): The organization ID to run the query against. If not provided by the user, discover options using the list_organizations tool.
- `projectID` (`string`, required): The project ID to run the query against. If not provided by the user, discover options using the list_projects tool.
- `recordingID` (`string`, required): The recording ID of the session.
- `sessionID` (`integer`, required): The session ID of the session. Provide this as an integer.
- `endTime` (`string`, optional): Optional ISO 8601 datetime. Only entries whose request started at or before this time are returned. Defaults to the end of the session.
- `limit` (`integer`, optional): Maximum number of entries to return per call. Defaults to 100.
- `maxStatus` (`integer`, optional): Optional inclusive upper bound on the response status code.
- `methods` (`array`, optional): Optional list of HTTP methods (e.g., ["POST", "PUT"]). Only entries whose request used one of these methods are returned. Matching is case-insensitive.
- `minStatus` (`integer`, optional): Optional inclusive lower bound on the response status code. Combine with maxStatus to select a range (e.g., 500 and 599 for server errors) or use both with the same value to select one code (e.g., 404).
- `offset` (`integer`, optional): Number of matching entries to skip, for pagination. Defaults to 0.
- `startTime` (`string`, optional): Optional ISO 8601 datetime. Only entries whose request started at or after this time are returned. Defaults to the start of the session.
- `urlFilter` (`string`, optional): Optional case-insensitive substring filter applied to request URLs (e.g., "/api/cart" or "subdomain.example.com"). Only entries whose URL contains this substring are returned.

Example input: `{"organizationID":"<organizationID>","projectID":"<projectID>","recordingID":"<recordingID>","sessionID":1}`

### `logrocketmcp_list_organizations`

List Organizations · Read-only

List all LogRocket organizations the authenticated user has access to. Use this first to discover available organizations before querying projects or sessions.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `logrocketmcp_list_projects`

List Projects · Read-only

List all projects within a LogRocket organization. Use this to identify accessible projects before querying sessions, metrics, or issues.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `organizationID` (`string`, required): The organization ID to list projects for. All projects belong to an organization. If not provided by the user, options should be discovered using the list_organizations tool.

Example input: `{"organizationID":"<organizationID>"}`

### `logrocketmcp_use_logrocket`

Use LogRocket · Read-only

Process a natural language query against LogRocket data — sessions, metrics, and issues. Use this to investigate user-reported bugs, understand behavior patterns, analyze performance metrics, and detect regressions by correlating code changes with LogRocket data.

Read only: yes. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `organizationID` (`string`, required): The organization ID to run the query against.

Should be inferred from user input if a slash-separated identifier of the form `<organizationID>/<projectID>` or a link to a LogRocket resource is provided. For example, a LogRocket session URL has the structure `https://app.logrocket.com/<organizationID>/<projectID>/s/<recordingID>/<sessionID>`. Similarly, links to other LogRocket resources (e.g., issues, metrics) will contain the organization ID as the first path segment.

If not provided by the user, discover options using the list_organizations tool. If multiple organizations are found, ask the user which one(s) they want to use before proceeding.
- `projectID` (`string`, required): The project ID to run the query against.

Should be inferred from user input if a slash-separated identifier of the form `<organizationID>/<projectID>` or a link to a LogRocket resource is provided. For example, a LogRocket session URL has the structure `https://app.logrocket.com/<organizationID>/<projectID>/s/<recordingID>/<sessionID>`. Similarly, links to other LogRocket resources (e.g., issues, metrics) will contain the project ID as the second path segment.

If not provided by the user, discover options using the list_projects tool. If multiple projects are found, ask the user which one(s) they want to use before proceeding.
- `query` (`string`, required): The natural language query to run against LogRocket. Not required when polling for a result.
- `chatID` (`string`, optional): The chatID from a previous response. Must be provided to continue an existing conversation (e.g., follow-up questions) or poll for a result. Omit to start a new conversation.
- `pollForResult` (`boolean`, optional): Set to true to poll for completion of a query that previously had status: thinking. Omit in all other cases.
- `timezone` (`string`, optional): Optional IANA timezone (e.g., 'America/New_York'). Time buckets align to this timezone's calendar (e.g., daily buckets break at its midnight). When omitted, they align to UTC. Pass the timezone the user asks for, or otherwise the timezone they are working in when known. If unknown, omit it; a UTC offset alone doesn't identify a timezone, so a guessed value may be silently wrong.

Example input: `{"organizationID":"<organizationID>","projectID":"<projectID>","query":"checkout errors affecting Chrome users"}`

### `logrocketmcp_watch_sessions`

Watch Sessions · Read-only

Use this to analyze one or more LogRocket sessions, each identified by its recording ID and session ID. You can use this tool to understand user behavior in the session or to extract additional information about the session (e.g., metadata, console logs, network requests and responses). Provide a separate natural language query describing what you want to know for each session to be analyzed. Sessions are analyzed in parallel, independently of each other. Session watching can take several minutes to complete; if pendingResults are returned, continue calling this tool with pollForResults: true and the pending fingerprints until all requests are complete.

Read only: yes. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `organizationID` (`string`, required): The organization ID to run the query against. If not provided by the user, discover options using the list_organizations tool.
- `projectID` (`string`, required): The project ID to run the query against. If not provided by the user, discover options using the list_projects tool.
- `fingerprints` (`array`, optional): Fingerprints identifying session watching requests that are still pending. Required when pollForResults is true.
- `pollForResults` (`boolean`, optional): Set to true to poll for completion of previously-submitted session watching requests. Omit in all other cases.
- `sessions` (`array`, optional): Sessions to be analyzed. Required when pollForResults is omitted or false. Omit when polling for already-submitted fingerprints.

Example input: `{"organizationID":"<organizationID>","projectID":"<projectID>"}`

## Related

Other Analytics connectors ([all 127](/agentkit/connectors/?category=analytics)):

- [Microsoft 365](/agentkit/connectors/microsoft365/): Scalekit connector, OAuth, 317 tools
- [HubSpot](/agentkit/connectors/hubspot/): Scalekit connector, OAuth, 457 tools
- [Snowflake](/agentkit/connectors/snowflake/): Scalekit connector, OAuth, 42 tools


---

## More Scalekit documentation

| Resource | What it contains | When to use it |
|----------|-----------------|----------------|
| [/llms.txt](/llms.txt) | Structured index with routing hints per product area | Start here — find which documentation set covers your topic before loading full content |
| [/llms-full.txt](/llms-full.txt) | Complete documentation for all Scalekit products in one file | Use when you need exhaustive context across multiple products or when the topic spans several areas |
| [sitemap-0.xml](https://docs.scalekit.com/sitemap-0.xml) | Full URL list of every documentation page | Use to discover specific page URLs you can fetch for targeted, page-level answers |
