Xano MCP server

Integrates with Xano's no-code backend platform to enable data querying, manipulation, and CRUD operations for rapid application development and prototyping.
Back to servers
Setup instructions
Provider
SarimSiddd
Release date
Jan 18, 2025
Language
TypeScript

The Xano MCP Server is an implementation of the Model Context Protocol for interacting with the Xano API, enabling you to manage Xano database operations through a standardized interface. It provides secure authentication and type-safe interactions with your Xano data.

Installation

To get started with the Xano MCP Server:

# Clone the repository
git clone [your-repo-url]
cd xano_mcp

# Install dependencies
npm install

Configuration

Setting up your environment variables:

# Copy the example environment file
cp .env.example .env

Edit the .env file with your Xano credentials:

XANO_API_KEY=your_api_key_here
XANO_API_URL=your_xano_api_url
NODE_ENV=development
API_TIMEOUT=10000

Environment Variables

Variable Description Required Default
XANO_API_KEY Your Xano API authentication key Yes -
XANO_API_URL Xano API endpoint URL Yes -
NODE_ENV Environment (development/production) No development
API_TIMEOUT API request timeout in milliseconds No 10000

Running the Server

Start the MCP server:

# Build the project
npm run build

# Start the server
npm start

# Alternatively, run in development mode
npm run dev

Available MCP Tools

Workspace Tools

  • get_workspaces: List all available workspaces

Table Tools

  • create_table: Create a new table in a workspace
  • get_table_content: Get content from a table with pagination support
  • add_table_content: Add new content to a table
  • update_table_content: Update existing content in a table
  • get_all_tables: List all tables in a workspace with detailed information

Usage Examples

Working with Workspaces

To list all available workspaces:

// List available workspaces
const result = await mcp.use_tool("get_workspaces", {});
console.log('Workspaces:', result);

Managing Tables

Creating and working with tables:

// Create a new table
const createResult = await mcp.use_tool("create_table", {
  workspaceId: 123,
  name: "MyTable"
});

// Add content to a table
const addResult = await mcp.use_tool("add_table_content", {
  workspaceId: 123,
  tableId: 456,
  content: {
    created_at: "2024-01-22T17:07:00.000Z"
  }
});

// Get table content with pagination
const getResult = await mcp.use_tool("get_table_content", {
  workspaceId: 123,
  tableId: 456,
  pagination: {
    page: 1,
    items: 50
  }
});

// Update table content
const updateResult = await mcp.use_tool("update_table_content", {
  workspaceId: 123,
  tableId: 456,
  contentId: "789",
  content: {
    created_at: "2024-01-22T17:07:00.000Z"
  }
});

Listing Tables

Get information about all tables in a workspace:

// List all tables in a workspace
const tables = await mcp.use_tool("get_all_tables", {
  workspaceId: 123
});
console.log('Tables:', tables);

The response will be an array of table objects with details:

[
  {
    id: number,
    name: string,
    description: string,
    created_at: string,
    updated_at: string,
    guid: string,
    auth: boolean,
    tag: string[],
    workspaceId: number
  },
  // More tables...
]

Error Handling

The server provides detailed error messages for various issues that might occur:

  • Invalid parameters
  • Authentication failures
  • API request failures
  • Content validation errors
  • Unknown tool requests

This makes troubleshooting easier when integrating with your application.

How to install this MCP server

For Claude Code

To add this MCP server to Claude Code, run this command in your terminal:

claude mcp add-json "xano" '{"command":"npx","args":["xano_mcp"]}'

See the official Claude Code MCP documentation for more details.

For Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "xano": {
            "command": "npx",
            "args": [
                "xano_mcp"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.

For Claude Desktop

To add this MCP server to Claude Desktop:

1. Find your configuration file:

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

2. Add this to your configuration file:

{
    "mcpServers": {
        "xano": {
            "command": "npx",
            "args": [
                "xano_mcp"
            ]
        }
    }
}

3. Restart Claude Desktop for the changes to take effect

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later