Skip to main content
Glama
argoproj-labs

argocd-mcp

Official

create_application

Deploy applications to Kubernetes clusters by creating ArgoCD application resources with specified source repositories, sync policies, and destination targets.

Instructions

create_application creates a new ArgoCD application in the specified namespace. The application.metadata.namespace field determines where the Application resource will be created (e.g., "argocd", "argocd-apps", or any custom namespace).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
applicationYes

Implementation Reference

  • Core implementation of application creation: performs HTTP POST to ArgoCD API /api/v1/applications with the application manifest.
    public async createApplication(application: V1alpha1Application) {
      const { body } = await this.client.post<V1alpha1Application, V1alpha1Application>(
        `/api/v1/applications`,
        null,
        application
      );
      return body;
    }
  • Zod schema defining the input structure for the 'application' parameter, used for validation in the tool registration.
    export const ApplicationSchema = z.object({
      metadata: z.object({
        name: z.string(),
        namespace: ApplicationNamespaceSchema
      }),
      spec: z.object({
        project: z.string(),
        source: z.object({
          repoURL: z.string(),
          path: z.string(),
          targetRevision: z.string()
        }),
        syncPolicy: z.object({
          syncOptions: z.array(z.string()),
          automated: z.object({
            prune: z.boolean(),
            selfHeal: z.boolean()
          }).optional(),
          retry: z
            .object({
              limit: z.number(),
              backoff: z.object({
                duration: z.string(),
                maxDuration: z.string(),
                factor: z.number()
              })
            })
        }),
        destination: z.object({
          server: z.string().optional(),
          namespace: z.string().optional(),
          name: z.string().optional()
        })
          .refine(
            (data: { server?: string; name?: string }) =>
              (!data.server && !!data.name) || (!!data.server && !data.name),
            {
              message: "Only one of server or name must be specified in destination"
            }
          )
          .describe(
            `The destination of the application.
             Only one of server or name must be specified.`
          )
      })
    });
  • Registers the MCP tool 'create_application' with name, description, input schema {application: ApplicationSchema}, and handler that delegates to ArgoCDClient.createApplication.
    this.addJsonOutputTool(
      'create_application',
      'create_application creates a new ArgoCD application in the specified namespace. The application.metadata.namespace field determines where the Application resource will be created (e.g., "argocd", "argocd-apps", or any custom namespace).',
      { application: ApplicationSchema },
      async ({ application }) =>
        await this.argocdClient.createApplication(application as V1alpha1Application)
    );
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It states this is a creation operation but doesn't mention permissions required, whether it's idempotent, what happens on conflicts, or what the response looks like. For a complex creation tool with nested objects, this leaves significant behavioral gaps unaddressed.

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?

Two clear sentences with zero waste. The first states the core purpose, the second clarifies a key parameter nuance. Well-structured and appropriately sized for the complexity. Could be slightly improved by front-loading more critical information about the tool's behavior.

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

Completeness2/5

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

For a complex creation tool with deeply nested parameters (1 top-level but many nested), no annotations, and no output schema, the description is inadequate. It explains namespace semantics but ignores the overall application structure, required permissions, error handling, and what constitutes a successful creation. Given the sibling tools include various read and update operations, more context is needed.

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

Parameters4/5

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

The description clarifies the namespace parameter semantics, explaining that 'application.metadata.namespace field determines where the Application resource will be created' and provides examples. With 0% schema description coverage and 1 parameter (though deeply nested), this adds meaningful context beyond the bare schema. However, it doesn't explain the overall 'application' object structure or other key fields.

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

Purpose4/5

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

The description clearly states the verb ('creates') and resource ('new ArgoCD application'), specifying it happens 'in the specified namespace'. It distinguishes from siblings like 'update_application' or 'delete_application' by focusing on creation. However, it doesn't explicitly differentiate from 'sync_application' which might also involve application management.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives like 'update_application' or 'sync_application'. It mentions the namespace parameter but doesn't explain prerequisites, error conditions, or typical use cases. No explicit when/when-not statements are present.

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/argoproj-labs/argocd-mcp'

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