Skip to main content

Talkwalker Sources/Authors panels API

Overview

A panel is a list of sources or authors that can be used to filter articles. The list can contain included and excluded elements. A panel can be part of a group.

Definition of a panel

The definition of a panel consists of the following parameters:

Fields of a panel
parameterdescriptionrequired?values
idunique panel IDoptionalgenerated automatically if absent or left empty
titlepanel titlerequired
descriptionpanel descriptionoptional
colorcolor of the panel on the platformoptional
group_idpanel group IDrequired if category_title is absentungrouped_source_panels_group will be used for ungrouped panels if absent.
included_entriesspecifies authors or sources included in the paneloptionalSee the format in the table below.
excluded_entriesspecifies authors or sources excluded from the paneloptionalSee the format in the table below.

Definition of an entry for a panel

Both included and excluded entries use the same structure:

Fields of a panel entry
parameterdescriptionrequired?values
entry_typeType of the panel's entry.requiredCould be an AUTHOR, a SOURCE or a URL.
idThe unique ID of the entry.requiredThe correct format includes the abbreviation of the given social media platform (ig = Instagram, tw = Twitter, fb = Facebook, yt = YouTube).
nameThe name of the entry.optional
urlURL of the entryOnly for entry_type="URL".
exact_matchIndicates whether the exact match is enabled.Only for entry_type="URL".true or false. Default value is false if absent.

Definition of a group of panels

The definition of a group consists of the following parameters:

Fields of a group
parameterdescriptionrequired?values
idUnique group ID.optionalgenerated automatically if absent or left empty.
titlegroup title.required

Retrieve all panels with their members

To get a list of groups and panels with their members, use the endpoint

Command
curl -XGET 'https://api.talkwalker.com/api/v2/talkwalker/p/<project_id>/source_panels/list'
Response
{
"status_code": "0",
"status_message": "OK",
"request": "GET /api/v2/talkwalker/p/<project_id>/source_panels/list?access_token=<access_token>",
"request_id": "#rwk2pw5knlde#",
"result_source_panels": {
"data": [
{
"group": {
"id": "predefined",
"title": "Predefined",
"panels": [
{
"id": "blocked"
},
{
"id": "favourites",
"included_entries": [
{
"id": "ex:www.example_tw_dm.com-995396628",
"entry_type": "AUTHOR",
"site": "ex",
"name": "Pascal"
}
]
},
{
"id": "star1",
"included_entries": [
{
"id": "ex:www.example_tw_dm.com-792524346",
"entry_type": "AUTHOR",
"site": "ex",
"name": "Pascal2"
}
]
},
{
"id": "star2"
},
{
"id": "star3"
}
]
}
},
{
"group": {
"id": "ungrouped",
"title": "Ungrouped",
"panels": [
{
"id": "<panel_id>",
"title": "API Panel demo",
"description": "test by API",
"color": "#596275",
"included_entries": [
{
"entry_type": "URL",
"site": "ex",
"url": "www.testme.com",
"exact_match": false
},
{
"id": "tw:234",
"entry_type": "AUTHOR",
"site": "tw",
"name": "Pascal bird 234"
}
]
},
{
"id": "<panel_id>",
"title": "test lu",
"description": "test",
"color": "#f7d794",
"included_entries": [
{
"entry_type": "URL",
"site": "ex",
"url": "www.wort.lu",
"exact_match": false
}
]
}
]
}
},
{
"group": {
"id": "<group_id>",
"title": "Twitter authors",
"panels": [
{
"id": "panel_id",
"title": "Tesla Authors",
"color": "#f7d794",
"included_entries": [
{
"id": "tw:1495956968640421893",
"entry_type": "AUTHOR",
"site": "tw",
"name": "Musk University | Quotes"
},
{
"id": "tw:116328126",
"entry_type": "AUTHOR",
"site": "tw",
"name": "Adam Cochran (adamscochran.eth)"
},
{
"id": "tw:132288724",
"entry_type": "AUTHOR",
"site": "tw",
"name": "Kirill Klip 🌎 ⚡️⛏ #Gold & #rEVolution 🔌🔋🚘"
}
]
}
]
}
}
]
}
}

Rate Limit

This endpoint is limited to 30 calls per minute.

Create a new group of panels

To create new groups of panels, you can use the endpoint

Command
curl -XPOST 'api.talkwalker.com/api/v2/talkwalker/p/<project_id>/source_panels/groups/add?access_token=<access_token>'
-d '<groups_definition>'
-H 'Content-Type: application/json; charset=UTF-8'
groups_definition
{
"groups": [
{
"title": "API group"
},
{
"title": "API group 2"
}
]
}
response
{
"status_code": "0",
"status_message": "OK",
"request": "POST /api/v2/talkwalker/p/<project_id>/source_panels/groups/add?access_token=<access_token>",
"request_id": "#rwk3dr8h7a0m#",
"result_source_panels": {
"data": [
{
"success": true,
"group": {
"id": "<group_id>",
"title": "API group"
}
},
{
"success": true,
"group": {
"id": "<group_id>",
"title": "API group 2"
}
}
]
}
}

Rate Limit

This endpoint is limited to 30 calls per minute.

Create a new panel

To create new source panels, you can use the endpoint

Command
curl -XPOST /api.talkwalker.com/api/v2/talkwalker/p/<project_id>/source_panels/add?access_token=<access_token>'
-d '<panel_definition>'
-H 'Content-Type: application/json; charset=UTF-8'
panel definition to create a new ungrouped panel
{
"panels": [
{
"title": "API Panel demo",
"description": "test by API",
"included_entries": [
{
"entry_type": "URL",
"url": "www.testme.com"
},
{
"entry_type": "AUTHOR",
"id": "tw:234",
"name": "Pascal bird 234"
}
]
}
]
}
Topic definition to create a new panel inside a group
{
"panels": [
{
"group_id": "<group_id>",
"title": "API Panel demo in a group",
"description": "test by API",
"included_entries": [
{
"entry_type": "URL",
"url": "www.testme.com"
},
{
"entry_type": "AUTHOR",
"id": "tw:234",
"name": "Pascal bird 234"
}
]
}
]
}
response
{
"status_code": "0",
"status_message": "OK",
"request": "POST /api/v2/talkwalker/p/<project_id>/source_panels/add?access_token=<access_token>",
"request_id": "#rwk2pg2tzi90#",
"result_source_panels": {
"data": [
{
"success": true,
"panel": {
"id": "<panel_id>",
"title": "API Panel demo",
"description": "test by API",
"color": "#596275",
"group_id": "ungrouped_source_panels_group",
"included_entries": [
{
"entry_type": "URL",
"site": "ex",
"url": "www.testme.com",
"exact_match": false
},
{
"id": "tw:234",
"entry_type": "AUTHOR",
"site": "tw",
"name": "Pascal bird 234"
}
]
}
}
]
}
}

Rate Limit

This endpoint is limited to 30 calls per minute.