Skip to content
Scalekit Docs
Talk to an Engineer Dashboard

GTmetrix MCP connector

OAuth 2.1/DCRDeveloper ToolsAnalyticsMonitoring

Connect to GTmetrix MCP to analyze web page performance, run speed tests, monitor Core Web Vitals, and get actionable optimization recommendations...

GTmetrix MCP connector

  1. Terminal window
    npm install @scalekit-sdk/node

    Full SDK reference: Node.js | Python

  2. 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. quickstart.ts
    import { ScalekitClient } from '@scalekit-sdk/node'
    import 'dotenv/config'
    const scalekit = new ScalekitClient(
    process.env.SCALEKIT_ENV_URL,
    process.env.SCALEKIT_CLIENT_ID,
    process.env.SCALEKIT_CLIENT_SECRET,
    )
    const actions = scalekit.actions
    const connector = 'gtmetrixmcp'
    const identifier = 'user_123'
    // Generate an authorization link for the user
    const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
    console.log('Authorize GTmetrix MCP:', link)
    process.stdout.write('Press Enter after authorizing...')
    await new Promise(r => process.stdin.once('data', r))
    // Make your first call
    const result = await actions.executeTool({
    connector,
    identifier,
    toolName: 'gtmetrixmcp_get_account_status',
    toolInput: {},
    })
    console.log(result)

Connect this agent connector to let your agent:

  • Test start — Start a new GTmetrix page performance test for a URL
  • List pages — List GTmetrix pages for the authenticated account
  • Get test, report history, report har — Get the current status of a started GTmetrix test

Use the exact tool names from the Tool list below when you call execute_tool. If you’re not sure which name to use, list the tools available for the current user first.

gtmetrixmcp_get_account_status#Returns the current GTmetrix account status including plan type, remaining API credits, next refill date, and feature access flags.0 params

Returns the current GTmetrix account status including plan type, remaining API credits, next refill date, and feature access flags.

gtmetrixmcp_get_catalog#Fetch a GTmetrix lookup catalog in JSON format for resolving names to IDs. Available catalogs: browsers, locations, simulated-devices, throttle-connections, lighthouse-audits.1 param

Fetch a GTmetrix lookup catalog in JSON format for resolving names to IDs. Available catalogs: browsers, locations, simulated-devices, throttle-connections, lighthouse-audits.

NameTypeRequiredDescription
catalog_idstringrequiredThe catalog to retrieve.
gtmetrixmcp_get_guide#Fetch a GTmetrix documentation guide in markdown format. Available guides: har-analysis, test-options, report-analysis, general-test-error, lighthouse-error.1 param

Fetch a GTmetrix documentation guide in markdown format. Available guides: har-analysis, test-options, report-analysis, general-test-error, lighthouse-error.

NameTypeRequiredDescription
guide_idstringrequiredThe identifier of the guide to fetch.
gtmetrixmcp_get_report#Retrieve the report data using the report ID. Contains GTmetrix scores, Core Web Vitals, top Lighthouse issues, resource summary, and download URLs.1 param

Retrieve the report data using the report ID. Contains GTmetrix scores, Core Web Vitals, top Lighthouse issues, resource summary, and download URLs.

NameTypeRequiredDescription
report_idstringrequiredThe 8-character report ID to retrieve.
gtmetrixmcp_get_report_har#Fetch the raw HAR (net.har) for a completed GTmetrix report and return it inline. Use when direct download of the HAR URL is not possible.2 params

Fetch the raw HAR (net.har) for a completed GTmetrix report and return it inline. Use when direct download of the HAR URL is not possible.

NameTypeRequiredDescription
report_slugstringrequiredThe 8-character report slug identifying the report.
forcebooleanoptionalIf true, re-fetches the HAR even if already cached. Defaults to false.
gtmetrixmcp_get_report_history#Fetch historical performance data for a GTmetrix page. Returns all reports in reverse chronological order for trend analysis.3 params

Fetch historical performance data for a GTmetrix page. Returns all reports in reverse chronological order for trend analysis.

NameTypeRequiredDescription
limitintegeroptionalMaximum number of historical reports to return (1–500).
page_slugstringoptional8-character alphanumeric slug identifying the GTmetrix page whose history to fetch.
report_slugstringoptional8-character alphanumeric slug identifying a specific report to start history from.
gtmetrixmcp_get_test#Get the current status of a started GTmetrix test. Long-polls server-side until the test completes or budget expires.2 params

Get the current status of a started GTmetrix test. Long-polls server-side until the test completes or budget expires.

NameTypeRequiredDescription
test_idstringrequiredThe 8-character test ID returned by gtmetrix_start_test.
wait_secondsintegeroptionalNumber of seconds to wait for the test to complete (0–30). If omitted, returns immediately with current status.
gtmetrixmcp_list_pages#List GTmetrix pages for the authenticated account. A page is a URL and test-settings combination. Returns pages with latest scores, Core Web Vitals, and monitoring status.5 params

List GTmetrix pages for the authenticated account. A page is a URL and test-settings combination. Returns pages with latest scores, Core Web Vitals, and monitoring status.

NameTypeRequiredDescription
browserstringoptionalFilter pages by browser name or ID.
limitintegeroptionalMaximum number of pages to return (1–2000).
locationstringoptionalFilter pages by test location name or ID.
monitoringstringoptionalFilter pages by monitoring frequency.
urlstringoptionalFilter pages by URL (partial match supported).
gtmetrixmcp_start_test#Start a new GTmetrix page performance test for a URL.1 param

Start a new GTmetrix page performance test for a URL.

NameTypeRequiredDescription
urlstringrequiredThe fully qualified URL of the page to test.