syntax = "proto3";
    option go_package = "./artifacts/academy-server/release-tsjs/modules/commonprofile";

import "artifacts/academy-server/release-tsjs/core/common.proto";




  

  

  
      
service CommonProfiles {
  rpc CommonProfileActionCreate (CommonProfileEntity) returns (CommonProfileCreateReply) {}
  rpc CommonProfileActionUpdate (CommonProfileEntity) returns (CommonProfileCreateReply) {}

  rpc CommonProfileActionQuery (QueryFilterRequest) returns (CommonProfileQueryReply) {}
  rpc CommonProfileActionGetOne (QueryFilterRequest) returns (CommonProfileReply) {}
  rpc CommonProfileActionRemove (QueryFilterRequest) returns (RemoveReply) {}
}

message CommonProfileCreateReply {
	CommonProfileEntity data  = 1;
	IError error = 2;
}

message CommonProfileReply {
	CommonProfileEntity data = 1;
	IError error = 2;
}

message CommonProfileQueryReply {
	repeated CommonProfileEntity items = 1;
	int64 totalItems = 2;
	int64 itemsPerPage = 3;
	int64 startIndex = 4;
	IError error = 5;
}







 
message CommonProfileEntity {
  optional string visibility = 1; // @tag(yaml:"visibility")
  optional string workspaceId = 2; // @tag(yaml:"workspaceId")
  optional string linkerId = 3; // @tag(yaml:"linkerId")
  optional string parentId = 4; // @tag(yaml:"parentId")
  string uniqueId = 5; // @tag(gorm:"primarykey;uniqueId;unique;not null;size:100;" yaml:"uniqueId")
  optional string userId = 6; // @tag(yaml:"userId")
  optional string firstName = 8; // @tag(  yaml:"firstName"  )

  optional string lastName = 9; // @tag(  yaml:"lastName"  )

  optional string phoneNumber = 10; // @tag(  yaml:"phoneNumber"  )

  optional string email = 11; // @tag(  yaml:"email"  )

  optional string company = 12; // @tag(  yaml:"company"  )

  optional string street = 13; // @tag(  yaml:"street"  )

  optional string houseNumber = 14; // @tag(  yaml:"houseNumber"  )

  optional string zipCode = 15; // @tag(  yaml:"zipCode"  )

  optional string city = 16; // @tag(  yaml:"city"  )

  optional string gender = 17; // @tag(  yaml:"gender"  )

  int64 rank = 18; // @tag(gorm:"type:int;name:rank")
  int64 updated = 19; // @tag(gorm:"autoUpdateTime:nano")
  int64 created = 20; // @tag(gorm:"autoUpdateTime:nano")
  string createdFormatted = 21; // @tag(sql:"-")
  string updatedFormatted = 22; // @tag(sql:"-")

}









/**
* Add your custom services, and messages here.
* It can be your dto for example. 
* - Use Module.yml for entities, otherwise it won't be managed
* - Don't use this file for entities might be queried by web
**/
      


