Skip to content
Scalekit Docs
Talk to an Engineer Dashboard

Connect AI agents to the Greptile MCP server

Vendor MCP
Open markdown

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

Tools
16
What they doRead · write · destructive
14 · 2 · 014 read2 write0 destructive
Users sign in with
OAuth app
Scalekit's or your own

Setup

  1. Install the SDK

    Terminal window
    npm install @scalekit-sdk/node dotenv
  2. Set your credentials

    Add your Scalekit credentials to your .env file. Find values in app.scalekit.com > Developers > API Credentials.

    .env
    SCALEKIT_ENVIRONMENT_URL=<your-environment-url>
    SCALEKIT_CLIENT_ID=<your-client-id>
    SCALEKIT_CLIENT_SECRET=<your-client-secret>
  3. Create the Greptile MCP connection

    In AgentKit > Connections, create a Greptile MCP connection. The name you give it is the connection_name your code passes. See Configure connections.

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

  4. Authorize a user and make your first call

    quickstart.mts
    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 = 'greptilmcp'
    const identifier = 'user_123'
    // Generate an authorization link for the user
    const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
    console.log('Authorize Greptile 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: 'greptilmcp_list_code_reviews',
    toolInput: {},
    })
    console.log(result)
    Terminal window
    npx tsx quickstart.mts

    Each user signs in once. See Authorize a user for the full flow and statuses.

Tools

Pass the exact name to execute_tool
Try in PlaygroundRequest a tool
  • greptilmcp_get_code_reviewGet detailed code review information including status, comments, and analysis results.Read-only

    Get Code Review

    Get detailed code review information including status, comments, and analysis results.

    Inputs

    codeReviewIdstringrequired
    The unique identifier of the code review to retrieve.
  • greptilmcp_get_custom_contextGet detailed custom context information including evidence and linked comments.Read-only

    Get Custom Context

    Get detailed custom context information including evidence and linked comments.

    Inputs

    customContextIdstringrequired
    The unique identifier of the custom context to retrieve.
  • greptilmcp_get_knowledge_base_documentGet the markdown body of a single knowledge base document.Read-only

    Get Knowledge Base Document

    Get the markdown body of a single knowledge base document. Returns the content plus the section and versionId it was read from.

    Inputs

    pathstringrequired
    Document path obtained from List Knowledge Base Documents.
    repoNamespaceExternalIdstringrequired
    Repository handle obtained from List Knowledge Bases.
  • greptilmcp_get_merge_requestGet detailed merge request information including metadata, statistics, Greptile comments, and review analysis.Read-only

    Get Merge Request

    Get detailed merge request information including metadata, statistics, Greptile comments, and review analysis.

    Inputs

    defaultBranchstringrequired
    The default branch of the repository.
    namestringrequired
    The repository name (e.g. owner/repo).
    prNumbernumberrequired
    The pull request or merge request number.
    remotestringrequired
    The git hosting provider: github, gitlab, azure, or bitbucket.one of githubgitlabazurebitbucket
    remoteUrlstring
    The remote URL of the repository.
  • greptilmcp_list_code_reviewsList code reviews with optional filtering by repository, PR number, and review status.Read-only

    List Code Reviews

    List code reviews with optional filtering by repository, PR number, and review status.

    Inputs

    defaultBranchstring
    Filter by the repository's default branch.
    limitnumber
    Maximum number of results to return (1-100). Defaults to 20.default 20
    namestring
    Filter by repository name (e.g. owner/repo).
    offsetnumber
    Number of results to skip for pagination. Defaults to 0.default 0
    prNumbernumber
    Filter by pull request number.
    remotestring
    Filter by git hosting provider.one of githubgitlabazurebitbucket
    remoteUrlstring
    Filter by the remote URL of the repository.
    statusstring
    Filter by code review status.one of PENDINGREVIEWING_FILESGENERATING_SUMMARYCOMPLETEDFAILEDSKIPPED
  • greptilmcp_list_custom_contextList organization custom context with optional filtering by type and generation source.Read-only

    List Custom Context

    List organization custom context with optional filtering by type and generation source.

    Inputs

    greptileGeneratedboolean
    Filter by whether the context was generated by Greptile.
    limitnumber
    Maximum number of results to return (1-100). Defaults to 20.default 20
    offsetnumber
    Number of results to skip for pagination. Defaults to 0.default 0
    typestring
    Filter by context type: CUSTOM_INSTRUCTION or PATTERN.one of CUSTOM_INSTRUCTIONPATTERN
  • greptilmcp_list_knowledge_base_documentsList the document paths in one repository's current published knowledge base.Read-only

    List Knowledge Base Documents

    List the document paths in one repository's current published knowledge base. Every returned path can be passed straight to Get Knowledge Base Document.

    Inputs

    repoNamespaceExternalIdstringrequired
    Repository handle obtained from List Knowledge Bases.
    limitnumber
    Maximum number of results to return (1-100). Defaults to 20.default 20
    offsetnumber
    Number of results to skip for pagination. Defaults to 0.default 0
  • greptilmcp_list_knowledge_basesList the repositories in your organization that have a published Greptile knowledge base — the per-repository documentation Greptile synthesizes from the codebase and consults while reviewing.Read-only

    List Knowledge Bases

    List the repositories in your organization that have a published Greptile knowledge base — the per-repository documentation Greptile synthesizes from the codebase and consults while reviewing.

    Inputs

    limitnumber
    Maximum number of results to return (1-100). Defaults to 20.default 20
    offsetnumber
    Number of results to skip for pagination. Defaults to 0.default 0