Explorar el Código

Argo Smart Routing实现

世祺 hace 1 año
padre
commit
812d94b5bb
Se han modificado 8 ficheros con 1070 adiciones y 872 borrados
  1. 427 155
      cloudflareApi/zone/zone.pb.go
  2. 147 1
      cloudflareApi/zone/zone_grpc.pb.go
  3. 10 13
      go.mod
  4. 18 699
      go.sum
  5. 1 1
      proto
  6. 206 3
      server/ZoneCloudflareServer.go
  7. 247 0
      server/ZoneCloudflareServer_test.go
  8. 14 0
      server/zone_convert.go

+ 427 - 155
cloudflareApi/zone/zone.pb.go

@@ -1,7 +1,7 @@
 // Code generated by protoc-gen-go. DO NOT EDIT.
 // versions:
 // 	protoc-gen-go v1.28.1
-// 	protoc        v3.21.4
+// 	protoc        v3.21.5
 // source: proto/zone.proto
 
 package zone
@@ -83,7 +83,7 @@ func (Phase) EnumDescriptor() ([]byte, []int) {
 	return file_proto_zone_proto_rawDescGZIP(), []int{0}
 }
 
-// Zone CURD
+//Zone CURD
 type ZoneCloudflareEntity struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -1877,6 +1877,187 @@ func (x *UpdatePageRulesPrioritiesRequestCloudflare) GetData() []*UpdatePageRule
 	return nil
 }
 
+type ArgoSetting struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	Enabled bool `protobuf:"varint,1,opt,name=enabled,proto3" json:"enabled,omitempty"`
+}
+
+func (x *ArgoSetting) Reset() {
+	*x = ArgoSetting{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_proto_zone_proto_msgTypes[28]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *ArgoSetting) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*ArgoSetting) ProtoMessage() {}
+
+func (x *ArgoSetting) ProtoReflect() protoreflect.Message {
+	mi := &file_proto_zone_proto_msgTypes[28]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use ArgoSetting.ProtoReflect.Descriptor instead.
+func (*ArgoSetting) Descriptor() ([]byte, []int) {
+	return file_proto_zone_proto_rawDescGZIP(), []int{28}
+}
+
+func (x *ArgoSetting) GetEnabled() bool {
+	if x != nil {
+		return x.Enabled
+	}
+	return false
+}
+
+type UpdateArgoRequestCloudflare struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	ApiKey      string       `protobuf:"bytes,1,opt,name=apiKey,proto3" json:"apiKey,omitempty"`
+	ApiEmail    string       `protobuf:"bytes,2,opt,name=apiEmail,proto3" json:"apiEmail,omitempty"`
+	ZoneId      string       `protobuf:"bytes,3,opt,name=zoneId,proto3" json:"zoneId,omitempty"`
+	ArgoSetting *ArgoSetting `protobuf:"bytes,4,opt,name=argo_setting,json=argoSetting,proto3" json:"argo_setting,omitempty"`
+}
+
+func (x *UpdateArgoRequestCloudflare) Reset() {
+	*x = UpdateArgoRequestCloudflare{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_proto_zone_proto_msgTypes[29]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *UpdateArgoRequestCloudflare) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*UpdateArgoRequestCloudflare) ProtoMessage() {}
+
+func (x *UpdateArgoRequestCloudflare) ProtoReflect() protoreflect.Message {
+	mi := &file_proto_zone_proto_msgTypes[29]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use UpdateArgoRequestCloudflare.ProtoReflect.Descriptor instead.
+func (*UpdateArgoRequestCloudflare) Descriptor() ([]byte, []int) {
+	return file_proto_zone_proto_rawDescGZIP(), []int{29}
+}
+
+func (x *UpdateArgoRequestCloudflare) GetApiKey() string {
+	if x != nil {
+		return x.ApiKey
+	}
+	return ""
+}
+
+func (x *UpdateArgoRequestCloudflare) GetApiEmail() string {
+	if x != nil {
+		return x.ApiEmail
+	}
+	return ""
+}
+
+func (x *UpdateArgoRequestCloudflare) GetZoneId() string {
+	if x != nil {
+		return x.ZoneId
+	}
+	return ""
+}
+
+func (x *UpdateArgoRequestCloudflare) GetArgoSetting() *ArgoSetting {
+	if x != nil {
+		return x.ArgoSetting
+	}
+	return nil
+}
+
+type IdRequest struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	ApiKey   string `protobuf:"bytes,1,opt,name=apiKey,proto3" json:"apiKey,omitempty"`
+	ApiEmail string `protobuf:"bytes,2,opt,name=apiEmail,proto3" json:"apiEmail,omitempty"`
+	ZoneId   string `protobuf:"bytes,3,opt,name=zoneId,proto3" json:"zoneId,omitempty"`
+}
+
+func (x *IdRequest) Reset() {
+	*x = IdRequest{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_proto_zone_proto_msgTypes[30]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *IdRequest) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*IdRequest) ProtoMessage() {}
+
+func (x *IdRequest) ProtoReflect() protoreflect.Message {
+	mi := &file_proto_zone_proto_msgTypes[30]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use IdRequest.ProtoReflect.Descriptor instead.
+func (*IdRequest) Descriptor() ([]byte, []int) {
+	return file_proto_zone_proto_rawDescGZIP(), []int{30}
+}
+
+func (x *IdRequest) GetApiKey() string {
+	if x != nil {
+		return x.ApiKey
+	}
+	return ""
+}
+
+func (x *IdRequest) GetApiEmail() string {
+	if x != nil {
+		return x.ApiEmail
+	}
+	return ""
+}
+
+func (x *IdRequest) GetZoneId() string {
+	if x != nil {
+		return x.ZoneId
+	}
+	return ""
+}
+
 type ZoneCloudflareEntity_Plan struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -1890,7 +2071,7 @@ type ZoneCloudflareEntity_Plan struct {
 func (x *ZoneCloudflareEntity_Plan) Reset() {
 	*x = ZoneCloudflareEntity_Plan{}
 	if protoimpl.UnsafeEnabled {
-		mi := &file_proto_zone_proto_msgTypes[28]
+		mi := &file_proto_zone_proto_msgTypes[31]
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		ms.StoreMessageInfo(mi)
 	}
@@ -1903,7 +2084,7 @@ func (x *ZoneCloudflareEntity_Plan) String() string {
 func (*ZoneCloudflareEntity_Plan) ProtoMessage() {}
 
 func (x *ZoneCloudflareEntity_Plan) ProtoReflect() protoreflect.Message {
-	mi := &file_proto_zone_proto_msgTypes[28]
+	mi := &file_proto_zone_proto_msgTypes[31]
 	if protoimpl.UnsafeEnabled && x != nil {
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		if ms.LoadMessageInfo() == nil {
@@ -2197,124 +2378,167 @@ var file_proto_zone_proto_rawDesc = []byte{
 	0x33, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e,
 	0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52,
 	0x75, 0x6c, 0x65, 0x73, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x69, 0x65, 0x73, 0x53, 0x74,
-	0x72, 0x75, 0x63, 0x74, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x2a, 0x84, 0x01, 0x0a, 0x05, 0x50,
-	0x68, 0x61, 0x73, 0x65, 0x12, 0x19, 0x0a, 0x15, 0x68, 0x74, 0x74, 0x70, 0x5f, 0x72, 0x65, 0x71,
-	0x75, 0x65, 0x73, 0x74, 0x5f, 0x73, 0x61, 0x6e, 0x69, 0x74, 0x69, 0x7a, 0x65, 0x10, 0x00, 0x12,
-	0x1a, 0x0a, 0x16, 0x68, 0x74, 0x74, 0x70, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f,
-	0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x6f, 0x72, 0x6d, 0x10, 0x01, 0x12, 0x1f, 0x0a, 0x1b, 0x68,
-	0x74, 0x74, 0x70, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x6c, 0x61, 0x74, 0x65,
-	0x5f, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x6f, 0x72, 0x6d, 0x10, 0x0c, 0x12, 0x23, 0x0a, 0x1f,
-	0x68, 0x74, 0x74, 0x70, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x5f, 0x68, 0x65,
-	0x61, 0x64, 0x65, 0x72, 0x73, 0x5f, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x6f, 0x72, 0x6d, 0x10,
-	0x0e, 0x32, 0xf9, 0x0c, 0x0a, 0x0e, 0x5a, 0x6f, 0x6e, 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66,
-	0x6c, 0x61, 0x72, 0x65, 0x12, 0x7e, 0x0a, 0x16, 0x5a, 0x6f, 0x6e, 0x65, 0x49, 0x44, 0x42, 0x79,
-	0x4e, 0x61, 0x6d, 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x12, 0x31,
-	0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a,
-	0x6f, 0x6e, 0x65, 0x2e, 0x5a, 0x6f, 0x6e, 0x65, 0x49, 0x44, 0x42, 0x79, 0x4e, 0x61, 0x6d, 0x65,
-	0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72,
-	0x65, 0x1a, 0x2f, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70,
-	0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x5a, 0x6f, 0x6e, 0x65, 0x49, 0x44, 0x42, 0x79, 0x4e,
-	0x61, 0x6d, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
-	0x72, 0x65, 0x22, 0x00, 0x12, 0x71, 0x0a, 0x0b, 0x5a, 0x6f, 0x6e, 0x65, 0x44, 0x65, 0x74, 0x61,
-	0x69, 0x6c, 0x73, 0x12, 0x30, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65,
-	0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x5a, 0x6f, 0x6e, 0x65, 0x44, 0x65, 0x74,
-	0x61, 0x69, 0x6c, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64,
-	0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x2e, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
+	0x72, 0x75, 0x63, 0x74, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0x27, 0x0a, 0x0b, 0x41, 0x72,
+	0x67, 0x6f, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61,
+	0x62, 0x6c, 0x65, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62,
+	0x6c, 0x65, 0x64, 0x22, 0xad, 0x01, 0x0a, 0x1b, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x72,
+	0x67, 0x6f, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c,
+	0x61, 0x72, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x70, 0x69, 0x4b, 0x65, 0x79, 0x18, 0x01, 0x20,
+	0x01, 0x28, 0x09, 0x52, 0x06, 0x61, 0x70, 0x69, 0x4b, 0x65, 0x79, 0x12, 0x1a, 0x0a, 0x08, 0x61,
+	0x70, 0x69, 0x45, 0x6d, 0x61, 0x69, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61,
+	0x70, 0x69, 0x45, 0x6d, 0x61, 0x69, 0x6c, 0x12, 0x16, 0x0a, 0x06, 0x7a, 0x6f, 0x6e, 0x65, 0x49,
+	0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x7a, 0x6f, 0x6e, 0x65, 0x49, 0x64, 0x12,
+	0x42, 0x0a, 0x0c, 0x61, 0x72, 0x67, 0x6f, 0x5f, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x18,
+	0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
+	0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x41, 0x72, 0x67, 0x6f, 0x53,
+	0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x52, 0x0b, 0x61, 0x72, 0x67, 0x6f, 0x53, 0x65, 0x74, 0x74,
+	0x69, 0x6e, 0x67, 0x22, 0x57, 0x0a, 0x09, 0x49, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
+	0x12, 0x16, 0x0a, 0x06, 0x61, 0x70, 0x69, 0x4b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
+	0x52, 0x06, 0x61, 0x70, 0x69, 0x4b, 0x65, 0x79, 0x12, 0x1a, 0x0a, 0x08, 0x61, 0x70, 0x69, 0x45,
+	0x6d, 0x61, 0x69, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, 0x70, 0x69, 0x45,
+	0x6d, 0x61, 0x69, 0x6c, 0x12, 0x16, 0x0a, 0x06, 0x7a, 0x6f, 0x6e, 0x65, 0x49, 0x64, 0x18, 0x03,
+	0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x7a, 0x6f, 0x6e, 0x65, 0x49, 0x64, 0x2a, 0x84, 0x01, 0x0a,
+	0x05, 0x50, 0x68, 0x61, 0x73, 0x65, 0x12, 0x19, 0x0a, 0x15, 0x68, 0x74, 0x74, 0x70, 0x5f, 0x72,
+	0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x73, 0x61, 0x6e, 0x69, 0x74, 0x69, 0x7a, 0x65, 0x10,
+	0x00, 0x12, 0x1a, 0x0a, 0x16, 0x68, 0x74, 0x74, 0x70, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73,
+	0x74, 0x5f, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x6f, 0x72, 0x6d, 0x10, 0x01, 0x12, 0x1f, 0x0a,
+	0x1b, 0x68, 0x74, 0x74, 0x70, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x6c, 0x61,
+	0x74, 0x65, 0x5f, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x6f, 0x72, 0x6d, 0x10, 0x0c, 0x12, 0x23,
+	0x0a, 0x1f, 0x68, 0x74, 0x74, 0x70, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x5f,
+	0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x5f, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x6f, 0x72,
+	0x6d, 0x10, 0x0e, 0x32, 0xf9, 0x0f, 0x0a, 0x0e, 0x5a, 0x6f, 0x6e, 0x65, 0x43, 0x6c, 0x6f, 0x75,
+	0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x12, 0x7e, 0x0a, 0x16, 0x5a, 0x6f, 0x6e, 0x65, 0x49, 0x44,
+	0x42, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65,
+	0x12, 0x31, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69,
+	0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x5a, 0x6f, 0x6e, 0x65, 0x49, 0x44, 0x42, 0x79, 0x4e, 0x61,
+	0x6d, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c,
+	0x61, 0x72, 0x65, 0x1a, 0x2f, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65,
+	0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x5a, 0x6f, 0x6e, 0x65, 0x49, 0x44, 0x42,
+	0x79, 0x4e, 0x61, 0x6d, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66,
+	0x6c, 0x61, 0x72, 0x65, 0x22, 0x00, 0x12, 0x71, 0x0a, 0x0b, 0x5a, 0x6f, 0x6e, 0x65, 0x44, 0x65,
+	0x74, 0x61, 0x69, 0x6c, 0x73, 0x12, 0x30, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
 	0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x5a, 0x6f, 0x6e, 0x65, 0x44,
-	0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x43, 0x6c, 0x6f, 0x75, 0x64,
-	0x66, 0x6c, 0x61, 0x72, 0x65, 0x22, 0x00, 0x12, 0x68, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x5a, 0x6f,
-	0x6e, 0x65, 0x73, 0x12, 0x2d, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65,
-	0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x5a, 0x6f, 0x6e, 0x65,
-	0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
-	0x72, 0x65, 0x1a, 0x2b, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41,
-	0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x73,
-	0x52, 0x65, 0x70, 0x6c, 0x79, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x22,
-	0x00, 0x12, 0x68, 0x0a, 0x08, 0x45, 0x64, 0x69, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x12, 0x2d, 0x2e,
-	0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f,
-	0x6e, 0x65, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
-	0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x2b, 0x2e, 0x63,
+	0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f,
+	0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x2e, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66,
+	0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x5a, 0x6f, 0x6e,
+	0x65, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x43, 0x6c, 0x6f,
+	0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x22, 0x00, 0x12, 0x68, 0x0a, 0x08, 0x47, 0x65, 0x74,
+	0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x12, 0x2d, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
+	0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x5a, 0x6f,
+	0x6e, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66,
+	0x6c, 0x61, 0x72, 0x65, 0x1a, 0x2b, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72,
+	0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x5a, 0x6f, 0x6e,
+	0x65, 0x73, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72,
+	0x65, 0x22, 0x00, 0x12, 0x68, 0x0a, 0x08, 0x45, 0x64, 0x69, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x12,
+	0x2d, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e,
+	0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x52, 0x65, 0x71,
+	0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x2b,
+	0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a,
+	0x6f, 0x6e, 0x65, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x52, 0x65, 0x70, 0x6c,
+	0x79, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x22, 0x00, 0x12, 0x6e, 0x0a,
+	0x0a, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x5a, 0x6f, 0x6e, 0x65, 0x12, 0x2f, 0x2e, 0x63, 0x6c,
+	0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65,
+	0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x5a, 0x6f, 0x6e, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
+	0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x2d, 0x2e, 0x63,
 	0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e,
-	0x65, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x43,
-	0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x22, 0x00, 0x12, 0x6e, 0x0a, 0x0a, 0x44,
-	0x65, 0x6c, 0x65, 0x74, 0x65, 0x5a, 0x6f, 0x6e, 0x65, 0x12, 0x2f, 0x2e, 0x63, 0x6c, 0x6f, 0x75,
-	0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x44,
-	0x65, 0x6c, 0x65, 0x74, 0x65, 0x5a, 0x6f, 0x6e, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
-	0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x2d, 0x2e, 0x63, 0x6c, 0x6f,
+	0x65, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x5a, 0x6f, 0x6e, 0x65, 0x52, 0x65, 0x70, 0x6c,
+	0x79, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x22, 0x00, 0x12, 0x5c, 0x0a,
+	0x09, 0x4c, 0x69, 0x73, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x12, 0x2e, 0x2e, 0x63, 0x6c, 0x6f,
 	0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e,
-	0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x5a, 0x6f, 0x6e, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x43,
-	0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x22, 0x00, 0x12, 0x5c, 0x0a, 0x09, 0x4c,
-	0x69, 0x73, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x12, 0x2e, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64,
-	0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x4c, 0x69,
-	0x73, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c,
-	0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1d, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64,
-	0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x5a, 0x6f,
-	0x6e, 0x65, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00, 0x12, 0x72, 0x0a, 0x14, 0x4c, 0x69, 0x73,
-	0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49,
-	0x64, 0x12, 0x39, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70,
-	0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x73,
-	0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65,
-	0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1d, 0x2e, 0x63,
-	0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e,
-	0x65, 0x2e, 0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00, 0x12, 0x7d, 0x0a,
-	0x0f, 0x41, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x43, 0x68, 0x65, 0x63, 0x6b,
-	0x12, 0x34, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69,
-	0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x41, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e,
-	0x43, 0x68, 0x65, 0x63, 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75,
-	0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x32, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c,
-	0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x41, 0x63, 0x74, 0x69,
-	0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x52, 0x65, 0x70, 0x6c, 0x79,
-	0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x22, 0x00, 0x12, 0x65, 0x0a, 0x0c,
-	0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x12, 0x31, 0x2e, 0x63,
+	0x4c, 0x69, 0x73, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
+	0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1d, 0x2e, 0x63, 0x6c, 0x6f,
+	0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e,
+	0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00, 0x12, 0x72, 0x0a, 0x14, 0x4c,
+	0x69, 0x73, 0x74, 0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e,
+	0x74, 0x49, 0x64, 0x12, 0x39, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65,
+	0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x5a, 0x6f, 0x6e,
+	0x65, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49, 0x64, 0x52, 0x65, 0x71,
+	0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1d,
+	0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a,
+	0x6f, 0x6e, 0x65, 0x2e, 0x5a, 0x6f, 0x6e, 0x65, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00, 0x12,
+	0x7d, 0x0a, 0x0f, 0x41, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x43, 0x68, 0x65,
+	0x63, 0x6b, 0x12, 0x34, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41,
+	0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x41, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x69,
+	0x6f, 0x6e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c,
+	0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x32, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64,
+	0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x41, 0x63,
+	0x74, 0x69, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x52, 0x65, 0x70,
+	0x6c, 0x79, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x22, 0x00, 0x12, 0x65,
+	0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x12, 0x31,
+	0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a,
+	0x6f, 0x6e, 0x65, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65,
+	0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72,
+	0x65, 0x1a, 0x20, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70,
+	0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x4c,
+	0x69, 0x73, 0x74, 0x22, 0x00, 0x12, 0x65, 0x0a, 0x0e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50,
+	0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x12, 0x33, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66,
+	0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x43, 0x72, 0x65,
+	0x61, 0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
+	0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1c, 0x2e, 0x63,
 	0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e,
-	0x65, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x52, 0x65,
-	0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a,
-	0x20, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e,
-	0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x4c, 0x69, 0x73,
-	0x74, 0x22, 0x00, 0x12, 0x65, 0x0a, 0x0e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x61, 0x67,
+	0x65, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x22, 0x00, 0x12, 0x65, 0x0a, 0x0e,
+	0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x12, 0x33,
+	0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a,
+	0x6f, 0x6e, 0x65, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75,
+	0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c,
+	0x61, 0x72, 0x65, 0x1a, 0x1c, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65,
+	0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c,
+	0x65, 0x22, 0x00, 0x12, 0x65, 0x0a, 0x0e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x50, 0x61, 0x67,
 	0x65, 0x52, 0x75, 0x6c, 0x65, 0x12, 0x33, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
-	0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74,
+	0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74,
 	0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
 	0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1c, 0x2e, 0x63, 0x6c, 0x6f,
 	0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e,
-	0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x22, 0x00, 0x12, 0x65, 0x0a, 0x0e, 0x55, 0x70,
-	0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x12, 0x33, 0x2e, 0x63,
+	0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x22, 0x00, 0x12, 0x7f, 0x0a, 0x19, 0x55, 0x70,
+	0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x50, 0x72, 0x69,
+	0x6f, 0x72, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x3e, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66,
+	0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x55, 0x70, 0x64,
+	0x61, 0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x50, 0x72, 0x69, 0x6f,
+	0x72, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f,
+	0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x20, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66,
+	0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x50, 0x61, 0x67,
+	0x65, 0x52, 0x75, 0x6c, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00, 0x12, 0x63, 0x0a, 0x0d, 0x55,
+	0x70, 0x64, 0x61, 0x74, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x53, 0x65, 0x74, 0x12, 0x32, 0x2e, 0x63,
 	0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e,
-	0x65, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65,
-	0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72,
-	0x65, 0x1a, 0x1c, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70,
-	0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x22,
-	0x00, 0x12, 0x65, 0x0a, 0x0e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52,
-	0x75, 0x6c, 0x65, 0x12, 0x33, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65,
-	0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x50,
-	0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c,
-	0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1c, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64,
-	0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x50, 0x61,
-	0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x22, 0x00, 0x12, 0x7f, 0x0a, 0x19, 0x55, 0x70, 0x64, 0x61,
-	0x74, 0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x50, 0x72, 0x69, 0x6f, 0x72,
-	0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x3e, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
-	0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74,
-	0x65, 0x50, 0x61, 0x67, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69,
-	0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64,
-	0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x20, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
-	0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52,
-	0x75, 0x6c, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00, 0x12, 0x63, 0x0a, 0x0d, 0x55, 0x70, 0x64,
-	0x61, 0x74, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x53, 0x65, 0x74, 0x12, 0x32, 0x2e, 0x63, 0x6c, 0x6f,
-	0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e,
-	0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x53, 0x65, 0x74, 0x52, 0x65, 0x71,
-	0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1c,
+	0x65, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x52, 0x75, 0x6c, 0x65, 0x53, 0x65, 0x74, 0x52,
+	0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65,
+	0x1a, 0x1c, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69,
+	0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x52, 0x75, 0x6c, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00,
+	0x12, 0x5d, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6c, 0x65, 0x53, 0x65, 0x74, 0x12, 0x2f,
 	0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a,
-	0x6f, 0x6e, 0x65, 0x2e, 0x52, 0x75, 0x6c, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00, 0x12, 0x5d,
-	0x0a, 0x0a, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6c, 0x65, 0x53, 0x65, 0x74, 0x12, 0x2f, 0x2e, 0x63,
-	0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e,
-	0x65, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6c, 0x65, 0x53, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75,
-	0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1c, 0x2e,
+	0x6f, 0x6e, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6c, 0x65, 0x53, 0x65, 0x74, 0x52, 0x65,
+	0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a,
+	0x1c, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e,
+	0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x52, 0x75, 0x6c, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00, 0x12,
+	0x67, 0x0a, 0x11, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x72, 0x67, 0x6f, 0x53, 0x65, 0x74,
+	0x74, 0x69, 0x6e, 0x67, 0x12, 0x2f, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72,
+	0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65,
+	0x41, 0x72, 0x67, 0x6f, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64,
+	0x66, 0x6c, 0x61, 0x72, 0x65, 0x1a, 0x1f, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61,
+	0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x41, 0x72, 0x67, 0x6f, 0x53,
+	0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x22, 0x00, 0x12, 0x52, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x41,
+	0x72, 0x67, 0x6f, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x12, 0x1d, 0x2e, 0x63, 0x6c, 0x6f,
+	0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e,
+	0x49, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x63, 0x6c, 0x6f, 0x75,
+	0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x41,
+	0x72, 0x67, 0x6f, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x22, 0x00, 0x12, 0x5e, 0x0a, 0x1a,
+	0x47, 0x65, 0x74, 0x41, 0x72, 0x67, 0x6f, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x53, 0x75,
+	0x62, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1d, 0x2e, 0x63, 0x6c, 0x6f,
+	0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e,
+	0x49, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x63, 0x6c, 0x6f, 0x75,
+	0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x2e, 0x41,
+	0x72, 0x67, 0x6f, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x22, 0x00, 0x12, 0x61, 0x0a, 0x1d,
+	0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x72, 0x67, 0x6f, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e,
+	0x67, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1d, 0x2e,
 	0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f,
-	0x6e, 0x65, 0x2e, 0x52, 0x75, 0x6c, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x00, 0x42, 0x3c, 0x0a,
-	0x17, 0x69, 0x6f, 0x2e, 0x67, 0x72, 0x70, 0x63, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c,
-	0x61, 0x72, 0x65, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x42, 0x09, 0x7a, 0x6f, 0x6e, 0x65, 0x50, 0x72,
-	0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x14, 0x2e, 0x2f, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c,
-	0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2f, 0x7a, 0x6f, 0x6e, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f,
-	0x74, 0x6f, 0x33,
+	0x6e, 0x65, 0x2e, 0x49, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x63,
+	0x6c, 0x6f, 0x75, 0x64, 0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2e, 0x7a, 0x6f, 0x6e,
+	0x65, 0x2e, 0x41, 0x72, 0x67, 0x6f, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x22, 0x00, 0x42,
+	0x3c, 0x0a, 0x17, 0x69, 0x6f, 0x2e, 0x67, 0x72, 0x70, 0x63, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64,
+	0x66, 0x6c, 0x61, 0x72, 0x65, 0x2e, 0x7a, 0x6f, 0x6e, 0x65, 0x42, 0x09, 0x7a, 0x6f, 0x6e, 0x65,
+	0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x14, 0x2e, 0x2f, 0x63, 0x6c, 0x6f, 0x75, 0x64,
+	0x66, 0x6c, 0x61, 0x72, 0x65, 0x41, 0x70, 0x69, 0x2f, 0x7a, 0x6f, 0x6e, 0x65, 0x62, 0x06, 0x70,
+	0x72, 0x6f, 0x74, 0x6f, 0x33,
 }
 
 var (
@@ -2330,7 +2554,7 @@ func file_proto_zone_proto_rawDescGZIP() []byte {
 }
 
 var file_proto_zone_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
-var file_proto_zone_proto_msgTypes = make([]protoimpl.MessageInfo, 31)
+var file_proto_zone_proto_msgTypes = make([]protoimpl.MessageInfo, 34)
 var file_proto_zone_proto_goTypes = []interface{}{
 	(Phase)(0),                                         // 0: cloudflareApi.zone.Phase
 	(*ZoneCloudflareEntity)(nil),                       // 1: cloudflareApi.zone.ZoneCloudflareEntity
@@ -2361,13 +2585,16 @@ var file_proto_zone_proto_goTypes = []interface{}{
 	(*UpdateRuleSetRequestCloudflare)(nil),             // 26: cloudflareApi.zone.UpdateRuleSetRequestCloudflare
 	(*UpdatePageRulesPrioritiesStruct)(nil),            // 27: cloudflareApi.zone.UpdatePageRulesPrioritiesStruct
 	(*UpdatePageRulesPrioritiesRequestCloudflare)(nil), // 28: cloudflareApi.zone.UpdatePageRulesPrioritiesRequestCloudflare
-	(*ZoneCloudflareEntity_Plan)(nil),                  // 29: cloudflareApi.zone.ZoneCloudflareEntity.Plan
-	nil,                                                // 30: cloudflareApi.zone.Rule.RequestHeaderEntry
-	nil,                                                // 31: cloudflareApi.zone.Rule.ResponseHeaderEntry
+	(*ArgoSetting)(nil),                                // 29: cloudflareApi.zone.ArgoSetting
+	(*UpdateArgoRequestCloudflare)(nil),                // 30: cloudflareApi.zone.UpdateArgoRequestCloudflare
+	(*IdRequest)(nil),                                  // 31: cloudflareApi.zone.IdRequest
+	(*ZoneCloudflareEntity_Plan)(nil),                  // 32: cloudflareApi.zone.ZoneCloudflareEntity.Plan
+	nil,                                                // 33: cloudflareApi.zone.Rule.RequestHeaderEntry
+	nil,                                                // 34: cloudflareApi.zone.Rule.ResponseHeaderEntry
 }
 var file_proto_zone_proto_depIdxs = []int32{
-	29, // 0: cloudflareApi.zone.ZoneCloudflareEntity.plan:type_name -> cloudflareApi.zone.ZoneCloudflareEntity.Plan
-	29, // 1: cloudflareApi.zone.ZoneCloudflareEntity.plan_pending:type_name -> cloudflareApi.zone.ZoneCloudflareEntity.Plan
+	32, // 0: cloudflareApi.zone.ZoneCloudflareEntity.plan:type_name -> cloudflareApi.zone.ZoneCloudflareEntity.Plan
+	32, // 1: cloudflareApi.zone.ZoneCloudflareEntity.plan_pending:type_name -> cloudflareApi.zone.ZoneCloudflareEntity.Plan
 	1,  // 2: cloudflareApi.zone.ZoneDetailsReplyCloudflare.result:type_name -> cloudflareApi.zone.ZoneCloudflareEntity
 	1,  // 3: cloudflareApi.zone.GetZonesReplyCloudflare.result:type_name -> cloudflareApi.zone.ZoneCloudflareEntity
 	1,  // 4: cloudflareApi.zone.ZonesList.result:type_name -> cloudflareApi.zone.ZoneCloudflareEntity
@@ -2375,48 +2602,57 @@ var file_proto_zone_proto_depIdxs = []int32{
 	17, // 6: cloudflareApi.zone.PageRuleList.page_rules:type_name -> cloudflareApi.zone.PageRule
 	17, // 7: cloudflareApi.zone.CreatePageRuleRequestCloudflare.page_rule:type_name -> cloudflareApi.zone.PageRule
 	17, // 8: cloudflareApi.zone.UpdatePageRuleRequestCloudflare.page_rule:type_name -> cloudflareApi.zone.PageRule
-	30, // 9: cloudflareApi.zone.Rule.requestHeader:type_name -> cloudflareApi.zone.Rule.RequestHeaderEntry
-	31, // 10: cloudflareApi.zone.Rule.responseHeader:type_name -> cloudflareApi.zone.Rule.ResponseHeaderEntry
+	33, // 9: cloudflareApi.zone.Rule.requestHeader:type_name -> cloudflareApi.zone.Rule.RequestHeaderEntry
+	34, // 10: cloudflareApi.zone.Rule.responseHeader:type_name -> cloudflareApi.zone.Rule.ResponseHeaderEntry
 	23, // 11: cloudflareApi.zone.RuleList.rules:type_name -> cloudflareApi.zone.Rule
 	0,  // 12: cloudflareApi.zone.GetRuleSetRequestCloudflare.phase:type_name -> cloudflareApi.zone.Phase
 	0,  // 13: cloudflareApi.zone.UpdateRuleSetRequestCloudflare.phase:type_name -> cloudflareApi.zone.Phase
 	23, // 14: cloudflareApi.zone.UpdateRuleSetRequestCloudflare.rules:type_name -> cloudflareApi.zone.Rule
 	27, // 15: cloudflareApi.zone.UpdatePageRulesPrioritiesRequestCloudflare.data:type_name -> cloudflareApi.zone.UpdatePageRulesPrioritiesStruct
-	2,  // 16: cloudflareApi.zone.ZoneCloudflare.ZoneIDByNameCloudflare:input_type -> cloudflareApi.zone.ZoneIDByNameRequestCloudflare
-	4,  // 17: cloudflareApi.zone.ZoneCloudflare.ZoneDetails:input_type -> cloudflareApi.zone.ZoneDetailsRequestCloudflare
-	6,  // 18: cloudflareApi.zone.ZoneCloudflare.GetZones:input_type -> cloudflareApi.zone.GetZonesRequestCloudflare
-	11, // 19: cloudflareApi.zone.ZoneCloudflare.EditZone:input_type -> cloudflareApi.zone.EditZoneRequestCloudflare
-	13, // 20: cloudflareApi.zone.ZoneCloudflare.DeleteZone:input_type -> cloudflareApi.zone.DeleteZoneRequestCloudflare
-	8,  // 21: cloudflareApi.zone.ZoneCloudflare.ListZones:input_type -> cloudflareApi.zone.ListZonesRequestCloudflare
-	9,  // 22: cloudflareApi.zone.ZoneCloudflare.ListZonesByAccountId:input_type -> cloudflareApi.zone.ListZonesByAccountIdRequestCloudflare
-	15, // 23: cloudflareApi.zone.ZoneCloudflare.ActivationCheck:input_type -> cloudflareApi.zone.ActivationCheckRequestCloudflare
-	19, // 24: cloudflareApi.zone.ZoneCloudflare.ListPageRule:input_type -> cloudflareApi.zone.ListPageRuleRequestCloudflare
-	20, // 25: cloudflareApi.zone.ZoneCloudflare.CreatePageRule:input_type -> cloudflareApi.zone.CreatePageRuleRequestCloudflare
-	21, // 26: cloudflareApi.zone.ZoneCloudflare.UpdatePageRule:input_type -> cloudflareApi.zone.UpdatePageRuleRequestCloudflare
-	22, // 27: cloudflareApi.zone.ZoneCloudflare.DeletePageRule:input_type -> cloudflareApi.zone.DeletePageRuleRequestCloudflare
-	28, // 28: cloudflareApi.zone.ZoneCloudflare.UpdatePageRulesPriorities:input_type -> cloudflareApi.zone.UpdatePageRulesPrioritiesRequestCloudflare
-	26, // 29: cloudflareApi.zone.ZoneCloudflare.UpdateRuleSet:input_type -> cloudflareApi.zone.UpdateRuleSetRequestCloudflare
-	25, // 30: cloudflareApi.zone.ZoneCloudflare.GetRuleSet:input_type -> cloudflareApi.zone.GetRuleSetRequestCloudflare
-	3,  // 31: cloudflareApi.zone.ZoneCloudflare.ZoneIDByNameCloudflare:output_type -> cloudflareApi.zone.ZoneIDByNameReplyCloudflare
-	5,  // 32: cloudflareApi.zone.ZoneCloudflare.ZoneDetails:output_type -> cloudflareApi.zone.ZoneDetailsReplyCloudflare
-	7,  // 33: cloudflareApi.zone.ZoneCloudflare.GetZones:output_type -> cloudflareApi.zone.GetZonesReplyCloudflare
-	12, // 34: cloudflareApi.zone.ZoneCloudflare.EditZone:output_type -> cloudflareApi.zone.EditZoneReplyCloudflare
-	14, // 35: cloudflareApi.zone.ZoneCloudflare.DeleteZone:output_type -> cloudflareApi.zone.DeleteZoneReplyCloudflare
-	10, // 36: cloudflareApi.zone.ZoneCloudflare.ListZones:output_type -> cloudflareApi.zone.ZonesList
-	10, // 37: cloudflareApi.zone.ZoneCloudflare.ListZonesByAccountId:output_type -> cloudflareApi.zone.ZonesList
-	16, // 38: cloudflareApi.zone.ZoneCloudflare.ActivationCheck:output_type -> cloudflareApi.zone.ActivationCheckReplyCloudflare
-	18, // 39: cloudflareApi.zone.ZoneCloudflare.ListPageRule:output_type -> cloudflareApi.zone.PageRuleList
-	17, // 40: cloudflareApi.zone.ZoneCloudflare.CreatePageRule:output_type -> cloudflareApi.zone.PageRule
-	17, // 41: cloudflareApi.zone.ZoneCloudflare.UpdatePageRule:output_type -> cloudflareApi.zone.PageRule
-	17, // 42: cloudflareApi.zone.ZoneCloudflare.DeletePageRule:output_type -> cloudflareApi.zone.PageRule
-	18, // 43: cloudflareApi.zone.ZoneCloudflare.UpdatePageRulesPriorities:output_type -> cloudflareApi.zone.PageRuleList
-	24, // 44: cloudflareApi.zone.ZoneCloudflare.UpdateRuleSet:output_type -> cloudflareApi.zone.RuleList
-	24, // 45: cloudflareApi.zone.ZoneCloudflare.GetRuleSet:output_type -> cloudflareApi.zone.RuleList
-	31, // [31:46] is the sub-list for method output_type
-	16, // [16:31] is the sub-list for method input_type
-	16, // [16:16] is the sub-list for extension type_name
-	16, // [16:16] is the sub-list for extension extendee
-	0,  // [0:16] is the sub-list for field type_name
+	29, // 16: cloudflareApi.zone.UpdateArgoRequestCloudflare.argo_setting:type_name -> cloudflareApi.zone.ArgoSetting
+	2,  // 17: cloudflareApi.zone.ZoneCloudflare.ZoneIDByNameCloudflare:input_type -> cloudflareApi.zone.ZoneIDByNameRequestCloudflare
+	4,  // 18: cloudflareApi.zone.ZoneCloudflare.ZoneDetails:input_type -> cloudflareApi.zone.ZoneDetailsRequestCloudflare
+	6,  // 19: cloudflareApi.zone.ZoneCloudflare.GetZones:input_type -> cloudflareApi.zone.GetZonesRequestCloudflare
+	11, // 20: cloudflareApi.zone.ZoneCloudflare.EditZone:input_type -> cloudflareApi.zone.EditZoneRequestCloudflare
+	13, // 21: cloudflareApi.zone.ZoneCloudflare.DeleteZone:input_type -> cloudflareApi.zone.DeleteZoneRequestCloudflare
+	8,  // 22: cloudflareApi.zone.ZoneCloudflare.ListZones:input_type -> cloudflareApi.zone.ListZonesRequestCloudflare
+	9,  // 23: cloudflareApi.zone.ZoneCloudflare.ListZonesByAccountId:input_type -> cloudflareApi.zone.ListZonesByAccountIdRequestCloudflare
+	15, // 24: cloudflareApi.zone.ZoneCloudflare.ActivationCheck:input_type -> cloudflareApi.zone.ActivationCheckRequestCloudflare
+	19, // 25: cloudflareApi.zone.ZoneCloudflare.ListPageRule:input_type -> cloudflareApi.zone.ListPageRuleRequestCloudflare
+	20, // 26: cloudflareApi.zone.ZoneCloudflare.CreatePageRule:input_type -> cloudflareApi.zone.CreatePageRuleRequestCloudflare
+	21, // 27: cloudflareApi.zone.ZoneCloudflare.UpdatePageRule:input_type -> cloudflareApi.zone.UpdatePageRuleRequestCloudflare
+	22, // 28: cloudflareApi.zone.ZoneCloudflare.DeletePageRule:input_type -> cloudflareApi.zone.DeletePageRuleRequestCloudflare
+	28, // 29: cloudflareApi.zone.ZoneCloudflare.UpdatePageRulesPriorities:input_type -> cloudflareApi.zone.UpdatePageRulesPrioritiesRequestCloudflare
+	26, // 30: cloudflareApi.zone.ZoneCloudflare.UpdateRuleSet:input_type -> cloudflareApi.zone.UpdateRuleSetRequestCloudflare
+	25, // 31: cloudflareApi.zone.ZoneCloudflare.GetRuleSet:input_type -> cloudflareApi.zone.GetRuleSetRequestCloudflare
+	30, // 32: cloudflareApi.zone.ZoneCloudflare.UpdateArgoSetting:input_type -> cloudflareApi.zone.UpdateArgoRequestCloudflare
+	31, // 33: cloudflareApi.zone.ZoneCloudflare.GetArgoSetting:input_type -> cloudflareApi.zone.IdRequest
+	31, // 34: cloudflareApi.zone.ZoneCloudflare.GetArgoSettingSubscription:input_type -> cloudflareApi.zone.IdRequest
+	31, // 35: cloudflareApi.zone.ZoneCloudflare.CreateArgoSettingSubscription:input_type -> cloudflareApi.zone.IdRequest
+	3,  // 36: cloudflareApi.zone.ZoneCloudflare.ZoneIDByNameCloudflare:output_type -> cloudflareApi.zone.ZoneIDByNameReplyCloudflare
+	5,  // 37: cloudflareApi.zone.ZoneCloudflare.ZoneDetails:output_type -> cloudflareApi.zone.ZoneDetailsReplyCloudflare
+	7,  // 38: cloudflareApi.zone.ZoneCloudflare.GetZones:output_type -> cloudflareApi.zone.GetZonesReplyCloudflare
+	12, // 39: cloudflareApi.zone.ZoneCloudflare.EditZone:output_type -> cloudflareApi.zone.EditZoneReplyCloudflare
+	14, // 40: cloudflareApi.zone.ZoneCloudflare.DeleteZone:output_type -> cloudflareApi.zone.DeleteZoneReplyCloudflare
+	10, // 41: cloudflareApi.zone.ZoneCloudflare.ListZones:output_type -> cloudflareApi.zone.ZonesList
+	10, // 42: cloudflareApi.zone.ZoneCloudflare.ListZonesByAccountId:output_type -> cloudflareApi.zone.ZonesList
+	16, // 43: cloudflareApi.zone.ZoneCloudflare.ActivationCheck:output_type -> cloudflareApi.zone.ActivationCheckReplyCloudflare
+	18, // 44: cloudflareApi.zone.ZoneCloudflare.ListPageRule:output_type -> cloudflareApi.zone.PageRuleList
+	17, // 45: cloudflareApi.zone.ZoneCloudflare.CreatePageRule:output_type -> cloudflareApi.zone.PageRule
+	17, // 46: cloudflareApi.zone.ZoneCloudflare.UpdatePageRule:output_type -> cloudflareApi.zone.PageRule
+	17, // 47: cloudflareApi.zone.ZoneCloudflare.DeletePageRule:output_type -> cloudflareApi.zone.PageRule
+	18, // 48: cloudflareApi.zone.ZoneCloudflare.UpdatePageRulesPriorities:output_type -> cloudflareApi.zone.PageRuleList
+	24, // 49: cloudflareApi.zone.ZoneCloudflare.UpdateRuleSet:output_type -> cloudflareApi.zone.RuleList
+	24, // 50: cloudflareApi.zone.ZoneCloudflare.GetRuleSet:output_type -> cloudflareApi.zone.RuleList
+	29, // 51: cloudflareApi.zone.ZoneCloudflare.UpdateArgoSetting:output_type -> cloudflareApi.zone.ArgoSetting
+	29, // 52: cloudflareApi.zone.ZoneCloudflare.GetArgoSetting:output_type -> cloudflareApi.zone.ArgoSetting
+	29, // 53: cloudflareApi.zone.ZoneCloudflare.GetArgoSettingSubscription:output_type -> cloudflareApi.zone.ArgoSetting
+	29, // 54: cloudflareApi.zone.ZoneCloudflare.CreateArgoSettingSubscription:output_type -> cloudflareApi.zone.ArgoSetting
+	36, // [36:55] is the sub-list for method output_type
+	17, // [17:36] is the sub-list for method input_type
+	17, // [17:17] is the sub-list for extension type_name
+	17, // [17:17] is the sub-list for extension extendee
+	0,  // [0:17] is the sub-list for field type_name
 }
 
 func init() { file_proto_zone_proto_init() }
@@ -2762,6 +2998,42 @@ func file_proto_zone_proto_init() {
 			}
 		}
 		file_proto_zone_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*ArgoSetting); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
+		file_proto_zone_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*UpdateArgoRequestCloudflare); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
+		file_proto_zone_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*IdRequest); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
+		file_proto_zone_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} {
 			switch v := v.(*ZoneCloudflareEntity_Plan); i {
 			case 0:
 				return &v.state
@@ -2783,7 +3055,7 @@ func file_proto_zone_proto_init() {
 			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
 			RawDescriptor: file_proto_zone_proto_rawDesc,
 			NumEnums:      1,
-			NumMessages:   31,
+			NumMessages:   34,
 			NumExtensions: 0,
 			NumServices:   1,
 		},

+ 147 - 1
cloudflareApi/zone/zone_grpc.pb.go

@@ -1,7 +1,7 @@
 // Code generated by protoc-gen-go-grpc. DO NOT EDIT.
 // versions:
 // - protoc-gen-go-grpc v1.2.0
-// - protoc             v3.21.4
+// - protoc             v3.21.5
 // source: proto/zone.proto
 
 package zone
@@ -40,6 +40,11 @@ type ZoneCloudflareClient interface {
 	//RuleSet UR
 	UpdateRuleSet(ctx context.Context, in *UpdateRuleSetRequestCloudflare, opts ...grpc.CallOption) (*RuleList, error)
 	GetRuleSet(ctx context.Context, in *GetRuleSetRequestCloudflare, opts ...grpc.CallOption) (*RuleList, error)
+	//Argo Smart Routing Setting UR
+	UpdateArgoSetting(ctx context.Context, in *UpdateArgoRequestCloudflare, opts ...grpc.CallOption) (*ArgoSetting, error)
+	GetArgoSetting(ctx context.Context, in *IdRequest, opts ...grpc.CallOption) (*ArgoSetting, error)
+	GetArgoSettingSubscription(ctx context.Context, in *IdRequest, opts ...grpc.CallOption) (*ArgoSetting, error)
+	CreateArgoSettingSubscription(ctx context.Context, in *IdRequest, opts ...grpc.CallOption) (*ArgoSetting, error)
 }
 
 type zoneCloudflareClient struct {
@@ -185,6 +190,42 @@ func (c *zoneCloudflareClient) GetRuleSet(ctx context.Context, in *GetRuleSetReq
 	return out, nil
 }
 
+func (c *zoneCloudflareClient) UpdateArgoSetting(ctx context.Context, in *UpdateArgoRequestCloudflare, opts ...grpc.CallOption) (*ArgoSetting, error) {
+	out := new(ArgoSetting)
+	err := c.cc.Invoke(ctx, "/cloudflareApi.zone.ZoneCloudflare/UpdateArgoSetting", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
+func (c *zoneCloudflareClient) GetArgoSetting(ctx context.Context, in *IdRequest, opts ...grpc.CallOption) (*ArgoSetting, error) {
+	out := new(ArgoSetting)
+	err := c.cc.Invoke(ctx, "/cloudflareApi.zone.ZoneCloudflare/GetArgoSetting", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
+func (c *zoneCloudflareClient) GetArgoSettingSubscription(ctx context.Context, in *IdRequest, opts ...grpc.CallOption) (*ArgoSetting, error) {
+	out := new(ArgoSetting)
+	err := c.cc.Invoke(ctx, "/cloudflareApi.zone.ZoneCloudflare/GetArgoSettingSubscription", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
+func (c *zoneCloudflareClient) CreateArgoSettingSubscription(ctx context.Context, in *IdRequest, opts ...grpc.CallOption) (*ArgoSetting, error) {
+	out := new(ArgoSetting)
+	err := c.cc.Invoke(ctx, "/cloudflareApi.zone.ZoneCloudflare/CreateArgoSettingSubscription", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
 // ZoneCloudflareServer is the server API for ZoneCloudflare service.
 // All implementations must embed UnimplementedZoneCloudflareServer
 // for forward compatibility
@@ -207,6 +248,11 @@ type ZoneCloudflareServer interface {
 	//RuleSet UR
 	UpdateRuleSet(context.Context, *UpdateRuleSetRequestCloudflare) (*RuleList, error)
 	GetRuleSet(context.Context, *GetRuleSetRequestCloudflare) (*RuleList, error)
+	//Argo Smart Routing Setting UR
+	UpdateArgoSetting(context.Context, *UpdateArgoRequestCloudflare) (*ArgoSetting, error)
+	GetArgoSetting(context.Context, *IdRequest) (*ArgoSetting, error)
+	GetArgoSettingSubscription(context.Context, *IdRequest) (*ArgoSetting, error)
+	CreateArgoSettingSubscription(context.Context, *IdRequest) (*ArgoSetting, error)
 	mustEmbedUnimplementedZoneCloudflareServer()
 }
 
@@ -259,6 +305,18 @@ func (UnimplementedZoneCloudflareServer) UpdateRuleSet(context.Context, *UpdateR
 func (UnimplementedZoneCloudflareServer) GetRuleSet(context.Context, *GetRuleSetRequestCloudflare) (*RuleList, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method GetRuleSet not implemented")
 }
+func (UnimplementedZoneCloudflareServer) UpdateArgoSetting(context.Context, *UpdateArgoRequestCloudflare) (*ArgoSetting, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method UpdateArgoSetting not implemented")
+}
+func (UnimplementedZoneCloudflareServer) GetArgoSetting(context.Context, *IdRequest) (*ArgoSetting, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method GetArgoSetting not implemented")
+}
+func (UnimplementedZoneCloudflareServer) GetArgoSettingSubscription(context.Context, *IdRequest) (*ArgoSetting, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method GetArgoSettingSubscription not implemented")
+}
+func (UnimplementedZoneCloudflareServer) CreateArgoSettingSubscription(context.Context, *IdRequest) (*ArgoSetting, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method CreateArgoSettingSubscription not implemented")
+}
 func (UnimplementedZoneCloudflareServer) mustEmbedUnimplementedZoneCloudflareServer() {}
 
 // UnsafeZoneCloudflareServer may be embedded to opt out of forward compatibility for this service.
@@ -542,6 +600,78 @@ func _ZoneCloudflare_GetRuleSet_Handler(srv interface{}, ctx context.Context, de
 	return interceptor(ctx, in, info, handler)
 }
 
+func _ZoneCloudflare_UpdateArgoSetting_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(UpdateArgoRequestCloudflare)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(ZoneCloudflareServer).UpdateArgoSetting(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/cloudflareApi.zone.ZoneCloudflare/UpdateArgoSetting",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(ZoneCloudflareServer).UpdateArgoSetting(ctx, req.(*UpdateArgoRequestCloudflare))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
+func _ZoneCloudflare_GetArgoSetting_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(IdRequest)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(ZoneCloudflareServer).GetArgoSetting(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/cloudflareApi.zone.ZoneCloudflare/GetArgoSetting",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(ZoneCloudflareServer).GetArgoSetting(ctx, req.(*IdRequest))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
+func _ZoneCloudflare_GetArgoSettingSubscription_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(IdRequest)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(ZoneCloudflareServer).GetArgoSettingSubscription(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/cloudflareApi.zone.ZoneCloudflare/GetArgoSettingSubscription",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(ZoneCloudflareServer).GetArgoSettingSubscription(ctx, req.(*IdRequest))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
+func _ZoneCloudflare_CreateArgoSettingSubscription_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(IdRequest)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(ZoneCloudflareServer).CreateArgoSettingSubscription(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/cloudflareApi.zone.ZoneCloudflare/CreateArgoSettingSubscription",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(ZoneCloudflareServer).CreateArgoSettingSubscription(ctx, req.(*IdRequest))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
 // ZoneCloudflare_ServiceDesc is the grpc.ServiceDesc for ZoneCloudflare service.
 // It's only intended for direct use with grpc.RegisterService,
 // and not to be introspected or modified (even as a copy)
@@ -609,6 +739,22 @@ var ZoneCloudflare_ServiceDesc = grpc.ServiceDesc{
 			MethodName: "GetRuleSet",
 			Handler:    _ZoneCloudflare_GetRuleSet_Handler,
 		},
+		{
+			MethodName: "UpdateArgoSetting",
+			Handler:    _ZoneCloudflare_UpdateArgoSetting_Handler,
+		},
+		{
+			MethodName: "GetArgoSetting",
+			Handler:    _ZoneCloudflare_GetArgoSetting_Handler,
+		},
+		{
+			MethodName: "GetArgoSettingSubscription",
+			Handler:    _ZoneCloudflare_GetArgoSettingSubscription_Handler,
+		},
+		{
+			MethodName: "CreateArgoSettingSubscription",
+			Handler:    _ZoneCloudflare_CreateArgoSettingSubscription_Handler,
+		},
 	},
 	Streams:  []grpc.StreamDesc{},
 	Metadata: "proto/zone.proto",

+ 10 - 13
go.mod

@@ -4,6 +4,7 @@ go 1.18
 
 require (
 	github.com/cloudflare/cloudflare-go v0.46.0
+	github.com/jinzhu/copier v0.3.5
 	github.com/samber/lo v1.37.0
 	google.golang.org/grpc v1.48.0
 	google.golang.org/protobuf v1.28.1
@@ -68,7 +69,6 @@ require (
 	github.com/go-xmlfmt/xmlfmt v0.0.0-20191208150333-d5b6f63a941b // indirect
 	github.com/gobwas/glob v0.2.3 // indirect
 	github.com/gofrs/flock v0.8.1 // indirect
-	github.com/golang/glog v1.0.0 // indirect
 	github.com/golang/protobuf v1.5.2 // indirect
 	github.com/golangci/check v0.0.0-20180506172741-cfe4005ccda2 // indirect
 	github.com/golangci/dupl v0.0.0-20180902072040-3e9179ac440a // indirect
@@ -89,13 +89,12 @@ require (
 	github.com/gostaticanalysis/comment v1.4.2 // indirect
 	github.com/gostaticanalysis/forcetypeassert v0.1.0 // indirect
 	github.com/gostaticanalysis/nilerr v0.1.1 // indirect
-	github.com/grpc-ecosystem/grpc-gateway/v2 v2.11.2 // indirect
 	github.com/hashicorp/errwrap v1.1.0 // indirect
 	github.com/hashicorp/go-changelog v0.0.0-20220419201213-5edfc0d651d8 // indirect
 	github.com/hashicorp/go-checkpoint v0.5.0 // indirect
 	github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
 	github.com/hashicorp/go-multierror v1.1.1 // indirect
-	github.com/hashicorp/go-retryablehttp v0.7.1 // indirect
+	github.com/hashicorp/go-retryablehttp v0.7.2 // indirect
 	github.com/hashicorp/go-uuid v1.0.3 // indirect
 	github.com/hashicorp/go-version v1.6.0 // indirect
 	github.com/hashicorp/hc-install v0.4.0 // indirect
@@ -110,7 +109,6 @@ require (
 	github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect
 	github.com/jgautheron/goconst v1.5.1 // indirect
 	github.com/jingyugao/rowserrcheck v1.1.1 // indirect
-	github.com/jinzhu/copier v0.3.5 // indirect
 	github.com/jirfag/go-printf-func-name v0.0.0-20200119135958-7558a9eaa5af // indirect
 	github.com/julz/importas v0.1.0 // indirect
 	github.com/kevinburke/ssh_config v0.0.0-20201106050909-4977a11b4351 // indirect
@@ -204,17 +202,16 @@ require (
 	golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d // indirect
 	golang.org/x/exp v0.0.0-20220303212507-bbda1eaf7a17 // indirect
 	golang.org/x/exp/typeparams v0.0.0-20220613132600-b0d781184e0d // indirect
-	golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4 // indirect
-	golang.org/x/net v0.0.0-20220805013720-a33c5aa5df48 // indirect
-	golang.org/x/oauth2 v0.0.0-20220722155238-128564f6959c // indirect
-	golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 // indirect
-	golang.org/x/sys v0.0.0-20220804214406-8e32c043e418 // indirect
-	golang.org/x/text v0.3.7 // indirect
-	golang.org/x/time v0.0.0-20220224211638-0e9765cccd65 // indirect
-	golang.org/x/tools v0.1.12 // indirect
+	golang.org/x/mod v0.8.0 // indirect
+	golang.org/x/net v0.10.0 // indirect
+	golang.org/x/oauth2 v0.0.0-20220718184931-c8730f7fcb92 // indirect
+	golang.org/x/sync v0.1.0 // indirect
+	golang.org/x/sys v0.8.0 // indirect
+	golang.org/x/text v0.9.0 // indirect
+	golang.org/x/time v0.3.0 // indirect
+	golang.org/x/tools v0.6.0 // indirect
 	google.golang.org/appengine v1.6.7 // indirect
 	google.golang.org/genproto v0.0.0-20220808131553-a91ffa7f803e // indirect
-	google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.2.0 // indirect
 	gopkg.in/ini.v1 v1.66.6 // indirect
 	gopkg.in/warnings.v0 v0.1.2 // indirect
 	gopkg.in/yaml.v2 v2.4.0 // indirect

La diferencia del archivo ha sido suprimido porque es demasiado grande
+ 18 - 699
go.sum


+ 1 - 1
proto

@@ -1 +1 @@
-Subproject commit fe237209c10ccd3a425d1c398b7c16c701ad3146
+Subproject commit e1cbc80711aa7c3259731a3642944221e6de6f4f

+ 206 - 3
server/ZoneCloudflareServer.go

@@ -13,12 +13,217 @@ import (
 	"io/ioutil"
 	"log"
 	"net/http"
+	"time"
 )
 
 type ZoneServer struct {
 	zone.UnimplementedZoneCloudflareServer
 }
 
+type Subscription struct {
+	ID       string `json:"id"`
+	RatePlan struct {
+		ID                string   `json:"id"`
+		PublicName        string   `json:"public_name"`
+		Currency          string   `json:"currency"`
+		Scope             string   `json:"scope"`
+		ExternallyManaged bool     `json:"externally_managed"`
+		Sets              []string `json:"sets"`
+		IsContract        bool     `json:"is_contract"`
+	} `json:"rate_plan"`
+	ComponentValues []struct {
+		Name    string `json:"name"`
+		Value   int    `json:"value"`
+		Default int    `json:"default,omitempty"`
+	} `json:"component_values"`
+	Zone struct {
+		ID   string `json:"id"`
+		Name string `json:"name"`
+	} `json:"zone"`
+	Frequency string `json:"frequency"`
+	Currency  string `json:"currency"`
+	Price     int    `json:"price"`
+	Product   struct {
+		Name       string `json:"name"`
+		Period     string `json:"period"`
+		Billing    string `json:"billing"`
+		PublicName string `json:"public_name"`
+		Duration   int    `json:"duration"`
+	} `json:"product"`
+	CancelAtPeriodEnd bool      `json:"cancel_at_period_end"`
+	CreatedDate       time.Time `json:"created_date"`
+}
+
+var ArgoSubscriptionId = "argo_zone_ent_tryout"
+
+func (s *ZoneServer) GetArgoSettingSubscription(ctx context.Context, request *zone.IdRequest) (*zone.ArgoSetting, error) {
+	log.Printf("apiKey Received: %v", request.GetApiKey())
+	log.Printf("apiEmail Received: %v", request.GetApiEmail())
+	log.Printf("zoneId Received: %v", request.GetZoneId())
+
+	//设置HTTP请求
+	client := &http.Client{}
+	req, err := http.NewRequest("GET", "https://api.cloudflare.com/client/v4/zones/"+request.ZoneId+"/subscriptions", nil)
+	if err != nil {
+		return nil, err
+	}
+
+	req.Header.Add("X-Auth-Key", request.GetApiKey())
+	req.Header.Add("X-Auth-Email", request.GetApiEmail())
+
+	//执行HTTP请求
+	resp, err := client.Do(req)
+	if err != nil {
+		return nil, err
+	}
+	defer func(Body io.ReadCloser) {
+		_ = Body.Close()
+	}(resp.Body)
+	body, _ := ioutil.ReadAll(resp.Body)
+
+	type ResponseType struct {
+		Errors     []interface{}  `json:"errors"`
+		Messages   []interface{}  `json:"messages"`
+		Result     []Subscription `json:"result"`
+		ResultInfo struct {
+			NextPage bool `json:"next_page"`
+		} `json:"result_info"`
+		Success bool `json:"success"`
+	}
+	var r ResponseType
+	err = json.Unmarshal(body, &r)
+
+	//处理返回逻辑
+	if err != nil {
+		return nil, fmt.Errorf("%s: %w", "error unmarshalling the JSON response", err)
+	}
+	if r.Success != true {
+		return nil, fmt.Errorf("%s", r.Errors)
+	}
+	log.Printf("Response: %v", r)
+
+	for _, v := range r.Result {
+
+		if v.RatePlan.ID == ArgoSubscriptionId {
+			return &zone.ArgoSetting{Enabled: true}, nil
+		}
+	}
+	return &zone.ArgoSetting{Enabled: false}, nil
+}
+
+func (s *ZoneServer) CreateArgoSettingSubscription(ctx context.Context, request *zone.IdRequest) (*zone.ArgoSetting, error) {
+	log.Printf("apiKey Received: %v", request.GetApiKey())
+	log.Printf("apiEmail Received: %v", request.GetApiEmail())
+	log.Printf("zoneId Received: %v", request.GetZoneId())
+
+	type RequestType struct {
+		RatePlan struct {
+			ID string `json:"id"`
+		} `json:"rate_plan"`
+		Zone struct {
+			ID   string `json:"id"`
+			Name string `json:"name"`
+		} `json:"zone"`
+	}
+	type ResponseType struct {
+		Errors   []interface{} `json:"errors"`
+		Messages []interface{} `json:"messages"`
+		Result   Subscription  `json:"result"`
+		Success  bool          `json:"success"`
+	}
+	bytesData, err := json.Marshal(RequestType{
+		RatePlan: struct {
+			ID string `json:"id"`
+		}{
+			ID: ArgoSubscriptionId,
+		},
+		Zone: struct {
+			ID   string `json:"id"`
+			Name string `json:"name"`
+		}{
+			ID: request.ZoneId,
+		},
+	})
+	if err != nil {
+		return nil, err
+	}
+	//设置HTTP请求
+	client := &http.Client{}
+	req, err := http.NewRequest("POST", "https://api.cloudflare.com/client/v4/zones/"+request.ZoneId+"/subscription", bytes.NewReader(bytesData))
+	if err != nil {
+		return nil, err
+	}
+
+	req.Header.Add("X-Auth-Key", request.GetApiKey())
+	req.Header.Add("X-Auth-Email", request.GetApiEmail())
+
+	//执行HTTP请求
+	resp, err := client.Do(req)
+	if err != nil {
+		return nil, err
+	}
+	defer func(Body io.ReadCloser) {
+		_ = Body.Close()
+	}(resp.Body)
+	body, _ := ioutil.ReadAll(resp.Body)
+
+	var r ResponseType
+	err = json.Unmarshal(body, &r)
+
+	//处理返回逻辑
+	if err != nil {
+		return nil, fmt.Errorf("%s: %w", "error unmarshalling the JSON response", err)
+	}
+	if r.Success != true {
+		return nil, fmt.Errorf("%s", r.Errors)
+	}
+	log.Printf("Response: %v", r)
+
+	if r.Result.RatePlan.ID == ArgoSubscriptionId {
+		return &zone.ArgoSetting{Enabled: true}, nil
+	}
+
+	return &zone.ArgoSetting{Enabled: false}, nil
+}
+
+func (s *ZoneServer) UpdateArgoSetting(ctx context.Context, requestCloudflare *zone.UpdateArgoRequestCloudflare) (*zone.ArgoSetting, error) {
+	log.Printf("apiKey Received: %v", requestCloudflare.GetApiKey())
+	log.Printf("apiEmail Received: %v", requestCloudflare.GetApiEmail())
+	log.Printf("zoneId Received: %v", requestCloudflare.GetZoneId())
+
+	api, err := cloudflare.New(requestCloudflare.GetApiKey(), requestCloudflare.GetApiEmail())
+	if err != nil {
+		return nil, err
+	}
+
+	settingValue := Proto2GoArgoSetting(requestCloudflare.GetArgoSetting())
+
+	setting, err := api.UpdateArgoSmartRouting(ctx, requestCloudflare.ZoneId, settingValue)
+	if err != nil {
+		return nil, err
+	}
+
+	return Go2ProtoArgoSetting(setting.Value), nil
+}
+
+func (s *ZoneServer) GetArgoSetting(ctx context.Context, requestCloudflare *zone.IdRequest) (*zone.ArgoSetting, error) {
+	log.Printf("apiKey Received: %v", requestCloudflare.GetApiKey())
+	log.Printf("apiEmail Received: %v", requestCloudflare.GetApiEmail())
+	log.Printf("zoneId Received: %v", requestCloudflare.GetZoneId())
+
+	api, err := cloudflare.New(requestCloudflare.GetApiKey(), requestCloudflare.GetApiEmail())
+	if err != nil {
+		return nil, err
+	}
+
+	setting, err := api.ArgoSmartRouting(ctx, requestCloudflare.ZoneId)
+	if err != nil {
+		return nil, err
+	}
+
+	return Go2ProtoArgoSetting(setting.Value), nil
+}
+
 func (s *ZoneServer) ZoneIDByNameCloudflare(ctx context.Context, requestCloudflare *zone.ZoneIDByNameRequestCloudflare) (*zone.ZoneIDByNameReplyCloudflare, error) {
 
 	log.Printf("apiKey Received: %v", requestCloudflare.GetApiKey())
@@ -70,9 +275,7 @@ func (s *ZoneServer) GetZones(ctx context.Context, requestCloudflare *zone.GetZo
 		return nil, err
 	}
 
-	ctxAPI := context.Background()
-
-	details, err := api.ListZones(ctxAPI, "name", requestCloudflare.GetDomain())
+	details, err := api.ListZones(ctx, "name", requestCloudflare.GetDomain())
 	if err != nil {
 		return nil, err
 	}

+ 247 - 0
server/ZoneCloudflareServer_test.go

@@ -2,6 +2,7 @@ package server
 
 import (
 	"cfTest/cloudflareApi/zone"
+	"reflect"
 
 	"context"
 	"github.com/samber/lo"
@@ -251,3 +252,249 @@ func TestZoneServer_UpdateRuleSet(t *testing.T) {
 		})
 	}
 }
+
+func TestZoneServer_GetArgoSetting(t *testing.T) {
+	type fields struct {
+		UnimplementedZoneCloudflareServer zone.UnimplementedZoneCloudflareServer
+	}
+	type args struct {
+		ctx               context.Context
+		requestCloudflare *zone.IdRequest
+	}
+	tests := []struct {
+		name    string
+		fields  fields
+		args    args
+		want    *zone.ArgoSetting
+		wantErr bool
+	}{
+		{
+			name: "test1",
+			fields: fields{
+				UnimplementedZoneCloudflareServer: zone.UnimplementedZoneCloudflareServer{},
+			},
+			args: args{
+				ctx: context.Background(),
+				requestCloudflare: &zone.IdRequest{
+					ApiKey:   apiKey,
+					ApiEmail: apiEmail,
+					ZoneId:   "f7eefa29114db32ab14397bdd5048ec8",
+				},
+			},
+			want:    &zone.ArgoSetting{Enabled: true},
+			wantErr: false,
+		},
+		{
+			name: "test1",
+			fields: fields{
+				UnimplementedZoneCloudflareServer: zone.UnimplementedZoneCloudflareServer{},
+			},
+			args: args{
+				ctx: context.Background(),
+				requestCloudflare: &zone.IdRequest{
+					ApiKey:   apiKey,
+					ApiEmail: apiEmail,
+					ZoneId:   "f7eefa29114db32ab14397bdd5048ec8",
+				},
+			},
+			want:    &zone.ArgoSetting{Enabled: false},
+			wantErr: false,
+		},
+	}
+	for _, tt := range tests {
+		t.Run(tt.name, func(t *testing.T) {
+			s := &ZoneServer{
+				UnimplementedZoneCloudflareServer: tt.fields.UnimplementedZoneCloudflareServer,
+			}
+			got, err := s.GetArgoSetting(tt.args.ctx, tt.args.requestCloudflare)
+			if (err != nil) != tt.wantErr {
+				t.Errorf("GetArgoSetting() error = %v, wantErr %v", err, tt.wantErr)
+				return
+			}
+			if !reflect.DeepEqual(got, tt.want) {
+				t.Errorf("GetArgoSetting() got = %v, want %v", got, tt.want)
+			}
+		})
+	}
+}
+
+func TestZoneServer_UpdateArgoSetting(t *testing.T) {
+	type fields struct {
+		UnimplementedZoneCloudflareServer zone.UnimplementedZoneCloudflareServer
+	}
+	type args struct {
+		ctx               context.Context
+		requestCloudflare *zone.UpdateArgoRequestCloudflare
+	}
+	tests := []struct {
+		name    string
+		fields  fields
+		args    args
+		want    *zone.ArgoSetting
+		wantErr bool
+	}{
+		{
+			name: "test1",
+			fields: fields{
+				UnimplementedZoneCloudflareServer: zone.UnimplementedZoneCloudflareServer{},
+			},
+			args: args{
+				ctx: context.Background(),
+				requestCloudflare: &zone.UpdateArgoRequestCloudflare{
+					ApiKey:      apiKey,
+					ApiEmail:    apiEmail,
+					ZoneId:      "f7eefa29114db32ab14397bdd5048ec8",
+					ArgoSetting: &zone.ArgoSetting{Enabled: false},
+				},
+			},
+			want:    &zone.ArgoSetting{Enabled: false},
+			wantErr: false,
+		},
+		{
+			name: "test1",
+			fields: fields{
+				UnimplementedZoneCloudflareServer: zone.UnimplementedZoneCloudflareServer{},
+			},
+			args: args{
+				ctx: context.Background(),
+				requestCloudflare: &zone.UpdateArgoRequestCloudflare{
+					ApiKey:      apiKey,
+					ApiEmail:    apiEmail,
+					ZoneId:      "f7eefa29114db32ab14397bdd5048ec8",
+					ArgoSetting: &zone.ArgoSetting{Enabled: true},
+				},
+			},
+			want:    &zone.ArgoSetting{Enabled: true},
+			wantErr: false,
+		},
+	}
+	for _, tt := range tests {
+		t.Run(tt.name, func(t *testing.T) {
+			s := &ZoneServer{
+				UnimplementedZoneCloudflareServer: tt.fields.UnimplementedZoneCloudflareServer,
+			}
+			got, err := s.UpdateArgoSetting(tt.args.ctx, tt.args.requestCloudflare)
+			if (err != nil) != tt.wantErr {
+				t.Errorf("UpdateArgoSetting() error = %v, wantErr %v", err, tt.wantErr)
+				return
+			}
+			if !reflect.DeepEqual(got, tt.want) {
+				t.Errorf("UpdateArgoSetting() got = %v, want %v", got, tt.want)
+			}
+		})
+	}
+}
+
+func TestZoneServer_GetArgoSettingSubscription(t *testing.T) {
+	type fields struct {
+		UnimplementedZoneCloudflareServer zone.UnimplementedZoneCloudflareServer
+	}
+	type args struct {
+		ctx     context.Context
+		request *zone.IdRequest
+	}
+	tests := []struct {
+		name    string
+		fields  fields
+		args    args
+		want    *zone.ArgoSetting
+		wantErr bool
+	}{
+		{
+			name: "启用测试",
+			fields: fields{
+				UnimplementedZoneCloudflareServer: zone.UnimplementedZoneCloudflareServer{},
+			},
+			args: args{
+				ctx: nil,
+				request: &zone.IdRequest{
+					ApiKey:   apiKey,
+					ApiEmail: apiEmail,
+					ZoneId:   "f7eefa29114db32ab14397bdd5048ec8",
+				},
+			},
+			want:    &zone.ArgoSetting{Enabled: true},
+			wantErr: false,
+		},
+		{
+			name: "未启用测试",
+			fields: fields{
+				UnimplementedZoneCloudflareServer: zone.UnimplementedZoneCloudflareServer{},
+			},
+			args: args{
+				ctx: nil,
+				request: &zone.IdRequest{
+					ApiKey:   apiKey,
+					ApiEmail: apiEmail,
+					ZoneId:   "6d89e53e52a08fc51b99628ff546c7fb",
+				},
+			},
+			want:    &zone.ArgoSetting{Enabled: false},
+			wantErr: false,
+		},
+	}
+	for _, tt := range tests {
+		t.Run(tt.name, func(t *testing.T) {
+			s := &ZoneServer{
+				UnimplementedZoneCloudflareServer: tt.fields.UnimplementedZoneCloudflareServer,
+			}
+			got, err := s.GetArgoSettingSubscription(tt.args.ctx, tt.args.request)
+			if (err != nil) != tt.wantErr {
+				t.Errorf("GetArgoSettingSubscription() error = %v, wantErr %v", err, tt.wantErr)
+				return
+			}
+			if !reflect.DeepEqual(got, tt.want) {
+				t.Errorf("GetArgoSettingSubscription() got = %v, want %v", got, tt.want)
+			}
+		})
+	}
+}
+
+func TestZoneServer_CreateArgoSettingSubscription(t *testing.T) {
+	type fields struct {
+		UnimplementedZoneCloudflareServer zone.UnimplementedZoneCloudflareServer
+	}
+	type args struct {
+		ctx     context.Context
+		request *zone.IdRequest
+	}
+	tests := []struct {
+		name    string
+		fields  fields
+		args    args
+		want    *zone.ArgoSetting
+		wantErr bool
+	}{
+		{
+			name: "测试",
+			fields: fields{
+				UnimplementedZoneCloudflareServer: zone.UnimplementedZoneCloudflareServer{},
+			},
+			args: args{
+				ctx: nil,
+				request: &zone.IdRequest{
+					ApiKey:   apiKey,
+					ApiEmail: apiEmail,
+					ZoneId:   "7a25de4f4ea643e99c66e84e7498ccc6",
+				},
+			},
+			want:    &zone.ArgoSetting{Enabled: true},
+			wantErr: false,
+		},
+	}
+	for _, tt := range tests {
+		t.Run(tt.name, func(t *testing.T) {
+			s := &ZoneServer{
+				UnimplementedZoneCloudflareServer: tt.fields.UnimplementedZoneCloudflareServer,
+			}
+			got, err := s.CreateArgoSettingSubscription(tt.args.ctx, tt.args.request)
+			if (err != nil) != tt.wantErr {
+				t.Errorf("CreateArgoSettingSubscription() error = %v, wantErr %v", err, tt.wantErr)
+				return
+			}
+			if !reflect.DeepEqual(got, tt.want) {
+				t.Errorf("CreateArgoSettingSubscription() got = %v, want %v", got, tt.want)
+			}
+		})
+	}
+}

+ 14 - 0
server/zone_convert.go

@@ -419,3 +419,17 @@ func Go2ProtoPageRule(rule *cloudflare.PageRule) *zone.PageRule {
 	}
 	return pageRule
 }
+func Proto2GoArgoSetting(setting *zone.ArgoSetting) string {
+	if setting.Enabled {
+		return "on"
+	} else {
+		return "off"
+	}
+}
+func Go2ProtoArgoSetting(setting string) *zone.ArgoSetting {
+	if setting == "on" {
+		return &zone.ArgoSetting{Enabled: true}
+	} else {
+		return &zone.ArgoSetting{Enabled: false}
+	}
+}