Hi, Twitter community
Twitter ads tv-markets API returns duplicate records in response. Is that an issue in the API or is there any primary key by which we can identify unique records across the response?

Thanks for reporting this. Could you post the response and identify the duplicates to help us investigate?

1 Like

Sorry, for the late reply. I am adding the JSON response below.
You can find the following record 2 times in the JSON response,

        {
            "name": "United States",
            "country_code": "US",
            "locale": "en-US"
        }

There are many more duplicate records available. And with key en-US you can find a total of 3 records. @osowskit1 Can you please suggest any primary key by which we can identify unique records across the response?

{
    "data": [
        {
            "name": "United States",
            "country_code": "US",
            "locale": "en-US"
        },
        {
            "name": "Germany",
            "country_code": "DE",
            "locale": "de-DE"
        },
        {
            "name": "Italy",
            "country_code": "IT",
            "locale": "it-IT"
        },
        {
            "name": "Argentina",
            "country_code": "AR",
            "locale": "es-AR"
        },
        {
            "name": "Brazil",
            "country_code": "BR",
            "locale": "pt-BR"
        },
        {
            "name": "United Kingdom",
            "country_code": "GB",
            "locale": "en-GB"
        },
        {
            "name": "Canada",
            "country_code": "CA",
            "locale": "en-CA"
        },
        {
            "name": "United States - Hispanic",
            "country_code": "US",
            "locale": "es-US"
        },
        {
            "name": "France",
            "country_code": "FR",
            "locale": "fr-FR"
        },
        {
            "name": "United States",
            "country_code": "US",
            "locale": "en-US"
        },
        {
            "name": "Japan",
            "country_code": "JP",
            "locale": "ja-JP"
        },
        {
            "name": "Ireland",
            "country_code": "IE",
            "locale": "en-IE"
        },
        {
            "name": "Mexico",
            "country_code": "MX",
            "locale": "es-MX"
        },
        {
            "name": "Austria",
            "country_code": "AT",
            "locale": "de-AT"
        },
        {
            "name": "Ireland",
            "country_code": "IE",
            "locale": "en-IE"
        },
        {
            "name": "Colombia",
            "country_code": "CO",
            "locale": "es-CO"
        },
        {
            "name": "Peru",
            "country_code": "PE",
            "locale": "es-PE"
        },
        {
            "name": "Chile",
            "country_code": "CL",
            "locale": "es-CL"
        },
        {
            "name": "Ecuador",
            "country_code": "EC",
            "locale": "es-EC"
        },
        {
            "name": "United Kingdom",
            "country_code": "GB",
            "locale": "en-GB"
        },
        {
            "name": "Venezuela",
            "country_code": "VE",
            "locale": "es-VE"
        },
        {
            "name": "Kuwait",
            "country_code": "KW",
            "locale": "ar-KW"
        },
        {
            "name": "UAE",
            "country_code": "AE",
            "locale": "ar-AE"
        },
        {
            "name": "Egypt",
            "country_code": "EG",
            "locale": "ar-EG"
        },
        {
            "name": "Saudi Arabia",
            "country_code": "SA",
            "locale": "ar-SA"
        },
        {
            "name": "Netherlands",
            "country_code": "NL",
            "locale": "nl-NL"
        },
        {
            "name": "Belgium",
            "country_code": "BE",
            "locale": "nl-BE"
        },
        {
            "name": "Uruguay",
            "country_code": "UY",
            "locale": "es-UY"
        },
        {
            "name": "Turkey",
            "country_code": "TR",
            "locale": "tr-TR"
        },
        {
            "name": "South Africa",
            "country_code": "ZA",
            "locale": "en-ZA"
        },
        {
            "name": "Canada",
            "country_code": "CA",
            "locale": "en-CA"
        },
        {
            "name": "India",
            "country_code": "IN",
            "locale": "en-IN"
        },
        {
            "name": "All",
            "country_code": "US",
            "locale": "en-US"
        },
        {
            "name": "United States - Hispanic",
            "country_code": "US",
            "locale": "es-US"
        },
        {
            "name": "Brazil",
            "country_code": "BR",
            "locale": "pt-BR"
        },
        {
            "name": "France",
            "country_code": "FR",
            "locale": "fr-FR"
        },
        {
            "name": "Spain",
            "country_code": "ES",
            "locale": "es-ES"
        },
        {
            "name": "Australia",
            "country_code": "AU",
            "locale": "en-AU"
        },
        {
            "name": "Japan",
            "country_code": "JP",
            "locale": "ja-JP"
        }
    ],
    "request": {
        "params": {}
    }
}

Thank you for reporting this. I’ve logged a bug with our engineering team to avoid returning duplicate records

Hi, @osowskit1 Is there any update on duplicate records in the response of tv-markets API?

I’ve reported the issue to the engineering team. I would recommend ignoring duplicate entries if this is causing advertisers confusion.

We also have this problem.