Skip to main content
Glama
OctopusDeploy

Octopus Deploy MCP Server

Official

List all projects in an Octopus Deploy space

list_projects
Read-onlyIdempotent

Retrieve all projects in a specified Octopus Deploy space, with optional filtering by partial name.

Instructions

This tool lists all projects in a given space. Projects let you manage software applications and services, each with their own deployment process, lifecycles, and variables. Projects are where you define what you are deploying and how it should be deployed. The space name is required, if you can't find the space name, ask the user directly for the name of the space. Optionally filter by partial name match using partialName parameter.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
spaceNameYes
partialNameNo
skipNo
takeNo

Implementation Reference

  • The main handler function for the list_projects tool. Creates an Octopus API client, calls projectRepository.list() with optional partialName/skip/take filters, maps response items to a concise JSON structure, and handles errors via handleOctopusApiError.
        async ({ spaceName, partialName, skip, take }) => {
          try {
            const configuration = getClientConfigurationFromEnvironment();
            const client = await Client.create(configuration);
            const projectRepository = new ProjectRepository(client, spaceName);
    
            const projectsResponse = await projectRepository.list({
              partialName,
              skip,
              take,
            });
    
            if (projectsResponse.Items.length === 0) {
              const message = partialName
                ? `No projects found matching '${partialName}' in space '${spaceName}'. Project names are case-sensitive.`
                : `No projects found in space '${spaceName}'. This space may be empty or you may not have permission to view projects.`;
    
              return {
                content: [
                  {
                    type: "text",
                    text: message,
                  },
                ],
              };
            }
    
            return {
              content: [
                {
                  type: "text",
                  text: JSON.stringify({
                    totalResults: projectsResponse.TotalResults,
                    itemsPerPage: projectsResponse.ItemsPerPage,
                    numberOfPages: projectsResponse.NumberOfPages,
                    lastPageNumber: projectsResponse.LastPageNumber,
                    items: projectsResponse.Items.map((project: Project) => ({
                      spaceId: project.SpaceId,
                      id: project.Id,
                      name: project.Name,
                      description: project.Description,
                      slug: project.Slug,
                      deploymentProcessId: project.DeploymentProcessId,
                      lifecycleId: project.LifecycleId,
                      isDisabled: project.IsDisabled,
                      repositoryUrl:
                        project.PersistenceSettings.Type === "VersionControlled"
                          ? project.PersistenceSettings.Url
                          : null,
                    })),
                  }),
                },
              ],
            };
          } catch (error) {
            handleOctopusApiError(error, { spaceName });
          }
        },
      );
    }
  • Input schema (Zod) for list_projects: requires spaceName (string), optional partialName (string), skip (number), take (number).
    inputSchema: {
      spaceName: z.string(),
      partialName: z.string().optional(),
      skip: z.number().optional(),
      take: z.number().optional(),
    },
  • registerListProjectsTool function that registers the tool with MCP server via server.registerTool('list_projects', ...).
    export function registerListProjectsTool(server: McpServer) {
      server.registerTool(
        "list_projects",
  • Self-registration call to registerToolDefinition, adding list_projects to the global TOOL_REGISTRY map with toolset 'projects' and readOnly: true.
    registerToolDefinition({
      toolName: "list_projects",
      config: { toolset: "projects", readOnly: true },
      registerFn: registerListProjectsTool,
    });
  • Import of './listProjects.js' in src/tools/index.ts triggers the self-registration side-effect when the module is loaded.
    import "./listProjects.js";
    import "./listEnvironments.js";
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true and destructiveHint=false, so the agent knows it's safe. The description adds that it lists all projects but does not disclose pagination behavior despite the presence of skip/take parameters in the schema. No contradictions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is four sentences, front-loaded with the main purpose, and concise. It could be slightly more structured but is generally effective with no wasted words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool has 4 parameters and no output schema. The description explains what projects are but does not mention return format or pagination details. For a list tool, this is a notable omission, making it moderately complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema has 0% description coverage, so the description must compensate. It explains spaceName and partialName well, but does not describe skip and take (pagination parameters). Thus, it adds partial value but leaves gaps.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'lists' and resource 'projects in a given space', with additional context that projects manage software deployments. It distinguishes from sibling tools like 'create_release' or 'deploy_release' by focusing on listing rather than creating or deploying.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly states the required parameter 'spaceName' and provides guidance to ask the user if not found. It also mentions optional partial name filter. However, it does not explicitly state when not to use or alternative tools, but the context is clear enough for an AI agent.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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