Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
gitpod-io
GitHub Repository: gitpod-io/gitpod
Path: blob/main/components/public-api/go/v1/token.pb.go
2500 views
1
// Copyright (c) 2025 Gitpod GmbH. All rights reserved.
2
// Licensed under the GNU Affero General Public License (AGPL).
3
// See License.AGPL.txt in the project root for license information.
4
5
// Code generated by protoc-gen-go. DO NOT EDIT.
6
// versions:
7
// protoc-gen-go v1.28.1
8
// protoc (unknown)
9
// source: gitpod/v1/token.proto
10
11
package v1
12
13
import (
14
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
15
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
16
reflect "reflect"
17
sync "sync"
18
)
19
20
const (
21
// Verify that this generated code is sufficiently up-to-date.
22
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
23
// Verify that runtime/protoimpl is sufficiently up-to-date.
24
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
25
)
26
27
type CreateTemporaryAccessTokenRequest struct {
28
state protoimpl.MessageState
29
sizeCache protoimpl.SizeCache
30
unknownFields protoimpl.UnknownFields
31
32
// user_id is the identifier of the user for which the token is created.
33
UserId string `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
34
// expiry_seconds is the number of seconds the token is valid for.
35
// value should in the range [1, 600]
36
ExpirySeconds int32 `protobuf:"varint,2,opt,name=expiry_seconds,json=expirySeconds,proto3" json:"expiry_seconds,omitempty"`
37
}
38
39
func (x *CreateTemporaryAccessTokenRequest) Reset() {
40
*x = CreateTemporaryAccessTokenRequest{}
41
if protoimpl.UnsafeEnabled {
42
mi := &file_gitpod_v1_token_proto_msgTypes[0]
43
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
44
ms.StoreMessageInfo(mi)
45
}
46
}
47
48
func (x *CreateTemporaryAccessTokenRequest) String() string {
49
return protoimpl.X.MessageStringOf(x)
50
}
51
52
func (*CreateTemporaryAccessTokenRequest) ProtoMessage() {}
53
54
func (x *CreateTemporaryAccessTokenRequest) ProtoReflect() protoreflect.Message {
55
mi := &file_gitpod_v1_token_proto_msgTypes[0]
56
if protoimpl.UnsafeEnabled && x != nil {
57
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
58
if ms.LoadMessageInfo() == nil {
59
ms.StoreMessageInfo(mi)
60
}
61
return ms
62
}
63
return mi.MessageOf(x)
64
}
65
66
// Deprecated: Use CreateTemporaryAccessTokenRequest.ProtoReflect.Descriptor instead.
67
func (*CreateTemporaryAccessTokenRequest) Descriptor() ([]byte, []int) {
68
return file_gitpod_v1_token_proto_rawDescGZIP(), []int{0}
69
}
70
71
func (x *CreateTemporaryAccessTokenRequest) GetUserId() string {
72
if x != nil {
73
return x.UserId
74
}
75
return ""
76
}
77
78
func (x *CreateTemporaryAccessTokenRequest) GetExpirySeconds() int32 {
79
if x != nil {
80
return x.ExpirySeconds
81
}
82
return 0
83
}
84
85
type CreateTemporaryAccessTokenResponse struct {
86
state protoimpl.MessageState
87
sizeCache protoimpl.SizeCache
88
unknownFields protoimpl.UnknownFields
89
90
// cookie_name is the name of the cookie to use for the token.
91
CookieName string `protobuf:"bytes,1,opt,name=cookie_name,json=cookieName,proto3" json:"cookie_name,omitempty"`
92
Token string `protobuf:"bytes,2,opt,name=token,proto3" json:"token,omitempty"`
93
}
94
95
func (x *CreateTemporaryAccessTokenResponse) Reset() {
96
*x = CreateTemporaryAccessTokenResponse{}
97
if protoimpl.UnsafeEnabled {
98
mi := &file_gitpod_v1_token_proto_msgTypes[1]
99
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
100
ms.StoreMessageInfo(mi)
101
}
102
}
103
104
func (x *CreateTemporaryAccessTokenResponse) String() string {
105
return protoimpl.X.MessageStringOf(x)
106
}
107
108
func (*CreateTemporaryAccessTokenResponse) ProtoMessage() {}
109
110
func (x *CreateTemporaryAccessTokenResponse) ProtoReflect() protoreflect.Message {
111
mi := &file_gitpod_v1_token_proto_msgTypes[1]
112
if protoimpl.UnsafeEnabled && x != nil {
113
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
114
if ms.LoadMessageInfo() == nil {
115
ms.StoreMessageInfo(mi)
116
}
117
return ms
118
}
119
return mi.MessageOf(x)
120
}
121
122
// Deprecated: Use CreateTemporaryAccessTokenResponse.ProtoReflect.Descriptor instead.
123
func (*CreateTemporaryAccessTokenResponse) Descriptor() ([]byte, []int) {
124
return file_gitpod_v1_token_proto_rawDescGZIP(), []int{1}
125
}
126
127
func (x *CreateTemporaryAccessTokenResponse) GetCookieName() string {
128
if x != nil {
129
return x.CookieName
130
}
131
return ""
132
}
133
134
func (x *CreateTemporaryAccessTokenResponse) GetToken() string {
135
if x != nil {
136
return x.Token
137
}
138
return ""
139
}
140
141
var File_gitpod_v1_token_proto protoreflect.FileDescriptor
142
143
var file_gitpod_v1_token_proto_rawDesc = []byte{
144
0x0a, 0x15, 0x67, 0x69, 0x74, 0x70, 0x6f, 0x64, 0x2f, 0x76, 0x31, 0x2f, 0x74, 0x6f, 0x6b, 0x65,
145
0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x09, 0x67, 0x69, 0x74, 0x70, 0x6f, 0x64, 0x2e,
146
0x76, 0x31, 0x22, 0x63, 0x0a, 0x21, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x65, 0x6d, 0x70,
147
0x6f, 0x72, 0x61, 0x72, 0x79, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x6f, 0x6b, 0x65, 0x6e,
148
0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x17, 0x0a, 0x07, 0x75, 0x73, 0x65, 0x72, 0x5f,
149
0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64,
150
0x12, 0x25, 0x0a, 0x0e, 0x65, 0x78, 0x70, 0x69, 0x72, 0x79, 0x5f, 0x73, 0x65, 0x63, 0x6f, 0x6e,
151
0x64, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x65, 0x78, 0x70, 0x69, 0x72, 0x79,
152
0x53, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x73, 0x22, 0x5b, 0x0a, 0x22, 0x43, 0x72, 0x65, 0x61, 0x74,
153
0x65, 0x54, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x72, 0x79, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73,
154
0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1f, 0x0a,
155
0x0b, 0x63, 0x6f, 0x6f, 0x6b, 0x69, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01,
156
0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6f, 0x6b, 0x69, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14,
157
0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74,
158
0x6f, 0x6b, 0x65, 0x6e, 0x32, 0x8b, 0x01, 0x0a, 0x0c, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x53, 0x65,
159
0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x7b, 0x0a, 0x1a, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54,
160
0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x72, 0x79, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x6f,
161
0x6b, 0x65, 0x6e, 0x12, 0x2c, 0x2e, 0x67, 0x69, 0x74, 0x70, 0x6f, 0x64, 0x2e, 0x76, 0x31, 0x2e,
162
0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x72, 0x79, 0x41,
163
0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
164
0x74, 0x1a, 0x2d, 0x2e, 0x67, 0x69, 0x74, 0x70, 0x6f, 0x64, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72,
165
0x65, 0x61, 0x74, 0x65, 0x54, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x72, 0x79, 0x41, 0x63, 0x63,
166
0x65, 0x73, 0x73, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65,
167
0x22, 0x00, 0x42, 0x51, 0x0a, 0x16, 0x69, 0x6f, 0x2e, 0x67, 0x69, 0x74, 0x70, 0x6f, 0x64, 0x2e,
168
0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x5a, 0x37, 0x67, 0x69,
169
0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x69, 0x74, 0x70, 0x6f, 0x64, 0x2d,
170
0x69, 0x6f, 0x2f, 0x67, 0x69, 0x74, 0x70, 0x6f, 0x64, 0x2f, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x6e,
171
0x65, 0x6e, 0x74, 0x73, 0x2f, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x2d, 0x61, 0x70, 0x69, 0x2f,
172
0x67, 0x6f, 0x2f, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
173
}
174
175
var (
176
file_gitpod_v1_token_proto_rawDescOnce sync.Once
177
file_gitpod_v1_token_proto_rawDescData = file_gitpod_v1_token_proto_rawDesc
178
)
179
180
func file_gitpod_v1_token_proto_rawDescGZIP() []byte {
181
file_gitpod_v1_token_proto_rawDescOnce.Do(func() {
182
file_gitpod_v1_token_proto_rawDescData = protoimpl.X.CompressGZIP(file_gitpod_v1_token_proto_rawDescData)
183
})
184
return file_gitpod_v1_token_proto_rawDescData
185
}
186
187
var file_gitpod_v1_token_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
188
var file_gitpod_v1_token_proto_goTypes = []interface{}{
189
(*CreateTemporaryAccessTokenRequest)(nil), // 0: gitpod.v1.CreateTemporaryAccessTokenRequest
190
(*CreateTemporaryAccessTokenResponse)(nil), // 1: gitpod.v1.CreateTemporaryAccessTokenResponse
191
}
192
var file_gitpod_v1_token_proto_depIdxs = []int32{
193
0, // 0: gitpod.v1.TokenService.CreateTemporaryAccessToken:input_type -> gitpod.v1.CreateTemporaryAccessTokenRequest
194
1, // 1: gitpod.v1.TokenService.CreateTemporaryAccessToken:output_type -> gitpod.v1.CreateTemporaryAccessTokenResponse
195
1, // [1:2] is the sub-list for method output_type
196
0, // [0:1] is the sub-list for method input_type
197
0, // [0:0] is the sub-list for extension type_name
198
0, // [0:0] is the sub-list for extension extendee
199
0, // [0:0] is the sub-list for field type_name
200
}
201
202
func init() { file_gitpod_v1_token_proto_init() }
203
func file_gitpod_v1_token_proto_init() {
204
if File_gitpod_v1_token_proto != nil {
205
return
206
}
207
if !protoimpl.UnsafeEnabled {
208
file_gitpod_v1_token_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
209
switch v := v.(*CreateTemporaryAccessTokenRequest); i {
210
case 0:
211
return &v.state
212
case 1:
213
return &v.sizeCache
214
case 2:
215
return &v.unknownFields
216
default:
217
return nil
218
}
219
}
220
file_gitpod_v1_token_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
221
switch v := v.(*CreateTemporaryAccessTokenResponse); i {
222
case 0:
223
return &v.state
224
case 1:
225
return &v.sizeCache
226
case 2:
227
return &v.unknownFields
228
default:
229
return nil
230
}
231
}
232
}
233
type x struct{}
234
out := protoimpl.TypeBuilder{
235
File: protoimpl.DescBuilder{
236
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
237
RawDescriptor: file_gitpod_v1_token_proto_rawDesc,
238
NumEnums: 0,
239
NumMessages: 2,
240
NumExtensions: 0,
241
NumServices: 1,
242
},
243
GoTypes: file_gitpod_v1_token_proto_goTypes,
244
DependencyIndexes: file_gitpod_v1_token_proto_depIdxs,
245
MessageInfos: file_gitpod_v1_token_proto_msgTypes,
246
}.Build()
247
File_gitpod_v1_token_proto = out.File
248
file_gitpod_v1_token_proto_rawDesc = nil
249
file_gitpod_v1_token_proto_goTypes = nil
250
file_gitpod_v1_token_proto_depIdxs = nil
251
}
252
253