Nina_advanced_api_mcp

Provides a local MCP server to expose NINA Advanced API endpoints for AI agents to control astrophotography hardware.
  • python

7

GitHub Stars

python

Language

6 months ago

First Indexed

2 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "padev1-nina_advanced_api_mcp": {
      "command": "uv",
      "args": [
        "run",
        "--with",
        "fastmcp,fastapi,uvicorn,pydantic,aiohttp,requests,python-dotenv",
        "fastmcp",
        "run",
        "path/nina_advanced_mcp.py"
      ],
      "env": {
        "LOG_LEVEL": "INFO",
        "NINA_HOST": "NINA_IP",
        "NINA_PORT": "1888",
        "IMAGE_SAVE_DIR": "~/Desktop/NINA_Images"
      }
    }
  }
}

You can run a local MCP server that exposes NINA Advanced API endpoints to AI agents, enabling automated control of your astrophotography setup. This server acts as a bridge between your NINA software and your MCP-enabled AI clients, translating natural-language or structured commands into actions for cameras, mounts, focusers, and more.

How to use

Connect your MCP client to the Nina Advanced API MCP server you run locally. The server exposes MCP endpoints that let you command equipment, read status, start imaging sequences, and monitor ongoing activities. Use natural-language prompts or structured commands to perform tasks such as connecting equipment, starting a sequence, or querying the current status. Begin by linking your AI agent to the MCP server, ensure the NINA host and port are reachable, and then issue commands like connecting equipment, initiating exposures, or starting a target sequence. The server also provides contextual help and AI-friendly error responses to guide you if something goes wrong.

How to install

Prerequisites you need before installing this MCP server:

  • Python 3.8 or higher

  • NINA software with Advanced API plugin

  • uv package manager

  • An AI agent with MCP support (for example Claude)

Installation steps you will execute:

Install and configure the MCP server locally

  1. Clone the MCP server repository.

  2. Set up environment variables to point to your NINA instance and define logging and image paths.

Configuration and starting the server

The MCP server is run using the uv tool. Include the following configuration to expose the Nina Advanced API MCP endpoint locally. This configuration uses the local host connection and exports the necessary environment variables for NINA.

MCP config snippet

{
  "mcpServers": {
    "nina_advanced_mcp": {
      "command": "uv",
      "args": [
        "run",
        "--with",
        "fastmcp,fastapi,uvicorn,pydantic,aiohttp,requests,python-dotenv",
        "fastmcp",
        "run",
        "path/nina_advanced_mcp.py"
      ],
      "env": {
        "NINA_HOST": "NINA_IP",
        "NINA_PORT": "1888",
        "LOG_LEVEL": "INFO",
        "IMAGE_SAVE_DIR": "~/Desktop/NINA_Images"
      }
    }
  }
}

Run and test

After configuring, start the MCP server and verify connectivity from your MCP client. Ensure the NINA host and port are reachable, then issue a basic command like reading the equipment status or connecting to all devices to confirm the bridge is active.

Notes and tips

  • The server relies on the Advanced API plugin in NINA. Make sure it is installed and configured in NINA.

  • The environment variables control how the server talks to NINA and where it stores captured images. Adjust NINA_HOST, NINA_PORT, LOG_LEVEL, and IMAGE_SAVE_DIR to match your environment.

Security and safety

Limit access to your MCP server to trusted agents and networks. Use strong credentials for your MCP client integrations and monitor logs for any unexpected commands.

Troubleshooting

If commands fail, verify that NINA is reachable at the configured host and port, the Advanced API plugin is active, and the MCP server has the correct environment variables. Check logs to identify errors related to connections, authentication, or missing endpoints.

Notes

This setup enables AI agents to interact with your astrophotography hardware through NINA using the Advanced API, providing a powerful automation layer for imaging workflows.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational