Skip to main content

Nife.io MCP Server

PyPI version npm version Python License: MIT Downloads Code style: black

A Model Context Protocol (MCP) server that interfaces with the Nife.io GraphQL API

Installation β€’ Quick Start β€’ Documentation β€’ Contributing


Overview​

The Nife.io MCP Server provides a standardized interface for interacting with the Nife.io GraphQL API through the Model Context Protocol. It enables seamless usage within Claude Desktop and other MCP-compatible clients, ensuring a consistent, secure, and efficient integration experience.

Key Features​

  • Intelligent GraphQL schema discovery and adaptation
  • Dynamic MCP tool generation based on schema
  • Minimal configuration and fast setup
  • Secure authentication using bearer tokens
  • Installable via PyPI, NPM, or directly from source
  • Compatible with macOS, Linux, and Windows
  • Production-grade error handling and logging

Installation​

pip install nife-mcp-server
npx @nifelabs/mcp-server

Option 3: Install From Source​

git clone https://github.com/nife-io/nife-mcp-server.git
cd nife-mcp-server
pip install -r requirements.txt

Quick Start​

1. Obtain Your Access Token​

nifectl auth login
nifectl auth token

2. Configure Claude Desktop​

{
"mcpServers": {
"nife": {
"command": "npx",
"args": ["-y", "@nife/mcp-server"],
"env": {
"NIFE_ACCESS_TOKEN": "your_token_here"
}
}
}
}

3. Restart Claude Desktop​

Your Nife.io MCP integration will now be active.

Usage​

Starting the Server​

# Installed via pip
nife-mcp-server

# Running from source
python -m nife_mcp_server.intelligent_main

The server will start on:
http://0.0.0.0:5000

Environment Variables​

  • NIFE_ACCESS_TOKEN – Required authentication token
  • NIFE_API_ENDPOINT – Optional custom GraphQL endpoint

Example Prompts for Claude​

List all my applications in Nife.io
Show the status of my deployments
Create a new application named "my-app"

Architecture​

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Claude Desktop β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚ MCP Protocol
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Nife MCP Serverβ”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜
β”‚ GraphQL
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Nife.io API β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Core Components​

  • Schema Manager
  • MCP Tool Generator
  • Query Builder
  • Authentication Layer

API Endpoints​

MCP Endpoints​

EndpointMethodDescription
/api/mcp/contextGETRetrieve model context
/api/mcp/contextPOSTUpdate model context
/api/mcp/schemaGETRetrieve GraphQL schema
/api/mcp/queryPOSTExecute custom query
/api/mcp/healthGETHealth check

GraphQL Capabilities​

  • Query all supported resource types
  • Execute mutations for resource management
  • Run custom queries
  • Perform schema introspection

Development​

Local Development Setup​

git clone https://github.com/nife-io/nife-mcp-server.git
cd nife-mcp-server

python -m venv .venv
source .venv/bin/activate # Windows: .venv\Scripts\activate

pip install -r requirements.txt
pip install -e .
python -m nife_mcp_server.intelligent_main

Project Structure​

nife-mcp-server/
β”œβ”€β”€ src/
β”‚ └── nife_mcp_server/
β”‚ β”œβ”€β”€ intelligent_main.py
β”‚ β”œβ”€β”€ schema_manager.py
β”‚ └── routes/
β”‚ └── mcp.py
β”œβ”€β”€ tests/
β”œβ”€β”€ docs/
└── bin/

Running Tests​

pytest
pytest --cov=nife_mcp_server

Support​


Made by the Nife.io team

Website β€’ Documentation β€’ Blog

  • 🌐 nife.io β€” Nife edge cloud platform
  • πŸš€ Launch Dashboard β€” Access your Nife platform
  • πŸ“¦ OpenHub β€” Deploy open source apps in one click