MCP Installation
Step-by-step guides for installing the Rebrandly MCP server on different AI assistants.
Before you begin
You'll need:
- Your Rebrandly API key - See How do I create an API key?
- AI assistant - One of the platforms listed below
- Node.js 20+ (for most platforms) - Download here
Platform availability
Some AI assistants require paid plans to use MCP servers. Check your AI assistant subscription for details. This quick reference reflects availability as of December 14, 2025.
Platforms with free MCP access
| Platform | Complexity | Requirements |
|---|---|---|
| Claude Desktop | Easy (config file) | Claude Desktop, Node.js 20+ |
| Gemini CLI | Easy (one command) | Gemini CLI, Node.js 20+ |
| VS Code + Copilot | Medium (config file) | VS Code 1.102+, Copilot |
| Amazon Q | Medium (config file) | Amazon Q, Node.js 20+ |
Platforms requiring paid plans
| Platform | Complexity | Requirements |
|---|---|---|
| Claude Code | Easy (one command) | Claude Code CLI |
| Cursor | Medium (config file) | Cursor IDE |
For other platforms, we include a generic configuration section.
Choose your platform
Installation guides for each AI assistant platform
Claude Desktop
Setup: JSON configuration file or via Settings UI
Claude Desktop via supergateway proxy.
Requirements
Use the supergateway or mcp-remote proxy to connect Claude Desktop to remote HTTP MCP servers.
Configuration File Location
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
Option 1: Via settings UI (recommended)
-
Open Claude Desktop.
-
Click on your profile icon and then click Settings.
-
Click Developer and then Edit Config. This will open your file finder and select the configuration file—
claude_desktop_config.json. -
Open the file with a text or code editor.
-
Copy these lines and paste them into the configuration file.
{ "mcpServers": { "rebrandly": { "command": "npx", "args": [ "-y", "supergateway", "--streamableHttp", "https://mcp.rebrandly.com/v1/mcp", "--header", "REBRANDLY_API_KEY:YOUR_API_KEY" ] } } } -
Replace
YOUR_API_KEYwith the key you've created in Rebrandly. Note that there is no space before the key. -
Save the file.
Option 2: Edit config file directly
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
(The folder names may vary based on your PC language.)
Add the same configuration shown above.
Alternative proxy: mcp-remote
If supergateway doesn't work, try mcp-remote:
`{
"mcpServers": {
"rebrandly": {
"command": "npx",
"args": [
"mcp-remote",
"https://mcp.rebrandly.com/v1/mcp",
"--header",
"REBRANDLY_API_KEY: YOUR_API_KEY"
]
}
}
}`Note: mcp-remote may have connection stability issues. Use supergateway if you experience disconnections.
Restart Claude Desktop
After editing the configuration, completely quit and restart Claude Desktop for changes to take effect.
Troubleshooting
If the MCP server doesn't appear:
-
Check that Node.js is installed:
node --version -
Check the debug logs:
cat ~/.mcp-auth/*_debug.log -
Test
mcp-remotemanually:npx mcp-remote https://mcp.rebrandly.com/v1/mcp --header "REBRANDLY_API_KEY: YOUR_API_KEY" --debug -
Ensure Claude Desktop is completely restarted (quit from menu bar, not just close window)
Verification
After configuration and restart, verify the connection by asking Claude Desktop:
List my Rebrandly linksGemini CLI
Setup: One-liner command
Gemini CLI provides excellent HTTP transport support with header configuration.
Requirements
- Gemini CLI installed (Installation Guide)
- Node.js 20+ (for npx commands)
Installation
gemini mcp add --scope user --transport http --header "REBRANDLY_API_KEY: YOUR_API_KEY" rebrandly https://mcp.rebrandly.com/v1/mcpReplace YOUR_API_KEY with your actual Rebrandly API key.
Options
--scope user: Makes the server available across all projects (recommended)--scope project: Makes the server available only for the current project--trust: Bypass tool confirmation prompts (use with caution)
Example with Trust
gemini mcp add --scope user --transport http --trust --header "REBRANDLY_API_KEY: YOUR_API_KEY" rebrandly https://mcp.rebrandly.com/v1/mcpManagement Commands
# List configured MCP servers
gemini mcp list
# Remove the server
gemini mcp remove rebrandlyManual Configuration
Alternatively, you can add the configuration directly to ~/.gemini/settings.json:
{
"mcpServers": {
"rebrandly": {
"httpUrl": "https://mcp.rebrandly.com/v1/mcp",
"headers": {
"REBRANDLY_API_KEY": "YOUR_API_KEY"
}
}
}
}Verification
After installation, verify the connection by running Gemini and asking:
List my Rebrandly linksVS Code + GitHub Copilot
Setup: JSON configuration file with stdio proxy
VS Code with GitHub Copilot supports MCP servers starting from VS Code 1.102+. Since Copilot attempts OAuth authentication for HTTP servers, we use mcp-remote as a stdio proxy.
Requirements
- VS Code 1.102 or later (Download)
- GitHub Copilot Chat extension installed and enabled (Marketplace)
- Node.js 20+ (Download) — required for mcp-remote proxy
Configuration File Location
- User-level:
~/.vscode/mcp.json - Workspace-level:
.vscode/mcp.json(in your project root)
Configuration (Recommended)
VS Code Copilot attempts OAuth authentication for direct HTTP connections. Use mcp-remote as a stdio proxy to handle header-based authentication:
{
"servers": {
"rebrandly": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"mcp-remote",
"https://mcp.rebrandly.com/v1/mcp",
"--header",
"REBRANDLY_API_KEY: YOUR_API_KEY"
]
}
}
}Replace YOUR_API_KEY with your actual Rebrandly API key.
Starting the Server
Open Command Palette (Cmd/Ctrl + Shift + P)
Run MCP: List Servers
Click Start next to the Rebrandly server
Using in Copilot Chat
Open Copilot Chat (click the icon in the title bar)
Select Agent from the popup menu
Use #tool_name to invoke specific tools
Troubleshooting If you see OAuth-related errors like "Error populating auth server metadata" or "User did not provide client details":
This means VS Code is trying to use OAuth instead of header authentication
Ensure you're using the stdio configuration with mcp-remote
Restart VS Code after configuration changes
Amazon Q Developer
Setup: JSON configuration file with stdio proxy
Amazon Q Developer supports MCP servers. Since Amazon Q attempts OAuth authentication for direct HTTP connections, we use supergateway as a stdio proxy to handle header-based authentication.
Requirements
- Amazon Q Developer CLI (Installation Guide) OR
- Amazon Q Developer IDE extension for VS Code or JetBrains (VS Code)
- Node.js 20+ (Download) - required for supergateway proxy
Configuration File Locations
- Global:
~/.aws/amazonq/mcp.json - Workspace:
.amazonq/mcp.json
Configuration (Recommended)
Amazon Q attempts OAuth authentication for direct HTTP connections. Use supergateway as a stdio proxy to handle header-based authentication:
Create or edit ~/.aws/amazonq/mcp.json:
{
"mcpServers": {
"rebrandly": {
"command": "npx",
"args": [
"-y",
"supergateway",
"--streamableHttp",
"https://mcp.rebrandly.com/v1/mcp",
"--header",
"REBRANDLY_API_KEY:YOUR_API_KEY"
]
}
}
}Replace YOUR_API_KEY with your actual Rebrandly API key.
Verification
In Amazon Q CLI:
q chat "What Rebrandly tools do you have access to?"Troubleshooting
If you see OAuth-related errors like "Server requires OAuth" or "OAuth client registration failed":
- This means Amazon Q is trying to use OAuth instead of header authentication
- Ensure you're using the stdio configuration with
supergateway(not direct HTTP) - Restart Amazon Q after configuration changes
- Verify Node.js is installed:
node --version
- Verify Node.js is installed:
Claude Code
Setup: One-liner command
Claude Code supports HTTP transport natively, making setup extremely simple.
Requirements
- Claude Code CLI installed (Installation Guide)
Installation at Global level
claude mcp add --transport http -s user rebrandly https://mcp.rebrandly.com/v1/mcp --header "REBRANDLY_API_KEY: YOUR_API_KEY"Installation at folder level
claude mcp add --transport http rebrandly https://mcp.rebrandly.com/v1/mcp --header "REBRANDLY_API_KEY: YOUR_API_KEY"Replace YOUR_API_KEY with your actual Rebrandly API key.
Verification
Start Claude Code by entering claude into your terminal, then ask Claude Code to list your links:
List my Rebrandly linksManagement Commands
# List configured MCP servers
claude mcp list
# Remove the server
claude mcp remove rebrandly
# Update your API key
claude mcp remove rebrandly && claude mcp add --transport http rebrandly https://mcp.rebrandly.com/v1/mcp --header "REBRANDLY_API_KEY: NEW_API_KEY"Cursor
Setup: Via Settings UI (recommended) or JSON configuration file
Cursor supports MCP servers through its settings UI and configuration files.
Requirements
- Cursor IDE installed (Download)
Option 1: Via Cursor Settings UI (Recommended)
The easiest way to configure the Rebrandly MCP server:
-
Open Cursor
-
Go to Settings (Cmd/Ctrl + ,)
-
Navigate to Tools & MCP section
-
Click New MCP Server
-
Cursor will open the
mcp.jsonfile - paste the following configuration:{ "mcpServers": { "rebrandly": { "url": "https://mcp.rebrandly.com/v1/mcp", "headers": { "REBRANDLY_API_KEY": "YOUR_API_KEY" } } } }
Replace YOUR_API_KEY with your actual Rebrandly API key.
Option 2: Edit JSON Configuration File Directly
Alternatively, create or edit ~/.cursor/mcp.json:
{
"mcpServers": {
"rebrandly": {
"url": "https://mcp.rebrandly.com/v1/mcp",
"headers": {
"REBRANDLY_API_KEY": "YOUR_API_KEY"
}
}
}
}Replace YOUR_API_KEY with your actual Rebrandly API key.
Verification
Open Cursor's AI chat and ask:
What Rebrandly tools are available?Other platforms
For other MCP-compatible tools not listed above, use this generic configuration pattern:
HTTP Transport
{
"mcpServers": {
"rebrandly": {
"transport": "http",
"url": "https://mcp.rebrandly.com/v1/mcp",
"headers": {
"REBRANDLY_API_KEY": "YOUR_API_KEY"
}
}
}
}Environment Variables
Many tools support environment variable substitution:
{
"mcpServers": {
"rebrandly": {
"url": "https://mcp.rebrandly.com/v1/mcp",
"headers": {
"REBRANDLY_API_KEY": "${REBRANDLY_API_KEY}"
}
}
}
}Then set the environment variable:
export REBRANDLY_API_KEY="your-api-key"Troubleshooting
Before integrating with your AI agent, or if you're experiencing issues, use these steps to diagnose problems.
Step 1: Test the Endpoint (No API Key Required)
First, verify the MCP server is reachable by listing available tools. This request does not require authentication:
curl -X POST https://mcp.rebrandly.com/v1/mcp \
-H "Content-Type: application/json" \
-d '{"jsonrpc": "2.0", "method": "tools/list", "id": 1}'Expected Successful Response
A successful response will return a JSON object containing available tools:
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"tools": [
{
"name": "rebrandly_create_link",
"description": "Create a new branded short link..."
},
{
"name": "rebrandly_list_links",
"description": "List branded short links..."
}
]
}
}Step 2: Test Your API Key
Once you've confirmed the endpoint is reachable, test your API key by calling a method that requires authentication:
curl -X POST https://mcp.rebrandly.com/v1/mcp \
-H "REBRANDLY_API_KEY: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"jsonrpc": "2.0", "method": "tools/call", "params": {"name": "rebrandly_list_links", "arguments": {}}, "id": 2}'Replace YOUR_API_KEY with your actual Rebrandly API key.
Common Error Responses
401 Unauthorized - Invalid or missing API key:
{
"jsonrpc": "2.0",
"id": 2,
"error": {
"code": -32001,
"message": "Unauthorized"
}
}Solution: Verify your API key is correct in the Rebrandly Dashboard.
Step 3: Test in Your Agent
Once both tests pass, configure your AI agent using the instructions above. Then verify by asking:
What Rebrandly tools are available?or
List my Rebrandly linksYour agent should respond with a list of available tools or your existing links.
Updated about 10 hours ago
