Skip to main content
This guide walks you through configuring the MCP (Model Context Protocol) server necessary to natively use WireMock Cloud from an MCP-compatible AI tool such as Cursor or Claude Desktop. This enables automatic API discovery, mocking and test abstraction from any codebase as part of prompt-driven development with your chosen AI tool. Additionally, it enables you to skip the complexity of building out new services early on - which can hamper the rapid development by introducing more failure points - and instead use simulated APIs on WireMock to prototype new capabilities with less system overhead.
Most users should install the WireMock Cloud agent skills plugin instead - it bundles this same MCP server connection alongside expert guidance for your agent, with no separate setup step. Use this page if you want the MCP server on its own, without the skills plugin.
Note that while this article documents use with Cursor, Claude Desktop and VSCode specifically, WireMock Cloud’s MCP server will work with any AI-powered tool that supports MCP.

Choosing a server

WireMock Cloud offers two ways to connect an AI tool via MCP:
  • Remote server (recommended) - a hosted HTTP server at https://mcp.wiremock.cloud/mcp. No local installation is required; your AI tool authenticates with your WireMock Cloud account via an OAuth sign-in in your browser the first time it connects, or with an API token for headless and CI clients that can’t complete a browser sign-in.
  • Local server - a stdio server launched on your machine by the WireMock CLI (wiremock mcp). Choose this if you need HTTP request authentication with locally stored credentials, or if your network can’t reach mcp.wiremock.cloud directly.
Both expose the same set of MCP tools. Use whichever matches your setup - you only need one. No prerequisites beyond an existing WireMock Cloud account - if you don’t have one, the OAuth step below will guide you through creating one.
Click this button to install with Cursor:Add WireMock MCP server to CursorOr, follow these instructions:
  • Open Settings->Cursor settings.
  • Navigate to Tools & Integrations.
  • Click New MCP Server. This opens mcp.json.
  • Add the WireMock server:
  • Save the file. Cursor will show a “needs authentication” indicator next to the server - click Connect to complete an OAuth sign-in in your browser.

Step 2: Confirm your setup

To confirm everything is working correctly, check that you’re logged in to WireMock Cloud by running the following prompt:
If logged in, you’ll see your account details rather than being prompted to sign in.

Authenticating with an API token

Clients that can’t complete an interactive browser sign-in - CI pipelines, scripts, or other headless agents - can authenticate to the remote server with a WireMock Cloud API token instead of OAuth. Get your token from the account security page (see Authentication), then send it in the Authorization header using the Token scheme in place of the OAuth sign-in step:
For example, to add the server to Claude Code without an interactive sign-in:
Or in an mcp.json-style configuration (Cursor):
Or for VS Code’s settings.json:
Other MCP clients that support custom headers for remote servers use a similar headers field - check your tool’s documentation for the exact configuration key.
Treat your API token like a password - anyone with it can access your WireMock Cloud account through the MCP server. Prefer OAuth sign-in for interactive use, and reserve API tokens for headless or CI environments where a browser isn’t available.

Option 2: Local server

Prerequisites

  • Node.js 18+ (to install the CLI)
  • An existing WireMock Cloud account (if you don’t have one, you can sign up during the login step)

Step 1: Install the WireMock CLI

Install the CLI globally using npm:

Step 2: Log in to WireMock Cloud

If you already have a WireMock Cloud account, simply log in. Otherwise, the login process will guide you through creating an account:

Step 3: Configure your AI tool

Click this button to install with Cursor:Add WireMock MCP server to CursorOr, follow these instructions:
  • Open Settings->Cursor settings.
  • Navigate to MCP.
  • Click Add new MCP server.
  • In the dialog, configure your server to run this command:
Configure MCP server
  • Verify Installation by looking for the green status dot next to the MCP server and the list of tool names.
Verify the MCP server is activeIf you have an existing real API integration, you can replace it with a WireMock stub. Generate the mock from documentation, source code, or other external description formats. This enables you to test your app in isolation without depending on live services.

Step 4: Confirm your setup

To confirm everything is working correctly, check that you’re logged in to WireMock Cloud by running the following prompt:
If logged in, you’ll see your account details rather than being prompted to sign in.Confirm you are logged in via the CLI

Next Steps

With WireMock MCP successfully installed, you can begin creating and using mocks in your development workflow:

Generate a new feature and mock a new API

Develop a new feature in your application that calls a fresh API. Quickly generate a WireMock stub for this API, and then wire it up to your app while in development mode.

Swap an existing API connection for a mock

If you have an existing real API integration, you can replace it with a WireMock Cloud mock. Generate the mock from documentation, source code, or other external description formats. This enables you to test your app in isolation without depending on live services.