Skip to main content

agentrun template

Manage AgentRun sandbox templates and their MCP service.

Run ecctl agentrun template <action> -h for usage, or ecctl schema agentrun.template.<action> --full for the complete, agent-readable spec of every parameter and behavior.

create

ecctl agentrun template create [flags]

Create an AgentRun sandbox template

  • Kind: mutation · Risk: medium
  • Synchronous: waits for READY (waiter ready_after_change, timeout 600s); use --no-wait to skip.
APIWhen calledPurpose
CreateTemplateEvery time the command runs.Perform the resource operation.
GetTemplateWhen --no-wait is not specified.Poll until the resource reaches the target state. (repeated)
ParameterTypeRequiredDescription
--cpunumberCPU cores
--memoryintegermemory in MB
--namestringtemplate name
--network-configurationobjectnetwork configuration as a JSON object or @file
--regionstringAlibaba Cloud region
--template-typestringtemplate type
--allow-anonymous-managebooleanallow data-plane create, stop, and delete sandbox calls
--arms-configurationobjectARMS configuration as a JSON object or @file
--container-configurationobjectcontainer configuration as a JSON object or @file
--credential-configurationobjectcredential configuration as a JSON object or @file
--descriptionstringtemplate description
--disk-sizeintegerdisk size in MB
--enable-agentbooleanenable the Sandbox Agent
--enable-pre-stopbooleanenable pre-stop handling
--environment-variablesobjectenvironment variables as a JSON object or @file
--execution-role-arnstringexecution role ARN
--idle-timeoutintegersandbox idle timeout in seconds
--log-configurationobjectlog configuration as a JSON object or @file
--nas-configobjectNAS mount configuration as a JSON object or @file
--oss-configurationobjectOSS mount configuration entries; repeat the flag with one JSON object or @file per mount
--pre-stop-timeoutintegerpre-stop timeout in seconds
--scaling-configobjectscaling configuration as a JSON object or @file
--template-configurationobjecttemplate-type-specific configuration as a JSON object or @file
--workspacestringworkspace ID

update

ecctl agentrun template update <name> [flags]

Update an AgentRun sandbox template

  • Kind: mutation · Risk: medium
  • Synchronous: waits for READY (waiter ready_after_change, timeout 600s); use --no-wait to skip.
  • Idempotent via clientToken.
APIWhen calledPurpose
UpdateTemplateEvery time the command runs.Perform the resource operation.
GetTemplateWhen --no-wait is not specified.Poll until the resource reaches the target state. (repeated)
ParameterTypeRequiredDescription
--regionstringAlibaba Cloud region
--allow-anonymous-managebooleanallow data-plane create, stop, and delete sandbox calls
--arms-configurationobjectARMS configuration as a JSON object or @file
--container-configurationobjectcontainer configuration as a JSON object or @file
--cpunumberCPU cores
--credential-configurationobjectcredential configuration as a JSON object or @file
--descriptionstringtemplate description
--enable-agentbooleanenable the Sandbox Agent
--enable-pre-stopbooleanenable pre-stop handling
--environment-variablesobjectenvironment variables as a JSON object or @file
--execution-role-arnstringexecution role ARN
--idle-timeoutintegersandbox idle timeout in seconds
--log-configurationobjectlog configuration as a JSON object or @file
--memoryintegermemory in MB
--nas-configobjectNAS mount configuration as a JSON object or @file
--network-configurationobjectnetwork configuration as a JSON object or @file
--oss-configurationobjectOSS mount configuration entries; repeat the flag with one JSON object or @file per mount
--pre-stop-timeoutintegerpre-stop timeout in seconds
--scaling-configobjectscaling configuration as a JSON object or @file
--template-configurationobjecttemplate-type-specific configuration as a JSON object or @file
--workspacestringworkspace ID

delete

ecctl agentrun template delete <name> [flags]

Delete an AgentRun sandbox template

  • Kind: mutation · Risk: high
  • Synchronous: waits for absent (waiter absent_after_delete, timeout 300s); use --no-wait to skip.
APIWhen calledPurpose
DeleteTemplateEvery time the command runs.Perform the resource operation.
ListTemplatesWhen --no-wait is not specified.Poll until the resource reaches the target state. (repeated)
ParameterTypeRequiredDescription
--regionstringAlibaba Cloud region

get

ecctl agentrun template get <name> [flags]

Get an AgentRun sandbox template

  • Kind: read · Risk: low
APIWhen calledPurpose
GetTemplateEvery time the command runs.Read the resource view.
ParameterTypeRequiredDescription
--regionstringAlibaba Cloud region
--fieldsstringcomma-separated resource fields to include

list

ecctl agentrun template list [flags]

List AgentRun sandbox templates

  • Kind: read · Risk: low
APIWhen calledPurpose
ListTemplatesEvery time the command runs.Read the resource view.
ParameterTypeRequiredDescription
--regionstringAlibaba Cloud region
--fieldsstringcomma-separated resource fields to include
--filterkey_valuefilter expression key=value
--limitintegermaximum templates to return (default: 100)
--pageintegerresults page to return (default: 1)
--workspace-idsstringworkspace IDs filter accepted by AgentRun

disable

ecctl agentrun template disable <name> [flags]

Disable the MCP service for a sandbox template

  • Kind: mutation · Risk: medium
APIWhen calledPurpose
StopTemplateMCPEvery time the command runs.Perform the resource operation.
GetTemplateEvery time the command runs.Read the resource view.
ParameterTypeRequiredDescription
--regionstringAlibaba Cloud region

enable

ecctl agentrun template enable <name> [flags]

Enable the MCP service for a sandbox template

  • Kind: mutation · Risk: medium
APIWhen calledPurpose
ActivateTemplateMCPEvery time the command runs.Perform the resource operation.
GetTemplateEvery time the command runs.Read the resource view.
ParameterTypeRequiredDescription
--regionstringAlibaba Cloud region
--enabled-toolsarrayMCP tools to enable
--transportstringMCP transport protocol