mirror of
				https://github.com/onepanelio/onepanel.git
				synced 2025-10-31 08:46:20 +08:00 
			
		
		
		
	
		
			
				
	
	
		
			92 lines
		
	
	
		
			2.2 KiB
		
	
	
	
		
			Protocol Buffer
		
	
	
	
	
	
			
		
		
	
	
			92 lines
		
	
	
		
			2.2 KiB
		
	
	
	
		
			Protocol Buffer
		
	
	
	
	
	
| syntax = "proto3";
 | |
| 
 | |
| package api;
 | |
| 
 | |
| import "google/api/annotations.proto";
 | |
| import "google/protobuf/empty.proto";
 | |
| import "workflow.proto";
 | |
| import "label.proto";
 | |
| 
 | |
| service CronWorkflowService {
 | |
|     rpc CreateCronWorkflow (CreateCronWorkflowRequest) returns (CronWorkflow) {
 | |
|         option (google.api.http) = {
 | |
|             post: "/apis/v1beta1/{namespace}/cron_workflow"
 | |
|             body: "cronWorkflow"
 | |
|         };
 | |
|     }
 | |
| 
 | |
|     rpc UpdateCronWorkflow(UpdateCronWorkflowRequest) returns (CronWorkflow) {
 | |
|         option (google.api.http) = {
 | |
|             put: "/apis/v1beta1/{namespace}/cron_workflow/{uid}"
 | |
|             body: "cronWorkflow"
 | |
|         };
 | |
|     }
 | |
| 
 | |
|     rpc GetCronWorkflow(GetCronWorkflowRequest) returns (CronWorkflow) {
 | |
|         option (google.api.http) = {
 | |
|             get: "/apis/v1beta1/{namespace}/cron_workflow/{uid}"
 | |
|         };
 | |
|     }
 | |
| 
 | |
|     rpc ListCronWorkflows(ListCronWorkflowRequest) returns (ListCronWorkflowsResponse) {
 | |
|         option (google.api.http) = {
 | |
|             get: "/apis/v1beta1/{namespace}/cron_workflows"
 | |
|             additional_bindings {
 | |
| 				get: "/apis/v1beta1/{namespace}/cron_workflows/{workflow_template_name}"
 | |
| 			}
 | |
|         };
 | |
|     }
 | |
| 
 | |
|     rpc DeleteCronWorkflow (DeleteCronWorkflowRequest) returns (google.protobuf.Empty) {
 | |
|         option (google.api.http) = {
 | |
|             delete: "/apis/v1beta1/{namespace}/cron_workflows/{uid}"
 | |
|         };
 | |
|     }
 | |
| }
 | |
| 
 | |
| message CronWorkflow {
 | |
|     string name = 1;
 | |
|     string uid = 2;
 | |
|     string manifest = 3;
 | |
| 
 | |
|     WorkflowExecution workflowExecution = 4;
 | |
| 
 | |
|     repeated KeyValue labels = 5;
 | |
|     string namespace = 6;
 | |
| }
 | |
| 
 | |
| message CreateCronWorkflowRequest {
 | |
|     string namespace = 1;
 | |
|     CronWorkflow cronWorkflow = 2;
 | |
| }
 | |
| 
 | |
| message GetCronWorkflowRequest {
 | |
|     string namespace = 1;
 | |
|     string uid = 2;
 | |
| }
 | |
| 
 | |
| message UpdateCronWorkflowRequest {
 | |
|     string namespace = 1 ;
 | |
|     string uid = 2;
 | |
|     CronWorkflow cronWorkflow = 3;
 | |
| }
 | |
| 
 | |
| message DeleteCronWorkflowRequest {
 | |
|     string namespace = 1;
 | |
|     string uid = 2;
 | |
| }
 | |
| 
 | |
| message ListCronWorkflowRequest {
 | |
|     string namespace = 1;
 | |
|     string workflow_template_name = 2;
 | |
|     int32 pageSize = 3;
 | |
|     int32 page = 4;
 | |
| }
 | |
| 
 | |
| message ListCronWorkflowsResponse {
 | |
|     int32 count = 1;
 | |
|     repeated CronWorkflow cronWorkflows = 2;
 | |
|     int32 page = 3;
 | |
|     int32 pages = 4;
 | |
|     int32 totalCount = 5;
 | |
| } | 
