order
    • 2 Minutes to read
    • Dark
      Light

    order

    • Dark
      Light

    Article summary

    Overview

    Value

    Description

    Data type

    Default value

    Required

    Where to analyze

    Request Parameter

    value

    Total order value including/excluding shipping, taxes, etc. Find more details below.

    String


    Yes

    Metric

    ov

    id

    Provide a unique order ID. This ensures that no orders are counted twice. If no id (see below) has been passed, Mapp Intelligence generates it.

    String


    -

    E-Commerce > Orders separately

    oi

    currency

    Contains the used currency code (ISO standard). Only relevant if several currencies are used in the shop. Find more details below.

    String


    -

    -

    cr

    couponValue

    Use this parameter if a coupon has been used. Contains the value of a coupon.

    Number

    0

    -

    Metric

    cb563

    paymentMethod

    Provide the payment method of the order.

    String


    -

    E-Commerce > E-Commerce Parameters

    cb761

    shippingService

    Provide the shipping service for the order.

    String


    -

    E-Commerce > E-Commerce Parameters

    cb762

    shippingSpeed

    Provide the delivery time of the order.

    String


    -

    E-Commerce > E-Commerce Parameters

    cb763

    shippingCosts

    Provide the delivery costs of the order.

    Number

    0

    -

    Metric

    cb764

    grossMargin

    Provide the margin of the order.

    Number

    0

    -

    Metric

    cb765

    orderStatus

    Provide the order status. Usually, this parameter gets imported. Typical examples are "Shipped", "Returned".

    String


    -

    E-Commerce > E-Commerce Parameters

    cb766

    parameter

    Use e-commerce parameters to add further information to an order. Find more details below.

    Object


    -

    E-Commerce > E-Commerce Parameters or metric


    cb[ID]

    Further information

    value

    "0" values are permitted.

    Do not use any thousands separator. Decimal places are separated using a point or comma.

    currency

    It can convert the order value, coupon value, shipping costs, and, if activated, other parameters into the default currency automatically. Please specify the default under Mapp Q3 > Configuration > System configuration > Data Collection.

    parameter

    Before use, parameters must be set up under Mapp Q3 > Configuration > Custom Parameters > E-Commerce Parameter.

    The ID and data type are defined for each parameter during setup. The reference (product or order) is selected during configuration. If "individual value" is set, the parameter refers to the order. If "multiple values" have been set, the parameter can refer to the product or the order. Find more info here.

    Example (parameter with ID "1"): {1:"Onlineshop"}

    You will find all tracked E-Commerce parameters if they are data type "text" or "generic" under E-Commerce > E-Commerce Parameters. Data type "number" will be available as a metric.

    Implementation Examples

    If you do not have automatic page tracking enabled, invoke the track method after adding all relevant tracking information.

    import { Component } from '@angular/core';
    import { WebtrekkSmartPixelAngular } from '@webtrekk-smart-pixel/angular';
    
    @Component({
        template: `<div>[ ... ]</div>`
    })
    export class ExampleComponent {
        constructor(private pixel: WebtrekkSmartPixelAngular) {
            this.pixel.order({
                value: 120.99,
                id: "M-12345",
                couponValue: 10.00,
                paymentMethod: "paypal",
                shippingService: "dhl",
                shippingSpeed: "express",
                shippingCosts: 4.95,
                grossMargin: 12.95,
                parameter: {5: "bill"}
            });
        }
    }

    Please add WebtrekkSmartPixelModule to your root NgModule and configure the options before using directives.

    If you do not have automatic page tracking enabled, invoke the track method after adding all relevant tracking information.

    import { Component } from '@angular/core';
    
    @Component({
        template: `<div [wt-order-data]="webtrekkData"></div>`
    })
    export class ExampleComponent {
        webtrekkData = {
            value: 19.95,
            id: '123456789',
            currency: 'EUR',
            couponValue: 10,
            paymentMethod: '1',
            shippingService: '2',
            shippingSpeed: '3',
            shippingCosts: 2.75,
            grossMargin: 2.50,
            orderStatus: '5',
            parameter: {1: 'foo', 2: 'bar'}
        }
    }


    Was this article helpful?

    What's Next