

# Using MCP with Amazon Q Developer
<a name="qdev-mcp"></a>

The Model Context Protocol (MCP) is an open standard that enables AI assistants to interact with external tools and services. Amazon Q Developer CLI now supports MCP, allowing you to extend Q's capabilities by connecting it to custom tools and services.

**Topics**
+ [

# MCP overview
](qdev-mcp-overview.md)
+ [

# MCP configuration in the CLI
](command-line-mcp-config-CLI.md)
+ [

## MCP configuration
](#mcp-configuration)
+ [

## Tools and prompts
](#command-line-mcp-tools-prompts)
+ [

# MCP configuration for Q Developer in the IDE
](mcp-ide.md)
+ [

## Key benefits
](#command-line-mcp-benefits)
+ [

## MCP architecture
](#command-line-mcp-architecture)
+ [

## Core MCP concepts
](#command-line-mcp-concepts)
+ [

# MCP security
](command-line-mcp-security.md)
+ [

# MCP governance for Q Developer
](mcp-governance.md)

# MCP overview
<a name="qdev-mcp-overview"></a>

MCP (Model Context Protocol) is an open protocol that standardizes how AI assistants communicate with external tools. It defines a structured way for AI models to discover available tools, request tool execution with specific parameters, and receive and process tool results.

Think of MCP like a universal connector for AI models, enabling them to interact with external systems, fetch live data, and integrate with various tools seamlessly. This allows Amazon Q to provide more contextually relevant assistance by accessing the information it needs in real-time.

![\[MCP architecture showing how Amazon Q Developer CLI connects to external data sources through MCP servers\]](http://docs.aws.amazon.com/amazonq/latest/qdeveloper-ug/images/mcp-response-diagram.png)


# MCP configuration in the CLI
<a name="command-line-mcp-config-CLI"></a>

This page covers CLI-specific options for configuring MCP servers.

## Configuration commands
<a name="command-line-mcp-config-commands"></a>

Usage: `qchat mcp [OPTIONS] COMMAND ` 


**MCP configuration commands**  

| Command | Description | 
| --- | --- | 
|  qchat mcp add  | Add or replace a configured server | 
|  qchat mcp remove  | Remove a server from the MCP configuration | 
|  qchat mcp list  | List configured servers | 
|  qchat mcp import  | Import a server configuration from another file | 
|  qchat mcp status  | Get the status of a configured server | 
|  qchat mcp help  | Print this list of commands or help for the given subcommand(s) | 

### MCP server arguments
<a name="command-line-mcp-enhanced-args"></a>

The `--args` parameter now supports comma-containing arguments using escaping or JSON array format:

```
# Escaped commas
q mcp add --name server --command cmd --args "arg1,arg2\,with\,commas,arg3"

# JSON array format  
q mcp add --name server --command cmd --args '["arg1", "arg2,with,commas", "arg3"]'
```

## Remote MCP servers
<a name="command-line-mcp-remote-servers"></a>

In addition to local MCP servers that run as processes, Amazon Q Developer CLI supports remote MCP servers that communicate over HTTP. Remote servers can use OAuth authentication or be open (no authentication required).

### Configuration
<a name="command-line-mcp-remote-config"></a>

Remote MCP servers are configured in your agent configuration file using the `type` and `url` fields:

```
{
  "mcpServers": {
    "find-a-domain": {
      "type": "http",
      "url": "https://api.findadomain.dev/mcp"
    }
  }
}
```

### OAuth authentication flow
<a name="command-line-mcp-oauth-flow"></a>

When using remote MCP servers that require OAuth authentication:

1. Start your Q CLI session with an agent that includes the remote MCP server

1. The server will initially show as "not yet loaded"

1. Use the `/mcp` command to begin authentication

1. Q CLI will indicate that the server requires authentication and provide a URL

1. Open the provided URL in your browser while keeping the Q CLI session open

1. Follow the authentication instructions in your browser

1. Return to the Q CLI window - you will be signed into the MCP server if authentication was successful

The server's tools will become available once authentication is complete.

## MCP configuration
<a name="mcp-configuration"></a>

### Setting up MCP servers with the Q CLI
<a name="setting-up-mcp-Q-CLI"></a>

The globally defined MCP configuration for Amazon Q CLI is handled at:

```
~/.aws/amazonq/cli-agents
```

Amazon Q Developer CLI supports both local MCP servers (that run as processes) and remote MCP servers (that communicate over HTTP). Remote servers can use OAuth authentication or be open with no authentication required.

For more information, see [the custom agent configuration guide on the Q CLI Github repo](https://github.com/aws/amazon-q-developer-cli/blob/main/docs/agent-format.md#mcpservers-field) and [Remote MCP servers](command-line-mcp-config-CLI.md#command-line-mcp-remote-servers).

### Setting up MCP servers with Q in the IDE
<a name="setting-up-mcp-Q-IDE"></a>

The globally defined MCP configuration for Amazon Q in the IDE is handled at:

```
~/.aws/amazonq/agents/default.json
```

For more information, see [MCP configuration for Q Developer in the IDE](mcp-ide.md).

### MCP server loading
<a name="command-line-mcp-server-loading"></a>

Amazon Q loads MCP servers in the background, allowing you to start interacting immediately without waiting for all servers to initialize. Tools become available progressively as their respective servers finish loading.

#### Checking server status
<a name="command-line-mcp-server-status"></a>

You can use the `/tools` command to see which servers are still loading and which tools are already available.

#### Configuring server initialization
<a name="command-line-mcp-server-config"></a>

You can customize the server initialization timeout using:

```
$ q settings mcp.initTimeout [value]
```

Where `[value]` is the timeout in milliseconds. This setting controls how long Amazon Q will wait for servers to initialize before allowing you to start interacting.

## Tools and prompts
<a name="command-line-mcp-tools-prompts"></a>

This section covers how to use MCP tools and prompts with Amazon Q Developer CLI.

### Understanding MCP tools
<a name="command-line-mcp-tools"></a>

MCP tools are executable functions that MCP servers expose to Amazon Q Developer CLI. They enable Amazon Q Developer to perform actions, process data, and interact with external systems on your behalf.

Each tool in MCP has:
+  **Name**: A unique identifier for the tool
+  **Description**: A human-readable description of what the tool does
+  **Input Schema**: A JSON Schema defining the parameters the tool accepts
+  **Annotations**: Optional hints about the tool's behavior and effects

### Discovering available tools
<a name="command-line-mcp-discovering-tools"></a>

To see what tools are available in your Q CLI session:

```
/tools
```

This command displays all available tools, including both built-in tools and those provided by MCP servers.

Tools can have different permission levels that determine how they're used:
+  **Auto-approved**: These tools can be used without explicit permission for each invocation
+  **Requires approval**: These tools need your explicit permission each time they're used
+  **Dangerous**: These tools are marked as potentially risky and require careful consideration before approval

### Using tools
<a name="command-line-mcp-using-tools"></a>

You can use MCP tools in two ways:

1.  **Natural Language Requests**: Simply describe what you want to do, and Q will determine which tool to use.

1.  **Direct Tool Invocation**: You can also explicitly request Q to use a specific tool.

### Working with prompts
<a name="command-line-mcp-prompts"></a>

MCP servers can provide predefined prompts that help guide Q in specific tasks:
+ List available prompts: `/prompts` 
+ Use a prompt: 
  +  `@ prompt-name arg1 arg2` 

Example of using a prompt with arguments:

```
@fetch https://docs.aws.amazon.com/amazonq/latest/qdeveloper-ug/command-line-mcp-configuration.html
```

# MCP configuration for Q Developer in the IDE
<a name="mcp-ide"></a>

This page covers IDE-specific options for configuring MCP servers. 

## Understanding MCP configuration files for Q Developer in the IDE
<a name="mcp-ide-configuration-understanding"></a>

When you use the GUI to add an MCP server to Q Developer in the IDE, the configuration is stored in one of two files:
+ At the global scope: \$1/.aws/amazonq/default.json
+ At the local scope: .amazonq/default.json

However, for legacy reasons, it is also possible to put MCP configuration information in two other locations: 
+ At the global scope: \$1/.aws/amazonq/mcp.json
+ At the local scope: .amazonq/mcp.json

Q Developer gives precedence to workspace level configurations for MCP servers, their permissions, and the settings stored.

**Note**  
If you have already set up an MCP configuration in an mcp.json file, and you are using the MCP configuration GUI for the first time, you will see that configuration in the GUI. 

Support for legacy mcp.json files is enabled by the useLegacyMcpJson field in your global default.json config file. By default, this field is set to true. For more information, see [UseLegacyMcpJson Field](https://github.com/aws/amazon-q-developer-cli/blob/main/docs/agent-format.md#uselegacymcpjson-field) in the Q Developer CLI GitHub repo.

Note that the mcp.json files may also be used by the Q CLI.

For information about how to set granular controls on MCP tooling, see the [Built-in tools reference](https://github.com/aws/amazon-q-developer-cli/blob/main/docs/agent-format.md#tools-field).

## Accessing the MCP configuration UI
<a name="mcp-ide-configuration-access-ui"></a>

To access the MCP configuration UI in Q Developer in the IDE:

1. Open your IDE (VS Code, JetBrains, etc.).

1. Open the Q Developer panel.

1. Open the **Chat** panel.

1. Choose the tools icon. ![\[tools icon\]](http://docs.aws.amazon.com/amazonq/latest/qdeveloper-ug/images/tools-icon-full.png) 

## Adding an MCP server
<a name="mcp-ide-configuration-add-mcp-server"></a>

There are two primary transport mechanisms for communication between AI clients and MCP servers: STDIO and HTTP.

### Adding an HTTP MCP server
<a name="mcp-ide-configuration-add-http-server"></a>

To add an HTTP MCP server to the IDE:

1.  [Access the MCP configuration UI](#mcp-ide-configuration-access-ui). 

1. Choose the plus (\$1) symbol.

1. Select the scope: global or local.

   If you select global scope, the MCP server configuration is stored in \$1/.aws/amazonq/default.json and available across all your projects. If you select local scope, the configuration is stored in .amazonq/default.json within your current project.

1. In the **Name** field, enter the name of the MCP server.

1. Select `http` as the transport protocol.

1. In the **URL** field, enter the URL that the MCP server will call when it initializes.

1. Under **Headers - optional**, you can enter key-value pairs that must be sent as HTTP request headers. .

1. Enter a **Timeout** value, as applicable.

1. Choose **Save**. 

   The configuration panel will be replaced with the tool permissions panel.

1. Follow the procedure under [Reviewing and adjusting tool permissions](#mcp-ide-configuration-review-adjust-tool) .

**Note**  
If the MCP HTTP endpoint requires authorization, then Amazon Q will automatically open a browser page so that you can authorize Amazon Q to access the MCP server.

### Adding an STDIO MCP server
<a name="mcp-ide-configuration-add-stdio-server"></a>

To add an STDIO MCP server to the IDE:

1.  [Access the MCP configuration UI](#mcp-ide-configuration-access-ui). 

1. Choose the plus (\$1) symbol.

1. Select the scope: global or local.

   If you select global scope, the MCP server configuration is stored in \$1/.aws/amazonq/default.json and available across all your projects. If you select local scope, the configuration is stored in .amazonq/default.json within your current project.

1. In the **Name** field, enter the name of the MCP server.

   For example, if we were installing the [AWS Documentation MCP server](https://awslabs.github.io/mcp/servers/aws-documentation-mcp-server/), the name might be *AWSDocMCPServer*. 

1. Select `stdio` as the transport protocol.

1. In the **Command** field, enter the shell command that the MCP server will run when it initializes.

   In the case of the AWS Documentation MCP Server, the command is `uvx`. This is an alias for `uv tool run`, which creates an ephemeral Python environment.

1. In the **Arguments** field, enter an argument to be given to the shell command, if applicable.

   In the case of the AWS Documentation MCP Server, the argument is *awslabs.aws-documentation-mcp-server@latest*. This is a Python package identifier that points to a package hosted on PyPI (Python Package Index).

   Add more arguments as necessary.

1. Fill in environment variables as applicable.

   In the case of our example, we first fill in Name: *FASTMCP\$1LOG\$1LEVEL* and Value: *ERROR*. 

   We will also use the name *AWS\$1DOCUMENTATION\$1PARTITION* and the value *aws* to indicate the [partition](https://docs.aws.amazon.com/whitepapers/latest/aws-fault-isolation-boundaries/partitions.html) that we'll be working with.

1. Enter a **Timeout** value, as applicable.

   For our example, we'll keep the recommended value of 60 (seconds).

1. Choose **Save**. 

   The configuration panel will be replaced with the tool permissions panel.

1. Follow the procedure under [Reviewing and adjusting tool permissions](#mcp-ide-configuration-review-adjust-tool) .

## Troubleshooting your MCP configuration
<a name="mcp-ide-configuration-troubleshooting"></a>

After you add an MCP server in the IDE, Amazon Q will attempt to connect to it.

If there are connection issues, then an alert will be displayed at the top of the panel. You should not expect the tools from that MCP server to function properly until the alert is resolved.

Choose **Fix Configuration** to return to the MCP configuration screen so that you can make the appropriate changes.

## Enabling an MCP server
<a name="mcp-ide-configuration-disable-server"></a>

The following procedure assumes that the MCP server in question is not already enabled.

To enable an MCP server in the IDE:

1. Open the MCP Servers panel.

1. Next to the server that you want to enable, choose **Enable**. 

## Disabling an MCP server
<a name="mcp-ide-configuration-disable-server"></a>

To disable an MCP server in the IDE:

1. Open the MCP Servers panel.

1. Choose the server you want to disable.

1. Choose the three dots next to **Edit setup**. 

1. Choose **Disable MCP Server**. 

## Deleting an MCP server that is currently enabled
<a name="mcp-ide-configuration-delete-enabled-server"></a>

To delete an MCP server that is currently enabled from the IDE:

1. Open the MCP Servers panel.

1. Choose the server you want to delete.

   A panel will open with details about that server.

1. Choose the three dots next to **Edit setup**. 

1. Choose **Delete MCP server**. 

1. Confirm the deletion when prompted.

## Deleting an MCP server that is currently disabled
<a name="mcp-ide-configuration-delete-disabled-server"></a>

To delete an MCP server that is currently disabled from the IDE:

1. Open the MCP Servers panel.

1. Next to the server that you want to delete, choose **Delete**. 

1. Confirm the deletion when prompted.

## Reviewing and adjusting tool permissions
<a name="mcp-ide-configuration-review-adjust-tool"></a>

To review and adjusting tool permissions:

1. Open the MCP Servers panel.

1. Choose the MCP server for which you want to review and adjust permissions.

1. For each tool, you can set one of the following permission levels:
   + Ask: Prompt for permission each time the tool is used.
   + Always allow: Allow the tool to run without prompting.
   + Deny: Do not use this tool.

## Key benefits
<a name="command-line-mcp-benefits"></a>
+  **Extensibility**: Connect Amazon Q to specialized tools for specific domains or workflows
+  **Customization**: Create custom tools tailored to your specific needs
+  **Ecosystem Integration**: Leverage the growing ecosystem of MCP-compatible tools
+  **Standardization**: Use a consistent protocol supported by multiple AI assistants
+  **Flexibility**: MCP allows you to switch between different LLM providers while maintaining the same tool integrations
+  **Security**: Keep your data within your infrastructure with local MCP servers

## MCP architecture
<a name="command-line-mcp-architecture"></a>

MCP follows a client-server architecture where:
+  **MCP Hosts**: Programs like Amazon Q Developer CLI that want to access data through MCP
+  **MCP Clients**: Protocol clients that maintain 1:1 connections with servers
+  **MCP Servers**: Lightweight programs that each expose specific capabilities through the standardized Model Context Protocol
+  **Local Data Sources**: Your computer's files, databases, and services that MCP servers can securely access
+  **Remote Services**: External systems available over the internet (e.g., through APIs) that MCP servers can connect to

**Example MCP Communication Flow**  

```
  User
   |
   v
+------------------+     +-----------------+     +------------------+
|                  |     |                 |     |                  |
| Amazon Q Dev     | --> | MCP Client API  | --> | MCP Server       |
|                  |     |                 |     |                  |
+------------------+     +-----------------+     +------------------+
                                                        |
                                                        v
                                                 +------------------+
                                                 |                  |
                                                 | External Service |
                                                 |                  |
                                                 +------------------+
```
Communication flow between user, Amazon Q Developer CLI, and external services through MCP

## Core MCP concepts
<a name="command-line-mcp-concepts"></a>

### Tools
<a name="command-line-mcp-concepts-tools"></a>

Tools are executable functions that MCP servers expose to clients. They allow Amazon Q to:
+ Perform actions in external systems
+ Process data in specialized ways
+ Interact with APIs and services
+ Execute commands on your behalf

Tools are defined with a unique name, a description, an input schema (using JSON Schema), and optional annotations about the tool's behavior.

### Prompts
<a name="command-line-mcp-concepts-prompts"></a>

Prompts are predefined templates that help guide Amazon Q in specific tasks. They can:
+ Accept dynamic arguments
+ Include context from resources
+ Chain multiple interactions
+ Guide specific workflows
+ Surface as UI elements (like slash commands)

### Resources
<a name="command-line-mcp-concepts-resources"></a>

Resources represent data that MCP servers can provide to Amazon Q, such as:
+ File contents
+ Database records
+ API responses
+ Documentation
+ Configuration data

# MCP security
<a name="command-line-mcp-security"></a>

When using MCP servers with Amazon Q Developer CLI, it's important to understand the security implications and best practices.

## Security model
<a name="command-line-mcp-security-model"></a>

The MCP security model in Amazon Q Developer CLI is designed with these principles:

1.  **Explicit Permission**: Tools require explicit user permission before execution

1.  **Local Execution**: MCP servers run locally on your machine

1.  **Isolation**: Each MCP server runs as a separate process

1.  **Transparency**: Users can see what tools are available and what they do

## Security considerations
<a name="command-line-mcp-security-considerations"></a>

Key security considerations when using MCP:
+ Only install servers from trusted sources
+ Review tool descriptions and annotations before approving
+ Use environment variables for sensitive configuration
+ Keep MCP servers and the Q CLI updated
+ Monitor MCP logs for unexpected activity

# MCP governance for Q Developer
<a name="mcp-governance"></a>

 Pro-tier customers using IAM Identity Center as the sign-in method can control MCP access for users within their organization. By default, your users can use any MCP server in their Q client. As an administrator, you have the ability to either entirely disable the use of MCP servers by your users, or specify a vetted list of MCP servers that your users are allowed use. 

 You control these restrictions using an MCP on/off toggle and an MCP registry. The MCP toggle and registry attributes are part of the [Q Developer profile](subscribe-understanding-profile.md), which can be defined at an organization level or at an account level, with the account-level profile superseding the organizational-level profile. You can specify a default MCP policy for your organization and override it for specific accounts; for example, disable MCP for the organization but enable it with an allow-list for certain teams (accounts). 

**Note**  
 Both the toggle and the registry settings are enforced on the client side. Be aware that your end users could circumvent it. 

## Disabling MCP for your organization
<a name="disabling-mcp"></a>

To disable MCP for your account or organization:

1. Open the Kiro console.

1. Choose **Settings**. 

1. Choose the **Q Developer** tab.

1.  Toggle **Model Context Protocol (MCP)** to **Off**. 

## Specifying an MCP allow-list for your organization
<a name="allow-listing-mcp"></a>

 To control which MCP servers your users can access, create a JSON file with the allowed servers, serve it over HTTPS, and add the URL to your Q Developer profile. Q Developer clients using this profile allow users to access only the MCP servers in your allow-list. 

### Specifying the MCP registry URL
<a name="specifying-registry-url"></a>

1. Open the Kiro console.

1. Choose **Settings**.

1. Choose the **Q Developer** tab.

1.  Ensure **Model Context Protocol (MCP)** is **On**. 

1.  In the **MCP Registry URL** field, choose **Edit**. 

1.  Enter the URL of an MCP registry JSON file containing the allow-listed MCP servers. 

1. Choose **Save**.

 The MCP registry URL is encrypted both in transit and at rest in accordance with [our data encryption policy](data-encryption.md). 

### MCP registry file format
<a name="registry-file-format"></a>

 The format of the registry JSON file is a subset of the server schema JSON in the [MCP registry standard](https://github.com/modelcontextprotocol/registry) v0.1. The JSON schema definition for the subset supported by Q Developer is available in the [registry schema](#registry-schema) section at the end of this document. 

 The following example shows an MCP registry file containing both a remote (HTTP) and a local (stdio) MCP server definition. 

```
{
  "servers": [
    {
      "server": {
        "name": "my-remote-server",
        "title": "My server",
        "description": "My server description",
        "version": "1.0.0",
        "remotes": [
          {
            "type": "streamable-http",
            "url": "https://acme.com/my-server",
            "headers": [
              {
                "name": "X-My-Header",
                "value": "SomeValue"
              }
            ]
          }
        ]
      }
    },
    {
      "server": {
        "name": "my-local-server",
        "title": "My server",
        "description": "My server description",
        "version": "1.0.0",
        "packages": [
          {
            "registryType": "npm",
            "registryBaseUrl": "https://npm.acme.com",
            "identifier": "@acme/my-server",
            "transport": {
              "type": "stdio"
            },
            "runtimeArguments": [
              {
                "type": "positional",
                "value": "-q"
              }
            ],
            "packageArguments": [
              {
                "type": "positional",
                "value": "start"
              }
            ],
            "environmentVariables": [
              {
                "name": "ENV_VAR",
                "value": "ENV_VAR_VALUE"
              }
            ]
          }
        ]
      }
    }
  ]
}
```

 The following table lists the properties for the registry JSON file. All properties are mandatory, unless otherwise noted. See the [registry schema](#registry-schema) section for the full JSON schema. 

 Nested attributes appear indented from their parent. For example, "headers" is a child attribute of "remotes", and "name" and "value" are child attributes of "headers". 


| Attribute | Description | Optional? | Example value | 
| --- | --- | --- | --- | 
|  **Common attributes**  |    |    |    | 
|  name  |  Server name. Must be unique within a given registry file.  |    |  "aws-ccapi-mcp"  | 
|  title  |  Human-readable server name.  |  Yes  |  "AWS CC API"  | 
|  description  |  Description of server.  |    |  "Manage AWS infra through natural language."  | 
|  version  |  Version of server. Semantic versioning (x.y.z) is strongly recommended.  |    |  "1.0.2"  | 
|  **Remote (HTTP) server attributes**  |    |    |    | 
|  remotes  |  Array with exactly one entry specifying the remote endpoint.  |    |  -  | 
|    type  |  Must be one of "streamable-http" or "sse".  |    |  "streamable-http"  | 
|    url  |  MCP server endpoint URL.  |    |  "https://mcp.figma.com/mcp"  | 
|    headers  |  Array of HTTP headers to include in each request.  |  Yes  |  -  | 
|      name  |  HTTP header name.  |    |  "Authorization"  | 
|      value  |  HTTP header value.  |    |  "Bearer mF\$19.B5f-4.1JqM"  | 
|  **Local (stdio) server attributes**  |    |    |    | 
|  packages  |  Array with exactly one entry containing the MCP server definition.  |    |  -  | 
|    registryType  |  Must be one of "npm", "pypi", or "oci". The following package runners are used to download and run the MCP server package: [\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/amazonq/latest/qdeveloper-ug/mcp-governance.html) Client machines must have the appropriate package runners pre-installed.  |    |  “npm”  | 
|    registryBaseUrl  |  Package registry URL.  |  Yes  |  "https://npm.acme.com"  | 
|    identifier  |  Server package identifier.  |    |  "@acme/my-server"  | 
|    transport  |  Object with exactly one property, "type".  |    |  -  | 
|      type  |  Must be "stdio".  |    |  “stdio”  | 
|    runtimeArguments  |  Array of arguments provided to the runtime, that is, to npx, uvx or docker.  |  Yes  |  -  | 
|      type  |  Must be "positional".  |    |  “positional”  | 
|      value  |  Runtime argument value.  |    |  “-q”  | 
|    packageArguments  |  Array of arguments provided to the MCP server.  |  Yes  |  -  | 
|      type  |  Must be "positional".  |    |  “positional”  | 
|      value  |  Package argument value.  |    |  “start”  | 
|    environmentVariables  |  Array of env vars to set before starting the server.  |  Yes  |  -  | 
|      name  |  Environment variable name.  |    |  "LOG\$1LEVEL"  | 
|      value  |  Environment variable value.  |    |  “INFO”  | 

### Serving the MCP registry file
<a name="serving-mcp-registry"></a>

 Serve the MCP registry JSON file over HTTPS using any web server, such as Amazon S3, Apache, or nginx. The URL must be accessible to Q Developer clients on your users' computers but can be private to your corporate network. 

 The HTTPS endpoint must have a valid SSL certificate signed by a trusted Certificate Authority. Self-signed certificates are not supported. 

 Q Developer fetches the MCP registry at startup and every 24 hours. During periodic synchronization, if a locally installed MCP server is no longer in the registry, Q Developer terminates that server and prevents users from adding it back. If the locally installed server has a different version than the server in the registry, Q Developer relaunches the server with the version defined in the registry. 

### Q Developer plugins
<a name="mcp-registry-q-dev-plugins"></a>

 When users launch Q Developer, it checks whether a registry URL is defined in the profile. If so, it retrieves the registry JSON at that URL and enforces that users can only use the MCP servers defined in the registry. When users add an MCP server, Q Developer displays a list of servers from the registry. 

![\[Screenshot showing the addition of MCP servers defined in the registry.\]](http://docs.aws.amazon.com/amazonq/latest/qdeveloper-ug/images/q-mcp-registry-add-server.png)


 Registry MCP server parameters (URL, package identifier, runtimeArguments, and so forth) are read-only. However, users can: 

1. Adjust MCP tool permissions (“Ask to run”, “Always run”, or “Deny”).

1. Select MCP server scope (Global or Workspace).

1. Change the request timeout.

1. Specify additional environment variables for local MCP servers.

1. Specify additional HTTP headers for remote MCP servers.

**Note**  
 User-specified environment variables or HTTP headers override registry definitions. This allows users to specify attributes specific to their setup, such as authentication keys or local folder paths. 

### MCP registry JSON schema
<a name="registry-schema"></a>

 The following JSON schema defines the MCP registry file format supported by Q Developer. You can use this schema to validate any registry files that you create. 

```
{
  "$schema": "https://json-schema.org/draft-07/schema",
  "properties": {
    "servers": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "server": {
            "$ref": "#/definitions/ServerDetail"
          }
        },
        "required": [
          "server"
        ]
      }
    }
  },
  "definitions": {
    "ServerDetail": {
      "properties": {
        "name": {
          "description": "Server name. Must be unique within a given registry file.",
          "example": "weather-mcp",
          "maxLength": 200,
          "minLength": 3,
          "pattern": "^[a-zA-Z0-9._-]+$",
          "type": "string"
        },
        "title": {
          "description": "Optional human-readable title or display name for the MCP server. MCP subregistries or clients MAY choose to use this for display purposes.",
          "example": "Weather API",
          "maxLength": 100,
          "minLength": 1,
          "type": "string"
        },
        "description": {
          "description": "Clear human-readable explanation of server functionality. Should focus on capabilities, not implementation details.",
          "example": "MCP server providing weather data and forecasts via OpenWeatherMap API",
          "maxLength": 100,
          "minLength": 1,
          "type": "string"
        },
        "version": {
          "description": "Version string for this server. SHOULD follow semantic versioning (e.g., '1.0.2', '2.1.0-alpha'). Equivalent of Implementation.version in MCP specification. Non-semantic versions are allowed but may not sort predictably. Version ranges are rejected (e.g., '^1.2.3', '~1.2.3', '\u003e=1.2.3', '1.x', '1.*').",
          "example": "1.0.2",
          "maxLength": 255,
          "type": "string"
        },
        "packages": {
          "items": {
            "$ref": "#/definitions/Package"
          },
          "type": "array",
          "minItems": 0,
          "maxItems": 1
        },
        "remotes": {
          "items": {
            "anyOf": [
              {
                "$ref": "#/definitions/StreamableHttpTransport"
              },
              {
                "$ref": "#/definitions/SseTransport"
              }
            ]
          },
          "type": "array",
          "minItems": 0,
          "maxItems": 1
        }
      },
      "required": [
        "name",
        "description",
        "version"
      ],
      "type": "object"
    },
    "Package": {
      "properties": {
        "registryType": {
          "description": "Registry type indicating how to download packages (e.g., 'npm', 'pypi', 'oci')",
          "enum": [
            "npm",
            "pypi",
            "oci"
          ],
          "type": "string"
        },
        "registryBaseUrl": {
          "description": "Base URL of the package registry",
          "examples": [
            "https://registry.npmjs.org",
            "https://pypi.org",
            "https://docker.io"
          ],
          "format": "uri",
          "type": "string"
        },
        "identifier": {
          "description": "Package identifier - either a package name (for registries) or URL (for direct downloads)",
          "examples": [
            "@modelcontextprotocol/server-brave-search",
            "https://github.com/example/releases/download/v1.0.0/package.mcpb"
          ],
          "type": "string"
        },
        "transport": {
          "anyOf": [
            {
              "$ref": "#/definitions/StdioTransport"
            },
            {
              "$ref": "#/definitions/StreamableHttpTransport"
            },
            {
              "$ref": "#/definitions/SseTransport"
            }
          ],
          "description": "Transport protocol configuration for the package"
        },

        "runtimeArguments": {
          "description": "A list of arguments to be passed to the package's runtime command (such as docker or npx).",
          "items": {
            "$ref": "#/definitions/PositionalArgument"
          },
          "type": "array"
        },
        "packageArguments": {
          "description": "A list of arguments to be passed to the package's binary.",
          "items": {
            "$ref": "#/definitions/PositionalArgument"
          },
          "type": "array"
        },
        "environmentVariables": {
          "description": "A mapping of environment variables to be set when running the package.",
          "items": {
            "$ref": "#/definitions/KeyValueInput"
          },
          "type": "array"
        }
      },
      "required": [
        "registryType",
        "identifier",
        "transport"
      ],
      "type": "object"
    },
    "StdioTransport": {
      "properties": {
        "type": {
          "description": "Transport type",
          "enum": [
            "stdio"
          ],
          "example": "stdio",
          "type": "string"
        }
      },
      "required": [
        "type"
      ],
      "type": "object"
    },
    "StreamableHttpTransport": {
      "properties": {
        "type": {
          "description": "Transport type",
          "enum": [
            "streamable-http"
          ],
          "example": "streamable-http",
          "type": "string"
        },
        "url": {
          "description": "URL template for the streamable-http transport. Variables in {curly_braces} reference argument valueHints, argument names, or environment variable names. After variable substitution, this should produce a valid URI.",
          "example": "https://api.example.com/mcp",
          "type": "string"
        },
        "headers": {
          "description": "HTTP headers to include",
          "items": {
            "$ref": "#/definitions/KeyValueInput"
          },
          "type": "array"
        }
      },
      "required": [
        "type",
        "url"
      ],
      "type": "object"
    },
    "SseTransport": {
      "properties": {
        "type": {
          "description": "Transport type",
          "enum": [
            "sse"
          ],
          "example": "sse",
          "type": "string"
        },
        "url": {
          "description": "Server-Sent Events endpoint URL",
          "example": "https://mcp-fs.example.com/sse",
          "format": "uri",
          "type": "string"
        },
        "headers": {
          "description": "HTTP headers to include",
          "items": {
            "$ref": "#/definitions/KeyValueInput"
          },
          "type": "array"
        }
      },
      "required": [
        "type",
        "url"
      ],
      "type": "object"
    },
    "PositionalArgument": {
      "properties": {
        "type": {
          "enum": [
            "positional"
          ],
          "example": "positional",
          "type": "string"
        },
        "value": {
          "description": "The value for the input.",
          "type": "string"
        }
      },
      "required": [
        "type",
        "value"
      ],
      "type": "object"
    },
    "KeyValueInput": {
      "properties": {
        "name": {
          "description": "Name of the header or environment variable.",
          "example": "SOME_VARIABLE",
          "type": "string"
        },
        "value": {
          "description": "The value for the input.",
          "type": "string"
        }
      },
      "required": [
        "name"
      ],
      "type": "object"
    }
  },
  "required": [
    "servers"
  ],
  "type": "object"
}
```