Skip to main content
Version: Next

vela mcp tool reference

This page lists every tool that vela mcp serves, with its inputs and the top-level fields of its result. Agents read the same descriptions and full JSON schemas from the server when they connect, so this page is for people: to see what an agent can do and what it gets back. To set the server up, see AI agents with vela mcp.

Tools come in three classes:

  • Read tools are always registered and never change the cluster.
  • Plan tools render or compare an Application without saving it.
  • Write tools exist only when the server is started with a flag that enables them.
ToolClassSummary
get_platform_inforeadReport the KubeVela versions and configuration this session runs against: vela CLI version, vela-core version and health, Kubernetes server version, enabled feature gates, and any version skew.
list_definitionsreadList the KubeVela definitions (components, traits, policies, workflow steps) available on this cluster, with their type, namespace, version, one-line description, the capability each provides and whether it is the platform default for the namespace.
describe_definitionreadReturn one KubeVela definition's parameter schema as JSON Schema, with required fields, defaults and description, plus its current revision.
list_applicationsreadList KubeVela Applications with phase, health, components, workflow state and whether the recorded status is stale.
get_applicationreadRead one Application live: its declared components, traits, policies and workflow with secret-like values removed, plus the controller's status for every service, the conditions, applied resources and the workflow steps.
get_workflowreadRead an Application's workflow: declared steps, each step's phase, reason, message and timing, which steps are suspended or failed, and the exact vela command that moves it forward.
get_managed_resourcereadRead the objects an Application manages, from its ResourceTrackers, with the live resource tree and health of each (Deployment, ReplicaSet, Pod and so on) in the cluster where it runs.
get_logsreadReturn a bounded, redacted tail of container logs for an Application's pods, found through its managed resources.
explain_definitionreadExplain one KubeVela definition from its live object: what kinds its template produces, which parameters flow into which fields, its parameter schema, health and custom status rules, trait behaviour and restrictions, revision history, and how many Applications use it.
explain_applicationreadExplain an Application end to end: each component with its definition, declared dependencies and data flow, recorded status per cluster, live managed resources with unhealthy descendants and pod phases, workflow state, recent events, and a list of findings ordered by severity, each citing the object it came from.
list_clustersreadList the clusters KubeVela can deploy to, with alias, credential type, endpoint and labels.
list_addonsreadList the addons enabled on this control plane with version, registry, phase, health and the clusters they reach, read from the Applications the addons installed.
dryrun_applicationplanRender an Application document the way vela dry-run does, without saving it: every Kubernetes object each component and trait would produce, plus policy objects.
diff_applicationplanCompare an Application document with what runs: renders both, lists every resource added, modified or removed with the fields that differ, flags placement, policy, component and approval-gate changes, and classifies risk LOW, MEDIUM or HIGH with every rule that fired.
apply_applicationwriteDeliver an Application after diff_application, using the token it returned for the same document.

The meta block​

Every result carries a meta block that says which system the data came from and when it was read.

FieldTypeDescription
featureGatesobjectvela-core feature gates set to a value other than their default. Absent gates are at their defaults; get_platform_info lists every gate set on the controller.
kubernetesobjectKubernetes API server version per cluster name.
observedAtstringWhen the data in this response was read, UTC.
sourcestringlive for an API server read, rendered for dry-run or diff output, cached for served data.
truncatedbooleanTrue when a size or count limit cut the data; narrow the request to see the rest.
velaCLIstringVersion of the vela binary serving this session.
velaCorestringvela-core controller version found on the cluster, or unknown.
warningsarray of stringVersion skew, identity and completeness notes that apply to this response.

get_platform_info​

Read. Always registered.

Report the KubeVela versions and configuration this session runs against: vela CLI version, vela-core version and health, Kubernetes server version, enabled feature gates, and any version skew. Call once per session before other tools so explanations match the running system. Pass the namespace the user is working in to learn how it delivers workloads today, so new work follows that practice.

Input​

FieldTypeRequiredDescription
namespacestringnoNamespace the user is about to work in. When set, the result reports how that namespace delivers workloads today.

Result​

FieldTypeDescription
clusterGatewayobjectWhether cluster-gateway was found and whether it forwards the caller's identity to other clusters.
controllerobjectWhether the vela-core Deployment was found, with its image and ready replicas.
featureGatesobjectFeature gates set on the vela-core controller's --feature-gates flag, with their values.
gitRevisionstringGit revision the vela binary was built from.
kubernetesobjectKubernetes API server version per cluster name.
metaobjectVersions and read time for this result. See the meta block.
practiceobjectHow the namespace delivers workloads today. Follow it: keep existing workloads in their form and match it for new work unless the user asks otherwise.
velaCLIstringVersion of the vela binary serving this session.
velaCorestringvela-core controller version found on the cluster, or unknown.
warningsarray of stringVersion skew and other notes about this platform.

list_definitions​

Read. Always registered.

List the KubeVela definitions (components, traits, policies, workflow steps) available on this cluster, with their type, namespace, version, one-line description, the capability each provides and whether it is the platform default for the namespace. Filter by provides to compare alternatives; when several fit and none is default, ask the user to choose.

Input​

FieldTypeRequiredDescription
namespacestringnoNamespace to list in addition to the system namespace. Empty lists every namespace the caller can read. Also decides which definition is marked default.
providesstringnoKeep definitions that provide this capability, such as postgres, to compare alternatives: those the platform labels with it, and unlabelled ones whose name or description mentions it, which matchedBy marks.
typestringnoLimit to one definition type: component, trait, policy or workflow-step. Empty lists all four.

Result​

FieldTypeDescription
definitionsarray of objectDefinitions sorted by type, namespace and name.
metaobjectVersions and read time for this result. See the meta block.

describe_definition​

Read. Always registered.

Return one KubeVela definition's parameter schema as JSON Schema, with required fields, defaults and description, plus its current revision. Use the returned schema as the only source of parameter names.

Input​

FieldTypeRequiredDescription
namestringyesDefinition name as returned by list_definitions.
namespacestringnoNamespace to look in before the system namespace.
typestringnoDefinition type: component, trait, policy or workflow-step. When empty every type is tried in that order.

Result​

FieldTypeDescription
defaultbooleanTrue when this is the platform default for the namespace in the request. Use it and name the alternatives; when several fit and none is default, ask the user to choose.
defaultForarray of stringNamespaces where the platform made this the default among definitions providing the same capability; * means every namespace.
descriptionstringOne-line description the definition declares.
latestRevisionstringName of the definition's latest DefinitionRevision.
matchedBystringSet by list_definitions when it filters by provides: label when the definition carries the provides label, name or description when it has no label but mentions the capability there. Confirm the latter from its description before relying on it.
metaobjectVersions and read time for this result. See the meta block.
namestringName of the object this result describes.
namespacestringNamespace of the object this result describes.
parametersobjectThe definition's parameters as JSON Schema.
providesstringCapability the platform labels this definition as providing, such as postgres. Definitions with the same value are alternatives.
requiredarray of stringParameter names the definition requires.
typestringDefinition type: component, trait, policy or workflow-step.
versionstringVersion the definition declares, if any.

list_applications​

Read. Always registered.

List KubeVela Applications with phase, health, components, workflow state and whether the recorded status is stale. Namespace narrows the list; the server's namespace restriction always applies.

Input​

FieldTypeRequiredDescription
namespacestringnoNamespace to list. Empty lists every namespace the server allows.

Result​

FieldTypeDescription
applicationsarray of objectApplications the server may read, sorted by namespace and name.
metaobjectVersions and read time for this result. See the meta block.

get_application​

Read. Always registered.

Read one Application live: its declared components, traits, policies and workflow with secret-like values removed, plus the controller's status for every service, the conditions, applied resources and the workflow steps. Use get_managed_resource for the live objects and get_workflow for step detail.

Input​

FieldTypeRequiredDescription
namestringyesApplication name.
namespacestringyesApplication namespace.

Result​

FieldTypeDescription
annotationsobjectApplication annotations. Values that embed a serialized object are dropped.
componentsarray of objectComponents with their types.
createdAtstringWhen the Application was created, UTC.
evidencearray of stringObjects this answer was derived from.
healthybooleanFalse when the phase or a workflow step failed, or when no service has reported status yet.
labelsobjectApplication labels.
metaobjectVersions and read time for this result. See the meta block.
namestringName of the object this result describes.
namespacestringNamespace of the object this result describes.
phasestringApplication phase as the controller recorded it, such as running or runningWorkflow.
revisionstringLatest ApplicationRevision name.
specobjectDeclared components, traits, policies and workflow, with secret-like values removed.
statusobjectStatus as the controller last wrote it: services, conditions, applied resources and workflow.
statusStalebooleanTrue when the controller has not observed the latest spec, so status describes an older generation.
workflowobjectWorkflow progress: mode, phase, and whether it is suspended, terminated or finished.

get_workflow​

Read. Always registered.

Read an Application's workflow: declared steps, each step's phase, reason, message and timing, which steps are suspended or failed, and the exact vela command that moves it forward. The server never resumes.

Input​

FieldTypeRequiredDescription
namestringyesApplication name.
namespacestringyesApplication namespace.

Result​

FieldTypeDescription
applicationstringApplication name.
evidencearray of stringObjects this answer was derived from.
metaobjectVersions and read time for this result. See the meta block.
namespacestringNamespace of the object this result describes.
specobjectWorkflow steps as the Application declares them.
statusobjectEach step's recorded phase, reason, message and timing, and the vela command that moves the workflow forward.

get_managed_resource​

Read. Always registered.

Read the objects an Application manages, from its ResourceTrackers, with the live resource tree and health of each (Deployment, ReplicaSet, Pod and so on) in the cluster where it runs. Narrow by component, cluster, kind and resourceName; a single match also returns the live object. Secrets return metadata only and objects the Application does not manage are refused.

Input​

FieldTypeRequiredDescription
namestringyesApplication name.
namespacestringyesApplication namespace.
clusterstringnoOnly resources in this cluster. Use local for the control plane.
componentstringnoOnly resources created by this component.
kindstringnoOnly resources of this kind, for example Deployment.
resourceNamestringnoOnly the resource with this name. With kind this selects one object and returns its live content.

Result​

FieldTypeDescription
applicationstringApplication name.
evidencearray of stringObjects this answer was derived from.
metaobjectVersions and read time for this result. See the meta block.
namespacestringNamespace of the object this result describes.
resourcesarray of objectManaged objects with cluster, health and the live resource tree. A single match also carries the live object.

get_logs​

Read. Always registered.

Return a bounded, redacted tail of container logs for an Application's pods, found through its managed resources. Narrow by component, cluster, pod and container; use previous for crash loops. Default 200 lines per pod, at most five pods per call.

Input​

FieldTypeRequiredDescription
namestringyesApplication name.
namespacestringyesApplication namespace.
clusterstringnoOnly pods in this cluster. Use local for the control plane.
componentstringnoOnly pods of this component.
containerstringnoContainer name. Empty uses the first container and lists the others.
podstringnoOne pod by name. Empty tails up to five pods.
previousbooleannoRead the previous container instance, for crash loops.
sinceSecondsintegernoOnly lines newer than this many seconds.
tailLinesintegernoLines per pod from the end. Default 200, maximum 2000.

Result​

FieldTypeDescription
applicationstringApplication name.
evidencearray of stringObjects this answer was derived from.
metaobjectVersions and read time for this result. See the meta block.
namespacestringNamespace of the object this result describes.
podsarray of objectOne entry per pod read, with its lines and whether they were cut.

explain_definition​

Read. Always registered.

Explain one KubeVela definition from its live object: what kinds its template produces, which parameters flow into which fields, its parameter schema, health and custom status rules, trait behaviour and restrictions, revision history, and how many Applications use it. Static inspection; nothing is rendered or applied.

Input​

FieldTypeRequiredDescription
namestringyesDefinition name as returned by list_definitions.
namespacestringnoNamespace to look in before the system namespace.
typestringnoDefinition type: component, trait, policy or workflow-step. When empty every type is tried in that order.

Result​

FieldTypeDescription
abstractbooleanTrue when the definition is abstract and is only extended, never used directly.
aliasstringShort alias the definition declares.
consumersobjectApplications that use this definition, within the namespaces the server may read.
defaultbooleanTrue when this is the platform default for the namespace in the request. Use it and name the alternatives; when several fit and none is default, ask the user to choose.
defaultForarray of stringNamespaces where the platform made this the default among definitions providing the same capability; * means every namespace.
deprecatedbooleanTrue when the definition is marked deprecated.
descriptionstringOne-line description the definition declares.
evidencearray of stringObjects this answer was derived from.
extendsstringDefinition this one extends, if any.
healthobjectHealth and custom status rules, verbatim CUE.
hiddenbooleanTrue when the definition asks to be hidden from listings.
inspectionErrorstringSet when the template could not be parsed; the schema and metadata are still valid.
latestRevisionstringName of the definition's latest DefinitionRevision.
matchedBystringSet by list_definitions when it filters by provides: label when the definition carries the provides label, name or description when it has no label but mentions the capability there. Confirm the latter from its description before relying on it.
metaobjectVersions and read time for this result. See the meta block.
namestringName of the object this result describes.
namespacestringNamespace of the object this result describes.
parameterUsagearray of objectWhich template fields each parameter flows into.
parametersobjectJSON Schema of the parameter block.
producesarray of objectKinds the template emits or patches, read from the template without rendering. An entry with no kind is built by an expression and is known only at render.
providesstringCapability the platform labels this definition as providing, such as postgres. Definitions with the same value are alternatives.
requiredarray of stringTop-level parameters with no default, which must be supplied.
restrictedBySelectorstringLabel selector that namespaces must match to use the definition, when the platform restricts it that way.
restrictedToNamespacesarray of stringNamespaces the definition may be used in, when the platform restricts it.
revisionsarray of objectDefinitionRevisions, newest first.
traitobjectFor traits: the workloads it applies to, what it conflicts with, and whether it restarts pods or manages the workload.
typestringDefinition type: component, trait, policy or workflow-step.
versionstringVersion the definition declares, if any.
workloadobjectFor components: the workload type, apiVersion and kind the template declares.

explain_application​

Read. Always registered.

Explain an Application end to end: each component with its definition, declared dependencies and data flow, recorded status per cluster, live managed resources with unhealthy descendants and pod phases, workflow state, recent events, and a list of findings ordered by severity, each citing the object it came from. Start here when asked why an application is not working.

Input​

FieldTypeRequiredDescription
namestringyesApplication name.
namespacestringyesApplication namespace.

Result​

FieldTypeDescription
componentsarray of objectEach component joined with its definition, status and live resources.
createdAtstringWhen the Application was created, UTC.
eventsarray of objectRecent events on the Application or its resources, newest first.
evidencearray of stringObjects this answer was derived from.
findingsarray of objectObservations ordered error, warning, info, each citing an object.
handlesobjectExact identifiers for queries to other tools: clusters, namespace, pods, labels and the time window. Use them verbatim; do not guess label names or time ranges.
healthybooleanFalse when the phase or a workflow step failed, or when no service has reported status yet.
metaobjectVersions and read time for this result. See the meta block.
namestringName of the object this result describes.
namespacestringNamespace of the object this result describes.
phasestringApplication phase as the controller recorded it, such as running or runningWorkflow.
policiesarray of objectPolicies the Application declares, with their types and properties.
revisionstringLatest ApplicationRevision name.
statusStalebooleanTrue when the controller has not observed the latest spec, so status describes an older generation.
unknownsarray of stringWhat could not be read. Report these as unknown rather than guessing.
workflowobjectWorkflow state with suspended and failed steps and the next command.

list_clusters​

Read. Always registered.

List the clusters KubeVela can deploy to, with alias, credential type, endpoint and labels. Credentials are never returned.

Input​

This tool takes no input.

Result​

FieldTypeDescription
clustersarray of objectClusters with alias, credential type, endpoint and labels.
evidencearray of stringObjects this answer was derived from.
metaobjectVersions and read time for this result. See the meta block.

list_addons​

Read. Always registered.

List the addons enabled on this control plane with version, registry, phase, health and the clusters they reach, read from the Applications the addons installed. Registry catalogues are not queried.

Input​

This tool takes no input.

Result​

FieldTypeDescription
addonsarray of objectEnabled addons.
evidencearray of stringObjects this answer was derived from.
metaobjectVersions and read time for this result. See the meta block.

dryrun_application​

Plan. Always registered; renders and compares without writing.

Render an Application document the way vela dry-run does, without saving it: every Kubernetes object each component and trait would produce, plus policy objects. Pass local definitions to render against definitions not yet on the cluster, such as the CUE vela def gen-module generates from a defkit module. Set serverCheck to have the API server validate every rendered object against the installed CRDs without storing it. Use it until the draft renders clean, then diff_application.

Input​

FieldTypeRequiredDescription
applicationstringyesThe Application as YAML or JSON, exactly as it would be applied.
definitionsarray of stringnoOptional local definitions, one per entry, used instead of the cluster's copy of the same name. Each is a CUE definition as vela def gen-module writes it for a defkit module, or a definition object as YAML.
namespacestringnoNamespace to render in when the document has none. The document's own namespace wins.
serverCheckbooleannoAlso send each rendered object to the API server as a dry run with strict field validation, so it is checked against the installed CRDs and admission. Nothing is stored. Needs the CRDs installed and permission to create the objects. Acceptance means this API server accepted the request now; RBAC, admission and live state at apply time can still differ.

Result​

FieldTypeDescription
applicationstringApplication name.
componentsarray of objectComponents in the document, with their types.
evidencearray of stringWhat was rendered and with which definitions.
metaobjectVersions and read time for this result. See the meta block.
namespacestringNamespace of the object this result describes.
policiesarray of objectObjects rendered by policies.
resourcesarray of objectEvery object the components and traits would create.
serverCheckobjectThe API server's verdict on each rendered object, when serverCheck was requested. Acceptance means the checked API server accepted the dry-run request; it is strong evidence the shape is right, not a promise that a later apply succeeds.

diff_application​

Plan. Always registered; renders and compares without writing.

Compare an Application document with what runs: renders both, lists every resource added, modified or removed with the fields that differ, flags placement, policy, component and approval-gate changes, and classifies risk LOW, MEDIUM or HIGH with every rule that fired. Returns a token that apply_application requires, so show this result to the user before any apply.

Input​

FieldTypeRequiredDescription
applicationstringyesThe Application as YAML or JSON, exactly as it would be applied.
definitionsarray of stringnoOptional local definitions, one per entry, used instead of the cluster's copy of the same name. Each is a CUE definition as vela def gen-module writes it for a defkit module, or a definition object as YAML.
namespacestringnoNamespace to render in when the document has none. The document's own namespace wins.
revisionstringnoApplicationRevision to compare against. Empty uses the latest revision; a missing Application compares against nothing.

Result​

FieldTypeDescription
applicationstringApplication name.
basestringApplicationRevision the document was compared with, or new when the Application does not exist.
changeSetobjectEverything that would change, computed from both renders.
evidencearray of stringObjects and renders this answer was derived from.
expiresAtstringWhen the token stops being accepted, UTC.
metaobjectVersions and read time for this result. See the meta block.
namespacestringNamespace of the object this result describes.
riskobjectRisk class with the rules that fired. Show it to the user with the change set.
tokenstringRequired by apply_application. Binds this exact document to the base revision; it does not record that anyone reviewed the diff.

apply_application​

Write. Registered only when the server starts with --allow-write.

Deliver an Application after diff_application, using the token it returned for the same document. Policy decides the mode and can only make it stricter: gitops returns YAML to commit and writes nothing; direct asks the user to confirm in their client with a prompt the server writes, and writes only after they accept. Never answer that prompt for the user. Report the mode used.

Input​

FieldTypeRequiredDescription
applicationstringyesThe same Application document that was passed to diff_application, byte for byte.
tokenstringyesThe token diff_application returned for this document.
modestringnoRequested write mode: gitops, gated or direct. Default gated, which this release applies as gitops because the controller hold gated mode needs does not exist yet. Policy may make the mode stricter, never looser.
namespacestringnoNamespace when the document has none, as for diff_application.

Result​

FieldTypeDescription
applicationstringApplication name.
appliedbooleanTrue only when the Application was written to the cluster.
declinedbooleanTrue when the user declined the confirmation prompt; nothing was written.
evidencearray of stringObjects this answer was derived from.
generationintegerGeneration of the Application as written. Empty when nothing was written.
metaobjectVersions and read time for this result. See the meta block.
modestringThe mode actually used after policy: gitops or direct. Report it to the user.
modeReasonsarray of stringWhy the mode differs from the one requested, one line per policy that applied.
namespacestringNamespace of the object this result describes.
nextstringWhat to do next, such as open a pull request or poll get_application.
resourceVersionstringresourceVersion of the Application as written. Empty when nothing was written.
riskobjectRisk class and rules from the diff this token was issued for.
yamlstringIn gitops mode, the Application to commit to the delivery repository. Nothing was written to the cluster.
Auto generated by hack/docgen/mcp in KubeVela.​