Get Contextual Segments

Get a list of available Contextual Segments for the specified account - e.g. in order to apply Contextual Targeting.

Examples

No filters applied

GET <<server_url>>/backstage/api/1.0/demo-account/dictionary/contextual_segments/
{
    "results": [
        {
            "id": 1900037,
            "provider": "Taboola",
            "label": "Contextual > Art and Entertainment > Books and Literature",
            "description": "Target articles on Taboola publisher network that talk about books and literature",
            "taxonomy": "CONTEXTUAL>ALL",
            "allowed_countries": "AU,IN,JP,US",
            "size": 28590
        },
        {
            "id": 1900024,
            "provider": "Taboola",
            "label": "Contextual > Art and Entertainment > Comics and Animation",
            "description": "Target articles on Taboola publisher network that talk about comics and animation",
            "taxonomy": "CONTEXTUAL>ALL",
            "allowed_countries": "BR,DE,AU,IN,JP,MX,GB,CA,US",
            "size": 59105
        }
        // Additional rows omitted
    ],
    "metadata": {
        // Fields omitted
    }
}

🚧

The payload for this endpoint is typically large.

Filter by 1 or more countries

Filter using the countryCodes query param:

GET <<server_url>>/backstage/api/1.0/demo-account/dictionary/contextual_segments?countryCodes=DE,AU
{
    "results": [
        {
            "id": 1900037,
            "provider": "Taboola",
            "label": "Contextual > Art and Entertainment > Books and Literature",
            "description": "Target articles on Taboola publisher network that talk about books and literature",
            "taxonomy": "CONTEXTUAL>ALL",
            "allowed_countries": "AU,IN,JP,US",
            "size": 28590
        },
        {
            "id": 1900024,
            "provider": "Taboola",
            "label": "Contextual > Art and Entertainment > Comics and Animation",
            "description": "Target articles on Taboola publisher network that talk about comics and animation",
            "taxonomy": "CONTEXTUAL>ALL",
            "allowed_countries": "BR,DE,AU,IN,JP,MX,GB,CA,US",
            "size": 59105
        }
        // Additional rows omitted  
    ]    
    "metadata": {
        // Fields omitted      
    }
}

🚧

Invalid account_id

If you pass an account_id or countryCode that does not exist, the endpoint will return a successful response with an empty collection.

{
    "results": [],
    "metadata": {
        "total": null,
        "count": null,
        "static_fields": [],
        "static_total_fields": []
    }
}
Language
Authentication
OAuth2
Click Try It! to start a request and see the response here!