syntax = "proto3";

package bounty_status;

option go_package = "bounty_status";

import "eventbus/owner.proto";

// BountyStatusUpdate triggers when a bounty status changed.
message BountyStatusUpdate {
  option (eventbus.owner.ldap_group) = "team-ads";
  // The bounty_id represents the identifier for a bounty (On Broadcaster side) from Bounty Board (Format as Version 4 UUID).
  string bounty_id = 1;
  // The campaign_id represents the identifier for a campaign (On Brand side) that the bounty associated to (Format as Version 4 UUID).
  string campaign_id = 2;
  // The user_id represents the identifier for a broadcaster which this bounty belongs to.
  string user_id = 3;
  // The is_promotional_bounty represents whether the bounty is a promotional bounty for expanding viewers.
  bool is_promotional_bounty = 4;
  // The event_type of the bounty event(Claim, Cancel, Start or Stop).
  BountyEventType event_type = 5;
}

// BountyEventType is the event type for describing this event for.
enum BountyEventType {
  // Present because proto3 specifies enums must start with value 0.
  BOUNTY_EVENT_TYPE_INVALID = 0;
  // CLAIM indicates the event is for a broadcaster claimed a bounty from Bounty Board.
  BOUNTY_EVENT_TYPE_CLAIM = 1;
  // CANCEL indicates the event that the broadcaster has cancelled this bounty.
  BOUNTY_EVENT_TYPE_CANCEL = 2;
  // START indicates the event that the broadcaster started doing this bounty.
  BOUNTY_EVENT_TYPE_START = 3;
  // STOP indicates the event that the broadcaster stopped the bounty promotional streaming.
  BOUNTY_EVENT_TYPE_STOP = 4;
}
