syntax = "proto3";

message LoginRecordInfo {
  int64 ID = 1;
  string created_at = 3;
  string updated_at = 4;
  int64 user_id = 5;
  string last_login_at = 6;
  string last_login_ipv4 = 7;
  string last_login_device = 8;
  string last_login_ua = 9;
  uint64 login_count = 10;
}

message RecordReq {
  int64 user_id = 1;
}

service Core {
  // Login Record management
  // group: login_record
  rpc getRecord(RecordReq) returns (LoginRecordInfo);
  // group: login_record
  rpc record(LoginRecordInfo) returns (BaseResp);
}