Attributes
Passing data in your Rokt integration is important as the rich, granular data allows for greater campaign optimization, enhanced targeting, personalization capabilities, and spend efficiencies. This also allows conversions to be attributed to the appropriate Rokt campaign with a high degree of accuracy.
You can find the full list of pre-defined Rokt attributes in the sections below, and you can also pass any custom attributes to complement the standard integration.
Core Attributes
Name | Attribute | Format | Payload Example |
---|---|---|---|
john.smith@rokt.com | |||
Email (MD5) | emailmd5 | MD5 hash string | 238afb9e862add7d56bbc4181b80fa32 |
Email (SHA256) | emailsha256 | SHA256 hash string | |
Amount | amount | amount | 300.5 |
Currency | currency | 3-letter ISO currency code | USD |
Quantity | quantity | number | 2 |
Payment Type | paymenttype | string | Credit Card, Paypal |
Credit Card BIN | ccbin | 6 digits | 372888 |
Margin | margin | amount | 10.5 |
Confirmation Reference | confirmationref | string | XYZ123 |
First Name | firstname | name | John |
Last Name | lastname | name | Smith |
Mobile | mobile | mobile format without country code | 7327572923 |
Title | title | Mr/Mrs/Ms/Miss | Ms |
Gender | gender | M or F | F |
Date of Birth | dob | yyyymmdd | 19831215 |
Age | age | integer | 33 |
Language | language | 2-letter ISO language code | en, nl, de, fr |
Experience | experience | string | |
Unit Number | unitno | string | 101 |
Address Line 1 | address1 | string | 123 Fake Street |
Address Line 2 | address2 | string | Building A |
ZIP/Postcode | zipcode | zipcode | 90210 |
City | city | string | New York |
State | state | state | NY |
Country | country | 2-letter ISO country code | us, au, nz, ca, gb, sg |
Conversion Type | conversiontype | string | |
Rokt Tracking ID | rokttrackingid | string |
E-commerce/Retail Data
Name | Attribute | Format | Payload Example |
---|---|---|---|
Restaurant ID | restaurantid | string | |
Delivery | delivery | boolean | |
Restaurant Name | restaurantname | string | |
Delivery/Pick up Address | deliveryaddress | string | |
Cuisine | cuisine | string | |
Delivery/Pick up Time | deliverytime | time | |
Delivery/Pick up Date | deliverydate | date | |
Restaurant ZIP/Postcode | restaurantzipcode | zipcode |
Event Ticketing Data
Name | Attribute | Format | Payload Example |
---|---|---|---|
Event Name | eventname | string | John Smith featuring the Smiths: Live |
Event Description | eventdescription | string | The most incredible show on earth. |
Event Time | eventtime | time | 0800, 1930 |
Event ID | eventid | string | E017448281A |
Event Date | eventdate | yyyymmdd | 20200822 |
Event Venue | eventvenue | string | Austin Big Stadium |
Event City | eventcity | string | |
Event State | eventstate | state | |
Event ZIP/Postcode | eventzipcode | zipcode | |
Event Country | eventcountry | country | |
Event Image URL | eventimage | url | |
Event URL | eventurl | url | |
Ticket URL | ticketurl | url | |
Number of Tickets | notickets | number | |
Seat Location(s) | seatlocation | string | |
Seat Number | seatnumber | number | |
Primary Artist ID | primaryartistid | string | |
Primary Artist Name | primaryartistname | string | |
Secondary Artist ID | secondaryartistid | string | |
Secondary Artist Name | secondaryartistname | string | |
Promoter | promoter | string | |
Promoter ID | promoterid | string | |
Venue ID | venueid | string | |
Venue Map URL | venuemap | url |
Media and Entertainment
Name | Attribute | Format | Payload Example |
---|---|---|---|
Section | section | string | |
Section ID | sectionid | string | |
Sub-section | subsection | string | |
Sub-section ID | subsectionid | string | |
Author Name | author | string | |
Author ID | authorid | string | |
Subscriber | subscriber | string | |
Subscription Program | subscription | string |
Transactional/Purchase Data
Name | Attribute | Format | Payload Example |
---|---|---|---|
Major Category | majorcat | string | Electronics |
Major Category ID | majorcatid | string | Cameras |
Minor Category | minorcat | string | 10011 |
Minor Category ID | minorcatid | string | 10 |
Customer Type | customertype | guest / member | 10 |
Product Name(s) | productname | string | |
Stock Keeping Unit (SKU) | sku | string | |
Shipping Type | shippingtype | string |
Travel Data
Name | Attribute | Format | Payload Example |
---|---|---|---|
Number of Passengers | pax | number | |
Travel Class | travelclass | string | |
Trip Type | triptype | string | |
Route | route | string | |
Loyalty Program | loyaltyprogram | string | |
Loyalty Program ID | loyaltyprogramid | string | |
Loyalty Tier | loyaltytier | string | |
Carrier | carrier | string | |
Booked Hotel | bookedhotel | boolean | |
Purchased Insurance | purchasedinsurance | boolean | |
Booked Car | carbooked | boolean | |
Excess Baggage | excessbaggage | boolean | |
Destination Airport | destairport | string | |
Destination City | destcity | string | |
Departure Airport | departairport | string | |
Departure City | departcity | string | |
Travel Time | traveltime | time | |
Travel Date | traveldate | date | |
Departure Airport ZIP/Postcode | departairportzipcode | zipcode | |
Check-In URL | checkinurl | url | |
Ticket URL | ticketurl | url | |
Passenger Name | passengername | name |
Fulfillment Attributes
Personally Identifiable Information (PII) is often required by Rokt to fulfill campaign goals. For example, a user's email address is considered PII and is essential for Rokt to be able to deliver an email campaign. These pieces of information are known as Fulfillment Attributes. Rokt has designed a ‘2 step data pass’ process that allows for the passing of Fulfillment Attributes to Rokt, whilst ensuring security for the customer and maintaining the quality of their experience.
The process allows for sharing of hashed (SHA256) PII values on the initiation of the integration, with the sharing of raw PII values deferred until after the customer has positively engaged with a Rokt offer. Disclosing hashed values at the initiation of the integration allows Rokt's systems to deliver on some of the expected functionalities (e.g. suppress showing offers to a returning user) while still respecting privacy concerns.
The following code snippet describes basic usage of the 2 step process:
Kotlin
import com.rokt.roktsdk.Widget
import com.rokt.roktsdk.Rokt
class ConfirmationActivity : Activity() {
private val roktCalllback = object : Rokt.RoktCallback {
override fun onLoad() {
}
override fun onShouldShowLoadingIndicator() {
}
override fun onShouldHideLoadingIndicator() {
}
override fun onUnload(reason: Rokt.UnloadReasons) {
}
}
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
...
// Include any appropriate consumer attributes
val attributes = hashMapOf(
Pair("emailsha256", "36f15652992f5c291ea233b930c8c435ee5a5fb115d25933e3266591d3f92f74"),
Pair("firstname", "Jenny"),
Pair("lastname", "Smith"),
Pair("mobile", "(323) 867-5309"),
Pair("postcode", "90210"),
Pair("country", "US")
)
// Widget placeholder mapping the placeholder view with placement location configuration
val widget = findViewById<Widget>(R.id.roktWidget)
val placeHolders = hashMapOf(
Pair("RoktEmbedded1", WeakReference(widget))
)
Rokt.execute2Step(pageIdentifier, attributes, this, placeholders, object : Rokt.RoktEventCallback {
override fun onEvent(eventType: Rokt.RoktEventType, roktEventHandler: Rokt.RoktEventHandler) {
if (eventType == Rokt.RoktEventType.FirstPositiveEngagement) {
roktEventHandler.setFulfillmentAttributes(mapOf("email" to "j.smith@example.com"))
}
}
})
...
}
}
Java
import com.rokt.roktsdk.Widget;
import com.rokt.roktsdk.Rokt;
class ConfirmationActivity : Activity() {
private Rokt.RoktCallback roktCallback = new Rokt.RoktCallback() {
@Override
public void onLoad() {
}
@Override
public void onShouldShowLoadingIndicator() {
}
@Override
public void onShouldHideLoadingIndicator() {
}
@Override
public void onUnload(@NotNull Rokt.UnloadReasons unloadReasons) {
}
};
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
...
Map<String, String> attributes = new HashMap<String, String>();
attributes.put("emailsha256", "36f15652992f5c291ea233b930c8c435ee5a5fb115d25933e3266591d3f92f74");
attributes.put("firstname", "Jenny");
attributes.put("lastname", "Smith");
attributes.put("mobile", "(323) 867-5309");
attributes.put("postcode", "90210");
attributes.put("country", "US");
// Widget placeholder mapping the placeholder view with placement location configuration
Widget widget = findViewById(R.id.roktWidget);
Map<String, WeakReference<Widget>> placeHolders = new HashMap<>();
placeHolders.put("RoktEmbedded1", new WeakReference<>(widget));
Rokt.INSTANCE.execute2Step("test,", roktCallback, new Rokt.RoktEventCallback() {
@Override
public void onEvent(Rokt.RoktEventType roktEventType, Rokt.RoktEventHandler roktEventHandler) {
Map<String,String> attributes = new HashMap<String, String>();
attributes.put("email", "j.smith@example.com");
if (roktEventType == Rokt.RoktEventType.FirstPositiveEngagement){
roktEventHandler.setFulfillmentAttributes(attributes);
}
}
});
...
}
}
The above snippet assumes you supply the hashed variant of the email synchronously prior to call execute2step method.
Note: please ensure that the email is lower cased and trimmed of whitespace prior to hashing.