Release Plan
This article primarily explains how to use Zadig's release plan feature, including planning, approval, and execution of release plans, as well as tracking detailed operation records.
# Planning
Access Management -> Release Plan: Create a new release plan, fill in the details, and save it as a draft. This feature supports multi-person collaboration for planning the release.

Parameter Description:
Name: The name of the release planRelease Owner: The person responsible for this release. After the release plan is formulated, only the owner can execute the releaseRelease Window: The time window during which publishing operations can be performedScheduled Execution: Execute the workflow in the release items at a specified timeRequirement Association: The associated requirement list, supporting multiple JIRA sprintsRelease Content: Specific release content, which can include multiple items. Each release item can specify an owner, and only the specified owner can execute it. Release items include two types: rich text and workflowRich Text Type: Input contentWorkflow Type: Select the project and workflow in Zadig and configure the workflow parameters as needed
Approval Configuration: Configure approval as needed, supporting three methods: Zadig, Feishu, and DingTalkZadig: The approval application will be sent to the email address corresponding to the account Zadig For specific approval configuration, please refer to the document ZadigFeishu: The approval application will be sent to Feishu. For specific approval configuration, please refer to the document Feishu for approval.Dingtalk: The approval application will be sent to DingTalk. For specific approval configuration, please refer to the document DingTalk approval.
# Approval
This applies to scenarios where the release plan includes approval configuration.
After the release owner submits the approval, the approver is responsible for the approval. Only after the approval is granted can the release owner proceed with the release.
Tip
If the approval is rejected, the release plan content can be edited again and the release plan can be re-planned.

# Execution
Tip
- Execution can be performed within the release time window.
- Only the release owner can execute the release.
For rich text type release content, click Complete on the right and enter the release notes.

For workflow type release content, click Execute on the right to automatically trigger the workflow execution. Click the link to view the workflow execution details.


For release items that need to be skipped, click Skip. Once all release items are either executed or skipped, the release plan will be automatically marked as completed.
# Operation Record
The system keeps a detailed record of the release plan's operation logs. Click Operation Record to view them.

# Hook External Systems and CallBack
# Hook External Systems
Request
POST
Body Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
id | string | Release plan id |
index | string | Release plan index |
name | string | Release plan name |
event_name | string | Event name, enum values: finish_planning, start_execute, all_job_done |
description | string | Requirement association |
manager | string | Release owner |
manager_id | string | Release owner ID |
instance_code | string | Instance Code (different after each edit) |
start_time | int | Release window - start time |
end_time | int | Release window - end time |
schedule_execute_time | int | Scheduled execution time |
approval_time | int | Approval time |
planning_time | int | Planning time |
executing_time | int | Execution time |
success_time | int | Success time |
status | string | Status |
jobs | []HookReleasePlanJob | Release content list |
created_by | string | Creator |
create_time | int | Creation time |
updated_by | string | Updater |
update_time | int | Update time |
Release Plan Status Description
| Name | Description |
|---|---|
planning | Planning |
finish_planning | Finished planning |
wait_for_approval | Waiting for approval |
executing | Executing |
denied | Denied |
timeout | Timeout |
success | Success |
wait_for_finish_planning_external_check | Waiting for finish planning external check |
wait_for_execute_external_check | Waiting for execution external check |
wait_for_all_done_external_check | Waiting for all jobs done external check |
wait_for_finish_planning_external_check_failed | Waiting for finish planning external check failed |
wait_for_execute_external_check_failed | Waiting for execution external check failed |
wait_for_all_done_external_check_failed | Waiting for all jobs done external check failed |
cancel | Cancel |
HookReleasePlanJob Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
id | string | Release task id |
name | string | Release task name |
status | string | Release task status |
type | string | Release task type, including text and workflow |
spec | ReleaseJobSpec | Release task specification, when type is text, the specification is TextReleasePlanJob, when type is workflow, the specification is WorkflowReleasePlanJob |
executed_by | string | Executor |
executed_time | string | Execution time |
Release Plan Task Status Description
| Name | Description |
|---|---|
todo | Not started |
done | Completed |
skipped | Skipped |
failed | Failed |
running | Running |
TextReleasePlanJob Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
content | string | Content |
remark | string | Remark |
WorkflowReleasePlanJob Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
workflow | Workflow | Workflow |
status | string | Task status including: created(creating), running(running), passed(passed), failed(failed), timeout(timeout), cancelled(cancelled) |
task_id | int | Workflow task ID |
Workflow Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
name | string | Workflow identifier |
display_name | string | Workflow display name |
disabled | bool | Whether disabled |
params | []WorkflowParam | Global variable list |
stages | []WorkflowStage | Stages |
project | string | Project identifier |
description | string | Description |
created_by | string | Creator |
create_time | int | Creation time |
updated_by | string | Updater |
update_time | int | Update time |
remark | string | Remark |
WorkflowParam Global Variable Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
name | string | Variable name |
description | string | Variable description |
type | string | Variable type, supports string/text/choice/repo types |
value | string | Variable value |
repo | Repo | repo type variable value, used when type is repo |
choice_options | []string | Choice option values |
choice_value | []string | Choice values |
default | string | Default value |
is_credential | bool | Whether it is sensitive information |
source | string | Source, supports runtime/fixed/reference |
Repo Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
source | string | Source |
repo_owner | string | Repository owner |
repo_namespace | string | Repository namespace |
repo_name | string | Repository name |
remote_name | string | Remote name |
branch | string | Branch name |
prs | []int | PR number list |
tag | string | Tag name |
commit_id | string | Commit ID |
commit_message | string | Commit message |
checkout_path | string | Checkout path |
codehost_id | int | Code source ID |
address | string | Address |
WorkflowStage Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
name | string | Name |
jobs | []WorkflowJob | Job list |
WorkflowJob Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
name | string | Name |
type | WorkflowJobType | Type, supports zadig-build/zadig-deploy/zadig-vm-deploy/zadig-test/zadig-scanning/zadig-distribute-image/freestyle/apollo/nacos/sql |
spec | any | Job specification |
run_policy | string | Run policy, supports default_not_run/force_run/skip, if empty then default run |
WorkflowJobType Parameter Description
| Parameter Name | Corresponding Spec | Description |
|---|---|---|
zadig-build | WorkflowBuildJobSpec | Build job Spec |
zadig-deploy | WorkflowDeployJobSpec | Deploy job Spec |
zadig-vm-deploy | WorkflowVmDeployJobSpec | VM deploy job Spec |
zadig-test | WorkflowTestingJobSpec | Test job Spec |
zadig-scanning | WorkflowScanningJobSpec | Scanning job Spec |
zadig-distribute-image | WorkflowDistributeImageJobSpec | Distribute image job Spec |
freestyle | WorkflowFreestyleJobSpec | General job Spec |
apollo | WorkflowApolloJobSpec | Apollo job Spec |
nacos | WorkflowNacosJobSpec | Nacos job Spec |
sql | WorkflowSqlJobSpec | SQL job Spec |
WorkflowBuildJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
source | string | Source, optional values: runtime/fixed/fromjob |
job_name | string | Referenced job name, used when source is fromjob |
ref_repos | bool | Whether to reference selected job code info |
service_and_builds | []ServiceAndBuild | Service and build list |
ServiceAndBuild Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
service_name | string | Service name |
service_module | string | Service module |
build_name | string | Build name |
image | string | Image address |
package | string | Binary package address |
image_name | string | Image name |
key_vals | []KeyVal | Build variable list |
repos | []Repo | Repository list |
KeyVal Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
key | string | Variable name |
value | string | Variable value |
type | string | Variable type, optional values: string/choice/multi-select/image/script |
registry_id | string | Image registry ID |
script | string | Script |
call_function | string | Call function |
choice_option | []string | Choice option values |
choice_value | []string | Choice values |
is_credential | bool | Whether it is sensitive information |
description | string | Description |
source | string | Source, optional values: runtime/fixed/reference |
WorkflowDeployJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
env | string | Environment name |
production | bool | Whether it is production environment |
deploy_type | string | Deploy type |
source | string | Source, fromjob/runtime, runtime means runtime input, fromjob means get from upstream build job |
env_source | string | Environment source, fromjob/runtime, runtime means runtime input, fromjob means get from upstream build job |
deploy_contents | []string | Deploy content, including image/vars/config |
job_name | string | Referenced job name, used when source is fromjob |
version_name | string | Version name, used when importing from version |
services | []DeployServiceInfo | Service list |
DeployServiceInfo Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
service_name | string | Service name |
modules | []DeployModuleInfo | Module list |
deployed | bool | Whether deployed |
auto_sync | bool | Whether auto sync is enabled in environment |
update_config | bool | Whether to update config |
updatable | bool | Whether updatable |
variable_kvs | []DeployVariableKv | Variable list |
variable_yaml | string | Final variable Yaml, used for Helm and K8S Yaml services |
value_merge_strategy | string | Values merge strategy, used for Helm services, options: override/reuse-values |
override_kvs | string | Key-value pair variables, used for Helm services, json encoded key-value pairs |
DeployModuleInfo Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
service_module | string | Service module |
image | string | Image address |
image_name | string | Image name |
DeployVariableKv Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
key | string | Variable name |
value | string | Image address |
type | string | Variable type, optional values: string/bool/enum/yaml |
options | string | Choice option values, used when type is enum |
desc | string | Description |
use_global_variable | bool | Whether to use global variable |
WorkflowVmDeployJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
env | string | Environment name |
production | bool | Whether it is production environment |
env_alias | string | Environment alias |
source | string | Source, fromjob/runtime, runtime means runtime input, fromjob means get from upstream build job |
job_name | string | Referenced job name, used when source is fromjob |
ref_repos | bool | Whether to reference selected job code info |
service_and_vm_deploys | []ServiceAndVmDeploy | Service and VM deploy list |
ServiceAndVmDeploy Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
service_name | string | Service name |
service_module | string | Service module |
deploy_name | string | Deploy name |
deploy_artifact_type | string | Deploy artifact type, optional values: image/file/other |
artifact_url | string | Deploy artifact address |
file_name | string | Deploy artifact file name |
image | string | Deploy artifact image address |
key_vals | []KeyVal | Variable list |
repos | []Repo | Repository list |
WorkflowFreestyleJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
freestyle_type | string | General job type, empty for single service, service_freestyle for multi-service |
source | string | Source, fromjob/runtime, runtime means runtime input, fromjob means get from upstream build job |
job_name | string | Referenced job name, used when source is fromjob |
ref_repos | bool | Whether to reference selected job code info |
repos | []Repo | Repository list, used for single service |
envs | []KeyVal | Variable list, used for single service |
services | []FreeStyleServiceInfo | Service list |
FreeStyleServiceInfo Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
service_name | string | Service name |
service_module | string | Service module |
repos | []Repo | Repository list |
key_vals | []KeyVal | Variable list |
WorkflowTestingJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
testing_type | string | Test job type, empty for single service, service_test for multi-service |
source | string | Source, fromjob/runtime, runtime means runtime input, fromjob means get from upstream build job |
job_name | string | Referenced job name, used when source is fromjob |
ref_repos | bool | Whether to reference selected job code info |
service_and_tests | []ServiceAndTest | Service and test list, used when test job type is multi-service |
test_modules | []TestModule | Test module list, used when test job type is single service |
ServiceAndTest Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
name | string | Test name |
service_name | string | Service name |
service_module | string | Service module |
repos | []Repo | Repository list |
key_vals | []KeyVal | Variable list |
TestModule Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
name | string | Test name |
repos | []Repo | Repository list |
key_vals | []KeyVal | Variable list |
WorkflowScanningsJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
scannings_type | string | Scanning job type, empty for single service, service_scannings for multi-service |
source | string | Source, fromjob/runtime, runtime means runtime input, fromjob means get from upstream build job |
job_name | string | Referenced job name, used when source is fromjob |
ref_repos | bool | Whether to reference selected job code info |
service_and_scannings | []ServiceAndScannings | Service and scanning list, used when scanning job type is multi-service |
scannings_modules | []ScanningsModule | Scanning module list, used when scanning job type is single service |
ServiceAndScannings Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
name | string | Scanning name |
service_name | string | Service name |
service_module | string | Service module |
repos | []Repo | Repository list |
key_vals | []KeyVal | Variable list |
ScanningsModule Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
name | string | Scanning name |
repos | []Repo | Repository list |
key_vals | []KeyVal | Variable list |
WorkflowNacosJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
nacos_id | string | Nacos ID |
namespace_id | string | Nacos namespace ID |
source | string | Source, fixed/runtime, runtime means runtime input, fixed means fixed value |
nacos_datas | []NacosData | Nacos data list |
NacosData Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
data_id | string | Data ID |
group | string | Data group |
desc | string | Data description |
format | string | Data format |
content | string | Data content |
original_content | string | Original data content |
namespace_id | string | Nacos namespace ID |
namespace_name | string | Nacos namespace name |
WorkflowApolloJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
apollo_id | string | Apollo ID |
namespace_list | []ApolloNamespace | Apollo namespace list |
ApolloNamespace Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
app_id | string | Application ID |
cluster_id | string | Cluster ID |
env | string | Environment |
namespace | string | Namespace |
type | string | Type |
original_config | []ApolloKV | Original config |
kv | []ApolloKV | Key-value list |
ApolloKV Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
key | string | Key |
val | string | Value |
WorkflowSqlJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
id | string | Database instance ID |
type | string | Database instance type, mysql/mariadb |
sql | string | SQL statement |
source | string | Source, fixed/runtime, runtime means runtime input, fixed means fixed value |
WorkflowDistributeImageJobSpec Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
source | string | Source, fromjob/runtime, runtime means runtime input, fromjob means get from upstream build job |
job_name | string | Referenced job name, used when source is fromjob |
distribute_method | string | Distribute image method, image_push/cloud_sync |
targets | []DistributeImageTarget | Image distribution target list |
enable_target_image_tag_rule | string | Whether to enable image version rule |
target_image_tag_rule | string | Image version rule |
DistributeImageTarget Parameter Description
| Parameter Name | Type | Description |
|---|---|---|
service_name | string | Service name |
service_module | string | Service module |
source_tag | string | Source image tag |
target_tag | string | Image version |
image_name | string | Image name |
source_image | string | Source image |
target_image | string | Target image |
update_tag | bool | If UpdateTag is false, use source tag as target tag |
Body Parameter Example
Details
{
"object_kind": "release_plan",
"event": "release_plan",
"workflow": null,
"release_plan": {
"id": "68b7ec363306e52e21b2dbe6",
"index": 52,
"name": "workflow-plan-3",
"event_name": "all_job_done",
"manager": "patrick",
"manager_id": "14790d50-37b3-11f0-b3aa-ee39782dea6e",
"start_time": 1756883513,
"end_time": 1757488313,
"schedule_execute_time": 1756893020,
"description": "<p><br></p>",
"created_by": "patrick",
"create_time": 1756884022,
"updated_by": "系统",
"update_time": 1756893023,
"jobs": [
{
"id": "e092f96c-4f78-410e-88bb-7afa881471d9",
"name": "all",
"type": "workflow",
"spec": {
"workflow": {
"name": "release-plan-hook-2",
"display_name": "release-plan-hook-2",
"disabled": false,
"category": "",
"params": [],
"stages": [
{
"name": "build",
"jobs": [
{
"name": "build",
"type": "zadig-build",
"spec": {
"source": "runtime",
"job_name": "",
"ref_repos": false,
"service_and_builds": [
{
"service_name": "service1",
"service_module": "service1",
"build_name": "yaml-general-build",
"image": "{{.job.build.service1.service1.output.IMAGE}}",
"package": "{{.job.build.service1.service1.output.PKG_FILE}}",
"image_name": "service1",
"key_vals": [
{
"key": "gggg",
"value": "gggg",
"type": "string",
"registry_id": "",
"is_credential": false,
"description": "",
"source": "runtime"
}
],
"repos": [
{
"source": "gitlab",
"repo_owner": "kr-test-org1",
"repo_namespace": "kr-test-org1",
"repo_name": "multi-service-demo",
"remote_name": "origin",
"branch": "patrick-01",
"tag": "",
"commit_id": "311fa899187a674a2e7fbf76cf2eeecdc8a51ac1",
"commit_message": "update service2 values\n",
"checkout_path": "",
"submodules": false,
"codehost_id": 1,
"address": "https://gitlab.com/",
}
]
}
]
},
"run_policy": ""
}
]
}
],
"project": "yaml",
"description": "",
"created_by": "patrick",
"create_time": 1756883358,
"updated_by": "patrick",
"update_time": 1756883481,
"remark": "",
"enable_approval_ticket": false,
"approval_ticket_id": ""
},
"status": "prepare",
"task_id": 3
},
"status": "failed",
"executed_by": "系统",
"executed_time": 1756893022
}
],
"status": "wait_for_success_external_check",
"planning_time": 1756892886,
"approval_time": 0,
"executing_time": 1756892896,
"success_time": 1756893100
}
}
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
# Release Plan CallBack
Request
POST /api/callback/release_plan
Body Parameter Description
| Parameter Name | Type | Description | Required | Default |
|---|---|---|---|---|
hook_event | string | Hook event, enum values: finish_planning, start_execute, all_job_done | Yes | None |
release_plan_id | string | Release plan ID | Yes | None |
instance_code | string | Instance Code | Yes | None |
result | string | Result, enum values: success, failed | Yes | None |
failed_reason | string | Failed reason | No | None |
Body Parameter Example
{
"hook_event": "all_job_done",
"release_plan_id": "68b7ec363306e52e21b2dbe6",
"instance_code": "e52e21b68b7ec3",
"result": "success",
"failed_reason": ""
}
2
3
4
5
6
7
Normal Response
{
"id": "6895627bd3a843cb7423728a"
}
2
3


