Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Rexi MCP Servershow me the schema for contract transactions"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Rexi MCP Server
An MCP (Model Context Protocol) server that wraps the Rexi API and exposes tools and resources for AI assistants.
Features
Tools
list_endpoints(tag: Optional[str])– Lists all API endpoints discovered fromdocs/openapi.generated.yaml, optionally filtered by tag.call_rexi(...)– Generic caller for any Rexi API endpoint with full parameter support:method: HTTP method (GET, POST, PUT, PATCH, DELETE, etc.)path: API path (e.g.,/v1/contracts/{contract_address})path_params: Dictionary to substitute{placeholders}in the pathquery: Query parameters as key-value pairsbody: Request body (sent as JSON)extra_headers: Additional HTTP headerstimeout_seconds: Request timeout (default: 30s)
Resources
rexi://openapi– Raw OpenAPI YAML specificationrexi://routes– JSON summary of all methods, paths, summaries, and tagsrexi://schemas– JSON array of available schema filenamesrexi-schemas://{name}– Contents of a specific schema file fromschema/directory
Requirements
Python 3.10+
Dependencies: Install via
pip install -r requirements.txtmcp[cli]– MCP SDK with CLI toolshttpx– Async HTTP clientPyYAML– YAML parser for OpenAPI specpython-dotenv– Environment variable management
Rexi API Key (optional but recommended): Set via
REXI_API_KEYenvironment variable
Environment Setup
Create a .env file in the project root (see .env.example):
REXI_API_KEY=your_api_key_hereEnvironment variables are loaded automatically when the server starts.
Running with the MCP CLI (Inspector)
From the project root:
uv run mcp dev mcp/server.py
# or with pipx / pip if you installed the CLI another way:
# mcp dev mcp/server.pyThis opens the MCP Inspector to interactively test tools and resources.
Install into Claude Desktop (or other hosts)
uv run mcp install mcp/server.py \
-v REXI_API_KEY=your_api_key_hereYou can also pass -f .env to load environment variables from a file.
Configuration
The server determines the base URL from the OpenAPI spec servers[0].url. If not found, it defaults to https://api.rexi.sh.
Auth header:
x-api-keypopulated fromREXI_API_KEYenv var if present.OpenAPI file path:
docs/openapi.generated.yaml.Schema directory:
schema/.
Notes
When calling
call_rexi, supply any requiredpath_paramsto fill placeholders like{contract_address}in thepathyou pass.queryandbodyare sent as query parameters and JSON body respectively.The server validates nothing beyond basic substitution; refer to the schemas under
schema/for expected shapes.All context parameters (
ctx) are automatically injected by FastMCP - you don't need to pass them manually.
Troubleshooting
Import Errors
If you get import errors for mcp, ensure you've installed the dependencies:
pip install -r requirements.txtAPI Key Issues
If API calls fail with authentication errors, verify your REXI_API_KEY is set correctly in your .env file or environment.
Missing OpenAPI/Schema Files
The server gracefully handles missing docs/openapi.generated.yaml and schema/ directory. If these files are missing:
list_endpoints()will return an empty listResources will return appropriate error messages
The server will still start and run
This server cannot be installed
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.