Update protobuf definitions: 1925e0de
By allanger
Commit link: 1925e0de3f
Pipeline link: https://ci.badhouseplants.net/repos/34/pipeline/73
This commit is contained in:
@@ -30,7 +30,15 @@ type TokenMetadata struct {
|
||||
// A token name
|
||||
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
||||
// Token expiration timestamp
|
||||
ExpiresAt *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=expires_at,json=expiresAt,proto3" json:"expires_at,omitempty"`
|
||||
ExpiresAt *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=expires_at,json=expiresAt,proto3" json:"expires_at,omitempty"`
|
||||
// When the token was used the last time
|
||||
LastUsedAt *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=last_used_at,json=lastUsedAt,proto3" json:"last_used_at,omitempty"`
|
||||
// When was the current token generated
|
||||
GeneratedAt *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=generated_at,json=generatedAt,proto3" json:"generated_at,omitempty"`
|
||||
// When was the current token entry created
|
||||
CreatedAt *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
|
||||
// When was the token revoked
|
||||
RevokedAt *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=revoked_at,json=revokedAt,proto3" json:"revoked_at,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
@@ -79,6 +87,34 @@ func (x *TokenMetadata) GetExpiresAt() *timestamppb.Timestamp {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *TokenMetadata) GetLastUsedAt() *timestamppb.Timestamp {
|
||||
if x != nil {
|
||||
return x.LastUsedAt
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *TokenMetadata) GetGeneratedAt() *timestamppb.Timestamp {
|
||||
if x != nil {
|
||||
return x.GeneratedAt
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *TokenMetadata) GetCreatedAt() *timestamppb.Timestamp {
|
||||
if x != nil {
|
||||
return x.CreatedAt
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *TokenMetadata) GetRevokedAt() *timestamppb.Timestamp {
|
||||
if x != nil {
|
||||
return x.RevokedAt
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type TokenUUID struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
// An ID of a token
|
||||
@@ -818,11 +854,18 @@ var File_tokens_v1_tokens_v1_proto protoreflect.FileDescriptor
|
||||
|
||||
const file_tokens_v1_tokens_v1_proto_rawDesc = "" +
|
||||
"\n" +
|
||||
"\x19tokens/v1/tokens_v1.proto\x12\ttokens.v1\x1a\x1bgoogle/protobuf/empty.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"^\n" +
|
||||
"\x19tokens/v1/tokens_v1.proto\x12\ttokens.v1\x1a\x1bgoogle/protobuf/empty.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xd1\x02\n" +
|
||||
"\rTokenMetadata\x12\x12\n" +
|
||||
"\x04name\x18\x01 \x01(\tR\x04name\x129\n" +
|
||||
"\n" +
|
||||
"expires_at\x18\x02 \x01(\v2\x1a.google.protobuf.TimestampR\texpiresAt\"\x1f\n" +
|
||||
"expires_at\x18\x02 \x01(\v2\x1a.google.protobuf.TimestampR\texpiresAt\x12<\n" +
|
||||
"\flast_used_at\x18\x03 \x01(\v2\x1a.google.protobuf.TimestampR\n" +
|
||||
"lastUsedAt\x12=\n" +
|
||||
"\fgenerated_at\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampR\vgeneratedAt\x129\n" +
|
||||
"\n" +
|
||||
"created_at\x18\x05 \x01(\v2\x1a.google.protobuf.TimestampR\tcreatedAt\x129\n" +
|
||||
"\n" +
|
||||
"revoked_at\x18\x06 \x01(\v2\x1a.google.protobuf.TimestampR\trevokedAt\"\x1f\n" +
|
||||
"\tTokenUUID\x12\x12\n" +
|
||||
"\x04uuid\x18\x01 \x01(\tR\x04uuid\"\"\n" +
|
||||
"\n" +
|
||||
@@ -922,47 +965,51 @@ var file_tokens_v1_tokens_v1_proto_goTypes = []any{
|
||||
}
|
||||
var file_tokens_v1_tokens_v1_proto_depIdxs = []int32{
|
||||
17, // 0: tokens.v1.TokenMetadata.expires_at:type_name -> google.protobuf.Timestamp
|
||||
16, // 1: tokens.v1.TokenPermissions.permissions:type_name -> tokens.v1.TokenPermissions.PermissionsEntry
|
||||
0, // 2: tokens.v1.CreateTokenRequest.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 3: tokens.v1.CreateTokenRequest.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
2, // 4: tokens.v1.CreateTokenResponse.token_value:type_name -> tokens.v1.TokenValue
|
||||
1, // 5: tokens.v1.UpdateTokenRequest.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
0, // 6: tokens.v1.UpdateTokenRequest.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 7: tokens.v1.UpdateTokenRequest.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
1, // 8: tokens.v1.UpdateTokenResponse.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
0, // 9: tokens.v1.UpdateTokenResponse.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 10: tokens.v1.UpdateTokenResponse.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
1, // 11: tokens.v1.ForceTokenExpirationRequest.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
1, // 12: tokens.v1.RegenerateTokenRequest.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
2, // 13: tokens.v1.RegenerateTokenResponse.token_value:type_name -> tokens.v1.TokenValue
|
||||
1, // 14: tokens.v1.GetTokenRequest.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
1, // 15: tokens.v1.GetTokenResponse.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
0, // 16: tokens.v1.GetTokenResponse.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 17: tokens.v1.GetTokenResponse.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
1, // 18: tokens.v1.ListTokensResponse.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
0, // 19: tokens.v1.ListTokensResponse.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 20: tokens.v1.ListTokensResponse.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
4, // 21: tokens.v1.ListPermissionsResponse.permissions:type_name -> tokens.v1.TokenPermissions
|
||||
3, // 22: tokens.v1.TokenPermissions.PermissionsEntry.value:type_name -> tokens.v1.MethodList
|
||||
5, // 23: tokens.v1.TokensService.CreateToken:input_type -> tokens.v1.CreateTokenRequest
|
||||
7, // 24: tokens.v1.TokensService.UpdateToken:input_type -> tokens.v1.UpdateTokenRequest
|
||||
9, // 25: tokens.v1.TokensService.ForceTokenExpiration:input_type -> tokens.v1.ForceTokenExpirationRequest
|
||||
10, // 26: tokens.v1.TokensService.RegenerateToken:input_type -> tokens.v1.RegenerateTokenRequest
|
||||
12, // 27: tokens.v1.TokensService.GetToken:input_type -> tokens.v1.GetTokenRequest
|
||||
18, // 28: tokens.v1.TokensService.ListTokens:input_type -> google.protobuf.Empty
|
||||
18, // 29: tokens.v1.TokensService.ListPermissions:input_type -> google.protobuf.Empty
|
||||
6, // 30: tokens.v1.TokensService.CreateToken:output_type -> tokens.v1.CreateTokenResponse
|
||||
8, // 31: tokens.v1.TokensService.UpdateToken:output_type -> tokens.v1.UpdateTokenResponse
|
||||
18, // 32: tokens.v1.TokensService.ForceTokenExpiration:output_type -> google.protobuf.Empty
|
||||
11, // 33: tokens.v1.TokensService.RegenerateToken:output_type -> tokens.v1.RegenerateTokenResponse
|
||||
13, // 34: tokens.v1.TokensService.GetToken:output_type -> tokens.v1.GetTokenResponse
|
||||
14, // 35: tokens.v1.TokensService.ListTokens:output_type -> tokens.v1.ListTokensResponse
|
||||
15, // 36: tokens.v1.TokensService.ListPermissions:output_type -> tokens.v1.ListPermissionsResponse
|
||||
30, // [30:37] is the sub-list for method output_type
|
||||
23, // [23:30] is the sub-list for method input_type
|
||||
23, // [23:23] is the sub-list for extension type_name
|
||||
23, // [23:23] is the sub-list for extension extendee
|
||||
0, // [0:23] is the sub-list for field type_name
|
||||
17, // 1: tokens.v1.TokenMetadata.last_used_at:type_name -> google.protobuf.Timestamp
|
||||
17, // 2: tokens.v1.TokenMetadata.generated_at:type_name -> google.protobuf.Timestamp
|
||||
17, // 3: tokens.v1.TokenMetadata.created_at:type_name -> google.protobuf.Timestamp
|
||||
17, // 4: tokens.v1.TokenMetadata.revoked_at:type_name -> google.protobuf.Timestamp
|
||||
16, // 5: tokens.v1.TokenPermissions.permissions:type_name -> tokens.v1.TokenPermissions.PermissionsEntry
|
||||
0, // 6: tokens.v1.CreateTokenRequest.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 7: tokens.v1.CreateTokenRequest.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
2, // 8: tokens.v1.CreateTokenResponse.token_value:type_name -> tokens.v1.TokenValue
|
||||
1, // 9: tokens.v1.UpdateTokenRequest.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
0, // 10: tokens.v1.UpdateTokenRequest.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 11: tokens.v1.UpdateTokenRequest.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
1, // 12: tokens.v1.UpdateTokenResponse.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
0, // 13: tokens.v1.UpdateTokenResponse.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 14: tokens.v1.UpdateTokenResponse.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
1, // 15: tokens.v1.ForceTokenExpirationRequest.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
1, // 16: tokens.v1.RegenerateTokenRequest.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
2, // 17: tokens.v1.RegenerateTokenResponse.token_value:type_name -> tokens.v1.TokenValue
|
||||
1, // 18: tokens.v1.GetTokenRequest.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
1, // 19: tokens.v1.GetTokenResponse.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
0, // 20: tokens.v1.GetTokenResponse.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 21: tokens.v1.GetTokenResponse.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
1, // 22: tokens.v1.ListTokensResponse.token_uuid:type_name -> tokens.v1.TokenUUID
|
||||
0, // 23: tokens.v1.ListTokensResponse.token_metadata:type_name -> tokens.v1.TokenMetadata
|
||||
4, // 24: tokens.v1.ListTokensResponse.token_permissions:type_name -> tokens.v1.TokenPermissions
|
||||
4, // 25: tokens.v1.ListPermissionsResponse.permissions:type_name -> tokens.v1.TokenPermissions
|
||||
3, // 26: tokens.v1.TokenPermissions.PermissionsEntry.value:type_name -> tokens.v1.MethodList
|
||||
5, // 27: tokens.v1.TokensService.CreateToken:input_type -> tokens.v1.CreateTokenRequest
|
||||
7, // 28: tokens.v1.TokensService.UpdateToken:input_type -> tokens.v1.UpdateTokenRequest
|
||||
9, // 29: tokens.v1.TokensService.ForceTokenExpiration:input_type -> tokens.v1.ForceTokenExpirationRequest
|
||||
10, // 30: tokens.v1.TokensService.RegenerateToken:input_type -> tokens.v1.RegenerateTokenRequest
|
||||
12, // 31: tokens.v1.TokensService.GetToken:input_type -> tokens.v1.GetTokenRequest
|
||||
18, // 32: tokens.v1.TokensService.ListTokens:input_type -> google.protobuf.Empty
|
||||
18, // 33: tokens.v1.TokensService.ListPermissions:input_type -> google.protobuf.Empty
|
||||
6, // 34: tokens.v1.TokensService.CreateToken:output_type -> tokens.v1.CreateTokenResponse
|
||||
8, // 35: tokens.v1.TokensService.UpdateToken:output_type -> tokens.v1.UpdateTokenResponse
|
||||
18, // 36: tokens.v1.TokensService.ForceTokenExpiration:output_type -> google.protobuf.Empty
|
||||
11, // 37: tokens.v1.TokensService.RegenerateToken:output_type -> tokens.v1.RegenerateTokenResponse
|
||||
13, // 38: tokens.v1.TokensService.GetToken:output_type -> tokens.v1.GetTokenResponse
|
||||
14, // 39: tokens.v1.TokensService.ListTokens:output_type -> tokens.v1.ListTokensResponse
|
||||
15, // 40: tokens.v1.TokensService.ListPermissions:output_type -> tokens.v1.ListPermissionsResponse
|
||||
34, // [34:41] is the sub-list for method output_type
|
||||
27, // [27:34] is the sub-list for method input_type
|
||||
27, // [27:27] is the sub-list for extension type_name
|
||||
27, // [27:27] is the sub-list for extension extendee
|
||||
0, // [0:27] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_tokens_v1_tokens_v1_proto_init() }
|
||||
|
||||
Reference in New Issue
Block a user