df/bff/proto/account.proto
itsscb d021f5db51 rf/modifies bff
ft/adds email_address and phone_number tables
ft/adds email and phone endpoints
ft/adds account_level query
2023-11-21 23:32:20 +01:00

31 lines
1.5 KiB
Protocol Buffer

syntax = "proto3";
package pb;
import "google/protobuf/timestamp.proto";
import "protoc-gen-openapiv2/options/annotations.proto";
option go_package = "github.com/itsscb/df/pb";
message Account {
option (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema) = {
json_schema: {
title: "Account";
};
example: "{\"id\": \"1\",\"email\": \"john.doe@example.com\", \"firstname\": \"John\", \"lastname\": \"Doe\", \"phone\": \"\", \"street\": \"Death Star 2\", \"zip\": \"0815\", \"city\": \"New York\", \"country\": \"USA\", \"birthday\": \"1990-10-05T00:00:00Z\", \"privacy_accepted\": false, \"privacy_accepted_date\": \"0001-01-01T00:00:00Z\", \"creator\": \"john.doe@example.com\", \"created\": \"2023-10-05T02:30:53Z\", \"changer\": \"john.doe@example.com\", \"changed\": \"2023-10-05T02:30:53Z\"}";
};
uint64 id = 1;
string email = 2;
optional string secret_key = 3;
optional uint32 account_level = 4;
google.protobuf.Timestamp email_verified_time = 9 [(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "\"2023-10-05T00:00:00Z\""
}];
bool email_verified = 10;
google.protobuf.Timestamp privacy_accepted_date = 12 [(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "\"2023-10-05T00:00:00Z\""
}];
int32 permission_level = 13 [(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
description: "Default is 0 (non-priviledged)"
}];
}