n8n can be used to build automation workflows with AI agents and external tools. When your n8n environment supports MCP clients with OAuth 2.0, you can connect it to the Sales Layer MCP Server and let an AI Agent use Sales Layer tools inside a workflow.
This article explains when to use the Sales Layer MCP Server in n8n, how to configure the connection, and when it is better to use the Sales Layer REST API directly instead.
Note: Do not use the Sales Layer Catalog Token as a direct bearer token against https://mcp.saleslayer.com. Remote MCP connections use OAuth 2.0. If your n8n setup cannot complete an OAuth flow for MCP, use the Sales Layer REST API directly instead
When to use MCP in n8n
Use the Sales Layer MCP Server in n8n when your workflow includes an AI Agent that needs to decide which Sales Layer tool to call based on the user request or workflow context.
Typical MCP use cases in n8n include:
- Letting an AI Agent search or inspect Sales Layer catalog data.
- Building catalog quality checks where the agent decides what to review.
- Creating workflows where Sales Layer tools are one step in a larger AI process.
- Combining catalog information with other systems already connected to n8n.
If your workflow only needs to call a fixed Sales Layer endpoint, such as retrieving products or updating a specific field, the Sales Layer REST API is usually simpler and more predictable.
MCP Server or REST API?
Before configuring n8n, decide whether your workflow needs MCP tools or direct REST API calls.
| Use case | Recommended option | Why |
|---|---|---|
| An AI Agent needs to choose between Sales Layer tools | Sales Layer MCP Server | MCP exposes tools that the agent can call depending on the task. |
| A workflow needs to call a fixed endpoint | Sales Layer REST API | REST API calls are simpler for deterministic automations. |
| The workflow must run fully headless without user authorization | Sales Layer REST API | Remote MCP authentication uses OAuth and may require an interactive authorization flow. |
| n8n does not support MCP OAuth in your version | Sales Layer REST API | The Catalog Token cannot be used as a direct bearer token for remote MCP. |
Before you start
Before connecting n8n to the Sales Layer MCP Server, make sure you have:
- Access to an n8n environment where MCP client nodes or MCP Client Tool nodes are available.
- An n8n workflow with an AI Agent if you want the agent to use Sales Layer tools.
- A Sales Layer account with access to the catalog you want to use.
- Your Sales Layer Catalog Token.
- A version of n8n that can complete OAuth 2.0 authentication for MCP connections.
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.
Note: In n8n, do not configure the MCP Server as a regular HTTP Request node with Authorization: Bearer your_catalog_token. That is not the remote MCP authentication flow.
Choose the access mode
Use the access mode that matches what your n8n workflow needs to do with Sales Layer.
| Mode | Server URL | Use it when |
|---|---|---|
| Default remote connection | https://mcp.saleslayer.com/mcp | You want to use the standard Sales Layer MCP endpoint. |
| Read-only | https://mcp.saleslayer.com/onlyread/mcp | The workflow only needs to query, inspect, or analyze catalog data. |
| Full access | https://mcp.saleslayer.com/full/mcp | The workflow needs to create or update Sales Layer data through MCP tools. |
For most n8n AI workflows, start with Read-only. Use Full access only for trusted workflows where the agent is expected to modify catalog data.
Option 1: Use the MCP Client Tool with an AI Agent
Use this option when your n8n workflow has an AI Agent and you want the agent to call Sales Layer tools.
- Open your n8n workflow.
- Add or open the AI Agent node.
- Add an MCP Client Tool to the agent tools section.
- In the MCP Client Tool, set the server or endpoint URL to the Sales Layer MCP Server URL.
- Select OAuth 2.0 as the authentication method if n8n asks for authentication.
- Use Dynamic discovery if your n8n version supports it.
- Save the credentials and start the authorization flow.
- When the Sales Layer authorization screen opens, enter your Sales Layer Catalog Token.
Use this URL for the standard remote setup:
https://mcp.saleslayer.com/mcp
Option 2: Use an MCP Client as a workflow step
Use this option when you want the workflow to call a specific MCP tool as part of a defined automation sequence, rather than letting an AI Agent decide when to call it.
- Open your n8n workflow.
- Add an MCP Client node if it is available in your n8n version.
- Set the server or endpoint URL to the Sales Layer MCP Server URL.
- Configure OAuth 2.0 authentication.
- Complete the Sales Layer authorization flow with your Catalog Token.
- Select the Sales Layer MCP tool that the workflow should run.
- Map the input values from previous workflow nodes.
- Run a test execution.
Manual OAuth reference values
If n8n asks for manual OAuth 2.0 values and does not support Dynamic discovery, use these reference endpoints:
| Field | Value |
|---|---|
| Authorization URL | https://mcp.saleslayer.com/oauth/authorize |
| Token URL | https://mcp.saleslayer.com/oauth/token |
| Discovery URL | https://mcp.saleslayer.com/.well-known/oauth-authorization-server |
| Grant type | Authorization Code with PKCE |
| Code challenge method | S256 |
Note: If your n8n version does not support Authorization Code with PKCE and S256 for this connection, it may not be compatible with the remote Sales Layer MCP Server.
Complete the Sales Layer authorization flow
When n8n starts the OAuth flow, a Sales Layer authorization screen should open in your browser.
- Wait for the Sales Layer authorization screen to open.
- Select the access profile if the screen asks you to choose one.
- Enter your Sales Layer Catalog Token.
- Validate the token and continue.
- Return to n8n when the authorization flow is complete.
- Save the credentials or node configuration.
Test the MCP connection
After the MCP connection is configured, run a simple test before using it in a production workflow.
For an AI Agent workflow, use a prompt such as:
What Sales Layer tools are available?
Then test with a catalog-related prompt:
Show me a summary of my Sales Layer catalog.
If the connection is working, the AI Agent should be able to call the Sales Layer MCP tools and return information from your catalog.
Alternative: use the Sales Layer REST API directly
If your n8n workflow does not need MCP tools, or if your n8n version cannot complete the OAuth flow for remote MCP, use the Sales Layer REST API directly.
Troubleshooting
| Issue | Likely cause | What to do |
|---|---|---|
| MCP Client Tool is not available | Your n8n version may not include MCP client nodes or the feature may not be enabled. | Check your n8n version and available AI nodes. Use the REST API option if MCP is not available. |
| invalid_token | The Catalog Token was used as a direct bearer token against the MCP Server. | Use OAuth 2.0 for remote MCP. Enter the Catalog Token only in the Sales Layer authorization screen. |
| 401 Unauthorized | n8n is not sending a valid OAuth access token, or the OAuth flow did not complete. | Reconnect the MCP credentials and complete the Sales Layer authorization flow again. |
| Authorization window does not open | Popups may be blocked, or the n8n environment may not support the required OAuth flow. | Allow popups and redirects. If the flow still fails, use the REST API option. |
| PKCE or S256 is not available | The OAuth configuration in your n8n version may not support the required security method. | Use a compatible MCP client or use the Sales Layer REST API directly. |
| The AI Agent does not call Sales Layer tools | The MCP Client Tool may not be connected to the agent, or the prompt does not require Sales Layer data. | Check the agent tools section and test with a direct prompt such as: What Sales Layer tools are available? |
| Read operations work, but updates fail | The connection is using read-only access. | Use full access only if the workflow must update Sales Layer data and your organization allows it. |
Best practices
Use MCP when an AI Agent needs to reason over available Sales Layer tools. Use the REST API when the workflow should run a fixed, predictable API call.
Start with read-only access when the workflow only needs to query or analyze data. Use full access only for controlled workflows that are expected to modify catalog information.
Keep your Catalog Token secure. Do not paste it into screenshots, shared workflow exports, public templates, or support tickets.
Test MCP workflows manually before enabling scheduled or production executions. For workflows that can modify data, include approval or review steps before write actions are executed.
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article