# MCP Server via command line
MCP command of vrest-ng-cli binary is used to start the vREST MCP (Model Context Protocol) server. Use this when you want to connect Cursor or other MCP clients to vREST NG services (e.g. to run tests, read specifications, or use vREST tools from your IDE).
# Prerequisites
You need a CLI token to authenticate the MCP server. For information on generating the CLI token, see CLI Token.
# Usage Instructions
vrest-ng-cli mcp --token="<TOKEN>" [--port=<port>]
# Example
vrest-ng-cli mcp --token="paste the generated CLI Token here"
To run the MCP server on a specific port (default is 3000):
vrest-ng-cli mcp --token="paste the generated CLI Token here" --port=3100
# Options
--token : Authentication token. Required. Generate it from the vREST NG
Dashboard (Configuration > CLI Token).
See [CLI Token](https://vrest.io/docs/dashboard/cli-token.html) for steps.
-p, --port : Port on which the MCP server will listen. [default: 3000]
# Configuring your MCP client
After starting the MCP server with vrest-ng-cli mcp, configure your MCP client (e.g. Cursor) to connect to it. Use the transport and port you started the server on (e.g. HTTP on port 3000). Refer to your client’s documentation for adding an MCP server.