Skip to main content
Glama
OctopusDeploy

Octopus Deploy MCP Server

Official

get_missing_tenant_variables

Identify tenant variables with missing values in Octopus Deploy. Filter by tenant, project, or environment to locate configuration gaps.

Instructions

Get missing tenant variables

This tool retrieves tenant variables that are missing values. Optionally filter by tenant, project, or environment.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
spaceNameYesThe space name
tenantIdNoFilter by specific tenant ID
projectIdNoFilter by specific project ID
environmentIdNoFilter by specific environment ID
includeDetailsNoInclude detailed information about missing variables

Implementation Reference

  • The handler function that implements the core logic of the 'get_missing_tenant_variables' tool. It creates an Octopus Deploy client, fetches missing tenant variables using TenantRepository, and returns the results as JSON in markdown content.
    async ({ spaceName, tenantId, projectId, environmentId, includeDetails = false }) => { const configuration = getClientConfigurationFromEnvironment(); const client = await Client.create(configuration); const tenantRepository = new TenantRepository(client, spaceName); const filterOptions = { tenantId, projectId, environmentId }; const missingVariables = await tenantRepository.missingVariables(filterOptions, includeDetails); return { content: [ { type: "text", text: JSON.stringify({ filters: filterOptions, includeDetails, missingVariables }), }, ], }; }
  • Zod schema defining the input parameters for the tool, including required spaceName and optional filters.
    { spaceName: z.string().describe("The space name"), tenantId: z.string().optional().describe("Filter by specific tenant ID"), projectId: z.string().optional().describe("Filter by specific project ID"), environmentId: z.string().optional().describe("Filter by specific environment ID"), includeDetails: z.boolean().optional().describe("Include detailed information about missing variables") },
  • Registers the tool in the TOOL_REGISTRY, specifying its name, toolset, read-only status, and the function to register it on the MCP server.
    registerToolDefinition({ toolName: "get_missing_tenant_variables", config: { toolset: "tenants", readOnly: true }, registerFn: registerGetMissingTenantVariablesTool, });
  • The registration function that calls server.tool() to register the tool on the MCP server, including name, description, schema, output hints, and handler.
    export function registerGetMissingTenantVariablesTool(server: McpServer) { server.tool( "get_missing_tenant_variables", `Get missing tenant variables This tool retrieves tenant variables that are missing values. Optionally filter by tenant, project, or environment.`, { spaceName: z.string().describe("The space name"), tenantId: z.string().optional().describe("Filter by specific tenant ID"), projectId: z.string().optional().describe("Filter by specific project ID"), environmentId: z.string().optional().describe("Filter by specific environment ID"), includeDetails: z.boolean().optional().describe("Include detailed information about missing variables") }, { title: "Get missing tenant variables from Octopus Deploy", readOnlyHint: true, }, async ({ spaceName, tenantId, projectId, environmentId, includeDetails = false }) => { const configuration = getClientConfigurationFromEnvironment(); const client = await Client.create(configuration); const tenantRepository = new TenantRepository(client, spaceName); const filterOptions = { tenantId, projectId, environmentId }; const missingVariables = await tenantRepository.missingVariables(filterOptions, includeDetails); return { content: [ { type: "text", text: JSON.stringify({ filters: filterOptions, includeDetails, missingVariables }), }, ], }; } ); }
  • Top-level function that registers all enabled tools by calling their individual registerFn, including get_missing_tenant_variables if enabled.
    export function registerTools(server: McpServer, config: ToolsetConfig = {}) { // Iterate through all registered tools and register those that are enabled for (const [, toolRegistration] of TOOL_REGISTRY) { if (isToolEnabled(toolRegistration, config)) { toolRegistration.registerFn(server); } } }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/OctopusDeploy/mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server