To collect the majority of user behavior events to BigQuery, OWOX BI, using either the customTask or analytics.js method, duplicates all the data Google Analytics collects from the website and sends it to the dedicated OWOX BI access point.
For collecting offline events or the events that happen after the user’s session on the website, Google Analytics offers using Measurement Protocol. The protocol can send any kind of user behavior data directly to Google Analytics using an HTTP request.
OWOX BI access point
If you send certain events to Google Analytics via Measurement Protocol, you need to duplicate them to the OWOX BI access point as well. The access point is
UA-XXXXX-X — is your Google Analytics tracking ID.
Without duplicating the request, the event data won’t get to BigQuery, which will result in data discrepancy with Google Analytics. Please note that to send the data to Google Analytics, you still need to send a request to
Sending requests to our access point is no different from sending them to Google Analytics: you send data as a POST or a GET request. See what the requests look like in Google documentation.
POST request (recommended method)
For a POST request, you need to specify a payload data identical to the one you send to Google Analytics. Here’s an example:
For POST requests, use one of these Content-type headers:
For a GET request, specify the set of parameters in the URL. For example:
Requirements for value formatting
In general, a field value format should comply with the Measurement Protocol’s documentation.
However, some fields should also meet specific requirements as they undergo additional processing by OWOX BI. Please see the table below.
NoteData that does not match the specified format cannot be processed by OWOX BI and will be written as NULL in Google BigQuery tables.
|Full name||Abbreviation||Value type||Supported value format|
|Page Load Time||plt||integer|
|Page Download Time||pdt||integer|
|Redirect Response Time||rrt||integer|
|TCP Connect Time||tcp||integer|
|Server Response Time||srt||integer|
|DOM Interactive Time||dit||integer|
|Content Load Time||clt||integer|
|User timing time||utt||integer|
Using the queueTime (&qt) parameter
By default, the time when a hit is reported equals the time when the hit occurs. However, hits may be reported with a delay. For example, in online payment, a bank confirms a transaction some time after this transaction is made by a user. To match this hit to the time it occurred, the queueTime (&qt) parameter must be used.
The &qt value represents the time delta (in milliseconds) between when the hit occurred and the time it was reported. By setting this parameter, the hit time (value in the time field) will be calculated correctly.
NoteThe &qt value must be of integer type and be greater than or equal to 0.
Otherwise, the &qt will be automatically assigned the NULL value and the hit will be assigned a time when it was reported.
Please see how the data is processed when sending a non-zero parameter &qt below.
|OWOX BI||Google Analytics|
|Hit data collection|
There are no limits for the &qt value.
A hit will get to a data table for the date calculated considering the difference in time between the value of &qt parameter and the time the hit was sent.
There are limits for the &qt value.
|Session data collection|
For session data collection based on the OWOX BI algorithm, the hits will be assigned to the corresponding sessions ('owoxbi_sessions_') within 30 days*.
For session data collection based on the Google Analytics algorithm, the hits will be assigned to the corresponding sessions within 48 hours* based on the clientId and timestamp values sent in the custom dimension (&cd).
Learn how the qt parameter affects assigning transactions to user sessions from this article.
- The request must contain the clientId (&cd) or the userId (&uid) parameter. Without sending at least one of these parameters, a hit will be processed neither in OWOX BI nor in Google Analytics.
If you use several hits to send data of a single transaction, you should submit unique parameter values in the actionField object per hit. For example, you can do it by entering different values for Revenue, Tax, or Affiliation in each actionField object. Otherwise, out of two (or more) hits with the same parameter values in the actionField object, only one hit will be recorded by GA.
While OWOX BI will record all the transaction hits regardless of the received values in the actionField object.
- In OWOX BI Pipeline, the maximum hit payload size is 16 KB. If exceeded this limit, hits won't be processed and sent to BigQuery.
- In Google Analytics hit payload must be no longer than 8 KB.
Anytime you can check the number of transactions collected to the BigQuery tables. Read more
HTTP request example
"el": "Form №1",
"ua": "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)",
Parameter breakdown example:
|device.userAgent||Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)|