syntax = "proto3";

package gateway.v1;

import "gateway/v1/campaign_state.proto";
import "gateway/v1/dynamic_device_info.proto";
import "gateway/v1/session_counters.proto";
import "gateway/v1/static_device_info.proto";

option swift_prefix = "Gateway";

// AdRequest is the request sent from the SDK to the Gateway
// It contains all the information needed to make a decision on what ad to return
message AdRequest {
  // Session Counters tracked by the SDK
  SessionCounters session_counters = 1;
  // Static Device Info collected during SDK initialization. Information collected here doesn't change during session.
  StaticDeviceInfo static_device_info = 2;
  // Dynamic Device Info collected at request time. Information collected here can change during session.
  DynamicDeviceInfo dynamic_device_info = 3;
  // Current campaign state in the SDK
  CampaignState campaign_state = 4;
  // Impression Opportunity ID
  bytes impression_opportunity_id = 5;
  // Placement ID which is requested to be loaded
  string placement_id = 6;
  // Flag which indicates if Impression Configuration should be returned in the ad response on fill
  bool request_impression_configuration = 7;
  // SCAR Signal
  bytes scar_signal = 8;
  // Locally cached WebView version
  optional int32 webview_version = 9;
  // TCF String provided by Publisher
  optional bytes tcf = 10;
}
