Is AI recommending you? Ask Contentstack Canoe for free
Is AI recommending your brand? Find out with Contentstack Canoe for free
Contentstack.comAcademyLogin
CS-log-dark.svgCS-log-dark.svg
  • Changelog
  • APIs
  • SDKs

Platform

  • Solution Center
  • Marketplace
  • Changelog
  • Developers & IT
  • Business users
  • Digital leaders
  • Developer Fast Track
  • Plans & Pricing

Solutions

  • Retail
  • Travel and tourism
  • Financial services
  • Technology
  • Manufacturing
  • E-commerce
  • Localization
  • Personalization
  • Portals and knowledge bases

Resources

  • Academy
  • Docs
  • Contentstack for Developers
  • Product updates
  • Contentstack on Contentstack
  • Blog
  • Insights and analyst reports
  • The Forrester Wave™: Digital Experience Platforms, Q4 2025
  • Webinars
  • Podcasts
  • Glossary
  • Content generative library
  • Community
  • Headless CMS
  • Composable AXP
  • Personalization
  • CDP

Customers

  • Case Studies
  • Customer Care
  • Contentstack Experience Awards
  • Customer support

Partners

  • Overview
  • Find a partner
  • Login

Company

  • About us
  • News
  • Customer support portal
  • Contact

Social

  • Facebook
  • LinkedIn
  • Instagram
  • GitHub
  • YouTube
  • Discord
  • X
LegalTermsPrivacyTrust Center

Cookie settings

Copyright © 2026 Contentstack Inc. All rights reserved.
/
  1. Home
  2. APIs
  3. Lytics API
  4. Jobs
  5. Analytics Setup

Analytics Setup

markdownView as Markdown

Create and manage data import and export jobs.

AnalyticsSetup: Create job

POSThttps://api.lytics.io/v2/job/analytics-setup

Create a AnalyticsSetup job

Sample Request
123456789101112131415161718192021222324
{
  "auth_ids": [
    "string"
  ],
  "config": {
    "adwords_account_id": "string",
    "ga4": true,
    "premium_account": true,
    "user_fields": [
      "string"
    ],
    "web_property_id": "string",
    "web_segment_dimension": "string",
    "web_user_dimension": "string"
  },
  "description": "string",
  "drop_events_during_quiet_window": true,
  "expires_at": "2019-08-24T14:15:22Z",
  "monitoring": {},
  "name": "string",
  "quiet_period": 0,
  "quiet_time_of_day": "string",
  "quiet_timezone": "string"
}
Sample Response
Status|201 Created
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
{
  "_meta": {},
  "data": {
    "account_id": "string",
    "anomaly_rule": {
      "aid": 0,
      "checks": [
        {
          "allowable_violations": 0,
          "interval": "string",
          "lookback_count": 0,
          "max_threshold": 0,
          "metric_type": "string",
          "min_threshold": 0,
          "type": "string",
          "variance_pct": 0
        }
      ],
      "created": "string",
      "id": "string",
      "subject_id": "string",
      "subject_type": "string",
      "updated": "string"
    },
    "api_token_auth_id": "string",
    "auth_ids": [
      "string"
    ],
    "config": {
      "adwords_account_id": "string",
      "ga4": true,
      "premium_account": true,
      "user_fields": [
        "string"
      ],
      "web_property_id": "string",
      "web_segment_dimension": "string",
      "web_user_dimension": "string"
    },
    "created": "string",
    "deleted": true,
    "description": "string",
    "drop_events_during_quiet_window": true,
    "expires_at": "2019-08-24T14:15:22Z",
    "id": "string",
    "meta": {},
    "monitoring": {},
    "name": "string",
    "quiet_period": 0,
    "quiet_time_of_day": "string",
    "quiet_timezone": "string",
    "sleep_until": "string",
    "status": "runnable",
    "updated": "string",
    "user_id": "string",
    "workflow": "string",
    "workflow_id": "string"
  },
  "request_id": "string",
  "status": 0
}

AnalyticsSetup: Get job

GEThttps://api.lytics.io/v2/job/analytics-setup/{id}

Get the summary of a AnalyticsSetup job

Sample Response
Status|200 OK
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
{
  "_meta": {},
  "data": {
    "account_id": "string",
    "anomaly_rule": {
      "aid": 0,
      "checks": [
        {
          "allowable_violations": 0,
          "interval": "string",
          "lookback_count": 0,
          "max_threshold": 0,
          "metric_type": "string",
          "min_threshold": 0,
          "type": "string",
          "variance_pct": 0
        }
      ],
      "created": "string",
      "id": "string",
      "subject_id": "string",
      "subject_type": "string",
      "updated": "string"
    },
    "api_token_auth_id": "string",
    "auth_ids": [
      "string"
    ],
    "config": {
      "adwords_account_id": "string",
      "ga4": true,
      "premium_account": true,
      "user_fields": [
        "string"
      ],
      "web_property_id": "string",
      "web_segment_dimension": "string",
      "web_user_dimension": "string"
    },
    "created": "string",
    "deleted": true,
    "description": "string",
    "drop_events_during_quiet_window": true,
    "expires_at": "2019-08-24T14:15:22Z",
    "id": "string",
    "meta": {},
    "monitoring": {},
    "name": "string",
    "quiet_period": 0,
    "quiet_time_of_day": "string",
    "quiet_timezone": "string",
    "sleep_until": "string",
    "status": "runnable",
    "updated": "string",
    "user_id": "string",
    "workflow": "string",
    "workflow_id": "string"
  },
  "request_id": "string",
  "status": 0
}

AnalyticsSetup: Update job

PUThttps://api.lytics.io/v2/job/analytics-setup/{id}

Update a AnalyticsSetup job

Sample Request
123456789101112131415161718192021222324
{
  "auth_ids": [
    "string"
  ],
  "config": {
    "adwords_account_id": "string",
    "ga4": true,
    "premium_account": true,
    "user_fields": [
      "string"
    ],
    "web_property_id": "string",
    "web_segment_dimension": "string",
    "web_user_dimension": "string"
  },
  "description": "string",
  "drop_events_during_quiet_window": true,
  "expires_at": "2019-08-24T14:15:22Z",
  "monitoring": {},
  "name": "string",
  "quiet_period": 0,
  "quiet_time_of_day": "string",
  "quiet_timezone": "string"
}
Sample Response
Status|200 OK
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
{
  "_meta": {},
  "data": {
    "account_id": "string",
    "anomaly_rule": {
      "aid": 0,
      "checks": [
        {
          "allowable_violations": 0,
          "interval": "string",
          "lookback_count": 0,
          "max_threshold": 0,
          "metric_type": "string",
          "min_threshold": 0,
          "type": "string",
          "variance_pct": 0
        }
      ],
      "created": "string",
      "id": "string",
      "subject_id": "string",
      "subject_type": "string",
      "updated": "string"
    },
    "api_token_auth_id": "string",
    "auth_ids": [
      "string"
    ],
    "config": {
      "adwords_account_id": "string",
      "ga4": true,
      "premium_account": true,
      "user_fields": [
        "string"
      ],
      "web_property_id": "string",
      "web_segment_dimension": "string",
      "web_user_dimension": "string"
    },
    "created": "string",
    "deleted": true,
    "description": "string",
    "drop_events_during_quiet_window": true,
    "expires_at": "2019-08-24T14:15:22Z",
    "id": "string",
    "meta": {},
    "monitoring": {},
    "name": "string",
    "quiet_period": 0,
    "quiet_time_of_day": "string",
    "quiet_timezone": "string",
    "sleep_until": "string",
    "status": "runnable",
    "updated": "string",
    "user_id": "string",
    "workflow": "string",
    "workflow_id": "string"
  },
  "request_id": "string",
  "status": 0
}
Hide Parameters

Query Parameters

account_idoptionalstring

The account ID. Defaults to the user's default account.

Headers

Authorizationoptionalstring

Body Parameters

auth_idsoptionalstring[]

Authorization IDs associated with the Job

configrequiredobject

Job configuration, unique per-workflow

config.adwords_account_idoptionalstring

Select which Google Analytics account to use

config.ga4optionalboolean

Select whether Google Analytics 4 or Google Universal Analytics is used

config.premium_accountoptionalboolean

Check if you have a Google Analytics 360 account

config.user_fieldsoptionalstring[]

Select the user fields to export to Google Analytics. If none are selected, only user audience affiliation will be exported. Regular Google Analytics accounts are limited to 20 custom dimensions per property and Google Analytics 360 accounts are limited to 200. Please make sure that there is enough room in your account for the number of dimensions that you select plus the two default dimensions

config.web_property_idoptionalstring

Select which web property to use. This will be the web property you use for all future Google Analytics data syncs

config.web_segment_dimensionoptionalstring

Select which custom dimension you would like to pass Lytics audiences to. We'll create one for you labeled "Lytics Audiences" if nothing is selected (recommended)

config.web_user_dimensionoptionalstring

Select which custom dimension to pass Lytics user IDs to. One will be created for you labeled "Lytics User ID" if nothing is selected (recommended).

descriptionoptionalstring

A user-defined description

drop_events_during_quiet_windowoptionalboolean
expires_atoptionalstring (date-time)
monitoringoptionalobject

Inline monitoring config. On write: omit to keep, null to clear, or a config to set.

namerequiredstring

A user-defined name

quiet_periodoptionalinteger
quiet_time_of_dayoptionalstring
quiet_timezoneoptionalstring
Hide Parameters

URL Parameters

idrequiredstring

The Job ID

Query Parameters

account_idoptionalstring

The account ID. Defaults to the user's default account.

Headers

Authorizationoptionalstring

Hide Parameters

URL Parameters

idrequiredstring

The Job ID

Query Parameters

account_idoptionalstring

The account ID. Defaults to the user's default account.

Headers

Authorizationoptionalstring

Body Parameters

auth_idsoptionalstring[]

Authorization IDs associated with the Job

configrequiredobject

Job configuration, unique per-workflow

config.adwords_account_idoptionalstring

Select which Google Analytics account to use

config.ga4optionalboolean

Select whether Google Analytics 4 or Google Universal Analytics is used

config.premium_accountoptionalboolean

Check if you have a Google Analytics 360 account

config.user_fieldsoptionalstring[]

Select the user fields to export to Google Analytics. If none are selected, only user audience affiliation will be exported. Regular Google Analytics accounts are limited to 20 custom dimensions per property and Google Analytics 360 accounts are limited to 200. Please make sure that there is enough room in your account for the number of dimensions that you select plus the two default dimensions

config.web_property_idoptionalstring

Select which web property to use. This will be the web property you use for all future Google Analytics data syncs

config.web_segment_dimensionoptionalstring

Select which custom dimension you would like to pass Lytics audiences to. We'll create one for you labeled "Lytics Audiences" if nothing is selected (recommended)

config.web_user_dimensionoptionalstring

Select which custom dimension to pass Lytics user IDs to. One will be created for you labeled "Lytics User ID" if nothing is selected (recommended).

descriptionoptionalstring

A user-defined description

drop_events_during_quiet_windowoptionalboolean
expires_atoptionalstring (date-time)
monitoringoptionalobject

Inline monitoring config. On write: omit to keep, null to clear, or a config to set.

namerequiredstring

A user-defined name

quiet_periodoptionalinteger
quiet_time_of_dayoptionalstring
quiet_timezoneoptionalstring