Skip to main content
Glama
akuity
by akuity

create_application

Deploy applications in ArgoCD by specifying metadata, source repository, sync policies, and destination targets to automate and manage Kubernetes deployments.

Instructions

create_application creates application

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
applicationYes

Implementation Reference

  • The core handler logic that executes the HTTP POST request to the ArgoCD API to create a new application.
    public async createApplication(application: V1alpha1Application) { const { body } = await this.client.post<V1alpha1Application, V1alpha1Application>( `/api/v1/applications`, null, application ); return body; }
  • MCP tool registration for 'create_application' using addJsonOutputTool, providing description, input schema, and handler callback that delegates to ArgoCDClient.
    '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) );
  • 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.` ) }) });

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

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