You can use the RudderStack track event to track events along with any associated properties and send this information to Rakuten.
A sample track event is shown below:
rudderananlytics.track('event',{orderId:"OR122441",land:1234,ranSiteId:"823421983a3-231824ft12-e12-gh1208b12-14"products:[{sku:'sku1',amount:'8'// instead of 10 for 20% discount
quantity:1,name:'Product1'},{sku:'sku2',amount:81// instead of 90 for 10% discount
quantity:2,name:'Product2'}]})
Property mappings
RudderStack maps the following properties to the Rakuten fields:
Note: Identifier representing the customer like ID, hashed email, etc. Make sure to not pass any PII. Any special characters should be URL-encoded into the hex format.
Note: Set in a cookie of your Rakuten Marketing-specific gateway page. Can include mixed-case letters, numbers, and special characters like -, ., _, /, and *.
properties.segment
segment
<32 characters
Note: Represents the customer segment.
properties.shipcountry properties.ship_country
shipcountry
<3 characters
Note: The country where the order is to be shipped. Must follow the ISO 3-character country code.
properties.shipped
shipped
Should be present as YYYYMMDD_HHMM in the GMT 24-hour format.
Note: Expected date when the order will be shipped.
Note: Identifier representing where the conversion took place like domain name of the site. Any special characters should be URL-encoded in the hex format.
properties.storeId properties.store_id
storeid
<255 characters
Note: Represents the category of the store where the conversion occurred.
Note: Represents the category name for the store where the conversion occurred.
Item-level mappings
RudderStack maps the following item-level properties to the Rakuten properties:
RudderStack property
Rakuten property
Limitations
product.$.sku
Required
skulist.$
-
product.$.amount product.$.(price*quantity)
Required
amtlist.$
-
product.$.quantity
Required
qlist.$
-
product.$.name
Required
namelist.$
-
product.$.brand
brandlist.$
<255 characters.
product.$.coupon
couponlist.$
-
Note: Holds a pipe-delimited list of item-level coupons applied to the order. Order of values in this list must match the order of values in skulist. Multiple item-level coupon codes are not allowed.
product.$.categoryId
catidlist.$
<128 characters
Note: You can specify up to 5 category IDs per item separated by >. For example, (1001>2001>3001)
product.$.category
catlist.$
<255 characters
Note: You can specify up to 5 category IDs per item separated by >. For example, (ParentCat>ChildCat1>ChildCat2)
product.$.discountAmount
disamtlist.$
<9 characters
Note: Pipe delimited list of item-specific discount amounts formatted as a number. Values must match the order of values in skulist.
product.$.discountType
distypelist.$
<256 characters
Note: Pipe delimited list of item-level discount types. Order of values must match of values in skulist. Special characters should be URL-encoded in hex format.
product.$.isClearance
isclearancelist.$
Acceptable values are Y or N
Note: Pipe delimited list of flags indicating if the item is on clearance. Values must match the order of values in skulist.
product.$.isMarketPlace
ismarketplacelist.$
Acceptable values are Y or N
Note: Pipe delimited list of flags indicating if the item is from a marketplace. Values must match the order of values in skulist.
product.$.isSale
issalelist.$
Acceptable values are Y or N
Note: Pipe delimited list of flags indicating if the item is on sale. Values must match the order of values in skulist.
product.$.itmStatus
itmstatuslist.$
<32 characters
Note: Pipe delimited list of item-level statuses. Order of values in this list must match the order of values in skulist. Possible values are In-Stock, Back-Ordered, etc. Special characters must be URL-encoded in hex format.
product.$.margin
marginlist.$
<3 characters
Note: Pipe delimited list representing profit margin of the products. Order of values in this list must match the order of values in skulist.
product.$.markdown
markdownlist.$
<6 characters
Note: Pipe delimited list representing markdown rate of an item. Order of values in this list must match the order of values in skulist.
product.$.sequence
sequencelist.$
<4 characters.
Note: Identifies the sequence of items included in a shipment or return.
product.$.shipby
shipbylist.$
<32 characters
Note: Pipe delimited list of strings identifying who shipped the item. Possible values are Store if the item is shipped from a physical store, Fulfullment Vendor X if shipped by a fulfillment partner, etc. Special characters must be URL-encoded in hex format.
product.$.shipID
shipidlist.$
<32 characters
Note: Identifies a collection of items that are shipped or returned together.
product.$.taxexempt
taxexemptlist.$
Acceptable values are Y or N
Note: Pipe delimited list of flags indicating if the item is tax-exempt. Rakuten then reduces the transaction amount by a defined tax rate.
Discount reporting
For accurate discount reporting, make sure to report only product discounts or discounts that reduce a product subtotal. Do not include free shipping in the discount amount.
Suppose a customer purchases 1 item of SKU A for $10.00 and 2 items of SKU B for $45.00 each and then redeems a 10% order-level discount. In that case, Rakuten provides two options for reporting discounts:
Reduced item reporting (preferred)
Discounts as SKU
Reduced item reporting
Rakuten prescribes this reporting method for selected goods commissioning, that is, if you want to commission by product type.
In this case, you can adjust the reported amount value to reflect the applied discounts. In the above example, you can send the amounts in a product array as $9.00 and $81.00 respectively for the two SKUs.
For multiple item purchases, disperse the discounts accordingly among each value in the total amount value.
Discounts as SKU
Rakuten prescribes this method if you intend to set the same commission on all goods.
For this reporting model, add an extra value to the sku, quantity, amount, and the product name fields that depict the discount.
For sku, and name, use the string Discount.
For quantity, use 0.
For amount, use the negative dollar value of the discount.
A sample track event highlighting this method is shown:
rudderananlytics.track('event',{products:[{sku:'sku1',amount:'100'quantity:1},{sku:'Discount',name:'Discount',amount:-10// Total discount of 10
quantity:0}]})
FAQ
Why are products commissionable even if iscomm is set to N (no)?
Note that iscomm is applicable for the entire order.
Even if you have iscomm=N in the postback, the transaction is still commissionable in Rakuten. You need to explicitly set the dynamic commissioning rules (for example, if iscomm equals N, pay $0 commission) in the Rakuten dashboard to avoid paying commission for a particular order.
How can I report a returned item in Order Cancelled or Partially Cancelled events?
Suppose a customer returns two items of SKU A and one item of SKU B, the cancellation records would look like below:
Note that the quantity shows the number of returned items and price is negative, reflecting the return. Quantity is not a negative number for returns unless the price in the original order was zero.
You must also account for any discounts applied during the order cancellation. For reduced item discount reporting, note that:
If you are using discount as a SKU option, send a cancellation record for the discount SKU item in addition to the regular SKUs of the order for cancellation.
This site uses cookies to improve your experience while you navigate through the website. Out of
these
cookies, the cookies that are categorized as necessary are stored on your browser as they are as
essential
for the working of basic functionalities of the website. We also use third-party cookies that
help
us
analyze and understand how you use this website. These cookies will be stored in your browser
only
with
your
consent. You also have the option to opt-out of these cookies. But opting out of some of these
cookies
may
have an effect on your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. This
category only includes cookies that ensures basic functionalities and security
features of the website. These cookies do not store any personal information.
This site uses cookies to improve your experience. If you want to
learn more about cookies and why we use them, visit our cookie
policy. We'll assume you're ok with this, but you can opt-out if you wish Cookie Settings.