Connecting Sales Layer MCP Server to VS Code and GitHub Copilot

Modified on Tue, 2 Jun at 12:33 PM


Visual Studio Code can connect to the Sales Layer MCP Server so GitHub Copilot Chat can use Sales Layer tools in Agent mode. This allows technical teams to query and analyze Sales Layer catalog data directly from VS Code while working on integrations, scripts, data checks, or catalog-related development tasks.


This article explains how to add the Sales Layer MCP Server to VS Code, authorize the connection, and use the tools from GitHub Copilot Chat.

i

Note: VS Code and GitHub Copilot features can vary depending on the installed version, extensions, and organization policies. If you do not see MCP options, update VS Code and check whether MCP servers are enabled for your Copilot organization.

Before you start


Before connecting the Sales Layer MCP Server to VS Code, make sure you have:


  • Visual Studio Code installed.
  • GitHub Copilot and GitHub Copilot Chat enabled in VS Code.
  • Access to Copilot Chat Agent mode.
  • Permission to add MCP servers in your VS Code or GitHub organization.
  • Access to the Sales Layer catalog you want to query.
  • Your Sales Layer Catalog Token.


At the moment, the Catalog Token is not obtained from an API/Tokens section inside the Sales Layer PIM. To get it, contact Sales Layer Support or your Sales Layer account representative.

!

Warning: Do not hardcode your Sales Layer Catalog Token in mcp.json or commit it to a repository. For the remote MCP Server, authentication is completed through the Sales Layer authorization flow.
If you save .vscode/mcp.json in a repository, do not include private credentials or token values in the file.

Choose where to save the MCP configuration


VS Code can store MCP server configuration in two places:


LocationUse it whenFile or command
WorkspaceYou want to share the MCP server configuration with a project team..vscode/mcp.json
User profileYou want the MCP server to be available across your VS Code workspaces.MCP: Open User Configuration


For a team project, use the workspace configuration. For personal use, use the user profile configuration.


Add the MCP Server using the Command Palette


The guided setup is the easiest way to add the Sales Layer MCP Server.


  1. Open VS Code.
  2. Open the Command Palette with Cmd+Shift+P on macOS or Ctrl+Shift+P on Windows and Linux.
  3. Run MCP: Add Server.
  4. Choose the HTTP or remote server option if VS Code asks for a server type.
  5. Enter the Sales Layer MCP Server URL.
  6. Enter a server name, for example sales-layer.
  7. Choose whether to save it in your workspace or user profile.
  8. Start or enable the server when VS Code asks you to do so.
  9. Confirm that you trust the MCP server configuration.


Use this URL for the standard remote setup:


https://mcp.saleslayer.com/mcp


Alternative setup with mcp.json


You can also configure the Sales Layer MCP Server manually by editing mcp.json.


For a workspace configuration, create or edit this file:


.vscode/mcp.json


Add the following configuration:


{
  "servers": {
    "sales-layer": {
      "type": "http",
      "url": "https://mcp.saleslayer.com/mcp"
    }
  }
}


After saving the file, VS Code should detect the MCP Server. If it does not start automatically, use the Command Palette and run MCP: List Servers, select sales-layer, and start the server.

Choose the access mode


Use the access mode that matches what you want GitHub Copilot to do with your Sales Layer catalog.


ModeServer URLUse it when
Default remote connectionhttps://mcp.saleslayer.com/mcpYou want to use the standard Sales Layer MCP endpoint.
Read-onlyhttps://mcp.saleslayer.com/onlyread/mcpCopilot only needs to inspect, query, or analyze catalog data.
Full accesshttps://mcp.saleslayer.com/full/mcpCopilot needs to create or update Sales Layer data through MCP tools.


For most first-time setups, start with Read-only. Use Full access only for trusted workflows where Copilot is expected to modify catalog data.


Authorize the Sales Layer connection


When VS Code starts the remote MCP Server, the Sales Layer authorization flow may open in your browser.


  1. Wait for the Sales Layer authorization screen to open.
  2. Select the access profile if the screen asks you to choose one.
  3. Enter your Sales Layer Catalog Token.
  4. Validate the token and continue.
  5. Return to VS Code when the authorization flow is complete.


Use Sales Layer tools in GitHub Copilot Chat


After the MCP Server is connected, use GitHub Copilot Chat in Agent mode.


  1. Open GitHub Copilot Chat in VS Code.
  2. Select Agent mode from the mode dropdown.
  3. Click the tools or Configure Tools icon.
  4. Find the sales-layer MCP server entry.
  5. Review the available Sales Layer tools.
  6. Enable the tools you want Copilot to use.
  7. Ask a Sales Layer catalog question in the chat box.


Test the connection


Start with a simple prompt to confirm that the Sales Layer tools are available:


What Sales Layer tools are available?


Then test with a catalog-related question:


Show me a summary of my Sales Layer catalog.


If the connection is working, Copilot should be able to call the Sales Layer MCP tools and return information from your catalog.


Example prompts


Once the connection is ready, you can ask GitHub Copilot questions such as:


  • Show me the available Sales Layer tools.
  • Find products with missing descriptions.
  • Check whether any products have empty technical attributes.
  • Summarize the catalog structure.
  • Help me inspect the data returned for a specific product reference.
  • Help me design a script that validates product data using Sales Layer catalog information.


Manage or restart the MCP Server


If you need to restart, disable, or inspect the Sales Layer MCP Server, use one of these options:


  • Run MCP: List Servers from the Command Palette.
  • Select the sales-layer server.
  • Choose the action you need, such as start, stop, restart, show output, or disable.
  • You can also edit mcp.json and use the inline actions shown by VS Code.


Troubleshooting


IssueLikely causeWhat to do
MCP commands are not availableYour VS Code version or Copilot extension may not support MCP servers.Update VS Code and GitHub Copilot, then check the Command Palette again.
MCP servers are blocked by organization policyYour Copilot Business or Enterprise organization may not allow MCP servers.Ask your GitHub organization administrator to check the MCP servers policy for Copilot.
Authorization does not openThe OAuth flow did not start, browser popups are blocked, or the server failed to start.Allow browser popups, restart the MCP Server, and check the MCP output logs.
invalid_tokenThe Catalog Token was used as a direct bearer token instead of being entered in the Sales Layer authorization screen.Remove any bearer token configuration and complete the Sales Layer authorization flow again.
No Sales Layer tools appear in Copilot ChatThe server may not be enabled, trusted, or started.Run MCP: List Servers, start the server, confirm trust, and check Configure Tools in Agent mode.
Copilot does not use the Sales Layer toolsAgent mode may not be selected, or the tools may be disabled.Open Copilot Chat, select Agent mode, and enable the Sales Layer tools from Configure Tools.
Read operations work, but updates failThe connection is using read-only access.Use full access only if your workflow requires write actions and your organization allows it.


Best practices


Start with read-only access when you only need Copilot to inspect, query, or analyze catalog data.


Use workspace configuration only when the MCP Server should be shared with the team. Use user configuration when the server is personal to your VS Code profile.


Do not commit credentials or token values to a repository. Keep mcp.json free of private keys and secrets.


After adding or changing the MCP Server, restart it and test it with a simple prompt before using it for real catalog work.


When working in a team or enterprise environment, confirm that your GitHub organization allows MCP servers in Copilot before troubleshooting the Sales Layer configuration.

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article