What Is TikTok for Business?

TikTok for Business is a global platform designed to give brands and marketers the solutions to be creative storytellers and meaningfully engage with the TikTok community.

Streamline TikTok customer data streaming with MetaRouter's unified tracking tag. Easily route your website and mobile events to TikTok to create advertising audience segments, measure campaign performance, and attribute conversions to ads that your customers have viewed on TikTok.

What are the benefits of integrating MetaRouter with TikTok for Business?

  • Enables TikTok tag removal.
  • No effect on website load latency.
  • Ensures event data is streaming into TikTok for Business for accurate ad decisioning and measurement.

Getting Started - From Your TikTok Account

From the TikTok Events Manager

  1. In Settings, generate access token used for authentication.
  2. Click the pixel to view its configuration details.
  3. In the Test Events tab, click the test code button to copy the code.
  4. In the body of your API request for reporting events, add a new field test_event_code
    and paste the code you get from Step 2 as the value of the field.
  5. Send the API Request.
  6. Replace values for Access-Token, pixel_code, and test_event_code with your own. For more information on retrieving the access token, pixel code, and the test event code, please refer to TikTok's documentation here.

From the TikTok Ads Manager

  1. Look for the test event in the Event Activity section to verify setup. Please refer to this document for verifying server-side integration setup.

Grab your Pixel ID

  1. From the TikTok Ads Manager, go to Tools in the upper-navigation.
  2. Click on Events.
  3. Click Manage under Web Events.
  4. Your Main Pixel ID will be listed.

Getting Started - From Your MetaRouter Account

Adding a TikTok integration.

From the integration library, add a TikTok integration. Then, fill out the Connection Parameters:

Connection ParameterDescription
API_VERSIONDefault version v1.2.
API_KEYAccess token generated under Settings in TikTok Events Manager.
PIXEL_IDYour pixel ID.

Adding a TikTok Sync

To gather the ttclid value (TikTok click ID) and ttp (TikTok tracking parameter) value, you must add a TikTok sync.

  1. From the Pipelines page, find the pipeline associated with the web property you’d like to add a sync to. Hover over the three dot dropdown and select “Build AJS File.”
  2. In the Identity Syncs section, select the TikTok sync.
  3. Fill out the following fields:
    1. Consent Type
    2. Cookie Lifetime (in days) - default 7 days
  4. Scroll down and click the Save and Build File button.
  5. Deploy your AJS file to propagate changes to your web property.

Event Mappings

MetaRouter provides all of the event mappings that TikTok integrations typically require. You may add custom events, parameters or mappings in accordance with TikTok’s API documentation.

Global

Global mappings will be applied to all events. If your parameter names do not match the Expected Inputs provided, you will need to overwrite the Inputs provided with your own.

Output KeyDescriptionExpected Input
event_id
Required
Type: string
Unique identifier for the event, generated by combining anonymousId and messageId.
N/A - Expression
timestamp
Required
Type: int
The timestamp of the event.
timestamp
context.ad.callback
Required
Type: string
TikTok ad callback identifier.
context.providers.tiktok.ttclid
context.page.url
Required
Type: string
The URL of the page where the event occurred.
N/A - Expression
context.page.referrerType: string
The referrer URL of the page where the event occurred.
context.page.referrer
context.user.ttp
Required
Type: string
TikTok tracking parameter.
context.providers.tiktok.ttp
context.user.external_id
Required
Type: string
External user identifier, hashed.
N/A - Expression
context.user.emailType: string
User email address, hashed.
N/A - Expression
context.user.phone_numberType: string
User phone number, hashed.
N/A - Expression
context.ip
Required
Type: string
IP address of the user.
context.ip
context.user_agent
Required
Type: string
User agent string of the browser.
context.userAgent

Event Specific

page

Output KeyDescriptionExpected Input
event
Required
Type: string
The name of the event.
Enrichment - ViewContent
properties.descriptionType: string
Description of the event.
Enrichment - page

products_searched

Output KeyDescriptionExpected Input
event
Required
Type: string - The name of the event.Enrichment - Search
properties.query
Required
Type: string - Search query text.properties.query

product_list_viewed

Output KeyDescriptionExpected Input
event
Required
Type: string - The name of the event.Enrichment - ViewContent
properties.descriptionType: string - Description of the event.Enrichment - product list viewed
properties.currency
Required
Type: string - Currency used in the transaction, converted to uppercase.properties.currency, default USD
properties.value
Required
Type: float - Total value of the viewed products.N/A - Expression
properties.contents
Required
Type: list of objects - List of contents in the product list viewed.N/A - Expression

product_viewed

Output KeyDescriptionExpected Input
event
Required
Type: string - The name of the event.Enrichment - ViewContent
properties.descriptionType: string - Description of the event.Enrichment - product viewed
properties.value
Required
Type: float - Price of the viewed product.properties.price
properties.contents
Required
Type: list of objects - Details of the viewed product.N/A - Expression

product_added

Output KeyDescriptionExpected Input
event
Required
Type: string - The name of the event.Enrichment - AddToCart
properties.currency
Required
Type: string - Currency used in the transaction, converted to uppercase.properties.currency, default USD
properties.value
Required
Type: float - Total value of the added product.N/A - Expression
properties.contents
Required
Type: list of objects - Details of the added product.N/A - Expression

cart_viewed

Output KeyDescriptionExpected Input
event
Required
Type: string - The name of the event.Enrichment - InitiateCheckout
properties.currency
Required
Type: string - Currency used in the transaction, converted to uppercase.properties.currency, default USD
properties.value
Required
Type: float - Total value of the cart.N/A - Expression
properties.contents
Required
Type: list of objects - Details of the cart contents.N/A - Expression

order_completed

Output KeyDescriptionExpected Input
event
Required
Type: string - The name of the event.Enrichment - CompletePayment
properties.currency
Required
Type: string - Currency used in the transaction, converted to uppercase.properties.currency, default USD
properties.value
Required
Type: float - Total value of the order.N/A - Expression
properties.contents
Required
Type: list of objects - Details of the ordered products.N/A - Expression

signed_up

Output KeyDescriptionExpected Input
event
Required
Type: string - The name of the event.Enrichment - CompleteRegistration

Required & Recommended Identifiers

These identifiers must be mapped to TikTok in order for successful user matching to occur. Without these IDs, any events sent to TikTok may not be accurately reflected in reporting. For your convenience, required and recommended IDs are mapped as Global parameters to ensure they are added to every event.

AttributeExampleSync Injector Required?
external_id
Required
SHA-256 hash: a84b5f3151b8b3de6bbd9067d3ed1bc3e4f9b30b6a6cfaf6746dbf8bb8f3adccNo
ip
Required
"192.168.0.1"No
ttclid
Required
"123e4567-e89b-12d3-a456-426614174000"Yes
timestamp
Required
"2023-05-28T14:45:00Z"No
userAgent
Required
"Mozilla/5.0 (Windows NT 10.0; Win64; x64)"No
ttp
Required
"a1b2c3d4e5f6"Yes
email
Recommended
SHA-256 hash: 587dfd511a0c05a6d71c4afae60bece0a5f8ccf2f7e7b1c74e3b9f1a5f8f5152No
phone_number
Recommended
SHA-256 hash: b1a8fd06fc2a2d5f2f03027e6d0d85ad9a9c0d1dcb8821b4d4cfc4d6d38b8b82No

Additional TikTok for Business Documentation

Ad Measurement API

Events API

Report Web Events in Bulk