get_redirection_host
Retrieve configuration details for a specific redirection host by its ID to manage web traffic routing in Nginx Proxy Manager.
Instructions
Get a specific redirection host by ID
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| host_id | Yes | The ID of the redirection host |
Implementation Reference
- src/npm_mcp/client.py:242-245 (handler)The client implementation that makes the HTTP request to the Nginx Proxy Manager API to fetch a redirection host.
async def get_redirection_host(self, host_id: int) -> RedirectionHost: host_id = _validate_int_id(host_id, "host_id") response = await self._request("GET", f"/api/nginx/redirection-hosts/{host_id}") return RedirectionHost(**response.json()) - src/npm_mcp/server.py:388-389 (handler)The server handler that receives the MCP tool call for 'get_redirection_host' and invokes the client method.
elif name == "get_redirection_host": return _model_response(await npm_client.get_redirection_host(arguments["host_id"])) - src/npm_mcp/server.py:81-87 (registration)Registration of the 'get_redirection_host' tool in the server's tools list.
Tool(name="get_redirection_host", description="Get a specific redirection host by ID", inputSchema=_id_schema("host_id", "The ID of the redirection host")), Tool( name="create_redirection_host", description="Create a new redirection host (HTTP redirect)", inputSchema={ "type": "object", "properties": {