request_certificate
Request Let's Encrypt SSL certificates for domains to secure web traffic through Nginx Proxy Manager.
Instructions
Request a new Let's Encrypt SSL certificate
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| domain_names | Yes | List of domains for the certificate | |
| nice_name | Yes | Friendly name for the certificate |
Implementation Reference
- src/npm_mcp/client.py:176-182 (handler)The implementation of the `request_certificate` tool, which sends a POST request to the NPM API to create a new certificate.
async def request_certificate(self, cert: Certificate) -> Certificate: response = await self._request( "POST", "/api/nginx/certificates", json=cert.model_dump(exclude_none=True, exclude={"id", "created_on", "modified_on"}), ) return Certificate(**response.json()) - src/npm_mcp/server.py:210-222 (registration)The MCP tool registration for `request_certificate`, including its description and input schema.
Tool( name="request_certificate", description="Request a new Let's Encrypt SSL certificate", inputSchema={ "type": "object", "properties": { "domain_names": {"type": "array", "items": {"type": "string"}, "description": "List of domains for the certificate"}, "nice_name": {"type": "string", "description": "Friendly name for the certificate"}, }, "required": ["domain_names", "nice_name"], }, ), Tool(name="delete_certificate", description="Delete an SSL certificate by ID", inputSchema=_id_schema("certificate_id", "The ID of the certificate to delete")), - src/npm_mcp/server.py:462-463 (handler)The tool execution handler in `server.py` that maps the request to `npm_client.request_certificate`.
elif name == "request_certificate": return _model_response(await npm_client.request_certificate(Certificate(**arguments)))