You need to enable JavaScript to run this app.
文档中心
基础设施管理

基础设施管理

复制全文
下载 pdf
执行计划
CreateExecutionPlan - 创建执行计划
复制全文
下载 pdf
CreateExecutionPlan - 创建执行计划
为资源栈创建执行计划。​
调试​
API Explorer
您可以通过 API Explorer 在线发起调用,无需关注签名生成过程,快速获取调用结果。
​
请求参数​
下方仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数。​
Action string 必选 示例值:CreateExecutionPlan​
要执行的操作,取值:CreateExecutionPlan。​
​
Version string 必选 示例值:2026-05-01​
API的版本,取值:2026-05-01。​
​
StackID string 必选 示例值:s-01arz3ndektsv4rrffq69g5fav​
资源栈 ID​
​
ExecutionPlanName string 必选 示例值:plan1​
执行计划名称,1-256 个字符。​
​
Description string 可选 示例值:my plan​
执行计划描述,最多 512 个字符。​
​
EngineVersion string 必选 示例值:terraform-1.5.7​
IaC 引擎版本。​
​
TemplateURL string 可选 示例值:https://xxx/template.zip​
模板 URL,支持 HTTP、HTTPS 或 tos:// 来源,模板最大为 5 MB。TemplateURL、TemplateID、ModuleID 必须且只能选择一种来源。​
​
TemplatePath string 可选 示例值:/​
模板包内相对目录,最长 1024 字符。默认根目录。需与模板来源一起传入。​
​
TemplateID string 可选 示例值:ptp-01arz3ndektsv4rrffq69g5fav​
在线模板 ID。TemplateURL、TemplateID、ModuleID 必须且只能选择一种来源。传入时必须同时指定 TemplateVersion。​
​
TemplateVersion long 可选 示例值:1​
模板业务版本号,必须大于 0。传入 TemplateID 时必填。​
​
ModuleID string 可选 示例值:mod-01arz3ndektsv4rrffq69g5fav​
公共 Module ID。TemplateURL、TemplateID、ModuleID 必须且只能选择一种来源。传入时必须同时指定 ModuleVersion 和非根目录 TemplatePath。​
​
ModuleVersion long 可选 示例值:1​
Module 业务版本号,必须大于 0。传入 ModuleID 时必填。​
​
Variables object[] 可选 示例值:-​
模板变量键值对列表​
Key string 必选 示例值:vpc_name​
变量名,不可为空或重复。​
​
Value object 可选 示例值:vpc-demo123​
变量值,支持任意 JSON 类型。​
​
​
​
​
返回参数​
下方仅列出本接口特有的返回参数。更多信息请参见返回结构。​
ExecutionPlanID string 示例值:ep-01arz3ndektsv4rrffq69g5fav​
执行计划 ID​
​
StackID string 示例值:s-01arz3ndektsv4rrffq69g5fav​
资源栈 ID​
​
Status string 示例值:CreateInProgress​
创建状态:CreateInProgress 或 CreateComplete。​
​
​
​
请求示例​
​
POST /?Action=CreateExecutionPlan&Version=2026-05-01 HTTP/1.1​
Host: inframanager.cn-beijing.volcengineapi.com​
Content-Type: application/json; charset=UTF-8​
X-Date: 20260922T100000Z​
X-Content-Sha256: 287e874e******d653b44d21e​
Authorization: HMAC-SHA256 Credential=Adfks******wekfwe/20260922/cn-beijing/inframanager/request, SignedHeaders=host;x-content-sha256;x-date, Signature=47a7d934ff7b37c03938******cd7b8278a40a1057690c401e92246a0e41085f​
​
{​
"StackID": "s-01arz3ndektsv4rrffq69g5fav",​
"ExecutionPlanName": "plan1",​
"Description": "my plan",​
"EngineVersion": "terraform-1.5.7",​
"TemplateURL": "https://xxx/template.zip",​
"TemplatePath": "/",​
"Variables": [​
{​
"Key": "vpc_name",​
"Value": "vpc-demo123"​
}​
]​
}​
​
返回示例​
​
{​
"ResponseMetadata": {​
"RequestId": "202609221800001234567890ABCDEF",​
"Action": "CreateExecutionPlan",​
"Version": "2026-05-01",​
"Service": "inframanager",​
"Region": "cn-beijing"​
},​
"Result": {​
"ExecutionPlanID": "ep-01arz3ndektsv4rrffq69g5fav",​
"StackID": "s-01arz3ndektsv4rrffq69g5fav",​
"Status": "CreateInProgress"​
}​
}​
​
错误码​
下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。​
​
状态码​
错误码​
错误信息​
说明​
400​
InvalidParameter​
The specified parameter %q is invalid.​
请求参数不合法。​
400​
InvalidTemplate.Archive​
The template archive is invalid: %s​
模板归档文件不合法。​
400​
InvalidTemplate.Content​
Failed to parse the template: %s​
模板内容解析失败。​
400​
MissingParameter​
The required parameter [%v] is missing​
缺少必填参数。​
400​
OperationFailed.TemplateDownload​
Failed to download the template: %s​
模板下载失败。​
400​
QuotaExceeded.TemplateSize​
The template size exceeds the limit: %s​
模板大小超过限制。​
400​
RegionNotSupport​
The service [%v] not support region [%v]​
服务不支持当前地域。​
400​
StackRoleUnavailable​
The role %q associated with this stack is unavailable. Please restore the IAM role or update the stack RoleName.​
资源栈关联角色不可用。​
404​
EntityNotFound.ExecutionPlan​
The execution plan %q does not exist for the specified stack in the current region.​
执行计划不存在或不属于指定资源栈和地域。​
404​
EntityNotFound.Stack​
The stack %q does not exist in the current region.​
资源栈不存在或不属于当前地域。​
409​
AlreadyExists.ExecutionPlan​
An execution plan named %q already exists for the specified stack.​
指定资源栈下同名执行计划已存在。​
409​
NoPermittedOperation.ExecutionPlanExpired​
The execution plan %q has expired because the stack state changed.​
资源栈已变化,执行计划已失效。​
409​
NoPermittedOperation.ExecutionPlanInProgress​
The execution plan operation for %q cannot proceed while an execution plan is in progress.​
资源栈下存在创建中的执行计划。​
409​
NoPermittedOperation.ExecutionPlanStatus​
The execution plan %q cannot perform this operation in its current status %q.​
执行计划当前状态不允许此操作。​
409​
NoPermittedOperation.StatusNotDeployable​
The stack %q cannot be deployed in its current status %q.​
资源栈当前状态不允许创建执行计划。​
409​
OperationFailed.ExecutionPlanCreate​
Failed to create execution plan %q: %s​
创建执行计划失败。​
409​
QuotaExceeded.ExecutionPlan​
The number of non-expired execution plans for stack %q has exceeded the quota.​
资源栈下未删除的执行计划数量超过配额。​
500​
InternalError​
The request has failed due to an unknown error.​
内部服务错误,请稍后重试。​
​
​
最近更新时间:2026.10.20 19:15:48
这个页面对您有帮助吗?
有用
有用
无用
无用