Model Context Protocol

NervesCloud MCP

Connect an MCP-aware client (Claude Code, Claude Desktop, a claude.ai connector, or any other host) to inspect and manage your NervesCloud device fleet. Every action is performed as you, limited to your existing organization permissions.

Endpoint

Streamable HTTP
https://mcp.nervescloud.com/mcp

Connecting

claude.ai / Desktop

Add a custom connector for the endpoint. You'll sign in to NervesCloud and approve the connection once, over OAuth.

Claude Code & API tokens

Send a NervesCloud personal API token as a bearer credential:

Authorization: Bearer nhu_…

MCP Inspector

Pick the Streamable HTTP transport and enter the endpoint URL to explore the tools interactively.

Tools

Every tool resolves your credential to a Nerves Cloud user and enforces that user's organization role. Read-only tools require the view role, actions that change device state require manage.

Tool Role Description
whoami any The Nerves Cloud user your credential resolves to.
list_orgs any The organizations you belong to.
list_products view The products in an organization.
get_product_summary view Fleet summary: device counts, connected vs disconnected, firmware spread.
list_devices view Devices in a product (paginated, with filters).
get_device view Full detail for a single device.
get_device_health view Connection status, latest health report, and metrics.
get_device_activity view Recent activity from a device's audit log.
get_device_logs view Device log lines (requires analytics to be enabled).
list_firmware view Firmware available for a product.
list_deployment_groups view Deployment groups and their match conditions.
list_scripts view Support scripts defined for a product.
set_device_tags manage Replaces a device's tags.
reboot_device manage Requests a reboot of a connected device.
reconnect_device manage Drops a device's socket to force it to reconnect.
upgrade_device manage Pushes a specific firmware (by UUID) as a one-off update.
run_script manage Runs a support script on a connected device and returns its output.
clear_penalty_box manage Removes a device from the update penalty box.

OAuth discovery

This server is a full OAuth 2.1 authorization server. Clients discover the flow from these public metadata endpoints (RFC 9728 / RFC 8414):