version: 2
models:
  - name: AD_REPORTING_ACCOUNT_DBT
    description: The most recent data for all ad accounts on all marketing platforms.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Ad Account ID
        tests:
          - not_null
      - name: PLATFORM
        description: Marketing Platform
        tests:
          - accepted_values:
              arguments:
                values: ['META', 'TIKTOK', 'GOOGLE']
      - name: NAME
        description: Ad Account Name
        tests:
          - not_null
      - name: BUSINESS_ACCOUNT_ID
        description: Business Manager Business Id
      - name: BUSINESS_ACCOUNT_NAME
        description: Business Manager Business Name
      - name: CURRENCY
        description: Account Currency
      - name: CAMPAIGNS_COUNT
        description: Number of Ad Campaigns of an Ad Account
        tests:
          - not_null
      - name: SYNCED_AT
        description: Timestamp of the last data sync by Fivetran
        tests:
          - not_null
  - name: AD_REPORTING_CAMPAIGN_DBT
    description: |
      The most recent Ad Campaign data for all marketing platforms.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Campaign Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Campaign External ID
        tests:
          - not_null
      - name: PLATFORM
        description: Marketing Platform
        tests:
          - accepted_values:
              arguments:
                values: ['META', 'TIKTOK', 'GOOGLE']
      - name: NAME
        description: Campaign Name
        tests:
          - not_null
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: GLOBAL_PARTICIPANT_ID
        description: |
          Global Participant ID matched using fuzzy string matching.
          Can be NULL.
      - name: START_AT
        description: Campaign Start datetime
        tests:
          - not_null
      - name: END_AT
        description: Campaign End datetime
        tests:
          - not_null
      - name: STATUS
        description: Campaign Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE' ]
      - name: EFFECTIVE_STATUS
        description: Campaign Effective Status
        tests:
          - not_null
      - name: OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: DAILY_BUDGET
        description: Campaign Daily Budget
      - name: LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: AD_SET_DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: AD_SET_LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "DAILY_BUDGET is null"
      - name: LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "LIFETIME_BUDGET is null"
      - name: AD_SET_DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is null"
      - name: AD_SET_LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Campaign Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Campaign Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Campaign Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_P50
        description: The number of times a video was played at 50% of its length.
        tests:
          - not_null
      - name: VIEWS_P75
        description: The number of times a video was played at 75% of its length.
        tests:
          - not_null
      - name: VIEWS_P100
        description: The number of times a video was played at 100% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
          - not_null
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Campaign Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Campaign Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED']
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_CAMPAIGN_DATE_DBT
    description: |
      The most recent Ad Campaign data for all marketing platforms by date.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
              - REPORT_DATE
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Campaign Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Campaign External ID
        tests:
          - not_null
      - name: REPORT_DATE
        description: Report Date
        tests:
          - not_null
      - name: PLATFORM
        description: Marketing Platform
        tests:
          - accepted_values:
              arguments:
                values: [ 'META', 'TIKTOK', 'GOOGLE' ]
      - name: NAME
        description: Campaign Name
        tests:
          - not_null
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: GLOBAL_PARTICIPANT_ID
        description: |
          Global Participant ID matched using fuzzy string matching.
          Can be NULL.
      - name: START_AT
        description: Campaign Start datetime
        tests:
          - not_null
      - name: END_AT
        description: Campaign End datetime
        tests:
          - not_null
      - name: STATUS
        description: Campaign Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE' ]
      - name: EFFECTIVE_STATUS
        description: Campaign Effective Status
        tests:
          - not_null
      - name: OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: DAILY_BUDGET
        description: Campaign Daily Budget
      - name: LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: AD_SET_DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: AD_SET_LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "DAILY_BUDGET is null"
      - name: LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "LIFETIME_BUDGET is null"
      - name: AD_SET_DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is null"
      - name: AD_SET_LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Campaign Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Campaign Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Campaign Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_P50
        description: The number of times a video was played at 50% of its length.
        tests:
          - not_null
      - name: VIEWS_P75
        description: The number of times a video was played at 75% of its length.
        tests:
          - not_null
      - name: VIEWS_P100
        description: The number of times a video was played at 100% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Campaign Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Campaign Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_CAMPAIGN_COUNTRY_DBT
    description: |
      The most recent Ad Campaign data for all marketing platforms by country.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - CAMPAIGN_ID
              - COUNTRY_CODE
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Campaign External ID
        tests:
          - not_null
      - name: COUNTRY_CODE
        description: Ad Country (ISO2 or UNKNOWN)
        tests:
          - not_null
      - name: PLATFORM
        description: Marketing Platform
        tests:
          - accepted_values:
              arguments:
                values: [ 'META', 'TIKTOK', 'GOOGLE' ]
      - name: NAME
        description: Campaign Name
        tests:
          - not_null
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: GLOBAL_PARTICIPANT_ID
        description: |
          Global Participant ID matched using fuzzy string matching.
          Can be NULL.
      - name: START_AT
        description: Campaign Start datetime
        tests:
          - not_null
      - name: END_AT
        description: Campaign End datetime
        tests:
          - not_null
      - name: STATUS
        description: Campaign Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE' ]
      - name: EFFECTIVE_STATUS
        description: Campaign Effective Status
        tests:
          - not_null
      - name: OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: DAILY_BUDGET
        description: Campaign Daily Budget
      - name: LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: AD_SET_DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: AD_SET_LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "DAILY_BUDGET is null"
      - name: LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "LIFETIME_BUDGET is null"
      - name: AD_SET_DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is null"
      - name: AD_SET_LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Campaign Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Campaign Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Campaign Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Campaign Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Campaign Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_CAMPAIGN_COUNTRY_DATE_DBT
    description: |
      The most recent Ad Campaign data for all marketing platforms by country and date.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - CAMPAIGN_ID
              - REPORT_DATE
              - COUNTRY_CODE
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Campaign External ID
        tests:
          - not_null
      - name: REPORT_DATE
        description: Report Date
        tests:
          - not_null
      - name: COUNTRY_CODE
        description: Ad Country (ISO2 or UNKNOWN)
        tests:
          - not_null
      - name: PLATFORM
        description: Marketing Platform
        tests:
          - accepted_values:
              arguments:
                values: [ 'META', 'TIKTOK', 'GOOGLE' ]
      - name: NAME
        description: Campaign Name
        tests:
          - not_null
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: GLOBAL_PARTICIPANT_ID
        description: |
          Global Participant ID matched using fuzzy string matching.
          Can be NULL.
      - name: START_AT
        description: Campaign Start datetime
        tests:
          - not_null
      - name: END_AT
        description: Campaign End datetime
        tests:
          - not_null
      - name: STATUS
        description: Campaign Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE' ]
      - name: EFFECTIVE_STATUS
        description: Campaign Effective Status
        tests:
          - not_null
      - name: OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: DAILY_BUDGET
        description: Campaign Daily Budget
      - name: LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: AD_SET_DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: AD_SET_LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "DAILY_BUDGET is null"
      - name: LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "LIFETIME_BUDGET is null"
      - name: AD_SET_DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is null"
      - name: AD_SET_LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Campaign Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Campaign Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Campaign Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Campaign Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Campaign Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_AD_SET_DBT
    description: |
      The most recent Ad Set data for all marketing platforms.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Ad Set Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Ad Set External ID
        tests:
          - not_null
      - name: PLATFORM
        description: Marketing Platform
        tests:
          - accepted_values:
              arguments:
                values: ['META', 'TIKTOK', 'GOOGLE']
      - name: NAME
        description: Ad Set Name
        tests:
          - not_null
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign ID (UUID)
        tests:
          - not_null
      - name: CAMPAIGN_NAME
        description: Campaign name
        tests:
          - not_null
      - name: CAMPAIGN_GLOBAL_PARTICIPANT_ID
        description: Campaign Global Participant ID
      - name: CAMPAIGN_OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: START_AT
        description: Ad Set Start datetime
        tests:
          - not_null
      - name: END_AT
        description: Ad Set End datetime
        tests:
          - not_null
      - name: STATUS
        description: Ad Set Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE', 'FROZEN' ]
      - name: EFFECTIVE_STATUS
        description: Ad Set Effective Status
        tests:
          - not_null
      - name: DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: CAMPAIGN_DAILY_BUDGET
        description: Campaign Daily Budget
      - name: CAMPAIGN_LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "DAILY_BUDGET is null"
      - name: LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "LIFETIME_BUDGET is null"
      - name: CAMPAIGN_DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is null"
      - name: CAMPAIGN_LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Ad Set Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Ad Set Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Ad Set Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_P50
        description: The number of times a video was played at 50% of its length.
        tests:
          - not_null
      - name: VIEWS_P75
        description: The number of times a video was played at 75% of its length.
        tests:
          - not_null
      - name: VIEWS_P100
        description: The number of times a video was played at 100% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Ad Set Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Ad Set Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_AD_SET_DATE_DBT
    description: |
      The most recent Ad Set data for all marketing platforms by date.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
              - REPORT_DATE
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Ad Set Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: REPORT_DATE
        description: Report Date
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Ad Set External ID
        tests:
          - not_null
      - name: PLATFORM
        description: Marketing Platform
        tests:
          - accepted_values:
              arguments:
                values: [ 'META', 'TIKTOK', 'GOOGLE' ]
      - name: NAME
        description: Ad Set Name
        tests:
          - not_null
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign ID (UUID)
        tests:
          - not_null
      - name: CAMPAIGN_NAME
        description: Campaign name
        tests:
          - not_null
      - name: CAMPAIGN_GLOBAL_PARTICIPANT_ID
        description: Campaign Global Participant ID
      - name: CAMPAIGN_OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: START_AT
        description: Ad Set Start datetime
        tests:
          - not_null
      - name: END_AT
        description: Ad Set End datetime
        tests:
          - not_null
      - name: STATUS
        description: Ad Set Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE', 'FROZEN' ]
      - name: EFFECTIVE_STATUS
        description: Ad Set Effective Status
        tests:
          - not_null
      - name: DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: CAMPAIGN_DAILY_BUDGET
        description: Campaign Daily Budget
      - name: CAMPAIGN_LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "DAILY_BUDGET is null"
      - name: LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "LIFETIME_BUDGET is null"
      - name: CAMPAIGN_DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is null"
      - name: CAMPAIGN_LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Ad Set Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Ad Set Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Ad Set Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_P50
        description: The number of times a video was played at 50% of its length.
        tests:
          - not_null
      - name: VIEWS_P75
        description: The number of times a video was played at 75% of its length.
        tests:
          - not_null
      - name: VIEWS_P100
        description: The number of times a video was played at 100% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Ad Set Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Ad Set Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_AD_SET_COUNTRY_DBT
    description: |
      The most recent Ad Set data for all marketing platforms by country.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
              - COUNTRY_CODE
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Ad Set Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Ad Set External ID
        tests:
          - not_null
      - name: COUNTRY_CODE
        description: Tiktok Ad Country (ISO2 or UNKNOWN)
        tests:
          - not_null
      - name: PLATFORM
        description: Marketing Platform
        tests:
          - accepted_values:
              arguments:
                values: [ 'META', 'TIKTOK', 'GOOGLE' ]
      - name: NAME
        description: Ad Set Name
        tests:
          - not_null
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign ID (UUID)
        tests:
          - not_null
      - name: CAMPAIGN_NAME
        description: Campaign name
        tests:
          - not_null
      - name: CAMPAIGN_GLOBAL_PARTICIPANT_ID
        description: Campaign Global Participant ID
      - name: CAMPAIGN_OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: START_AT
        description: Ad Set Start datetime
        tests:
          - not_null
      - name: END_AT
        description: Ad Set End datetime
        tests:
          - not_null
      - name: STATUS
        description: Ad Set Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE', 'FROZEN' ]
      - name: EFFECTIVE_STATUS
        description: Ad Set Effective Status
        tests:
          - not_null
      - name: DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: CAMPAIGN_DAILY_BUDGET
        description: Campaign Daily Budget
      - name: CAMPAIGN_LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "DAILY_BUDGET is null"
      - name: LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "LIFETIME_BUDGET is null"
      - name: CAMPAIGN_DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is null"
      - name: CAMPAIGN_LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Ad Set Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Ad Set Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Ad Set Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: ORDERS_PLACED
        description: The number of Orders placed.
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Ad Set Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Ad Set Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_AD_SET_COUNTRY_DATE_DBT
    description: |
      The most recent Ad Set data for all marketing platforms by country and date.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
              - REPORT_DATE
              - COUNTRY_CODE
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Ad Set Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Ad Set External ID
        tests:
          - not_null
      - name: REPORT_DATE
        description: Report Date
        tests:
          - not_null
      - name: COUNTRY_CODE
        description: Tiktok Ad Country (ISO2 or UNKNOWN)
        tests:
          - not_null
      - name: PLATFORM
        description: Marketing Platform
        tests:
          - accepted_values:
              arguments:
                values: [ 'META', 'TIKTOK', 'GOOGLE' ]
      - name: NAME
        description: Ad Set Name
        tests:
          - not_null
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign ID (UUID)
        tests:
          - not_null
      - name: CAMPAIGN_NAME
        description: Campaign name
        tests:
          - not_null
      - name: CAMPAIGN_GLOBAL_PARTICIPANT_ID
        description: Campaign Global Participant ID
      - name: CAMPAIGN_OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: START_AT
        description: Ad Set Start datetime
        tests:
          - not_null
      - name: END_AT
        description: Ad Set End datetime
        tests:
          - not_null
      - name: STATUS
        description: Ad Set Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE', 'FROZEN' ]
      - name: EFFECTIVE_STATUS
        description: Ad Set Effective Status
        tests:
          - not_null
      - name: DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: CAMPAIGN_DAILY_BUDGET
        description: Campaign Daily Budget
      - name: CAMPAIGN_LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "DAILY_BUDGET is null"
      - name: LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "LIFETIME_BUDGET is null"
      - name: CAMPAIGN_DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is null"
      - name: CAMPAIGN_LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Ad Set Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Ad Set Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Ad Set Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: ORDERS_PLACED
        description: The number of Orders placed.
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Ad Set Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Ad Set Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_AD_DBT
    description: |
      The most recent Ad data for all marketing platforms.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Ad Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Ad External ID
        tests:
          - not_null
      - name: NAME
        description: Ad Name
        tests:
          - not_null
      - name: STATUS
        description: Ad Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE', 'FROZEN' ]
      - name: EFFECTIVE_STATUS
        description: Ad Effective Status
        tests:
          - not_null
      - name: CREATIVE_ID
        description: Creative ID
      - name: CREATIVE_ORIGINAL_THUMBNAIL_URL
        description: Creative thumbnail URL from the platform CDN. Expires in a few days after being synced from Fivetran.
      - name: CREATIVE_IMAGE_URL
        description: Ad Creative original Ad Image URL. It is present when a Creative is an Image uploaded directly to Ads Manager.
      - name: CREATIVE_VIDEO_URL
        description: Ad Creative original Ad Video URL. It is present when a Creative is a Video uploaded directly to Ads Manager.
      - name: CREATIVE_POST_URL
        description: Platform post URL. It is present when a Creative is a boosted post. Leads to Instagram posts for META and TikTok posts for TiKTok.
      - name: TARGET_URL
        description: Platform post URL.
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign ID (UUID)
        tests:
          - not_null
      - name: CAMPAIGN_NAME
        description: Campaign name
        tests:
          - not_null
      - name: CAMPAIGN_GLOBAL_PARTICIPANT_ID
        description: Campaign Global Participant ID
      - name: CAMPAIGN_OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: AD_SET_ID
        description: Ad Set ID (UUID)
        tests:
          - not_null
      - name: AD_SET_NAME
        description: Ad Set name
        tests:
          - not_null
      - name: AD_SET_START_AT
        description: Ad Set Start At timestamp
        tests:
          - not_null
      - name: AD_SET_END_AT
        description: Ad Set End At timestamp
        tests:
          - not_null
      - name: AD_SET_DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: AD_SET_LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: CAMPAIGN_DAILY_BUDGET
        description: Campaign Daily Budget
      - name: CAMPAIGN_LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: AD_SET_DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is null"
      - name: AD_SET_LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is null"
      - name: CAMPAIGN_DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is null"
      - name: CAMPAIGN_LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Ad Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Ad Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Ad Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_P50
        description: The number of times a video was played at 50% of its length.
        tests:
          - not_null
      - name: VIEWS_P75
        description: The number of times a video was played at 75% of its length.
        tests:
          - not_null
      - name: VIEWS_P100
        description: The number of times a video was played at 100% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Ad Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Ad Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: AVERAGE_VIDEO_PLAY
        description: AVerage Video Play metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
        tests:
          - not_null
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_AD_DATE_DBT
    description: |
      The most recent Ad data for all marketing platforms by date.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
              - REPORT_DATE
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Ad Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Ad External ID
        tests:
          - not_null
      - name: REPORT_DATE
        description: Report Date
        tests:
          - not_null
      - name: NAME
        description: Ad Name
        tests:
          - not_null
      - name: STATUS
        description: Ad Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE', 'FROZEN' ]
      - name: EFFECTIVE_STATUS
        description: Ad Effective Status
        tests:
          - not_null
      - name: CREATIVE_ID
        description: Creative ID
      - name: CREATIVE_ORIGINAL_THUMBNAIL_URL
        description: Creative thumbnail URL from the platform CDN. Expires in a few days after being synced from Fivetran.
      - name: CREATIVE_IMAGE_URL
        description: Ad Creative original Ad Image URL. It is present when a Creative is an Image uploaded directly to Ads Manager.
      - name: CREATIVE_VIDEO_URL
        description: Ad Creative original Ad Video URL. It is present when a Creative is a Video uploaded directly to Ads Manager.
      - name: CREATIVE_POST_URL
        description: Platform post URL. It is present when a Creative is a boosted post. Leads to Instagram posts for META and TikTok posts for TiKTok.
      - name: TARGET_URL
        description: Platform post URL.
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign ID (UUID)
        tests:
          - not_null
      - name: CAMPAIGN_NAME
        description: Campaign name
        tests:
          - not_null
      - name: CAMPAIGN_GLOBAL_PARTICIPANT_ID
        description: Campaign Global Participant ID
      - name: CAMPAIGN_OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: AD_SET_ID
        description: Ad Set ID (UUID)
        tests:
          - not_null
      - name: AD_SET_NAME
        description: Ad Set name
        tests:
          - not_null
      - name: AD_SET_START_AT
        description: Ad Set Start At timestamp
        tests:
          - not_null
      - name: AD_SET_END_AT
        description: Ad Set End At timestamp
        tests:
          - not_null
      - name: AD_SET_DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: AD_SET_LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: CAMPAIGN_DAILY_BUDGET
        description: Campaign Daily Budget
      - name: CAMPAIGN_LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: AD_SET_DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is null"
      - name: AD_SET_LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is null"
      - name: CAMPAIGN_DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is null"
      - name: CAMPAIGN_LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Ad Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Ad Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Ad Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_P50
        description: The number of times a video was played at 50% of its length.
        tests:
          - not_null
      - name: VIEWS_P75
        description: The number of times a video was played at 75% of its length.
        tests:
          - not_null
      - name: VIEWS_P100
        description: The number of times a video was played at 100% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Ad Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Ad Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: AVERAGE_VIDEO_PLAY
        description: AVerage Video Play metric.
      - name: AVERAGE_VIDEO_PLAY_PER_USER
        description: Average Video PLay Per user metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
        tests:
          - not_null
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_AD_COUNTRY_DBT
    description: |
      The most recent Ad data for all marketing platforms by country.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
              - COUNTRY_CODE
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Ad Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Ad External ID
        tests:
          - not_null
      - name: COUNTRY_CODE
        description: Tiktok Ad Country (ISO2 or UNKNOWN)
        tests:
          - not_null
      - name: NAME
        description: Ad Name
        tests:
          - not_null
      - name: STATUS
        description: Ad Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE', 'FROZEN' ]
      - name: EFFECTIVE_STATUS
        description: Ad Effective Status
        tests:
          - not_null
      - name: CREATIVE_ID
        description: Creative ID
      - name: CREATIVE_ORIGINAL_THUMBNAIL_URL
        description: Creative thumbnail URL from the platform CDN. Expires in a few days after being synced from Fivetran.
      - name: CREATIVE_IMAGE_URL
        description: Ad Creative original Ad Image URL. It is present when a Creative is an Image uploaded directly to Ads Manager.
      - name: CREATIVE_VIDEO_URL
        description: Ad Creative original Ad Video URL. It is present when a Creative is a Video uploaded directly to Ads Manager.
      - name: CREATIVE_POST_URL
        description: Platform post URL. It is present when a Creative is a boosted post. Leads to Instagram posts for META.
      - name: TARGET_URL
        description: Platform post URL.
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign ID (UUID)
        tests:
          - not_null
      - name: CAMPAIGN_NAME
        description: Campaign name
        tests:
          - not_null
      - name: CAMPAIGN_GLOBAL_PARTICIPANT_ID
        description: Campaign Global Participant ID
      - name: CAMPAIGN_OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: AD_SET_ID
        description: Ad Set ID (UUID)
        tests:
          - not_null
      - name: AD_SET_NAME
        description: Ad Set name
        tests:
          - not_null
      - name: AD_SET_START_AT
        description: Ad Set Start At timestamp
        tests:
          - not_null
      - name: AD_SET_END_AT
        description: Ad Set End At timestamp
        tests:
          - not_null
      - name: AD_SET_DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: AD_SET_LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: CAMPAIGN_DAILY_BUDGET
        description: Campaign Daily Budget
      - name: CAMPAIGN_LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: AD_SET_DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is null"
      - name: AD_SET_LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is null"
      - name: CAMPAIGN_DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is null"
      - name: CAMPAIGN_LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Ad Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Ad Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Ad Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: ORDERS_PLACED
        description: The number of Orders Placed.
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Ad Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Ad Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: AVERAGE_VIDEO_PLAY
        description: AVerage Video Play metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
        tests:
          - not_null
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_AD_COUNTRY_DATE_DBT
    description: |
      The most recent Ad data for all marketing platforms by country and date.
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - ID
              - REPORT_DATE
              - COUNTRY_CODE
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: ID
        description: Ad Internal ID (A hashed concatenation of EXTERNAL_ID and PLATFORM)
        tests:
          - not_null
      - name: EXTERNAL_ID
        description: Ad External ID
        tests:
          - not_null
      - name: REPORT_DATE
        description: Report Date
        tests:
          - not_null
      - name: COUNTRY_CODE
        description: Tiktok Ad Country (ISO2 or UNKNOWN)
        tests:
          - not_null
      - name: NAME
        description: Ad Name
        tests:
          - not_null
      - name: STATUS
        description: Ad Status
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'ACTIVE', 'PAUSED', 'DELETED', 'ARCHIVED', 'ENABLE', 'DISABLE', 'FROZEN' ]
      - name: EFFECTIVE_STATUS
        description: Ad Effective Status
        tests:
          - not_null
      - name: CREATIVE_ID
        description: Creative ID
      - name: CREATIVE_ORIGINAL_THUMBNAIL_URL
        description: Creative thumbnail URL from the platform CDN. Expires in a few days after being synced from Fivetran.
      - name: CREATIVE_IMAGE_URL
        description: Ad Creative original Ad Image URL. It is present when a Creative is an Image uploaded directly to Ads Manager.
      - name: CREATIVE_VIDEO_URL
        description: Ad Creative original Ad Video URL. It is present when a Creative is a Video uploaded directly to Ads Manager.
      - name: CREATIVE_POST_URL
        description: Platform post URL. It is present when a Creative is a boosted post. Leads to Instagram posts for META.
      - name: TARGET_URL
        description: Platform post URL.
      - name: ACCOUNT_ID
        description: Account ID
        tests:
          - not_null
      - name: CAMPAIGN_ID
        description: Campaign ID (UUID)
        tests:
          - not_null
      - name: CAMPAIGN_NAME
        description: Campaign name
        tests:
          - not_null
      - name: CAMPAIGN_GLOBAL_PARTICIPANT_ID
        description: Campaign Global Participant ID
      - name: CAMPAIGN_OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: AD_SET_ID
        description: Ad Set ID (UUID)
        tests:
          - not_null
      - name: AD_SET_NAME
        description: Ad Set name
        tests:
          - not_null
      - name: AD_SET_START_AT
        description: Ad Set Start At timestamp
        tests:
          - not_null
      - name: AD_SET_END_AT
        description: Ad Set End At timestamp
        tests:
          - not_null
      - name: AD_SET_DAILY_BUDGET
        description: Ad Set Daily Budget
      - name: AD_SET_LIFETIME_BUDGET
        description: Ad Set Lifetime Budget
      - name: CAMPAIGN_DAILY_BUDGET
        description: Campaign Daily Budget
      - name: CAMPAIGN_LIFETIME_BUDGET
        description: Campaign Lifetime Budget
      - name: AD_SET_DAILY_BUDGET_USD
        description: Ad Set Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_DAILY_BUDGET is null"
      - name: AD_SET_LIFETIME_BUDGET_USD
        description: Ad Set Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "AD_SET_LIFETIME_BUDGET is null"
      - name: CAMPAIGN_DAILY_BUDGET_USD
        description: Campaign Daily Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_DAILY_BUDGET is null"
      - name: CAMPAIGN_LIFETIME_BUDGET_USD
        description: Campaign Lifetime Budget in USD
        tests:
          - not_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is not null"
          - is_null:
              arguments:
                where: "CAMPAIGN_LIFETIME_BUDGET is null"
      - name: TARGETING_COUNTRIES
        description: Targeting Countries ISO-2 country codes
        tests:
          - not_null
      - name: PUBLISHER_PLATFORMS
        description: Publishing platforms (e.g., facebook, instagram for Meta). Objective Value for Goolge, NULL for TikTok.
      - name: CURRENCY
        description: Currency code
        tests:
          - not_null
      - name: CLICKS
        description: Ad Total Clicks
        tests:
          - not_null
      - name: IMPRESSIONS
        description: Ad Impressions (the number of times the ad has been shown)
        tests:
          - not_null
      - name: REACH
        description: Ad Reach (the number of unique users who have seen the ad)
      - name: ESTIMATED_AD_RECALLERS
        description: |
          An estimate of the number of additional people who may remember seeing the ad, if asked, within 2 days
      - name: VIEWS_P25
        description: The number of times a video was played at 25% of its length.
        tests:
          - not_null
      - name: VIEWS_THRUPLAY
        description: The number of times a video was played to completion or at least 15 seconds
      - name: VIEWS_6S
        description: The number of times a video was played for at least 6 seconds.
      - name: VIEWS_FOCUSED_6S
        description: The number of times a video was played for at least 6 seconds or received at least 1 engagement within 1 day of the user seeing a paid ad.
      - name: VIEWS
        description: Value equal to a metric chosen to best represent Views on a given platform. Equal to VIEWS_THRUPLAY for Facebook Ads and VIEWS_FOCUSED_6S for TikTok Ads.
        tests:
          - not_null
      - name: PURCHASES
        description: The number of purchases of an advertised item.
      - name: POST_SHARES
        description: The number of post shares
      - name: POST_REACTIONS
        description: The number of post reactions
      - name: PAGE_LIKES
        description: The number of page likes
      - name: POST_COMMENTS
        description: The number of post comments
      - name: ORDERS_PLACED
        description: The number of Orders Placed.
      - name: FOLLOWS
        description: number of Tiktok Ad's generated follows
      - name: FREQUENCY
        description: Impressions / Reach
      - name: SPEND
        description: |
          Ad Total Spend at the moment (in the original monetary units specified by CURRENCY column, e.g. USD or EUR).
        tests:
          - not_null
      - name: SPEND_USD
        description: |
          Ad Total Spend at the moment (in USD, converted using The Orchard exchange rate from FACTS.PROD.DIM_CURRENCY).
        tests:
          - not_null
      - name: LIKES
        description: Likes metric.
      - name: RESULT
        description: Result metric.
      - name: COMPLETE_PAYMENT
        description: Complete Payment metric.
      - name: CHECKOUT
        description: Checkout metric.
      - name: AVERAGE_VIDEO_PLAY
        description: AVerage Video Play metric.
      - name: SHARES
        description: TikTok Ads Shares
      - name: COMMENTS
        description: TikTok Ads Comments
      - name: PROFILE_VISITS
        description: TikTok Ads Profile Visits
      - name: CLICKS_ON_MUSIC
        description: TikTok Ads Music Clicks
      - name: COST_PER_ACTION
        description: Cost Per Action
        tests:
          - not_null
      - name: COST_PER_ACTION_USD
        description: Cost Per Action in USD
        tests:
          - not_null
      - name: COST_PER_IMPRESSION
        description: Cost Per Impression
        tests:
          - not_null
      - name: COST_PER_IMPRESSION_USD
        description: Cost Per Impression in USD
        tests:
          - not_null
      - name: ACTION_TYPE
        description: Action Type Name
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CLICKS', 'VIEWS', 'PURCHASES', 'EAR', 'FOLLOWS', 'REACH', 'ORDERS_PLACED' ]
      - name: ACTIONS
        description: Actions value
        tests:
          - not_null
      - name: RATE_TYPE
        description: Rate Type
        tests:
          - not_null
          - accepted_values:
              arguments:
                values: [ 'CTR', 'VTR', 'CR', 'EARR', 'FR', 'FREQUENCY' ]
      - name: RATE
        description: Rate Value
        tests:
          - not_null
      - name: CTR
        description: Click Through Rate
      - name: SYNCED_AT
        description: A timestamp of the last ad performance data synced from Fivetran
        tests:
          - not_null
      - name: MIN_REPORT_DATE
        description: The earliest report date for this entity
      - name: MAX_REPORT_DATE
        description: The latest report date for this entity
  - name: AD_REPORTING_CAMPAIGN_BENCHMARK_BY_ACCOUNT_DBT
    description: Benchmark values of Meta Campaign performance by Account and Objective
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - VENDOR_ID
              - SUBACCOUNT_ID
              - PLATFORM
              - OBJECTIVE
    columns:
      - name: VENDOR_ID
        description: Vendor ID
        tests:
          - not_null
      - name: SUBACCOUNT_ID
        description: Subaccount ID
        tests:
          - not_null
      - name: PLATFORM
        description: Platform
        tests:
          - not_null
      - name: OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: RATE
        description: Average rate for all Campaigns given an objective (weighted by Actions)
        tests:
          - not_null
      - name: CTR
        description: Click Through Rate
  - name: AD_REPORTING_CAMPAIGN_BENCHMARK_BY_ACCOUNT_COUNTRY_DBT
    description: Benchmark values of Meta Campaign performance by Account, Objective and Country
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - VENDOR_ID
              - SUBACCOUNT_ID
              - COUNTRY_CODE
              - PLATFORM
              - OBJECTIVE
    columns:
      - name: VENDOR_ID
        description: Vendor ID
        tests:
          - not_null
      - name: SUBACCOUNT_ID
        description: Subaccount ID
        tests:
          - not_null
      - name: COUNTRY_CODE
        description: Ad Country (ISO2 or UNKNOWN)
        tests:
          - not_null
      - name: PLATFORM
        description: Platform
        tests:
          - not_null
      - name: OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: RATE
        description: Average rate for all Campaigns given an objective (weighted by Actions)
        tests:
          - not_null
      - name: CTR
        description: Click Through Rate
  - name: AD_REPORTING_CAMPAIGN_BENCHMARK_BY_ACCOUNT_ARTIST_DBT
    description: Benchmark values of Ad Campaign performance by Account, Global Participant and Objective
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - VENDOR_ID
              - SUBACCOUNT_ID
              - GLOBAL_PARTICIPANT_ID
              - PLATFORM
              - OBJECTIVE
    columns:
      - name: VENDOR_ID
        description: Vendor ID
        tests:
          - not_null
      - name: SUBACCOUNT_ID
        description: Subaccount ID
        tests:
          - not_null
      - name: GLOBAL_PARTICIPANT_ID
        description: Global Participant ID
        tests:
          - not_null
      - name: PLATFORM
        description: Platform
        tests:
          - not_null
      - name: OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: RATE
        description: Average rate for all Campaigns given an objective (weighted by Actions)
        tests:
          - not_null
      - name: CTR
        description: Click Through Rate
  - name: AD_REPORTING_CAMPAIGN_BENCHMARK_BY_ACCOUNT_ARTIST_COUNTRY_DBT
    description: Benchmark values of Ad Campaign performance by Account, Global Participant, Objective and Country
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - VENDOR_ID
              - SUBACCOUNT_ID
              - GLOBAL_PARTICIPANT_ID
              - COUNTRY_CODE
              - PLATFORM
              - OBJECTIVE
    columns:
      - name: VENDOR_ID
        description: Vendor ID
        tests:
          - not_null
      - name: SUBACCOUNT_ID
        description: Subaccount ID
        tests:
          - not_null
      - name: GLOBAL_PARTICIPANT_ID
        description: Global Participant ID
        tests:
          - not_null
      - name: COUNTRY_CODE
        description: Ad Country (ISO2 or UNKNOWN)
        tests:
          - not_null
      - name: PLATFORM
        description: Platform
        tests:
          - not_null
      - name: OBJECTIVE
        description: Campaign Objective
        tests:
          - not_null
      - name: RATE
        description: Average rate for all Campaigns given an objective (weighted by Actions)
        tests:
          - not_null
      - name: CTR
        description: Click Through Rate
  - name: AD_REPORTING_SOURCE_SCHEMA_ACCOUNT_DBT
    description: A mapping table between a current state of source schema, ad account and vendor relations
    tests:
      - dbt_utils.unique_combination_of_columns:
          arguments:
            combination_of_columns:
              - SOURCE_SCHEMA
              - AD_ACCOUNT_ID
              - VENDOR_ID
    columns:
      - name: SOURCE_SCHEMA
        description: Source Fivetran schema.
        tests:
          - not_null
      - name: Platform
        description: Platform
        tests:
          - not_null
      - name: PLATFORM
        description: Platform
        tests:
          - not_null
      - name: AD_ACCOUNT_ID
        description: External Ad Account ID
        tests:
          - not_null
      - name: VENDOR_ID
        description: Vendor ID
        tests:
          - not_null
      - name: VENDOR_NAME
        description: Vendor Name
        tests:
          - not_null
      - name: BRAND_NAME
        description: Brand Name
        tests:
          - not_null
