RTBKit
0.9
Open-source framework to create real-time ad bidding systems.
|
Public Types | |
typedef boost::function < BidRequest *(const std::string)> | Parser |
Public Member Functions | |
Json::Value | toJson () const |
std::string | toJsonStr () const |
Id | getUserId (IdDomain domain) const |
Id | getUserId (const std::string &domain) const |
int | findAdSpotIndex (const Id &adSpotId) const |
SegmentResult | segmentPresent (const std::string &source, const std::string &segment) const |
SegmentResult | segmentPresent (const std::string &source, int segment) const |
void | sortAll () |
void | serialize (ML::DB::Store_Writer &store) const |
void | reconstitute (ML::DB::Store_Reader &store) |
std::string | serializeToString () const |
Static Public Member Functions | |
static BidRequest | createFromJson (const Json::Value &json) |
static void | registerParser (const std::string &source, Parser parser) |
static BidRequest * | parse (const std::string &source, const std::string &bidRequest) |
static BidRequest * | parse (const std::string &source, const Utf8String &bidRequest) |
static BidRequest | createFromString (const std::string &str) |
Public Attributes | |
Id | auctionId |
AuctionType | auctionType |
double | timeAvailableMs |
Date | timestamp |
bool | isTest |
std::string | protocolVersion |
What protocol version, eg OpenRTB. | |
std::string | exchange |
std::string | provider |
OpenRTB::Optional< OpenRTB::Site > | site |
OpenRTB::Optional< OpenRTB::App > | app |
OpenRTB::Optional < OpenRTB::Device > | device |
OpenRTB::Optional< OpenRTB::User > | user |
std::vector< AdSpot > | imp |
std::string | language |
User's language. | |
Location | location |
Best available location information. | |
Url | url |
std::string | ipAddress |
std::string | userAgent |
UserIds | userIds |
SegmentsBySource | restrictions |
SegmentsBySource | segments |
Json::Value | meta |
Json::Value | unparseable |
std::vector< CurrencyCode > | bidCurrency |
LineItems | winSurcharges |
Definition at line 268 of file bid_request.h.
BidRequest RTBKIT::BidRequest::createFromJson | ( | const Json::Value & | json | ) | [static] |
Create a new BidRequest from a canonical JSON value.
Definition at line 999 of file bid_request.cc.
int RTBKIT::BidRequest::findAdSpotIndex | ( | const Id & | adSpotId | ) | const [inline] |
Return the spot number with the given ID. -1 on not found.
Definition at line 365 of file bid_request.h.
Id RTBKIT::BidRequest::getUserId | ( | IdDomain | domain | ) | const |
Return the ID for the given domain.
Definition at line 1220 of file bid_request.cc.
BidRequest * RTBKIT::BidRequest::parse | ( | const std::string & | source, |
const std::string & | bidRequest | ||
) | [static] |
Parse the given bid request from the given source. The correct parser will be looked up in a registry based upon the source.
Definition at line 1163 of file bid_request.cc.
void RTBKIT::BidRequest::registerParser | ( | const std::string & | source, |
Parser | parser | ||
) | [static] |
Register the given parser for the bid request. Should be done in a static initilalizer on shared library load.
Definition at line 1118 of file bid_request.cc.
SegmentResult RTBKIT::BidRequest::segmentPresent | ( | const std::string & | source, |
const std::string & | segment | ||
) | const |
Query the presence of the given segment in the given source.
Definition at line 1197 of file bid_request.cc.
SegmentResult RTBKIT::BidRequest::segmentPresent | ( | const std::string & | source, |
int | segment | ||
) | const |
Query the presence of the given segment in the given source.
Definition at line 1209 of file bid_request.cc.
Json::Value RTBKIT::BidRequest::toJson | ( | ) | const |
Return a canonical JSON version of the bid request.
Definition at line 898 of file bid_request.cc.
std::string RTBKIT::BidRequest::toJsonStr | ( | ) | const |
Return a canonical stringified JSON version of the bid request.
Definition at line 951 of file bid_request.cc.
Information specific to the app that generated the request. Only one of site or app will be present.
Definition at line 297 of file bid_request.h.
std::vector<CurrencyCode> RTBKIT::BidRequest::bidCurrency |
Set of currency codes in which the bid can occur.
Definition at line 344 of file bid_request.h.
Information about the device that generated the request.
Definition at line 300 of file bid_request.h.
std::vector<AdSpot> RTBKIT::BidRequest::imp |
The impressions that are available within the bid request.
Definition at line 306 of file bid_request.h.
This field indicates the segments that are available in the bid request for the user.
Definition at line 333 of file bid_request.h.
Information specific to the site that generated the request. Only one of site or app will be present.
Definition at line 292 of file bid_request.h.
Extra fields included in the JSON that are unparseable by the bid request parser. Recorded here so that no information is lost in the round trip.
Definition at line 341 of file bid_request.h.
Information about the user that generated the request.
Definition at line 303 of file bid_request.h.
This field should be used to indicate what User IDs are available in the bid request. These are normally used by the augmentors to attach first or third party data to the bid request.
Definition at line 325 of file bid_request.h.
Amount of extras that will be paid if we win the auction. These will be accumulated in the banker against the winning account.
Definition at line 349 of file bid_request.h.