Skip to content

MCP Setup

TeamLoop uses the Model Context Protocol (MCP) to connect with AI assistants like Claude. This guide covers setup for both SaaS and AWS Marketplace deployments.

TeamLoop uses OAuth 2.0 Device Authorization for all MCP connections. There are no API keys — you sign in with your browser on first use, and the token is stored locally and refreshed automatically.

  1. You configure your MCP client with the TeamLoop MCP server
  2. On first use, a browser window opens for sign-in
  3. After authenticating, the token is stored locally
  4. Subsequent sessions reuse the stored token — no repeated sign-in
DeploymentIdentity Provider
SaaSAuth0 (app.teamloop.io)
MarketplaceAWS Cognito (your deployment)

Locate your config file:

PlatformPath
macOS~/Library/Application Support/Claude/claude_desktop_config.json
Windows%APPDATA%\Claude\claude_desktop_config.json
Linux~/.config/claude/claude_desktop_config.json

Add TeamLoop to your mcpServers configuration:

{
"mcpServers": {
"teamloop": {
"command": "npx",
"args": ["-y", "@teamloop/mcp-server"]
}
}
}

Restart Claude Desktop. On first tool use, a browser window opens for sign-in.

Add to your project’s .mcp.json:

{
"mcpServers": {
"teamloop": {
"command": "npx",
"args": ["-y", "@teamloop/mcp-server"]
}
}
}

Then trigger authentication:

Terminal window
claude /mcp

Go to Settings > MCP and add a new server with the same command and args as above.

The server runs via stdio using the npx @teamloop/mcp-server command. Any MCP client that supports stdio transport can use it.

SettingValue
Commandnpx
Args-y, @teamloop/mcp-server
Transportstdio
AuthenticationOAuth 2.0 Device Flow (automatic)
VariableRequiredDescription
TEAMLOOP_API_URLNoCustom API URL (default: https://api.teamloop.io)
TEAMLOOP_LOG_LEVELNoLogging level (debug, info, warn, error)

You can run the MCP server directly:

Terminal window
npx @teamloop/mcp-server

The server communicates via stdin/stdout using newline-delimited JSON-RPC.

Marketplace deployments use OAuth 2.0 with Cognito. Users sign in through the Cognito hosted UI — the same credentials they use for the dashboard. If SAML federation is enabled, corporate SSO works automatically.

Your MCP endpoint URL comes from the CloudFormation stack outputs:

  • With custom domain: https://YOUR_DOMAIN/mcp/
  • Without custom domain: https://ALB_DNS_NAME/mcp/ (from the ALBURL output)

Go to Settings > MCP and add a new server:

{
"mcpServers": {
"teamloop": {
"url": "https://YOUR_DOMAIN/mcp/"
}
}
}

Restart Cursor. On first MCP tool use, a browser window opens for Cognito sign-in.

Terminal window
claude mcp add teamloop --transport http https://YOUR_DOMAIN/mcp/

Then trigger authentication:

Terminal window
claude /mcp

A browser window opens for Cognito sign-in. After authenticating, the token is stored and Claude Code can use TeamLoop tools.

Add to your settings.json:

{
"claude-code.mcpServers": {
"teamloop": {
"url": "https://YOUR_DOMAIN/mcp/"
}
}
}

For any MCP-compatible client that supports HTTP transport:

SettingValue
Server URLhttps://YOUR_DOMAIN/mcp/
TransportHTTP (Streamable)
AuthenticationOAuth 2.0 / Bearer Token

Replace YOUR_DOMAIN with your custom domain or the ALB DNS name from the stack outputs.

After configuration, verify TeamLoop is working:

  1. Start a new conversation in your AI assistant
  2. Ask: “What TeamLoop tools are available?”
  3. The assistant should list the TeamLoop tools (e.g., teamloop_query, teamloop_save_knowledge)

If the tools don’t appear:

  • Check the config file syntax
  • Run npx @teamloop/mcp-server directly to check for errors
  • Enable debug logging (see below)

TeamLoop respects your integration tokens:

  • Only accesses tools you’ve connected
  • Only sees data your API tokens have access to
  • Integration tokens are encrypted at rest using pgcrypto
  • Ensure Node.js 18+ is installed
  • Try running npx @teamloop/mcp-server manually
  • Check network connectivity
  • Ensure your browser can reach the sign-in page
  • For SaaS: check that app.teamloop.io is accessible
  • For Marketplace: check that the Cognito hosted UI domain is accessible

”Unauthorized” After Sign-In (Marketplace)

Section titled “”Unauthorized” After Sign-In (Marketplace)”
  • Verify the user exists in the Cognito User Pool
  • Check that the MCP CLI app client (CognitoMCPClientId in stack outputs) is correctly configured
  • Ensure the callback URL http://localhost:9876/callback is not blocked by a firewall
  • Access tokens expire after 1 hour and refresh automatically
  • If refresh fails, remove the stored token and re-authenticate
  • For Marketplace: check CloudWatch logs at /ecs/STACK_NAME/api for auth errors

Enable debug logs to diagnose issues:

{
"mcpServers": {
"teamloop": {
"command": "npx",
"args": ["-y", "@teamloop/mcp-server"],
"env": {
"TEAMLOOP_LOG_LEVEL": "debug"
}
}
}
}