// notification contains shared FlatBuffers payloads published by
// Notification Service toward the gateway client event stream. Each
// table mirrors one catalog kind defined in
// `backend/internal/notification/catalog.go`; the table name is the
// camel-case form of the kind with the `Event` suffix.

include "common.fbs";

namespace notification;

table LobbyInviteReceivedEvent {
  game_id:common.UUID (required);
  inviter_user_id:common.UUID (required);
}

table LobbyInviteRevokedEvent {
  game_id:common.UUID (required);
}

table LobbyApplicationSubmittedEvent {
  game_id:common.UUID (required);
  application_id:common.UUID (required);
}

table LobbyApplicationApprovedEvent {
  game_id:common.UUID (required);
}

table LobbyApplicationRejectedEvent {
  game_id:common.UUID (required);
}

table LobbyMembershipRemovedEvent {
  reason:string;
}

table LobbyMembershipBlockedEvent {
  game_id:common.UUID (required);
  reason:string;
}

table LobbyRaceNameRegisteredEvent {
  race_name:string;
}

table LobbyRaceNamePendingEvent {
  race_name:string;
  expires_at:string;
}

table LobbyRaceNameExpiredEvent {
  race_name:string;
}

table RuntimeImagePullFailedEvent {
  game_id:common.UUID (required);
  image_ref:string;
}

table RuntimeContainerStartFailedEvent {
  game_id:common.UUID (required);
}

table RuntimeStartConfigInvalidEvent {
  game_id:common.UUID (required);
  reason:string;
}
