github.com/gravitational/teleport/api@v0.0.0-20240507183017-3110591cbafc/gen/proto/go/userpreferences/v1/onboard.pb.go (about) 1 // Copyright 2023 Gravitational, Inc 2 // 3 // Licensed under the Apache License, Version 2.0 (the "License"); 4 // you may not use this file except in compliance with the License. 5 // You may obtain a copy of the License at 6 // 7 // http://www.apache.org/licenses/LICENSE-2.0 8 // 9 // Unless required by applicable law or agreed to in writing, software 10 // distributed under the License is distributed on an "AS IS" BASIS, 11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 // See the License for the specific language governing permissions and 13 // limitations under the License. 14 15 // Code generated by protoc-gen-go. DO NOT EDIT. 16 // versions: 17 // protoc-gen-go v1.34.0 18 // protoc (unknown) 19 // source: teleport/userpreferences/v1/onboard.proto 20 21 package userpreferencesv1 22 23 import ( 24 protoreflect "google.golang.org/protobuf/reflect/protoreflect" 25 protoimpl "google.golang.org/protobuf/runtime/protoimpl" 26 reflect "reflect" 27 sync "sync" 28 ) 29 30 const ( 31 // Verify that this generated code is sufficiently up-to-date. 32 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) 33 // Verify that runtime/protoimpl is sufficiently up-to-date. 34 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) 35 ) 36 37 // Resources are the Resource options in the onboarding questionnaire 38 type Resource int32 39 40 const ( 41 Resource_RESOURCE_UNSPECIFIED Resource = 0 42 Resource_RESOURCE_WINDOWS_DESKTOPS Resource = 1 43 Resource_RESOURCE_SERVER_SSH Resource = 2 44 Resource_RESOURCE_DATABASES Resource = 3 45 Resource_RESOURCE_KUBERNETES Resource = 4 46 Resource_RESOURCE_WEB_APPLICATIONS Resource = 5 47 ) 48 49 // Enum value maps for Resource. 50 var ( 51 Resource_name = map[int32]string{ 52 0: "RESOURCE_UNSPECIFIED", 53 1: "RESOURCE_WINDOWS_DESKTOPS", 54 2: "RESOURCE_SERVER_SSH", 55 3: "RESOURCE_DATABASES", 56 4: "RESOURCE_KUBERNETES", 57 5: "RESOURCE_WEB_APPLICATIONS", 58 } 59 Resource_value = map[string]int32{ 60 "RESOURCE_UNSPECIFIED": 0, 61 "RESOURCE_WINDOWS_DESKTOPS": 1, 62 "RESOURCE_SERVER_SSH": 2, 63 "RESOURCE_DATABASES": 3, 64 "RESOURCE_KUBERNETES": 4, 65 "RESOURCE_WEB_APPLICATIONS": 5, 66 } 67 ) 68 69 func (x Resource) Enum() *Resource { 70 p := new(Resource) 71 *p = x 72 return p 73 } 74 75 func (x Resource) String() string { 76 return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) 77 } 78 79 func (Resource) Descriptor() protoreflect.EnumDescriptor { 80 return file_teleport_userpreferences_v1_onboard_proto_enumTypes[0].Descriptor() 81 } 82 83 func (Resource) Type() protoreflect.EnumType { 84 return &file_teleport_userpreferences_v1_onboard_proto_enumTypes[0] 85 } 86 87 func (x Resource) Number() protoreflect.EnumNumber { 88 return protoreflect.EnumNumber(x) 89 } 90 91 // Deprecated: Use Resource.Descriptor instead. 92 func (Resource) EnumDescriptor() ([]byte, []int) { 93 return file_teleport_userpreferences_v1_onboard_proto_rawDescGZIP(), []int{0} 94 } 95 96 // MarketingParams are the parameters associated with a user via marketing campaign at the time of sign up. 97 // They contain both traditional Urchin Tracking Module (UTM) parameters as well as custom parameters. 98 type MarketingParams struct { 99 state protoimpl.MessageState 100 sizeCache protoimpl.SizeCache 101 unknownFields protoimpl.UnknownFields 102 103 // campaign is the UTM campaign parameter which identifies a specific product promotion 104 Campaign string `protobuf:"bytes,1,opt,name=campaign,proto3" json:"campaign,omitempty"` 105 // source is the UTM source parameter which identifies which site sent the traffic 106 Source string `protobuf:"bytes,2,opt,name=source,proto3" json:"source,omitempty"` 107 // medium is the UTM medium parameter which identifies what type of link was used 108 Medium string `protobuf:"bytes,3,opt,name=medium,proto3" json:"medium,omitempty"` 109 // intent is the internal query param, which identifies any additional marketing intentions 110 // via internally set and directed parameters. 111 Intent string `protobuf:"bytes,4,opt,name=intent,proto3" json:"intent,omitempty"` 112 } 113 114 func (x *MarketingParams) Reset() { 115 *x = MarketingParams{} 116 if protoimpl.UnsafeEnabled { 117 mi := &file_teleport_userpreferences_v1_onboard_proto_msgTypes[0] 118 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 119 ms.StoreMessageInfo(mi) 120 } 121 } 122 123 func (x *MarketingParams) String() string { 124 return protoimpl.X.MessageStringOf(x) 125 } 126 127 func (*MarketingParams) ProtoMessage() {} 128 129 func (x *MarketingParams) ProtoReflect() protoreflect.Message { 130 mi := &file_teleport_userpreferences_v1_onboard_proto_msgTypes[0] 131 if protoimpl.UnsafeEnabled && x != nil { 132 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 133 if ms.LoadMessageInfo() == nil { 134 ms.StoreMessageInfo(mi) 135 } 136 return ms 137 } 138 return mi.MessageOf(x) 139 } 140 141 // Deprecated: Use MarketingParams.ProtoReflect.Descriptor instead. 142 func (*MarketingParams) Descriptor() ([]byte, []int) { 143 return file_teleport_userpreferences_v1_onboard_proto_rawDescGZIP(), []int{0} 144 } 145 146 func (x *MarketingParams) GetCampaign() string { 147 if x != nil { 148 return x.Campaign 149 } 150 return "" 151 } 152 153 func (x *MarketingParams) GetSource() string { 154 if x != nil { 155 return x.Source 156 } 157 return "" 158 } 159 160 func (x *MarketingParams) GetMedium() string { 161 if x != nil { 162 return x.Medium 163 } 164 return "" 165 } 166 167 func (x *MarketingParams) GetIntent() string { 168 if x != nil { 169 return x.Intent 170 } 171 return "" 172 } 173 174 // OnboardUserPreferences is the user preferences selected during onboarding. 175 type OnboardUserPreferences struct { 176 state protoimpl.MessageState 177 sizeCache protoimpl.SizeCache 178 unknownFields protoimpl.UnknownFields 179 180 // preferredResources is an array of the resources a user selected during their onboarding questionnaire. 181 PreferredResources []Resource `protobuf:"varint,1,rep,packed,name=preferred_resources,json=preferredResources,proto3,enum=teleport.userpreferences.v1.Resource" json:"preferred_resources,omitempty"` 182 // marketingParams are the parameters associated with a user via marketing campaign at the time of sign up 183 MarketingParams *MarketingParams `protobuf:"bytes,2,opt,name=marketing_params,json=marketingParams,proto3" json:"marketing_params,omitempty"` 184 } 185 186 func (x *OnboardUserPreferences) Reset() { 187 *x = OnboardUserPreferences{} 188 if protoimpl.UnsafeEnabled { 189 mi := &file_teleport_userpreferences_v1_onboard_proto_msgTypes[1] 190 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 191 ms.StoreMessageInfo(mi) 192 } 193 } 194 195 func (x *OnboardUserPreferences) String() string { 196 return protoimpl.X.MessageStringOf(x) 197 } 198 199 func (*OnboardUserPreferences) ProtoMessage() {} 200 201 func (x *OnboardUserPreferences) ProtoReflect() protoreflect.Message { 202 mi := &file_teleport_userpreferences_v1_onboard_proto_msgTypes[1] 203 if protoimpl.UnsafeEnabled && x != nil { 204 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 205 if ms.LoadMessageInfo() == nil { 206 ms.StoreMessageInfo(mi) 207 } 208 return ms 209 } 210 return mi.MessageOf(x) 211 } 212 213 // Deprecated: Use OnboardUserPreferences.ProtoReflect.Descriptor instead. 214 func (*OnboardUserPreferences) Descriptor() ([]byte, []int) { 215 return file_teleport_userpreferences_v1_onboard_proto_rawDescGZIP(), []int{1} 216 } 217 218 func (x *OnboardUserPreferences) GetPreferredResources() []Resource { 219 if x != nil { 220 return x.PreferredResources 221 } 222 return nil 223 } 224 225 func (x *OnboardUserPreferences) GetMarketingParams() *MarketingParams { 226 if x != nil { 227 return x.MarketingParams 228 } 229 return nil 230 } 231 232 var File_teleport_userpreferences_v1_onboard_proto protoreflect.FileDescriptor 233 234 var file_teleport_userpreferences_v1_onboard_proto_rawDesc = []byte{ 235 0x0a, 0x29, 0x74, 0x65, 0x6c, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x70, 236 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x76, 0x31, 0x2f, 0x6f, 0x6e, 237 0x62, 0x6f, 0x61, 0x72, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x74, 0x65, 0x6c, 238 0x65, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x75, 0x73, 0x65, 0x72, 0x70, 0x72, 0x65, 0x66, 0x65, 0x72, 239 0x65, 0x6e, 0x63, 0x65, 0x73, 0x2e, 0x76, 0x31, 0x22, 0x75, 0x0a, 0x0f, 0x4d, 0x61, 0x72, 0x6b, 240 0x65, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x63, 241 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 242 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x6f, 0x75, 0x72, 0x63, 243 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 244 0x16, 0x0a, 0x06, 0x6d, 0x65, 0x64, 0x69, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 245 0x06, 0x6d, 0x65, 0x64, 0x69, 0x75, 0x6d, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x6e, 0x74, 0x65, 0x6e, 246 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x69, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x22, 247 0xc9, 0x01, 0x0a, 0x16, 0x4f, 0x6e, 0x62, 0x6f, 0x61, 0x72, 0x64, 0x55, 0x73, 0x65, 0x72, 0x50, 248 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x56, 0x0a, 0x13, 0x70, 0x72, 249 0x65, 0x66, 0x65, 0x72, 0x72, 0x65, 0x64, 0x5f, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 250 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0e, 0x32, 0x25, 0x2e, 0x74, 0x65, 0x6c, 0x65, 0x70, 0x6f, 251 0x72, 0x74, 0x2e, 0x75, 0x73, 0x65, 0x72, 0x70, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 252 0x65, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x52, 0x12, 253 0x70, 0x72, 0x65, 0x66, 0x65, 0x72, 0x72, 0x65, 0x64, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 254 0x65, 0x73, 0x12, 0x57, 0x0a, 0x10, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x69, 0x6e, 0x67, 0x5f, 255 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x74, 256 0x65, 0x6c, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x75, 0x73, 0x65, 0x72, 0x70, 0x72, 0x65, 0x66, 257 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 258 0x74, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x0f, 0x6d, 0x61, 0x72, 0x6b, 259 0x65, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2a, 0xac, 0x01, 0x0a, 0x08, 260 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x18, 0x0a, 0x14, 0x52, 0x45, 0x53, 0x4f, 261 0x55, 0x52, 0x43, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 262 0x10, 0x00, 0x12, 0x1d, 0x0a, 0x19, 0x52, 0x45, 0x53, 0x4f, 0x55, 0x52, 0x43, 0x45, 0x5f, 0x57, 263 0x49, 0x4e, 0x44, 0x4f, 0x57, 0x53, 0x5f, 0x44, 0x45, 0x53, 0x4b, 0x54, 0x4f, 0x50, 0x53, 0x10, 264 0x01, 0x12, 0x17, 0x0a, 0x13, 0x52, 0x45, 0x53, 0x4f, 0x55, 0x52, 0x43, 0x45, 0x5f, 0x53, 0x45, 265 0x52, 0x56, 0x45, 0x52, 0x5f, 0x53, 0x53, 0x48, 0x10, 0x02, 0x12, 0x16, 0x0a, 0x12, 0x52, 0x45, 266 0x53, 0x4f, 0x55, 0x52, 0x43, 0x45, 0x5f, 0x44, 0x41, 0x54, 0x41, 0x42, 0x41, 0x53, 0x45, 0x53, 267 0x10, 0x03, 0x12, 0x17, 0x0a, 0x13, 0x52, 0x45, 0x53, 0x4f, 0x55, 0x52, 0x43, 0x45, 0x5f, 0x4b, 268 0x55, 0x42, 0x45, 0x52, 0x4e, 0x45, 0x54, 0x45, 0x53, 0x10, 0x04, 0x12, 0x1d, 0x0a, 0x19, 0x52, 269 0x45, 0x53, 0x4f, 0x55, 0x52, 0x43, 0x45, 0x5f, 0x57, 0x45, 0x42, 0x5f, 0x41, 0x50, 0x50, 0x4c, 270 0x49, 0x43, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x53, 0x10, 0x05, 0x42, 0x59, 0x5a, 0x57, 0x67, 0x69, 271 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x72, 0x61, 0x76, 0x69, 0x74, 0x61, 272 0x74, 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x2f, 0x74, 0x65, 0x6c, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x2f, 273 0x61, 0x70, 0x69, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 274 0x2f, 0x75, 0x73, 0x65, 0x72, 0x70, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x73, 275 0x2f, 0x76, 0x31, 0x3b, 0x75, 0x73, 0x65, 0x72, 0x70, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 276 0x63, 0x65, 0x73, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, 277 } 278 279 var ( 280 file_teleport_userpreferences_v1_onboard_proto_rawDescOnce sync.Once 281 file_teleport_userpreferences_v1_onboard_proto_rawDescData = file_teleport_userpreferences_v1_onboard_proto_rawDesc 282 ) 283 284 func file_teleport_userpreferences_v1_onboard_proto_rawDescGZIP() []byte { 285 file_teleport_userpreferences_v1_onboard_proto_rawDescOnce.Do(func() { 286 file_teleport_userpreferences_v1_onboard_proto_rawDescData = protoimpl.X.CompressGZIP(file_teleport_userpreferences_v1_onboard_proto_rawDescData) 287 }) 288 return file_teleport_userpreferences_v1_onboard_proto_rawDescData 289 } 290 291 var file_teleport_userpreferences_v1_onboard_proto_enumTypes = make([]protoimpl.EnumInfo, 1) 292 var file_teleport_userpreferences_v1_onboard_proto_msgTypes = make([]protoimpl.MessageInfo, 2) 293 var file_teleport_userpreferences_v1_onboard_proto_goTypes = []interface{}{ 294 (Resource)(0), // 0: teleport.userpreferences.v1.Resource 295 (*MarketingParams)(nil), // 1: teleport.userpreferences.v1.MarketingParams 296 (*OnboardUserPreferences)(nil), // 2: teleport.userpreferences.v1.OnboardUserPreferences 297 } 298 var file_teleport_userpreferences_v1_onboard_proto_depIdxs = []int32{ 299 0, // 0: teleport.userpreferences.v1.OnboardUserPreferences.preferred_resources:type_name -> teleport.userpreferences.v1.Resource 300 1, // 1: teleport.userpreferences.v1.OnboardUserPreferences.marketing_params:type_name -> teleport.userpreferences.v1.MarketingParams 301 2, // [2:2] is the sub-list for method output_type 302 2, // [2:2] is the sub-list for method input_type 303 2, // [2:2] is the sub-list for extension type_name 304 2, // [2:2] is the sub-list for extension extendee 305 0, // [0:2] is the sub-list for field type_name 306 } 307 308 func init() { file_teleport_userpreferences_v1_onboard_proto_init() } 309 func file_teleport_userpreferences_v1_onboard_proto_init() { 310 if File_teleport_userpreferences_v1_onboard_proto != nil { 311 return 312 } 313 if !protoimpl.UnsafeEnabled { 314 file_teleport_userpreferences_v1_onboard_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { 315 switch v := v.(*MarketingParams); i { 316 case 0: 317 return &v.state 318 case 1: 319 return &v.sizeCache 320 case 2: 321 return &v.unknownFields 322 default: 323 return nil 324 } 325 } 326 file_teleport_userpreferences_v1_onboard_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { 327 switch v := v.(*OnboardUserPreferences); i { 328 case 0: 329 return &v.state 330 case 1: 331 return &v.sizeCache 332 case 2: 333 return &v.unknownFields 334 default: 335 return nil 336 } 337 } 338 } 339 type x struct{} 340 out := protoimpl.TypeBuilder{ 341 File: protoimpl.DescBuilder{ 342 GoPackagePath: reflect.TypeOf(x{}).PkgPath(), 343 RawDescriptor: file_teleport_userpreferences_v1_onboard_proto_rawDesc, 344 NumEnums: 1, 345 NumMessages: 2, 346 NumExtensions: 0, 347 NumServices: 0, 348 }, 349 GoTypes: file_teleport_userpreferences_v1_onboard_proto_goTypes, 350 DependencyIndexes: file_teleport_userpreferences_v1_onboard_proto_depIdxs, 351 EnumInfos: file_teleport_userpreferences_v1_onboard_proto_enumTypes, 352 MessageInfos: file_teleport_userpreferences_v1_onboard_proto_msgTypes, 353 }.Build() 354 File_teleport_userpreferences_v1_onboard_proto = out.File 355 file_teleport_userpreferences_v1_onboard_proto_rawDesc = nil 356 file_teleport_userpreferences_v1_onboard_proto_goTypes = nil 357 file_teleport_userpreferences_v1_onboard_proto_depIdxs = nil 358 }