syntax = "proto3";
package event;

import "google/protobuf/wrappers.proto";
import "google/protobuf/empty.proto";

import "core_shared.proto";

option go_package = "com.github/quabynah-bilson/proche;core";

// event management service
service EventService {
  rpc create_event (core.CreateEventRequest) returns (core.ProcheEvent);
  rpc get_event (google.protobuf.StringValue) returns (stream core.ProcheEvent);
  rpc get_event_by_user (google.protobuf.StringValue) returns (stream core.ProcheEventList);
  rpc get_events_by_location (core.CommonAddress) returns (stream core.ProcheEventList);
  rpc list_events (google.protobuf.Empty) returns (stream core.ProcheEventList);
  rpc update_event (core.ProcheEvent) returns (core.ProcheEvent);
  rpc delete_event (google.protobuf.StringValue) returns (google.protobuf.Empty);
  // candidates
  rpc get_candidates_for_event(google.protobuf.StringValue) returns (stream core.EventCandidateList);
}
